home *** CD-ROM | disk | FTP | other *** search
/ The Datafile PD-CD 4 / DATAFILE_PDCD4.iso / utilities / utilss / sockets / include / netinet / h / in_var < prev    next >
Encoding:
Text File  |  1995-01-11  |  1.9 KB  |  61 lines

  1. /*
  2.  * $Header: /ax/networking:include/netinet/in_var.h:networking  1.1  $
  3.  * $Source: /ax/networking:include/netinet/in_var.h: $
  4.  *
  5.  * Copyright (c) 1988 Acorn Computers Ltd., Cambridge, England
  6.  *
  7.  * $Log:    in_var.h,v $
  8.  * Revision 1.1  95/01/11  10:16:54  kwelton
  9.  * Initial revision
  10.  * 
  11.  * Revision 1.3  88/06/17  20:26:34  beta
  12.  * Acorn Unix initial beta version
  13.  * 
  14.  */
  15. /* @(#)in_var.h    1.1 87/06/23 3.2/4.3NFSSRC */
  16. /*
  17.  * Copyright (c) 1985, 1986 Regents of the University of California.
  18.  * All rights reserved.  The Berkeley software License Agreement
  19.  * specifies the terms and conditions for redistribution.
  20.  *
  21.  *    @(#)in_var.h    7.1 (Berkeley) 6/5/86
  22.  */
  23.  
  24. /*
  25.  * Interface address, Internet version.  One of these structures
  26.  * is allocated for each interface with an Internet address.
  27.  * The ifaddr structure contains the protocol-independent part
  28.  * of the structure and is assumed to be first.
  29.  */
  30. struct in_ifaddr {
  31.     struct    ifaddr ia_ifa;        /* protocol-independent info */
  32. #define    ia_addr    ia_ifa.ifa_addr
  33. #define    ia_broadaddr    ia_ifa.ifa_broadaddr
  34. #define    ia_dstaddr    ia_ifa.ifa_dstaddr
  35. #define    ia_ifp        ia_ifa.ifa_ifp
  36.     u_long    ia_net;            /* network number of interface */
  37.     u_long    ia_netmask;        /* mask of net part */
  38.     u_long    ia_subnet;        /* subnet number, including net */
  39.     u_long    ia_subnetmask;        /* mask of net + subnet */
  40.     struct    in_addr ia_netbroadcast; /* broadcast addr for (logical) net */
  41.     int    ia_flags;
  42.     struct    in_ifaddr *ia_next;    /* next in list of internet addresses */
  43. };
  44. /*
  45.  * Given a pointer to an in_ifaddr (ifaddr),
  46.  * return a pointer to the addr as a sockadd_in.
  47.  */
  48. #define    IA_SIN(ia) ((struct sockaddr_in *)(&((struct in_ifaddr *)ia)->ia_addr))
  49. /*
  50.  * ia_flags
  51.  */
  52. #define    IFA_ROUTE    0x01        /* routing entry installed */
  53.  
  54. #ifdef    KERNEL
  55. struct    in_ifaddr *in_ifaddr;
  56. struct    in_ifaddr *in_iaonnetof();
  57. struct    ifqueue    ipintrq;        /* ip packet input queue */
  58. #endif
  59.  
  60. /* EOF in_var.h */
  61.