Skip to contentSkip to conversation

minios: new version netfront driver

PATCH New Jacob Gorm Hansen 1 participant 1 message Jan 4, 2007

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 minios: new version netfront driver

The attached patch adds a netfront driver to mini-os. This version is much improved compared to the one previously posted (ie. it actually works this time).

Jacob

extras/mini-os/kernel.c +8 -0
diff -r 52ae8dd4bc75 extras/mini-os/kernel.c
@@ -36,6 +36,7 @@
 #include <sched.h>
 #include <xenbus.h>
 #include <gnttab.h>
+#include <netfront.h>
 #include <xen/features.h>
 #include <xen/version.h>
 
@@ -66,11 +67,18 @@ void xenbus_tester(void *p)
     /* test_xenbus(); */
 }
 
+void netfront_thread(void *p)
+{
+    init_netfront(&start_info);
+}
+
+
 /* This should be overridden by the application we are linked against. */
 __attribute__((weak)) int app_main(start_info_t *si)
 {
     printk("Dummy main: start_info=%p\n", si);
     create_thread("xenbus_tester", xenbus_tester, si);
+    create_thread("netfront", netfront_thread, si);
     return 0;
 }
 
extras/mini-os/include/netfront.h new file +2 -0
diff -r 52ae8dd4bc75 extras/mini-os/include/netfront.h
@@ -0,0 +1,2 @@
+void init_netfront(void*);
+void netfront_xmit(unsigned char* data,int len);
extras/mini-os/netfront.c new file +455 -0

455 lines not on this page · raw message

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel