diff options
author | maximsch2 <maximsch2> | 2006-06-21 08:50:07 +0000 |
---|---|---|
committer | maximsch2 <maximsch2> | 2006-06-21 08:50:07 +0000 |
commit | 6518e55984e96525c94930b8be6c39b2e5e25ead (patch) | |
tree | d5b5653447e036e8dd15439d8bc2a0265aa5ec15 | |
parent | 03cf4f22e339faf4aebe991ae290e0db59f9e185 (diff) |
Applied fixes from debian patchset. Fixes compilation with 2.6.17 and other issuse. Added some fixes to WE code.
-rw-r--r-- | Makefile | 15 | ||||
-rw-r--r-- | at76_usbdfu.c | 6 | ||||
-rw-r--r-- | at76c503-fw_skel.c | 74 | ||||
-rw-r--r-- | at76c503.c | 169 | ||||
-rw-r--r-- | at76c503.h | 2 | ||||
-rwxr-xr-x | scripts/fwbin2pkg.sh | 5 |
6 files changed, 111 insertions, 160 deletions
@@ -1,4 +1,4 @@ -#$Id: Makefile,v 1.41 2004/09/19 19:17:29 jal2 Exp $ +#$Id: Makefile,v 1.42 2006/06/21 08:50:07 maximsch2 Exp $ # # Copyright (c) 2002 - 2003 Oliver Kurth # (c) 2003 - 2004 Jörg Albert <joerg.albert@gmx.de> @@ -49,7 +49,7 @@ FW_HDRS= fw-pkg-505-rfmd2958-1.101.0-86.h fw-pkg-i3863.h \ SCRIPTS = fwbin2h fwbin2pkg.sh fwconvert fwversion -DISTFILES = $(SRCS) $(HDRS) $(FW_HDRS) Makefile README COPYING \ +DISTFILES = $(SRCS) $(HDRS) Makefile README COPYING \ CHANGELOG gen_fw.c kernel_patch.sh Makefile.k26 TOPDISTFILES = @@ -83,19 +83,18 @@ all: modules modules: mkdir -p .tmp_versions - -cp $(KERNEL_SRC)/.tmp_versions/*.mod $(MODVERDIR) - $(MAKE) -C $(KERNEL_SRC) SUBDIRS=$(SRCDIR) MODVERDIR=$(MODVERDIR) \ + $(MAKE) -C $(KERNEL_SRC) M=$(SRCDIR) MODVERDIR=$(MODVERDIR) \ EXTRA_CFLAGS="$(FW_DL)" modules mv_old: for i in $(MODULES:%.o=%.ko); do \ find $(DEL_MODULE_DIR) -name $$i -exec rm -f {} {}.orig \; ;done -install-modules: all mv_old +install-modules: all mkdir -p $(MODULE_DIR) install -m 644 -o 0 -g 0 $(MODULES:%.o=%.ko) $(MODULE_DIR) -install: install-modules +install: mv_old install-modules $(DEPMOD) -ae uninstall: @@ -128,11 +127,11 @@ mv_old: for i in $(MODULES); do \ find $(DEL_MODULE_DIR) -name $$i -exec rm -f {} {}.orig \; ;done -install-modules: all mv_old +install-modules: all mkdir -p $(MODULE_DIR) for f in $(MODULES); do install -m 644 -o 0 -g 0 $$f $(MODULE_DIR)/$$f; done -install: install-modules +install: mv_old install-modules $(DEPMOD) -ae uninstall: diff --git a/at76_usbdfu.c b/at76_usbdfu.c index 8190ffc..f99d100 100644 --- a/at76_usbdfu.c +++ b/at76_usbdfu.c @@ -1,5 +1,5 @@ /* -*- linux-c -*- */ -/* $Id: at76_usbdfu.c,v 1.2 2004/09/05 14:07:09 jal2 Exp $ */ +/* $Id: at76_usbdfu.c,v 1.3 2006/06/21 08:50:07 maximsch2 Exp $ */ /* * USB Device Firmware Upgrade (DFU) handler * @@ -57,8 +57,8 @@ static int debug = 0; #define DRIVER_DESC "USB Device Firmware Upgrade (DFU) handler" /* Module paramaters */ -MODULE_PARM(debug, "i"); -MODULE_PARM_DESC(debug, "debug enabled (=1)"); +module_param(debug, bool, 0400); +MODULE_PARM_DESC(debug, "debug on/off"); /* DFU states */ diff --git a/at76c503-fw_skel.c b/at76c503-fw_skel.c index 2622f29..5880ee9 100644 --- a/at76c503-fw_skel.c +++ b/at76c503-fw_skel.c @@ -1,6 +1,6 @@ /* -*- linux-c -*- */ /* - * $Id: at76c503-fw_skel.c,v 1.8 2005/03/08 00:07:55 jal2 Exp $ + * $Id: at76c503-fw_skel.c,v 1.9 2006/06/21 08:50:07 maximsch2 Exp $ * * Driver for at76c503-based devices based on the Atmel "Fast-Vnet" reference * @@ -31,22 +31,7 @@ #include <asm/arch/ipaq.h> #include <asm/arch-pxa/h5400-asic.h> #endif - -#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 5, 0) -extern inline char *fw_dev_param(struct usb_device *udev, char *buf) -{ -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 4, 20) - snprintf(buf, FIRMWARE_NAME_MAX, "usb-%s-%s", - udev->bus->bus_name, udev->devpath); -#else - snprintf(buf, FIRMWARE_NAME_MAX, "usb-%d-%d", - udev->bus->busnum, udev->devnum); -#endif - return buf; -} -#else -#define fw_dev_param(udev, buf) (&udev->dev) -#endif +#include <linux/module.h> MODULE_DEVICE_TABLE (usb, dev_table); @@ -55,14 +40,12 @@ const struct firmware *fw; /* Module paramaters */ -static char netdev_name[IFNAMSIZ+1] = "wlan%d"; -MODULE_PARM(netdev_name, "c" __MODULE_STRING(IFNAMSIZ)); -MODULE_PARM_DESC(netdev_name, - "network device name (default is wlan%d)"); -static int debug = 1; -MODULE_PARM(debug, "i"); -MODULE_PARM_DESC(debug, - "debug output (default: 1)"); +static char* netdev_name = "wlan%d"; +module_param(netdev_name, charp,0400); +MODULE_PARM_DESC(netdev_name, "network device name (default is wlan%d)"); +static int debug=0; +module_param(debug, bool, 0400); +MODULE_PARM_DESC(debug, "debug on/off"); /* Use our own dbg macro */ #undef dbg @@ -74,22 +57,15 @@ MODULE_PARM_DESC(debug, /* local function prototypes */ - -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0) -static void *at76c50x_probe(struct usb_device *udev, unsigned int ifnum, - const struct usb_device_id *id); -static void at76c50x_disconnect(struct usb_device *dev, void *ptr); -#else static int at76c50x_probe(struct usb_interface *interface, const struct usb_device_id *id); static void at76c50x_disconnect(struct usb_interface *interface); -#endif /* structure for registering this driver with the usb subsystem */ static struct usb_driver module_usb = { -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,20) +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,20) && LINUX_VERSION_CODE < KERNEL_VERSION(2,6,16) owner: THIS_MODULE, #endif name: DRIVER_NAME, @@ -101,24 +77,14 @@ static struct usb_driver module_usb = { /* Module and USB entry points */ -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0) -static void *at76c50x_probe(struct usb_device *udev, unsigned int ifnum, - const struct usb_device_id *id) -#else static int at76c50x_probe(struct usb_interface *interface, const struct usb_device_id *id) -#endif { void *devptr = NULL; int retval; -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0) -#define RETERR(x) return NULL -#else -#define RETERR(x) return x struct usb_device *udev __attribute__ ((unused)); udev = interface_to_usbdev(interface); -#endif /* if fw is statically compiled in, we use it */ if (static_fw.size > 0) { @@ -126,50 +92,38 @@ static int at76c50x_probe(struct usb_interface *interface, fw = &static_fw; } else { #ifdef CONFIG_AT76C503_FIRMWARE_DOWNLOAD - char buf[FIRMWARE_NAME_MAX] __attribute__ ((unused)); if (fw == NULL) { dbg("downloading firmware " FW_NAME); - if (request_firmware(&fw, FW_NAME, - fw_dev_param(udev,buf)) == 0) { + if (request_firmware(&fw, FW_NAME, &udev->dev) == 0) { dbg("got it."); } else { err("firmware " FW_NAME " not found."); err("You may need to download the firmware from " "http://www.thekelleys.org.uk/atmel or " "ftp://ftp.berlios.de/pub/at76c503a/firmware/"); - RETERR(-EFAULT); + return -EFAULT; } } else dbg("re-using previously loaded fw"); #else err("either configure driver for firmware loader or compile" "firmware in"); - RETERR(-EFAULT); + return -EFAULT; #endif } retval = at76c503_do_probe(THIS_MODULE, udev, &module_usb, fw->data, fw->size, BOARDTYPE, netdev_name, &devptr); -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0) - return devptr; -#else return retval; -#endif } -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0) -static void at76c50x_disconnect(struct usb_device *dev, void *ptr) -#else static void at76c50x_disconnect(struct usb_interface *interface) -#endif { -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0) struct at76c503 *ptr; ptr = usb_get_intfdata (interface); usb_set_intfdata(interface, NULL); -#endif info("%s disconnecting", ((struct at76c503 *)ptr)->netdev->name); at76c503_delete_device(ptr); @@ -221,8 +175,8 @@ static void __exit mod_exit(void) #endif } -module_init (mod_init); -module_exit (mod_exit); +module_init(mod_init); +module_exit(mod_exit); MODULE_AUTHOR(DRIVER_AUTHOR); MODULE_DESCRIPTION(DRIVER_DESC); @@ -1,5 +1,5 @@ /* -*- linux-c -*- */ -/* $Id: at76c503.c,v 1.75 2006/02/11 19:18:44 tim_small Exp $ +/* $Id: at76c503.c,v 1.76 2006/06/21 08:50:07 maximsch2 Exp $ * * USB at76c503/at76c505 driver * @@ -139,9 +139,6 @@ # define USB_CTRL_GET_TIMEOUT 5 #endif -/* try to make it compile for both 2.4.x and 2.6.x kernels */ -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 5, 0) - /* number of endpoints of an interface */ #define NUM_EP(intf) (intf)->altsetting[0].desc.bNumEndpoints #define EP(intf,nr) (intf)->altsetting[0].endpoint[(nr)].desc @@ -156,34 +153,6 @@ static inline struct urb *alloc_urb(int iso_pk, int mem_flags) { return usb_alloc_urb(iso_pk, mem_flags); } -#else - -/* 2.4.x kernels */ - -#define NUM_EP(intf) (intf)->altsetting[0].bNumEndpoints -#define EP(intf,nr) (intf)->altsetting[0].endpoint[(nr)] - -#define GET_DEV(udev) usb_inc_dev_use((udev)) -#define PUT_DEV(udev) usb_dec_dev_use((udev)) - -#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 4, 25) -// this macro is defined from 2.4.25 onward -#define SET_NETDEV_DEV(x,y) -#endif - -#define SET_NETDEV_OWNER(ndev,owner) ndev->owner = owner - -static inline int submit_urb(struct urb *urb, int mem_flags) { - return usb_submit_urb(urb); -} -static inline struct urb *alloc_urb(int iso_pk, int mem_flags) { - return usb_alloc_urb(iso_pk); -} - -static inline void usb_set_intfdata(struct usb_interface *intf, void *data) {} - -#endif //#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 5, 0) - /* Backwards compatibility for usb_kill_urb() */ #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 10) # define usb_kill_urb usb_unlink_urb @@ -309,69 +278,70 @@ static const u8 zeros[32]; /* Version Information */ #define DRIVER_DESC "Generic Atmel at76c503/at76c505 routines" -/* Module paramaters */ -MODULE_PARM(debug, "i"); #define DRIVER_AUTHOR \ "Oliver Kurth, Joerg Albert <joerg.albert@gmx.de>, Alex, Nick Jones, "\ "Balint Seeber <n0_5p4m_p13453@hotmail.com>" + +/* Module paramaters */ +module_param(debug, int, 0400); MODULE_PARM_DESC(debug, "Debugging level"); static int rx_copybreak = 200; -MODULE_PARM(rx_copybreak, "i"); +module_param(rx_copybreak, int, 0400); MODULE_PARM_DESC(rx_copybreak, "rx packet copy threshold"); static int scan_min_time = 10; -MODULE_PARM(scan_min_time, "i"); +module_param(scan_min_time, int, 0400); MODULE_PARM_DESC(scan_min_time, "scan min channel time (default: 10)"); static int scan_max_time = 120; -MODULE_PARM(scan_max_time, "i"); +module_param(scan_max_time, int, 0400); MODULE_PARM_DESC(scan_max_time, "scan max channel time (default: 120)"); static int scan_mode = SCAN_TYPE_ACTIVE; -MODULE_PARM(scan_mode, "i"); +module_param(scan_mode, int, 0400); MODULE_PARM_DESC(scan_mode, "scan mode: 0 active (with ProbeReq, default), 1 passive"); static int preamble_type = PREAMBLE_TYPE_LONG; -MODULE_PARM(preamble_type, "i"); +module_param(preamble_type, int, 0400); MODULE_PARM_DESC(preamble_type, "preamble type: 0 long (default), 1 short"); static int auth_mode = 0; -MODULE_PARM(auth_mode, "i"); +module_param(auth_mode, int, 0400); MODULE_PARM_DESC(auth_mode, "authentication mode: 0 open system (default), " "1 shared secret"); static int pm_mode = PM_ACTIVE; -MODULE_PARM(pm_mode, "i"); +module_param(pm_mode, int, 0400); MODULE_PARM_DESC(pm_mode, "power management mode: 1 active (def.), 2 powersave, 3 smart save"); static int pm_period = 0; -MODULE_PARM(pm_period, "i"); +module_param(pm_period, int, 0400); MODULE_PARM_DESC(pm_period, "period of waking up the device in usec"); static int international_roaming = IR_OFF; -MODULE_PARM(international_roaming, "i"); +module_param(international_roaming, int, 0400); MODULE_PARM_DESC(international_roaming, "enable international roaming: 0 (no, default), 1 (yes)"); static int default_iw_mode = IW_MODE_INFRA; -MODULE_PARM(default_iw_mode, "i"); +module_param(default_iw_mode, int, 0400); MODULE_PARM_DESC(default_iw_mode, "default IW mode for a new device: " "1 (ad-hoc), 2 (infrastructure, def.), 6 (monitor mode)"); static int monitor_scan_min_time = 50; -MODULE_PARM(monitor_scan_min_time, "i"); +module_param(monitor_scan_min_time, int, 0400); MODULE_PARM_DESC(monitor_scan_min_time, "scan min channel time in MONITOR MODE (default: 50)"); static int monitor_scan_max_time = 600; -MODULE_PARM(monitor_scan_max_time, "i"); +module_param(monitor_scan_max_time, int, 0400); MODULE_PARM_DESC(monitor_scan_max_time, "scan max channel time in MONITOR MODE (default: 600)"); #define DEF_RTS_THRESHOLD 1536 #define DEF_FRAG_THRESHOLD 1536 #define DEF_SHORT_RETRY_LIMIT 8 //#define DEF_LONG_RETRY_LIMIT 4 -#define DEF_ESSID "okuwlan" -#define DEF_ESSID_LEN 7 +#define DEF_ESSID "" +#define DEF_ESSID_LEN 0 #define DEF_CHANNEL 10 #define MAX_RTS_THRESHOLD 2347 @@ -387,6 +357,7 @@ const long channel_frequency[] = { /* the broadcast address */ const u8 bc_addr[ETH_ALEN] = {0xff,0xff,0xff,0xff,0xff,0xff}; +const u8 off_addr[ETH_ALEN] = {0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; /* the supported rates of this hardware, bit7 marks a mandantory rate */ const u8 hw_rates[4] = {0x82,0x84,0x0b,0x16}; @@ -2837,6 +2808,7 @@ kevent(void *data) goto end_startibss; } + netif_carrier_on(dev->netdev); netif_start_queue(dev->netdev); } end_startibss: @@ -2888,6 +2860,7 @@ end_startibss: memcpy(dev->bssid, bptr->bssid, ETH_ALEN); dev->channel = bptr->channel; iwevent_bss_connect(dev->netdev,bptr->bssid); + netif_carrier_on(dev->netdev); netif_start_queue(dev->netdev); /* just to be sure */ del_timer_sync(&dev->mgmt_timer); @@ -4821,7 +4794,9 @@ void at76c503_tx_timeout(struct net_device *netdev) if (!dev) return; warn("%s: tx timeout.", netdev->name); +#if WIRELESS_EXT < 17 dev->write_urb->transfer_flags |= USB_ASYNC_UNLINK; +#endif usb_unlink_urb(dev->write_urb); dev->stats.tx_errors++; } @@ -5152,7 +5127,6 @@ static int ethtool_ioctl(struct at76c503 *dev, void *useraddr) strncpy(info->version, DRIVER_VERSION, sizeof(info->version)); info->version[sizeof(info->version)-1] = '\0'; -#if (LINUX_VERSION_CODE > KERNEL_VERSION(2, 4, 7)) snprintf(info->bus_info, sizeof(info->bus_info)-1, "usb%d:%d", dev->udev->bus->busnum, dev->udev->devnum); @@ -5161,15 +5135,6 @@ static int ethtool_ioctl(struct at76c503 *dev, void *useraddr) "%d.%d.%d-%d", dev->fw_version.major, dev->fw_version.minor, dev->fw_version.patch, dev->fw_version.build); -#else - /* Take the risk of a buffer overflow: no snprintf... */ - sprintf(info->bus_info, "usb%d:%d", dev->udev->bus->busnum, - dev->udev->devnum); - - sprintf(info->fw_version, "%d.%d.%d-%d", - dev->fw_version.major, dev->fw_version.minor, - dev->fw_version.patch, dev->fw_version.build); -#endif if (copy_to_user (useraddr, info, sizeof (*info))) { kfree(info); return -EFAULT; @@ -5678,7 +5643,8 @@ int at76c503_iw_handler_set_wap(struct net_device *netdev, // if the incomming address == ff:ff:ff:ff:ff:ff, the user has // chosen any or auto AP preference - if (!memcmp(ap_addr->sa_data, bc_addr, ETH_ALEN)) { + if (!memcmp(ap_addr->sa_data, bc_addr, ETH_ALEN) + || !memcmp(ap_addr->sa_data, off_addr, ETH_ALEN)) { dev->wanted_bssid_valid = 0; } else { // user wants to set a preferred AP address @@ -5724,6 +5690,10 @@ int at76c503_iw_handler_set_scan(struct net_device *netdev, { struct at76c503 *dev = (struct at76c503*)netdev->priv; unsigned long flags; + int ret = 0; +#if WIRELESS_EXT > 19 + struct iw_scan_req *req = NULL; +#endif dbg(DBG_IOCTL, "%s: SIOCSIWSCAN", netdev->name); @@ -5747,12 +5717,38 @@ int at76c503_iw_handler_set_scan(struct net_device *netdev, netif_carrier_off(dev->netdev); netif_stop_queue(dev->netdev); } + +#if WIRELESS_EXT > 19 + if (wrqu->data.length + && wrqu->data.length == sizeof(struct iw_scan_req)) { + req = (struct iw_scan_req *)extra; + + if (req->scan_type == IW_SCAN_TYPE_PASSIVE) + dev->scan_mode = SCAN_TYPE_PASSIVE; + else if (req->scan_type == IW_SCAN_TYPE_ACTIVE) + dev->scan_mode = SCAN_TYPE_ACTIVE; + + /* Sanity check values? */ + if (req->min_channel_time > 0) { + if (dev->istate == MONITORING) + dev->monitor_scan_min_time = req->min_channel_time; + else + dev->scan_min_time = min_channel_time; + } + if (req->max_channel_time > 0) { + if (dev->istate == MONITORING) + dev->monitor_scan_max_time = req->max_channel_time; + else + dev->scan_max_time = max_channel_time; + } + } +#endif // change to scanning state NEW_STATE(dev, SCANNING); defer_kevent(dev, KEVENT_SCAN); - return 0; + return ret; } static @@ -5884,12 +5880,20 @@ int at76c503_iw_handler_set_essid(struct net_device *netdev, if (data->flags) { memcpy(dev->essid, extra, data->length); - // iwconfig gives len including 0 byte - - // 3 hours debugging... grrrr (oku) - dev->essid_size = data->length - 1; + dev->essid_size = data->length; +#if WIRELESS_EXT < 21 + /* For historic reasons, the SSID length used to include one + * extra character, C string nul termination, even though SSID is + * really an octet string that should not be presented as a C + * string. WE-21 changes this to explicitly require the length + * _not_ to include nul termination, but for WE < 21, decrement + * the length count here to remove the nul termination. */ + dev->essid_size = min(dev->essid_size - 1, 0); +#endif } else { + /* Use any SSID */ dev->essid_size = 0; } @@ -6699,16 +6703,16 @@ static const struct iw_handler_def at76c503_handler_def = .num_standard = sizeof(at76c503_handlers)/sizeof(iw_handler), .num_private = sizeof(at76c503_priv_handlers)/sizeof(iw_handler), .num_private_args = sizeof(at76c503_priv_args)/ - sizeof(struct iw_priv_args), + sizeof(struct iw_priv_args), .standard = (iw_handler *) at76c503_handlers, .private = (iw_handler *) at76c503_priv_handlers, .private_args = (struct iw_priv_args *) at76c503_priv_args, #if WIRELESS_EXT > 16 - .get_wireless_stats = at76c503_get_wireless_stats, -#elif WIRELESS_EXT = 16 + .get_wireless_stats = at76c503_get_wireless_stats, +#endif +#if WIRELESS_EXT == 15 || WIRELESS_EXT == 16 .spy_offset = offsetof(struct at76c503, spy_data), -#endif // #if WIRELESS_EXT > 15 - +#endif }; #endif // #if WIRELESS_EXT > 12 @@ -7144,7 +7148,6 @@ set_debug_end: void at76c503_delete_device(struct at76c503 *dev) { int i; - int sem_taken; if (!dev) return; @@ -7155,14 +7158,17 @@ void at76c503_delete_device(struct at76c503 *dev) dbg(DBG_PROC_ENTRY, "%s: ENTER",__FUNCTION__); if (dev->flags & AT76C503A_NETDEV_REGISTERED) { - if ((sem_taken=down_trylock(&rtnl_sem)) != 0) +#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 17) + if (down_trylock(&rtnl_sem) != 0) { +#else + if (rtnl_trylock() == 0) { +#endif info("%s: rtnl_sem already down'ed", __FUNCTION__); - - /* synchronously calls at76c503_stop() */ - unregister_netdevice(dev->netdev); - - if (!sem_taken) + } else { + /* synchronously calls at76c503_stop() */ + unregister_netdevice(dev->netdev); rtnl_unlock(); + } } PUT_DEV(dev->udev); @@ -7378,11 +7384,7 @@ int init_new_device(struct at76c503 *dev) /* set up the endpoint information */ /* check out the endpoints */ -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 5, 0) dev->interface = dev->udev->actconfig->interface[0]; -#else - dev->interface = &dev->udev->actconfig->interface[0]; -#endif dbg(DBG_DEVSTART, "USB interface: %d endpoints", NUM_EP(dev->interface)); @@ -7415,7 +7417,7 @@ int init_new_device(struct at76c503 *dev) else dev->rx_data_fcs_len = 4; - info("$Id: at76c503.c,v 1.75 2006/02/11 19:18:44 tim_small Exp $ compiled %s %s", __DATE__, __TIME__); + info("$Id: at76c503.c,v 1.76 2006/06/21 08:50:07 maximsch2 Exp $ compiled %s %s", __DATE__, __TIME__); info("firmware version %d.%d.%d #%d (fcs_len %d)", dev->fw_version.major, dev->fw_version.minor, dev->fw_version.patch, dev->fw_version.build, @@ -7564,12 +7566,7 @@ int at76c503_do_probe(struct module *mod, struct usb_device *udev, u8 *fw_data, int fw_size, u32 board_type, const char *netdev_name, void **devptr) { - struct usb_interface *intf = -#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 5, 0) - udev->actconfig->interface[0]; -#else - &udev->actconfig->interface[0]; -#endif + struct usb_interface *intf = udev->actconfig->interface[0]; int ret; struct at76c503 *dev = NULL; int op_mode; @@ -1,5 +1,5 @@ /* -*- linux-c -*- */ -/* $Id: at76c503.h,v 1.33 2006/02/11 19:18:45 tim_small Exp $ +/* $Id: at76c503.h,v 1.34 2006/06/21 08:50:07 maximsch2 Exp $ * * Copyright (c) 2002 - 2003 Oliver Kurth * (c) 2003 - 2004 Jörg Albert <joerg.albert@gmx.de> diff --git a/scripts/fwbin2pkg.sh b/scripts/fwbin2pkg.sh index 1bace97..6e7870f 100755 --- a/scripts/fwbin2pkg.sh +++ b/scripts/fwbin2pkg.sh @@ -17,7 +17,7 @@ OUTF=$3 [ $DEBUG -eq 1 ] && echo "#DBG comment $COMMENT, converting $INF into $OUTF" -echo '/* $Id: fwbin2pkg.sh,v 1.2 2003/12/25 22:40:27 jal2 Exp $ */' > $OUTF +echo '/* $Id: fwbin2pkg.sh,v 1.3 2006/06/21 08:50:08 maximsch2 Exp $ */' > $OUTF echo "/* $COMMENT */" >> $OUTF echo '/**************************************************************************/' >> $OUTF echo '/* */' >> $OUTF @@ -48,4 +48,5 @@ od -An -tx1 -v -w8 $INF | sed 's/\([0-9a-f][0-9a-f]\)/0x\1,/g' >> $OUTF echo '};' >> $OUTF echo '' >> $OUTF echo "const struct firmware static_fw = {`ls -l $INF | awk '{print $5}'`, fw_bin};" >> $OUTF -echo '' >> $OUTF
\ No newline at end of file +echo '' >> $OUTF + |