1 /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ 2 #ifndef _UAPI__LINUX_ATALK_H__ 3 #define _UAPI__LINUX_ATALK_H__ 4 5 #include <linux/types.h> 6 #include <asm/byteorder.h> 7 #include <linux/socket.h> 8 9 /* 10 * AppleTalk networking structures 11 * 12 * The following are directly referenced from the University Of Michigan 13 * netatalk for compatibility reasons. 14 */ 15 #define ATPORT_FIRST 1 16 #define ATPORT_RESERVED 128 17 #define ATPORT_LAST 254 /* 254 is only legal on localtalk */ 18 #define ATADDR_ANYNET (uint16_t)0 19 #define ATADDR_ANYNODE (uint8_t)0 20 #define ATADDR_ANYPORT (uint8_t)0 21 #define ATADDR_BCAST (uint8_t)255 22 #define DDP_MAXSZ 587 23 #define DDP_MAXHOPS 15 /* 4 bits of hop counter */ 24 25 #define SIOCATALKDIFADDR (SIOCPROTOPRIVATE + 0) 26 27 struct atalk_addr { 28 uint16_t s_net; 29 uint8_t s_node; 30 }; 31 32 struct sockaddr_at { 33 __kernel_sa_family_t sat_family; 34 uint8_t sat_port; 35 struct atalk_addr sat_addr; 36 char sat_zero[8]; 37 }; 38 39 struct atalk_netrange { 40 uint8_t nr_phase; 41 uint16_t nr_firstnet; 42 uint16_t nr_lastnet; 43 }; 44 45 #endif /* _UAPI__LINUX_ATALK_H__ */ 46