~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/include/net/irda/irda.h

Version: ~ [ linux-5.4-rc3 ] ~ [ linux-5.3.6 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.79 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.149 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.196 ] ~ [ linux-4.8.17 ] ~ [ linux-4.7.10 ] ~ [ linux-4.6.7 ] ~ [ linux-4.5.7 ] ~ [ linux-4.4.196 ] ~ [ linux-4.3.6 ] ~ [ linux-4.2.8 ] ~ [ linux-4.1.52 ] ~ [ linux-4.0.9 ] ~ [ linux-3.19.8 ] ~ [ linux-3.18.140 ] ~ [ linux-3.17.8 ] ~ [ linux-3.16.75 ] ~ [ linux-3.15.10 ] ~ [ linux-3.14.79 ] ~ [ linux-3.13.11 ] ~ [ linux-3.12.74 ] ~ [ linux-3.11.10 ] ~ [ linux-3.10.108 ] ~ [ linux-3.9.11 ] ~ [ linux-3.8.13 ] ~ [ linux-3.7.10 ] ~ [ linux-3.6.11 ] ~ [ linux-3.5.7 ] ~ [ linux-3.4.113 ] ~ [ linux-3.3.8 ] ~ [ linux-3.2.102 ] ~ [ linux-3.1.10 ] ~ [ linux-3.0.101 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.5 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /*********************************************************************
  2  *                
  3  * Filename:      irda.h
  4  * Version:       1.0
  5  * Description:   IrDA common include file for kernel internal use
  6  * Status:        Stable
  7  * Author:        Dag Brattli <dagb@cs.uit.no>
  8  * Created at:    Tue Dec  9 21:13:12 1997
  9  * Modified at:   Fri Jan 28 13:16:32 2000
 10  * Modified by:   Dag Brattli <dagb@cs.uit.no>
 11  * 
 12  *     Copyright (c) 1998-2000 Dag Brattli, All Rights Reserved.
 13  *     Copyright (c) 2000-2002 Jean Tourrilhes <jt@hpl.hp.com>
 14  *      
 15  *     This program is free software; you can redistribute it and/or 
 16  *     modify it under the terms of the GNU General Public License as 
 17  *     published by the Free Software Foundation; either version 2 of 
 18  *     the License, or (at your option) any later version.
 19  *  
 20  *     Neither Dag Brattli nor University of Tromsø admit liability nor
 21  *     provide warranty for any of this software. This material is 
 22  *     provided "AS-IS" and at no charge.
 23  *     
 24  ********************************************************************/
 25 
 26 #ifndef NET_IRDA_H
 27 #define NET_IRDA_H
 28 
 29 #include <linux/skbuff.h>               /* struct sk_buff */
 30 #include <linux/kernel.h>
 31 #include <linux/if.h>                   /* sa_family_t in <linux/irda.h> */
 32 #include <linux/irda.h>
 33 
 34 typedef __u32 magic_t;
 35 
 36 #ifndef TRUE
 37 #define TRUE 1
 38 #endif
 39 
 40 #ifndef FALSE 
 41 #define FALSE 0
 42 #endif
 43 
 44 /* Hack to do small backoff when setting media busy in IrLAP */
 45 #ifndef SMALL
 46 #define SMALL 5
 47 #endif
 48 
 49 #ifndef IRDA_MIN /* Lets not mix this MIN with other header files */
 50 #define IRDA_MIN(a, b) (((a) < (b)) ? (a) : (b))
 51 #endif
 52 
 53 #ifndef IRDA_ALIGN
 54 #  define IRDA_ALIGN __attribute__((aligned))
 55 #endif
 56 
 57 #ifdef CONFIG_IRDA_DEBUG
 58 
 59 extern unsigned int irda_debug;
 60 
 61 /* use 0 for production, 1 for verification, >2 for debug */
 62 #define IRDA_DEBUG_LEVEL 0
 63 
 64 #define IRDA_DEBUG(n, args...) \
 65 do {    if (irda_debug >= (n)) \
 66                 printk(KERN_DEBUG args); \
 67 } while (0)
 68 #define IRDA_ASSERT(expr, func) \
 69 do { if(!(expr)) { \
 70         printk( "Assertion failed! %s:%s:%d %s\n", \
 71                 __FILE__,__func__,__LINE__,(#expr) ); \
 72         func } } while (0)
 73 #define IRDA_ASSERT_LABEL(label)        label
 74 #else
 75 #define IRDA_DEBUG(n, args...) do { } while (0)
 76 #define IRDA_ASSERT(expr, func) do { (void)(expr); } while (0)
 77 #define IRDA_ASSERT_LABEL(label)
 78 #endif /* CONFIG_IRDA_DEBUG */
 79 
 80 #define IRDA_WARNING(args...) do { if (net_ratelimit()) printk(KERN_WARNING args); } while (0)
 81 #define IRDA_MESSAGE(args...) do { if (net_ratelimit()) printk(KERN_INFO args); } while (0)
 82 #define IRDA_ERROR(args...)   do { if (net_ratelimit()) printk(KERN_ERR args); } while (0)
 83 
 84 /*
 85  *  Magic numbers used by Linux-IrDA. Random numbers which must be unique to 
 86  *  give the best protection
 87  */
 88 
 89 #define IRTTY_MAGIC        0x2357
 90 #define LAP_MAGIC          0x1357
 91 #define LMP_MAGIC          0x4321
 92 #define LMP_LSAP_MAGIC     0x69333
 93 #define LMP_LAP_MAGIC      0x3432
 94 #define IRDA_DEVICE_MAGIC  0x63454
 95 #define IAS_MAGIC          0x007
 96 #define TTP_MAGIC          0x241169
 97 #define TTP_TSAP_MAGIC     0x4345
 98 #define IROBEX_MAGIC       0x341324
 99 #define HB_MAGIC           0x64534
100 #define IRLAN_MAGIC        0x754
101 #define IAS_OBJECT_MAGIC   0x34234
102 #define IAS_ATTRIB_MAGIC   0x45232
103 #define IRDA_TASK_MAGIC    0x38423
104 
105 #define IAS_DEVICE_ID 0x0000 /* Defined by IrDA, IrLMP section 4.1 (page 68) */
106 #define IAS_PNP_ID    0xd342
107 #define IAS_OBEX_ID   0x34323
108 #define IAS_IRLAN_ID  0x34234
109 #define IAS_IRCOMM_ID 0x2343
110 #define IAS_IRLPT_ID  0x9876
111 
112 struct net_device;
113 struct packet_type;
114 
115 extern void irda_proc_register(void);
116 extern void irda_proc_unregister(void);
117 
118 extern int irda_sysctl_register(void);
119 extern void irda_sysctl_unregister(void);
120 
121 extern int irsock_init(void);
122 extern void irsock_cleanup(void);
123 
124 extern int irda_nl_register(void);
125 extern void irda_nl_unregister(void);
126 
127 extern int irlap_driver_rcv(struct sk_buff *skb, struct net_device *dev,
128                             struct packet_type *ptype,
129                             struct net_device *orig_dev);
130 
131 #endif /* NET_IRDA_H */
132 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | Wiki (Japanese) | Wiki (English) | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

osdn.jp