net/sockopt: move BINDTODEVICE to socket level

rename the UDP_BINDTODEVICE to SO_BINDTODEVICE to follow the linux
style to be compatible with non-UDP protocol binding requirements

Signed-off-by: chao.an <anchao@xiaomi.com>
This commit is contained in:
chao.an
2022-08-24 10:30:01 +08:00
committed by Xiang Xiao
parent 50177dbae1
commit 9cb17841d8
17 changed files with 76 additions and 185 deletions
+3 -1
View File
@@ -61,10 +61,12 @@
#define _SO_SNDLOWAT _SO_BIT(SO_SNDLOWAT)
#define _SO_SNDTIMEO _SO_BIT(SO_SNDTIMEO)
#define _SO_TYPE _SO_BIT(SO_TYPE)
#define _SO_TIMESTAMP _SO_BIT(SO_TIMESTAMP)
#define _SO_BINDTODEVICE _SO_BIT(SO_BINDTODEVICE)
/* This is the largest option value. REVISIT: belongs in sys/socket.h */
#define _SO_MAXOPT (16)
#define _SO_MAXOPT (18)
/* Macros to set, test, clear options */