forked from yystopf/xiuos
add test_net.c and modify makefile
This commit is contained in:
parent
514b9973b6
commit
59c1edce98
|
@ -22,11 +22,12 @@ INC_DIR = -I$(KERNEL_ROOT)/services/shell/letter-shell \
|
|||
-I$(KERNEL_ROOT)/services/lib/serial \
|
||||
-I$(KERNEL_ROOT)/services/lib/usyscall \
|
||||
-I$(KERNEL_ROOT)/services/fs/libfs \
|
||||
-I$(KERNEL_ROOT)/services/net/libnet \
|
||||
-I$(KERNEL_ROOT)/services/boards/$(BOARD) \
|
||||
-I$(KERNEL_ROOT)/services/app
|
||||
|
||||
ifeq ($(BOARD), imx6q-sabrelite)
|
||||
all: init test_fs simple_client simple_server shell fs_server test_irq_hdlr test_irq_block test_irq_send eth_driver epit_server readme.txt lwip | bin
|
||||
all: init test_fs simple_client simple_server shell fs_server test_irq_hdlr test_irq_block test_irq_send eth_driver epit_server readme.txt test_net lwip | bin
|
||||
else
|
||||
all: init test_fs simple_client simple_server shell fs_server test_irq_hdlr readme.txt | bin
|
||||
endif
|
||||
|
@ -88,6 +89,10 @@ test_priority: test_priority.o libserial.o printf.o usyscall.o arch_usyscall.o l
|
|||
@${ld} ${user_ldflags} -e main -o $@ $^ ${board_specs}
|
||||
@${objdump} -S $@ > $@.asm
|
||||
|
||||
test_net:test_fs.o lwip_service.o libipc.o session.o libserial.o printf.o usyscall.o arch_usyscall.o libmem.o
|
||||
@${ld} ${user_ldflags} -e main -o $@ $^ ${board_specs}
|
||||
@${objdump} -S $@ > $@.asm
|
||||
|
||||
%.o: %.c
|
||||
@${cc} ${cflags} ${c_useropts} ${INC_DIR} -o $@ -c $<
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
|
||||
// Block size
|
||||
#define BLOCK_SIZE 512
|
||||
#define NR_BIT_BLOCKS 2
|
||||
#define NR_BIT_BLOCKS 4
|
||||
|
||||
// bits size
|
||||
#define BITS 8
|
||||
|
|
|
@ -24,7 +24,7 @@ INC_DIR = -I$(KERNEL_ROOT)/services/net/libnet \
|
|||
-I$(KERNEL_ROOT)/services/app
|
||||
|
||||
net_server: lwip_service.o
|
||||
@mv $^ $(KERNEL_ROOT)/services/net/net_server
|
||||
@mv $^ $(KERNEL_ROOT)/services/app
|
||||
|
||||
%.o: %.c
|
||||
@echo "cc $^"
|
||||
|
|
|
@ -54,8 +54,7 @@ session = $(KERNEL_ROOT)/services/app/session.o
|
|||
libipc = $(KERNEL_ROOT)/services/app/libipc.o
|
||||
|
||||
lwip: COMPILER lwip_server.o | bin
|
||||
@${ld} ${user_ldflags} -e main -o $@ ${api} ${core} ${ipv4} ${netif} lwip_service.o lwip_server.o \
|
||||
${board_specs} ${libserial} ${printf} ${libmem} ${usyscall} ${arch_usyscall} ${session} ${libipc}
|
||||
@${ld} ${user_ldflags} -e main -o $@ ${api} ${core} ${ipv4} ${netif} lwip_server.o ${libserial} ${printf} ${libmem} ${usyscall} ${arch_usyscall} ${session} ${libipc} ${board_specs}
|
||||
@${objdump} -S $@ > $@.asm
|
||||
@mv *.o bin
|
||||
@mv $@ $(KERNEL_ROOT)/services/app
|
||||
|
|
|
@ -49,7 +49,7 @@ Modification:
|
|||
#define ROOT_INUM 1 // root inode number
|
||||
#define BLOCK_SIZE 512 // block size
|
||||
#define NR_BIT_PER_BYTE 8
|
||||
#define NR_BIT_BLOCKS 2
|
||||
#define NR_BIT_BLOCKS 4
|
||||
#define nr_blocks_total (BLOCK_SIZE * NR_BIT_PER_BYTE * NR_BIT_BLOCKS) // total number of blocks (including used blocks and free blocks)
|
||||
#define nr_inodes 200 // total number of inodes
|
||||
|
||||
|
|
Loading…
Reference in New Issue