Skip to content

Commit 4e83ae6

Browse files
committed
mips, net: ensure that SOCK_COREDUMP is defined
For historical reasons mips has to override the socket enum values but the defines are all the same. So simply move the ARCH_HAS_SOCKET_TYPES scope. Fixes: a9194f8 ("coredump: add coredump socket") Suggested-by: Arnd Bergmann <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
1 parent a3b4ca6 commit 4e83ae6

File tree

2 files changed

+1
-11
lines changed

2 files changed

+1
-11
lines changed

arch/mips/include/asm/socket.h

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -36,15 +36,6 @@ enum sock_type {
3636
SOCK_PACKET = 10,
3737
};
3838

39-
#define SOCK_MAX (SOCK_PACKET + 1)
40-
/* Mask which covers at least up to SOCK_MASK-1. The
41-
* * remaining bits are used as flags. */
42-
#define SOCK_TYPE_MASK 0xf
43-
44-
/* Flags for socket, socketpair, paccept */
45-
#define SOCK_CLOEXEC O_CLOEXEC
46-
#define SOCK_NONBLOCK O_NONBLOCK
47-
4839
#define ARCH_HAS_SOCKET_TYPES 1
4940

5041
#endif /* _ASM_SOCKET_H */

include/linux/net.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ enum sock_type {
7070
SOCK_DCCP = 6,
7171
SOCK_PACKET = 10,
7272
};
73+
#endif /* ARCH_HAS_SOCKET_TYPES */
7374

7475
#define SOCK_MAX (SOCK_PACKET + 1)
7576
/* Mask which covers at least up to SOCK_MASK-1. The
@@ -83,8 +84,6 @@ enum sock_type {
8384
#endif
8485
#define SOCK_COREDUMP O_NOCTTY
8586

86-
#endif /* ARCH_HAS_SOCKET_TYPES */
87-
8887
/**
8988
* enum sock_shutdown_cmd - Shutdown types
9089
* @SHUT_RD: shutdown receptions

0 commit comments

Comments
 (0)