Skip to content

Commit 4a19ec5

Browse files
LA-Tothdavem330
authored andcommitted
[NET]: Introducing socket mark socket option.
A userspace program may wish to set the mark for each packets its send without using the netfilter MARK target. Changing the mark can be used for mark based routing without netfilter or for packet filtering. It requires CAP_NET_ADMIN capability. Signed-off-by: Laszlo Attila Toth <[email protected]> Acked-by: Patrick McHardy <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 036c2e2 commit 4a19ec5

File tree

27 files changed

+65
-0
lines changed

27 files changed

+65
-0
lines changed

include/asm-alpha/socket.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,6 @@
6060
#define SO_SECURITY_ENCRYPTION_TRANSPORT 20
6161
#define SO_SECURITY_ENCRYPTION_NETWORK 21
6262

63+
#define SO_MARK 36
64+
6365
#endif /* _ASM_SOCKET_H */

include/asm-arm/socket.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,4 +52,6 @@
5252
#define SO_TIMESTAMPNS 35
5353
#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
5454

55+
#define SO_MARK 36
56+
5557
#endif /* _ASM_SOCKET_H */

include/asm-avr32/socket.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,4 +52,6 @@
5252
#define SO_TIMESTAMPNS 35
5353
#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
5454

55+
#define SO_MARK 36
56+
5557
#endif /* __ASM_AVR32_SOCKET_H */

include/asm-blackfin/socket.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,4 +50,7 @@
5050
#define SO_PASSSEC 34
5151
#define SO_TIMESTAMPNS 35
5252
#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
53+
54+
#define SO_MARK 36
55+
5356
#endif /* _ASM_SOCKET_H */

include/asm-cris/socket.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,8 @@
5454
#define SO_TIMESTAMPNS 35
5555
#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
5656

57+
#define SO_MARK 36
58+
5759
#endif /* _ASM_SOCKET_H */
5860

5961

include/asm-frv/socket.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,5 +52,7 @@
5252
#define SO_TIMESTAMPNS 35
5353
#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
5454

55+
#define SO_MARK 36
56+
5557
#endif /* _ASM_SOCKET_H */
5658

include/asm-h8300/socket.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,4 +52,6 @@
5252
#define SO_TIMESTAMPNS 35
5353
#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
5454

55+
#define SO_MARK 36
56+
5557
#endif /* _ASM_SOCKET_H */

include/asm-ia64/socket.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,4 +61,6 @@
6161
#define SO_TIMESTAMPNS 35
6262
#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
6363

64+
#define SO_MARK 36
65+
6466
#endif /* _ASM_IA64_SOCKET_H */

include/asm-m32r/socket.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,4 +52,6 @@
5252
#define SO_TIMESTAMPNS 35
5353
#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
5454

55+
#define SO_MARK 36
56+
5557
#endif /* _ASM_M32R_SOCKET_H */

include/asm-m68k/socket.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,4 +52,6 @@
5252
#define SO_TIMESTAMPNS 35
5353
#define SCM_TIMESTAMPNS SO_TIMESTAMPNS
5454

55+
#define SO_MARK 36
56+
5557
#endif /* _ASM_SOCKET_H */

0 commit comments

Comments
 (0)