Palacios Public Git Repository

To checkout Palacios execute

  git clone http://v3vee.org/palacios/palacios.web/palacios.git
This will give you the master branch. You probably want the devel branch or one of the release branches. To switch to the devel branch, simply execute
  cd palacios
  git checkout --track -b devel origin/devel
The other branches are similar.


added network subsystem
Jack Lange [Tue, 16 Sep 2008 19:25:03 +0000 (19:25 +0000)]
palacios/include/geekos/net.h [new file with mode: 0644]
palacios/src/geekos/net.c [new file with mode: 0644]

diff --git a/palacios/include/geekos/net.h b/palacios/include/geekos/net.h
new file mode 100644 (file)
index 0000000..dbb7741
--- /dev/null
@@ -0,0 +1,15 @@
+#ifndef __NET_H__
+#define __NET_H__
+
+
+
+void Init_Network();
+
+
+void test_network();
+
+
+
+
+
+#endif
diff --git a/palacios/src/geekos/net.c b/palacios/src/geekos/net.c
new file mode 100644 (file)
index 0000000..8c5c024
--- /dev/null
@@ -0,0 +1,32 @@
+#include <geekos/net.h>
+#include <geekos/socket.h>
+#include <geekos/ne2k.h>
+
+void Init_Network() {
+  init_socket_layer();
+}
+
+
+
+
+void test_network() {
+
+    uchar_t local_addr[4];
+    uchar_t remote_addr[4];
+
+    local_addr[0] = 10;
+    local_addr[1] = 0;
+    local_addr[2] = 2;
+    local_addr[3] = 21;
+
+    set_ip_addr(local_addr);
+
+    remote_addr[0] = 10;
+    remote_addr[1] = 0;
+    remote_addr[2] = 2;
+    remote_addr[3] = 20;
+
+
+    connect(remote_addr, 4301);
+
+}