sbcv2: turn on networking support options
authorAlan Cox <alan@linux.intel.com>
Fri, 7 Sep 2018 01:32:56 +0000 (02:32 +0100)
committerAlan Cox <alan@linux.intel.com>
Fri, 7 Sep 2018 01:32:56 +0000 (02:32 +0100)
Kernel/platform-sbcv2/Makefile
Kernel/platform-sbcv2/config.h
Kernel/platform-sbcv2/discard.c
Kernel/platform-sbcv2/fuzix.lnk
Kernel/platform-sbcv2/main.c

index 46109a8..2b8e51b 100644 (file)
@@ -1,4 +1,4 @@
-CROSS_CCOPTS += -I../dev/
+CROSS_CCOPTS += -I../dev/ -I../dev/net/
 
 
 CSRCS = devtty.c
@@ -13,11 +13,10 @@ DISCARD_DSRCS = ../dev/devide_discard.c
 DSRCS = ../dev/blkdev.c ../dev/devide.c ../dev/mbr.c ../dev/ds1302_discard.c
 DSRCS += ../dev/propio2.c ../dev/ds1302.c
 DSRCS += ../dev/devfd.c ../dev/ppide_rbc.c
+NSRCS = ../dev/net/net_wiznet.c ../dev/net/net_native.c
 
 DASRCS = ../dev/rbcfd9266_hw.s ../dev/ds1302_rbc.s
 
-NSRCS = 
-
 COBJS = $(CSRCS:.c=.rel)
 AOBJS = $(ASRCS:.s=.rel)
 NOBJS = $(patsubst ../dev/net/%.c,%.rel, $(NSRCS))
index 7f804c9..91e8fe8 100644 (file)
@@ -98,6 +98,13 @@ extern unsigned int swap_dev;
  */
 #define TICKSPERSEC 10     /* Ticks per second */
 
+/* Core networking support */
+#define CONFIG_NET
+/* With a WizNet card */
+#define CONFIG_NET_WIZNET
+/* Or native (eg SLIP) */
+//#define CONFIG_NET_NATIVE
+
 /*
  *     The device (major/minor) for the console and boot up tty attached to
  *     init at start up. 512 is the major 2, so all the tty devices are
index 2df9d4b..127dcf5 100644 (file)
@@ -6,7 +6,7 @@
 #include <blkdev.h>
 #include <devide.h>
 #include <propio2.h>
-#include <devrtc.h>
+#include <ds1302.h>
 
 extern int strcmp(const char *, const char *);
 
@@ -90,4 +90,5 @@ void device_init(void)
        devide_init();
        prop_sd_probe();
        ds1302_init();
+       sock_init();
 }
index 853a4ff..2cbf8aa 100644 (file)
@@ -27,6 +27,7 @@ syscall_fs2.rel
 syscall_fs3.rel
 syscall_proc.rel
 syscall_other.rel
+syscall_net.rel
 tty.rel
 mm.rel
 swap.rel
@@ -44,4 +45,6 @@ platform-sbcv2/ds1302_discard.rel
 platform-sbcv2/ds1302_rbc.rel
 platform-sbcv2/devfd.rel
 platform-sbcv2/rbcfd9266_hw.rel
+platform-sbcv2/net_native.rel
+platform-sbcv2/net_wiznet.rel
 -e
index fdb4e2f..e4df431 100644 (file)
@@ -5,6 +5,7 @@
 #include <devtty.h>
 #include <rtc.h>
 #include <ds1302.h>
+#include <net_wiznet.h>
 
 uint16_t ramtop = PROGTOP;
 uint16_t swap_dev = 0xFFFF;
@@ -42,6 +43,9 @@ void platform_idle(void)
 void platform_interrupt(void)
 {
        tty_poll();
+#ifdef CONFIG_NET_WIZNET
+       wiz_poll();
+#endif
 }
 
 /* This points to the last buffer in the disk buffers. There must be at least