summaryrefslogtreecommitdiff
path: root/pfinet/linux-src/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'pfinet/linux-src/include/linux')
-rw-r--r--pfinet/linux-src/include/linux/net.h12
-rw-r--r--pfinet/linux-src/include/linux/rtnetlink.h8
2 files changed, 15 insertions, 5 deletions
diff --git a/pfinet/linux-src/include/linux/net.h b/pfinet/linux-src/include/linux/net.h
index 63e996f9..da193dcc 100644
--- a/pfinet/linux-src/include/linux/net.h
+++ b/pfinet/linux-src/include/linux/net.h
@@ -65,8 +65,14 @@ struct socket
unsigned long flags;
struct proto_ops *ops;
struct inode *inode;
+#ifdef _HURD_
+ uint_fast32_t refcnt; /* # of sock_user's pointing to this */
+ mach_port_t identity; /* for io_identity */
+ struct file; /* forward decl magic */
+#else
struct fasync_struct *fasync_list; /* Asynchronous wake up list */
struct file *file; /* File back pointer for gc */
+#endif
struct sock *sk;
struct wait_queue *wait;
@@ -103,12 +109,12 @@ struct proto_ops {
int (*getsockopt) (struct socket *sock, int level, int optname,
char *optval, int *optlen);
int (*fcntl) (struct socket *sock, unsigned int cmd,
- unsigned long arg);
+ unsigned long arg);
int (*sendmsg) (struct socket *sock, struct msghdr *m, int total_len, struct scm_cookie *scm);
int (*recvmsg) (struct socket *sock, struct msghdr *m, int total_len, int flags, struct scm_cookie *scm);
};
-struct net_proto_family
+struct net_proto_family
{
int family;
int (*create)(struct socket *sock, int protocol);
@@ -119,7 +125,7 @@ struct net_proto_family
short encrypt_net;
};
-struct net_proto
+struct net_proto
{
const char *name; /* Protocol name */
void (*init_func)(struct net_proto *); /* Bootstrap */
diff --git a/pfinet/linux-src/include/linux/rtnetlink.h b/pfinet/linux-src/include/linux/rtnetlink.h
index b339f652..2b5d6efa 100644
--- a/pfinet/linux-src/include/linux/rtnetlink.h
+++ b/pfinet/linux-src/include/linux/rtnetlink.h
@@ -49,7 +49,7 @@
#define RTM_MAX (RTM_BASE+31)
-/*
+/*
Generic structure for encapsulation optional route information.
It is reminiscent of sockaddr, but with sa_family replaced
with attribute type.
@@ -90,7 +90,7 @@ struct rtmsg
unsigned char rtm_table; /* Routing table id */
unsigned char rtm_protocol; /* Routing protocol; see below */
- unsigned char rtm_scope; /* See below */
+ unsigned char rtm_scope; /* See below */
unsigned char rtm_type; /* See below */
unsigned rtm_flags;
@@ -636,15 +636,19 @@ extern __inline__ void rtnl_exunlock(void)
extern __inline__ void rtnl_shlock(void)
{
+#ifndef _HURD_
while (atomic_read(&rtnl_rlockct))
sleep_on(&rtnl_wait);
atomic_inc(&rtnl_rlockct);
+#endif
}
extern __inline__ void rtnl_shunlock(void)
{
+#ifndef _HURD_
if (atomic_dec_and_test(&rtnl_rlockct))
wake_up(&rtnl_wait);
+#endif
}
extern __inline__ void rtnl_exlock(void)