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

Linux Cross Reference
Linux/net/irda/irsyms.c

Version: ~ [ 2.4.0 ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /*********************************************************************
  2  *                
  3  * Filename:      irsyms.c
  4  * Version:       0.9
  5  * Description:   IrDA module symbols
  6  * Status:        Experimental.
  7  * Author:        Dag Brattli <dagb@cs.uit.no>
  8  * Created at:    Mon Dec 15 13:55:39 1997
  9  * Modified at:   Wed Jan  5 15:12:41 2000
 10  * Modified by:   Dag Brattli <dagb@cs.uit.no>
 11  * 
 12  *     Copyright (c) 1997, 1999-2000 Dag Brattli, All Rights Reserved.
 13  *      
 14  *     This program is free software; you can redistribute it and/or 
 15  *     modify it under the terms of the GNU General Public License as 
 16  *     published by the Free Software Foundation; either version 2 of 
 17  *     the License, or (at your option) any later version.
 18  *  
 19  *     Neither Dag Brattli nor University of Tromsų admit liability nor
 20  *     provide warranty for any of this software. This material is 
 21  *     provided "AS-IS" and at no charge.
 22  *     
 23  ********************************************************************/
 24 
 25 #include <linux/config.h>
 26 #include <linux/module.h>
 27 
 28 #include <linux/init.h>
 29 #include <linux/poll.h>
 30 #include <linux/proc_fs.h>
 31 #include <linux/smp_lock.h>
 32 
 33 #include <asm/segment.h>
 34 
 35 #include <net/irda/irda.h>
 36 #include <net/irda/irmod.h>
 37 #include <net/irda/irlap.h>
 38 #ifdef CONFIG_IRDA_COMPRESSION
 39 #include <net/irda/irlap_comp.h>
 40 #endif /* CONFIG_IRDA_COMPRESSION */
 41 #include <net/irda/irlmp.h>
 42 #include <net/irda/iriap.h>
 43 #include <net/irda/irias_object.h>
 44 #include <net/irda/irttp.h>
 45 #include <net/irda/irda_device.h>
 46 #include <net/irda/wrapper.h>
 47 #include <net/irda/timer.h>
 48 #include <net/irda/parameters.h>
 49 
 50 extern struct proc_dir_entry *proc_irda;
 51 
 52 extern void irda_proc_register(void);
 53 extern void irda_proc_unregister(void);
 54 extern int  irda_sysctl_register(void);
 55 extern void irda_sysctl_unregister(void);
 56 
 57 extern int irda_proto_init(void);
 58 extern void irda_proto_cleanup(void);
 59 
 60 extern int irda_device_init(void);
 61 extern int irlan_init(void);
 62 extern int irlan_client_init(void);
 63 extern int irlan_server_init(void);
 64 extern int ircomm_init(void);
 65 extern int ircomm_tty_init(void);
 66 extern int irlpt_client_init(void);
 67 extern int irlpt_server_init(void);
 68 
 69 #ifdef CONFIG_IRDA_COMPRESSION
 70 #ifdef CONFIG_IRDA_DEFLATE
 71 extern irda_deflate_init();
 72 #endif /* CONFIG_IRDA_DEFLATE */
 73 #endif /* CONFIG_IRDA_COMPRESSION */
 74 
 75 /* IrTTP */
 76 EXPORT_SYMBOL(irttp_open_tsap);
 77 EXPORT_SYMBOL(irttp_close_tsap);
 78 EXPORT_SYMBOL(irttp_connect_response);
 79 EXPORT_SYMBOL(irttp_data_request);
 80 EXPORT_SYMBOL(irttp_disconnect_request);
 81 EXPORT_SYMBOL(irttp_flow_request);
 82 EXPORT_SYMBOL(irttp_connect_request);
 83 EXPORT_SYMBOL(irttp_udata_request);
 84 EXPORT_SYMBOL(irttp_dup);
 85 
 86 /* Main IrDA module */
 87 #ifdef CONFIG_IRDA_DEBUG
 88 EXPORT_SYMBOL(irda_debug);
 89 #endif
 90 EXPORT_SYMBOL(irda_notify_init);
 91 EXPORT_SYMBOL(irda_lock);
 92 #ifdef CONFIG_PROC_FS
 93 EXPORT_SYMBOL(proc_irda);
 94 #endif
 95 EXPORT_SYMBOL(irda_param_insert);
 96 EXPORT_SYMBOL(irda_param_extract);
 97 EXPORT_SYMBOL(irda_param_extract_all);
 98 EXPORT_SYMBOL(irda_param_pack);
 99 EXPORT_SYMBOL(irda_param_unpack);
100 
101 /* IrIAP/IrIAS */
102 EXPORT_SYMBOL(iriap_open);
103 EXPORT_SYMBOL(iriap_close);
104 EXPORT_SYMBOL(iriap_getvaluebyclass_request);
105 EXPORT_SYMBOL(irias_object_change_attribute);
106 EXPORT_SYMBOL(irias_add_integer_attrib);
107 EXPORT_SYMBOL(irias_add_octseq_attrib);
108 EXPORT_SYMBOL(irias_add_string_attrib);
109 EXPORT_SYMBOL(irias_insert_object);
110 EXPORT_SYMBOL(irias_new_object);
111 EXPORT_SYMBOL(irias_delete_object);
112 EXPORT_SYMBOL(irias_delete_value);
113 EXPORT_SYMBOL(irias_find_object);
114 EXPORT_SYMBOL(irias_find_attrib);
115 EXPORT_SYMBOL(irias_new_integer_value);
116 EXPORT_SYMBOL(irias_new_string_value);
117 EXPORT_SYMBOL(irias_new_octseq_value);
118 
119 /* IrLMP */
120 EXPORT_SYMBOL(irlmp_discovery_request);
121 EXPORT_SYMBOL(irlmp_get_discoveries);
122 EXPORT_SYMBOL(sysctl_discovery_timeout);
123 EXPORT_SYMBOL(irlmp_register_client);
124 EXPORT_SYMBOL(irlmp_unregister_client);
125 EXPORT_SYMBOL(irlmp_update_client);
126 EXPORT_SYMBOL(irlmp_register_service);
127 EXPORT_SYMBOL(irlmp_unregister_service);
128 EXPORT_SYMBOL(irlmp_service_to_hint);
129 EXPORT_SYMBOL(irlmp_data_request);
130 EXPORT_SYMBOL(irlmp_open_lsap);
131 EXPORT_SYMBOL(irlmp_close_lsap);
132 EXPORT_SYMBOL(irlmp_connect_request);
133 EXPORT_SYMBOL(irlmp_connect_response);
134 EXPORT_SYMBOL(irlmp_disconnect_request);
135 EXPORT_SYMBOL(irlmp_get_daddr);
136 EXPORT_SYMBOL(irlmp_get_saddr);
137 EXPORT_SYMBOL(irlmp_dup);
138 EXPORT_SYMBOL(lmp_reasons);
139 
140 /* Queue */
141 EXPORT_SYMBOL(hashbin_find);
142 EXPORT_SYMBOL(hashbin_new);
143 EXPORT_SYMBOL(hashbin_insert);
144 EXPORT_SYMBOL(hashbin_delete);
145 EXPORT_SYMBOL(hashbin_remove);
146 EXPORT_SYMBOL(hashbin_remove_this);
147 EXPORT_SYMBOL(hashbin_get_next);
148 EXPORT_SYMBOL(hashbin_get_first);
149 
150 /* IrLAP */
151 EXPORT_SYMBOL(irlap_open);
152 EXPORT_SYMBOL(irlap_close);
153 #ifdef CONFIG_IRDA_COMPRESSION
154 EXPORT_SYMBOL(irda_unregister_compressor);
155 EXPORT_SYMBOL(irda_register_compressor);
156 #endif /* CONFIG_IRDA_COMPRESSION */
157 EXPORT_SYMBOL(irda_init_max_qos_capabilies);
158 EXPORT_SYMBOL(irda_qos_bits_to_value);
159 EXPORT_SYMBOL(irda_device_setup);
160 EXPORT_SYMBOL(irda_device_set_media_busy);
161 EXPORT_SYMBOL(irda_device_txqueue_empty);
162 
163 EXPORT_SYMBOL(irda_device_dongle_init);
164 EXPORT_SYMBOL(irda_device_dongle_cleanup);
165 EXPORT_SYMBOL(irda_device_register_dongle);
166 EXPORT_SYMBOL(irda_device_unregister_dongle);
167 EXPORT_SYMBOL(irda_task_execute);
168 EXPORT_SYMBOL(irda_task_kick);
169 EXPORT_SYMBOL(irda_task_next_state);
170 EXPORT_SYMBOL(irda_task_delete);
171 
172 EXPORT_SYMBOL(async_wrap_skb);
173 EXPORT_SYMBOL(async_unwrap_char);
174 EXPORT_SYMBOL(irda_start_timer);
175 EXPORT_SYMBOL(setup_dma);
176 EXPORT_SYMBOL(infrared_mode);
177 
178 #ifdef CONFIG_IRTTY
179 EXPORT_SYMBOL(irtty_set_dtr_rts);
180 EXPORT_SYMBOL(irtty_register_dongle);
181 EXPORT_SYMBOL(irtty_unregister_dongle);
182 EXPORT_SYMBOL(irtty_set_packet_mode);
183 #endif
184 
185 int __init irda_init(void)
186 {
187         IRDA_DEBUG(0, __FUNCTION__ "()\n");
188 
189         irlmp_init();
190         irlap_init();
191         
192         iriap_init();
193         irttp_init();
194         
195 #ifdef CONFIG_PROC_FS
196         irda_proc_register();
197 #endif
198 #ifdef CONFIG_SYSCTL
199         irda_sysctl_register();
200 #endif
201         /* 
202          * Initialize modules that got compiled into the kernel 
203          */
204 #ifdef CONFIG_IRLAN
205         irlan_init();
206 #endif
207 #ifdef CONFIG_IRCOMM
208         ircomm_init();
209         ircomm_tty_init();
210 #endif
211 
212 #ifdef CONFIG_IRDA_COMPRESSION
213 #ifdef CONFIG_IRDA_DEFLATE
214         irda_deflate_init();
215 #endif /* CONFIG_IRDA_DEFLATE */
216 #endif /* CONFIG_IRDA_COMPRESSION */
217 
218         return 0;
219 }
220 
221 static void __exit irda_cleanup(void)
222 {
223 #ifdef CONFIG_SYSCTL
224         irda_sysctl_unregister();
225 #endif  
226 
227 #ifdef CONFIG_PROC_FS
228         irda_proc_unregister();
229 #endif
230         /* Remove higher layers */
231         irttp_cleanup();
232         iriap_cleanup();
233 
234         /* Remove lower layers */
235         irda_device_cleanup();
236         irlap_cleanup(); /* Must be done before irlmp_cleanup()! DB */
237 
238         /* Remove middle layer */
239         irlmp_cleanup();
240 }
241 
242 /*
243  * Function irda_unlock (lock)
244  *
245  *    Unlock variable. Returns false if lock is already unlocked
246  *
247  */
248 inline int irda_unlock(int *lock) 
249 {
250         if (!test_and_clear_bit(0, (void *) lock))  {
251                 printk("Trying to unlock already unlocked variable!\n");
252                 return FALSE;
253         }
254         return TRUE;
255 }
256 
257 /*
258  * Function irda_notify_init (notify)
259  *
260  *    Used for initializing the notify structure
261  *
262  */
263 void irda_notify_init(notify_t *notify)
264 {
265         notify->data_indication = NULL;
266         notify->udata_indication = NULL;
267         notify->connect_confirm = NULL;
268         notify->connect_indication = NULL;
269         notify->disconnect_indication = NULL;
270         notify->flow_indication = NULL;
271         notify->status_indication = NULL;
272         notify->instance = NULL;
273         strncpy(notify->name, "Unknown", NOTIFY_MAX_NAME);
274 }
275 
276 

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

This page was automatically generated by the LXR engine.
Visit the LXR main site for more information.