(2/16) add alloc_irdadev
Subsystems (2)
PATCH 1/1 (2/16) add alloc_irdadev
For 2.6.0-test6 add alloc_irdadev in same manner as alloc_etherdev.
include/net/irda/irda_device.h +1 -0
@@ -223,6 +223,7 @@int irda_device_set_dtr_rts (struct net_device *dev,int dtr,int rts);int irda_device_change_speed (struct net_device *dev,__u32 speed);void irda_device_setup (struct net_device *dev); +struct net_device *alloc_irdadev (int sizeof_priv);/* Dongle interface */ void irda_device_unregister_dongle (struct dongle_reg *dongle);
net/irda/irda_device.c +11 -0
@@ -388,6 +388,17 @@ }/* +* Funciton alloc_irdadev +* Allocates and sets up an IRDA device in a manner similar to +* alloc_etherdev. +*/ +struct net_device *alloc_irdadev (int sizeof_priv) +{ +return alloc_netdev (sizeof_priv,"irda%d" , irda_device_setup); +} + + +/* * Function irda_device_txqueue_empty (dev) * * Check if there is still some frames in the transmit queue for this
net/irda/irsyms.c +1 -0
@@ -150,6 +150,7 @@EXPORT_SYMBOL (irda_init_max_qos_capabilies);EXPORT_SYMBOL (irda_qos_bits_to_value);EXPORT_SYMBOL (irda_device_setup); +EXPORT_SYMBOL (alloc_irdadev);EXPORT_SYMBOL (irda_device_set_media_busy);EXPORT_SYMBOL (irda_device_txqueue_empty);