Skip to contentSkip to conversation

Sync with 2.6.19 kernel header about include/linux.

PATCH In review Masahide NAKAMURA 3 participants 6 messages Dec 5, 2006

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/7 Sync with 2.6.19 kernel header about include/linux.

---
 include/linux/fib_rules.h                |    3 
 include/linux/genetlink.h                |   18 +
 include/linux/if_addr.h                  |   55 +++
 include/linux/if_link.h                  |  136 ++++++++
 include/linux/inet_diag.h                |   26 +
 include/linux/neighbour.h                |  159 +++++++++
 include/linux/netfilter_ipv4/ip_tables.h |  238 +++++++------
 include/linux/netlink.h                  |  109 ++++++
 include/linux/pkt_cls.h                  |    1 
 include/linux/rtnetlink.h                |  532 ++++++++++--------------------
 include/linux/socket.h                   |   20 +
 include/linux/tcp.h                      |  244 +++++++++++++-
 include/linux/types.h                    |  202 +++++++++++
 include/linux/xfrm.h                     |   55 +++
 14 files changed, 1294 insertions(+), 504 deletions(-)
include/linux/fib_rules.h +1 -2
index 8270aac..4418c8d 100644
@@ -6,7 +6,6 @@ #include <linux/rtnetlink.h>
 
 /* rule is permanent, and cannot be deleted */
 #define FIB_RULE_PERMANENT	1
