1 /* SPDX-License-Identifier: GPL-2.0+ WITH Linu 1 /* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */ 2 /* 2 /* 3 * INET An implementation of the TCP/I 3 * INET An implementation of the TCP/IP protocol suite for the LINUX 4 * operating system. INET is imp 4 * operating system. INET is implemented using the BSD Socket 5 * interface as the means of comm 5 * interface as the means of communication with the user level. 6 * 6 * 7 * Definitions for the Interfaces 7 * Definitions for the Interfaces handler. 8 * 8 * 9 * Version: @(#)dev.h 1.0.10 08/12/ 9 * Version: @(#)dev.h 1.0.10 08/12/93 10 * 10 * 11 * Authors: Ross Biro 11 * Authors: Ross Biro 12 * Fred N. van Kempen, <waltje@uW 12 * Fred N. van Kempen, <waltje@uWalt.NL.Mugnet.ORG> 13 * Corey Minyard <wf-rch!minyard@ 13 * Corey Minyard <wf-rch!minyard@relay.EU.net> 14 * Donald J. Becker, <becker@cesd 14 * Donald J. Becker, <becker@cesdis.gsfc.nasa.gov> 15 * Alan Cox, <alan@lxorguk.ukuu.o 15 * Alan Cox, <alan@lxorguk.ukuu.org.uk> 16 * Bjorn Ekwall. <bj0rn@blox.se> 16 * Bjorn Ekwall. <bj0rn@blox.se> 17 * Pekka Riikonen <priikone@posei 17 * Pekka Riikonen <priikone@poseidon.pspt.fi> 18 * 18 * 19 * This program is free software; 19 * This program is free software; you can redistribute it and/or 20 * modify it under the terms of t 20 * modify it under the terms of the GNU General Public License 21 * as published by the Free Softw 21 * as published by the Free Software Foundation; either version 22 * 2 of the License, or (at your 22 * 2 of the License, or (at your option) any later version. 23 * 23 * 24 * Moved to /usr/include/linux fo 24 * Moved to /usr/include/linux for NET3 25 */ 25 */ 26 #ifndef _UAPI_LINUX_NETDEVICE_H 26 #ifndef _UAPI_LINUX_NETDEVICE_H 27 #define _UAPI_LINUX_NETDEVICE_H 27 #define _UAPI_LINUX_NETDEVICE_H 28 28 29 #include <linux/if.h> 29 #include <linux/if.h> 30 #include <linux/if_ether.h> 30 #include <linux/if_ether.h> 31 #include <linux/if_packet.h> 31 #include <linux/if_packet.h> 32 #include <linux/if_link.h> 32 #include <linux/if_link.h> 33 33 34 34 35 #define MAX_ADDR_LEN 32 /* Lar 35 #define MAX_ADDR_LEN 32 /* Largest hardware address length */ 36 36 37 /* Initial net device group. All devices belon 37 /* Initial net device group. All devices belong to group 0 by default. */ 38 #define INIT_NETDEV_GROUP 0 38 #define INIT_NETDEV_GROUP 0 39 39 40 40 41 /* interface name assignment types (sysfs name 41 /* interface name assignment types (sysfs name_assign_type attribute) */ 42 #define NET_NAME_UNKNOWN 0 /* unk 42 #define NET_NAME_UNKNOWN 0 /* unknown origin (not exposed to userspace) */ 43 #define NET_NAME_ENUM 1 /* enu 43 #define NET_NAME_ENUM 1 /* enumerated by kernel */ 44 #define NET_NAME_PREDICTABLE 2 /* pre 44 #define NET_NAME_PREDICTABLE 2 /* predictably named by the kernel */ 45 #define NET_NAME_USER 3 /* pro 45 #define NET_NAME_USER 3 /* provided by user-space */ 46 #define NET_NAME_RENAMED 4 /* ren 46 #define NET_NAME_RENAMED 4 /* renamed by user-space */ 47 47 48 /* Media selection options. */ 48 /* Media selection options. */ 49 enum { 49 enum { 50 IF_PORT_UNKNOWN = 0, 50 IF_PORT_UNKNOWN = 0, 51 IF_PORT_10BASE2, 51 IF_PORT_10BASE2, 52 IF_PORT_10BASET, 52 IF_PORT_10BASET, 53 IF_PORT_AUI, 53 IF_PORT_AUI, 54 IF_PORT_100BASET, 54 IF_PORT_100BASET, 55 IF_PORT_100BASETX, 55 IF_PORT_100BASETX, 56 IF_PORT_100BASEFX 56 IF_PORT_100BASEFX 57 }; 57 }; 58 58 59 /* hardware address assignment types */ 59 /* hardware address assignment types */ 60 #define NET_ADDR_PERM 0 /* add 60 #define NET_ADDR_PERM 0 /* address is permanent (default) */ 61 #define NET_ADDR_RANDOM 1 /* add 61 #define NET_ADDR_RANDOM 1 /* address is generated randomly */ 62 #define NET_ADDR_STOLEN 2 /* add 62 #define NET_ADDR_STOLEN 2 /* address is stolen from other device */ 63 #define NET_ADDR_SET 3 /* add 63 #define NET_ADDR_SET 3 /* address is set using 64 * dev 64 * dev_set_mac_address() */ 65 65 66 #endif /* _UAPI_LINUX_NETDEVICE_H */ 66 #endif /* _UAPI_LINUX_NETDEVICE_H */ 67 67
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.