* [Qemu-devel] define sock_type (patch for HOST_MIPS)
@ 2007-06-23 14:37 Jun Peng
0 siblings, 0 replies; only message in thread
From: Jun Peng @ 2007-06-23 14:37 UTC (permalink / raw)
To: qemu-devel
[-- Attachment #1: Type: text/plain, Size: 68 bytes --]
Hello.
This patch is made for HOST_MIPS, to fix a sock_type error.
[-- Attachment #2: qemu-20070623-socket.patch --]
[-- Type: text/plain, Size: 1049 bytes --]
diff -Nurb qemu-20070623/linux-user/socket.h qemu-loongson/linux-user/socket.h
--- qemu-20070623/linux-user/socket.h 2006-06-24 23:06:03.000000000 +0800
+++ qemu-loongson/linux-user/socket.h 2007-06-23 21:44:48.000000000 +0800
@@ -135,4 +135,14 @@
#define TARGET_SO_PEERSEC 31
+ enum sock_type {
+ TARGET_SOCK_STREAM = 1,
+ TARGET_SOCK_DGRAM = 2,
+ TARGET_SOCK_RAW = 3,
+ TARGET_SOCK_RDM = 4,
+ TARGET_SOCK_SEQPACKET = 5,
+ //TARGET_SOCK_DCCP = 6,
+ TARGET_SOCK_PACKET = 10,
+ };
+
#endif
diff -Nurb qemu-20070623/linux-user/syscall.c qemu-loongson/linux-user/syscall.c
--- qemu-20070623/linux-user/syscall.c 2007-06-23 16:39:14.000000000 +0800
+++ qemu-loongson/linux-user/syscall.c 2007-06-23 21:44:48.000000000 +0800
@@ -869,7 +869,7 @@
static long do_socket(int domain, int type, int protocol)
{
-#if defined(TARGET_MIPS)
+#if defined(TARGET_MIPS) || defined(HOST_MIPS)
switch(type) {
case TARGET_SOCK_DGRAM:
type = SOCK_DGRAM;
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2007-06-23 14:37 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-23 14:37 [Qemu-devel] define sock_type (patch for HOST_MIPS) Jun Peng
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).