-#define FIB_RULE_INVERT		2
 
 struct fib_rule_hdr
 {
@@ -35,7 +34,7 @@ enum
 	FRA_UNUSED3,
 	FRA_UNUSED4,
 	FRA_UNUSED5,
-	FRA_FWMARK,	/* mark */
+	FRA_FWMARK,	/* netfilter mark */
 	FRA_FLOW,	/* flow/class id */
 	FRA_UNUSED6,
 	FRA_UNUSED7,
include/linux/genetlink.h +18 -0
index 84f12a4..9049dc6 100644
@@ -16,6 +16,8 @@ struct genlmsghdr {
 
 #define GENL_HDRLEN	NLMSG_ALIGN(sizeof(struct genlmsghdr))
 
+#define GENL_ADMIN_PERM		0x01
+
 /*
  * List of reserved static generic netlink identifiers:
  */
@@ -43,9 +45,25 @@ enum {
 	CTRL_ATTR_UNSPEC,
 	CTRL_ATTR_FAMILY_ID,
 	CTRL_ATTR_FAMILY_NAME,
+	CTRL_ATTR_VERSION,
+	CTRL_ATTR_HDRSIZE,
+	CTRL_ATTR_MAXATTR,
+	CTRL_ATTR_OPS,
 	__CTRL_ATTR_MAX,
 };
 
 #define CTRL_ATTR_MAX (__CTRL_ATTR_MAX - 1)
 
+enum {
+	CTRL_ATTR_OP_UNSPEC,
+	CTRL_ATTR_OP_ID,
+	CTRL_ATTR_OP_FLAGS,
+	CTRL_ATTR_OP_POLICY,
+	CTRL_ATTR_OP_DOIT,
+	CTRL_ATTR_OP_DUMPIT,
+	__CTRL_ATTR_OP_MAX,
+};
+
+#define CTRL_ATTR_OP_MAX (__CTRL_ATTR_OP_MAX - 1)
+
 #endif	/* __LINUX_GENERIC_NETLINK_H */
include/linux/if_addr.h new file +55 -0

55 lines not on this page · raw message

include/linux/if_link.h new file +136 -0

136 lines not on this page · raw message

include/linux/inet_diag.h +21 -5
index 85d456d..6e8bc54 100644
@@ -9,10 +9,10 @@ #define INET_DIAG_GETSOCK_MAX 24
 
 /* Socket identity */
 struct inet_diag_sockid {
-	__u16	idiag_sport;
-	__u16	idiag_dport;
-	__u32	idiag_src[4];
-	__u32	idiag_dst[4];
+	__be16	idiag_sport;
+	__be16	idiag_dport;
+	__be32	idiag_src[4];
+	__be32	idiag_dst[4];
 	__u32	idiag_if;
 	__u32	idiag_cookie[2];
 #define INET_DIAG_NOCOOKIE (~0U)
@@ -67,7 +67,7 @@ struct inet_diag_hostcond {
 	__u8	family;
 	__u8	prefix_len;
 	int	port;
-	__u32	addr[0];
+	__be32	addr[0];
 };
 
 /* Base info structure. It contains socket identity (addrs/ports/cookie)
@@ -118,5 +118,21 @@ struct tcpvegas_info {
 	__u32	tcpv_minrtt;
 };
 
+#ifdef __KERNEL__
+struct sock;
+struct inet_hashinfo;
+
+struct inet_diag_handler {
+	struct inet_hashinfo    *idiag_hashinfo;
+	void			(*idiag_get_info)(struct sock *sk,
+						  struct inet_diag_msg *r,
+						  void *info);
+	__u16                   idiag_info_size;
+	__u16                   idiag_type;
+};
+
+extern int  inet_diag_register(const struct inet_diag_handler *handler);
+extern void inet_diag_unregister(const struct inet_diag_handler *handler);
+#endif /* __KERNEL__ */
 
 #endif /* _INET_DIAG_H_ */
include/linux/neighbour.h new file +159 -0

159 lines not on this page · raw message

include/linux/netfilter_ipv4/ip_tables.h +116 -122

308 lines not on this page · raw message

include/linux/netlink.h +109 -0

120 lines not on this page · raw message

include/linux/pkt_cls.h +1 -0
index bd2c5a2..c3f01b3 100644
@@ -305,6 +305,7 @@ enum
 	TCA_FW_POLICE,
 	TCA_FW_INDEV, /*  used by CONFIG_NET_CLS_IND */
 	TCA_FW_ACT, /* used by CONFIG_NET_CLS_ACT */
+	TCA_FW_MASK,
 	__TCA_FW_MAX
 };
 
include/linux/rtnetlink.h +176 -356

584 lines not on this page · raw message

include/linux/socket.h +19 -1
index 33bfe70..3614090 100644
@@ -103,7 +103,9 @@ #define CMSG_OK(mhdr, cmsg) ((cmsg)->cms
  *	This mess will go away with glibc
  */
  
-#if    defined(__GNUC__) 
+#ifdef __KERNEL__
+#define __KINLINE static inline
+#elif  defined(__GNUC__) 
 #define __KINLINE static __inline__
 #elif defined(__cplusplus)
 #define __KINLINE static inline
@@ -283,5 +285,21 @@ #define SOL_TIPC	271
 /* IPX options */
 #define IPX_TYPE	1
 
+#ifdef __KERNEL__
+extern int memcpy_fromiovec(unsigned char *kdata, struct iovec *iov, int len);
+extern int memcpy_fromiovecend(unsigned char *kdata, struct iovec *iov, 
+				int offset, int len);
+extern int csum_partial_copy_fromiovecend(unsigned char *kdata, 
+					  struct iovec *iov, 
+					  int offset, 
+					  unsigned int len, int *csump);
+
+extern int verify_iovec(struct msghdr *m, struct iovec *iov, char *address, int mode);
+extern int memcpy_toiovec(struct iovec *v, unsigned char *kdata, int len);
+extern int move_addr_to_user(void *kaddr, int klen, void __user *uaddr, int __user *ulen);
+extern int move_addr_to_kernel(void __user *uaddr, int ulen, void *kaddr);
+extern int put_cmsg(struct msghdr*, int level, int type, int len, void *data);
+
+#endif
 #endif /* not kernel and not glibc */
 #endif /* _LINUX_SOCKET_H */
include/linux/tcp.h +236 -8

267 lines not on this page · raw message

include/linux/types.h new file +202 -0

202 lines not on this page · raw message

include/linux/xfrm.h +45 -10

135 lines not on this page · raw message

Signature · 1 line
1.4.2
#1 lore raw

* Masahide NAKAMURA <[email protected]> 2006-12-05 19:15

Quoted 13 lines
include/linux/fib_rules.h +0 -1
index 8270aac..4418c8d 100644
@@ -6,7 +6,6 @@ #include <linux/rtnetlink.h>
 
 /* rule is permanent, and cannot be deleted */
 #define FIB_RULE_PERMANENT	1
-#define FIB_RULE_INVERT		2
 
 struct fib_rule_hdr
 {

include/linux/fib_rules.h enum · line 40

Quoted 8 lines
include/linux/fib_rules.h +1 -1
@@ -35,7 +34,7 @@ enum
 	FRA_UNUSED3,
 	FRA_UNUSED4,
 	FRA_UNUSED5,
-	FRA_FWMARK,	/* mark */
+	FRA_FWMARK,	/* netfilter mark */
 	FRA_FLOW,	/* flow/class id */
 	FRA_UNUSED6,
 	FRA_UNUSED7,

Why are you reverting this?

#2 lore raw
Quoted 11 lines · Thomas Graf

* Masahide NAKAMURA <[email protected]> 2006-12-05 19:15

Quoted 10 lines
include/linux/fib_rules.h +0 -1
index 8270aac..4418c8d 100644
@@ -6,7 +6,6 @@ #include <linux/rtnetlink.h>
 
 /* rule is permanent, and cannot be deleted */
 #define FIB_RULE_PERMANENT	1
-#define FIB_RULE_INVERT		2
 
Quoted 13 lines

include/linux/fib_rules.h enum · line 40

Quoted 11 lines
include/linux/fib_rules.h +1 -1
 struct fib_rule_hdr
 {
@@ -35,7 +34,7 @@ enum
 	FRA_UNUSED3,
 	FRA_UNUSED4,
 	FRA_UNUSED5,
-	FRA_FWMARK,	/* mark */
+	FRA_FWMARK,	/* netfilter mark */
 	FRA_FLOW,	/* flow/class id */
 	FRA_UNUSED6,
 	FRA_UNUSED7,

Why are you reverting this?

I just update the header about include/linux without thinking. Should I have to update them except fib_rules.h?

Anyway, I'll fix "[PATCH 1/7]" and send it again.

Thanks,

Signature · 1 line
Masahide NAKAMURA
#3 lore raw

* Masahide NAKAMURA <[email protected]> 2006-12-05 20:44

Quoted 26 lines
Quoted 11 lines · Thomas Graf

* Masahide NAKAMURA <[email protected]> 2006-12-05 19:15

Quoted 10 lines
include/linux/fib_rules.h +0 -1
index 8270aac..4418c8d 100644
@@ -6,7 +6,6 @@ #include <linux/rtnetlink.h>
 
 /* rule is permanent, and cannot be deleted */
 #define FIB_RULE_PERMANENT	1
-#define FIB_RULE_INVERT		2
 
Quoted 13 lines

include/linux/fib_rules.h enum · line 40

Quoted 11 lines

struct fib_rule_hdr
{

include/linux/fib_rules.h +1 -1
@@ -35,7 +34,7 @@ enum
 	FRA_UNUSED3,
 	FRA_UNUSED4,
 	FRA_UNUSED5,
-	FRA_FWMARK,	/* mark */
+	FRA_FWMARK,	/* netfilter mark */
 	FRA_FLOW,	/* flow/class id */
 	FRA_UNUSED6,
 	FRA_UNUSED7,

Why are you reverting this?

Quoted 2 lines

I just update the header about include/linux without thinking. Should I have to update them except fib_rules.h?

The iproute2 git tree already contains patches for the 2.6.20 release.

#4 lore raw
Quoted 6 lines · Thomas Graf
Quoted 3 lines
Quoted 1 line

Why are you reverting this?

I just update the header about include/linux without thinking. Should I have to update them except fib_rules.h?

The iproute2 git tree already contains patches for the 2.6.20 release.

OK, thanks. Can you know another patch which is already updated to newer version except fib_fules.h, iprule.c?

Regards,

Signature · 1 line
Masahide NAKAMURA
#5 lore raw
Quoted 5 lines · On Tue, 05 Dec 2006 21:27:08 +0900 Masahide NAKAMURA <[email protected]>…
Quoted 4 lines · Thomas Graf
Quoted 3 lines
Quoted 1 line

Why are you reverting this?

I just update the header about include/linux without thinking. Should I have to update them except fib_rules.h?

Quoted 8 lines
Quoted 2 lines

The iproute2 git tree already contains patches for the 2.6.20 release.

OK, thanks. Can you know another patch which is already updated to newer version except fib_fules.h, iprule.c?

Regards,

Rather than apply your patch I am just rerunning my header extract script against latest 2.6.19-git7 tree

Signature · 1 line
Stephen Hemminger <[email protected]>