summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ipw2200.c
AgeCommit message (Collapse)Author
2006-10-05IRQ: Maintain regs pointer globally rather than passing to IRQ handlersDavid Howells
Maintain a per-CPU global "struct pt_regs *" variable which can be used instead of passing regs around manually through all ~1800 interrupt handlers in the Linux kernel. The regs pointer is used in few places, but it potentially costs both stack space and code to pass it around. On the FRV arch, removing the regs parameter from all the genirq function results in a 20% speed up of the IRQ exit path (ie: from leaving timer_interrupt() to leaving do_IRQ()). Where appropriate, an arch may override the generic storage facility and do something different with the variable. On FRV, for instance, the address is maintained in GR28 at all times inside the kernel as part of general exception handling. Having looked over the code, it appears that the parameter may be handed down through up to twenty or so layers of functions. Consider a USB character device attached to a USB hub, attached to a USB controller that posts its interrupts through a cascaded auxiliary interrupt controller. A character device driver may want to pass regs to the sysrq handler through the input layer which adds another few layers of parameter passing. I've build this code with allyesconfig for x86_64 and i386. I've runtested the main part of the code on FRV and i386, though I can't test most of the drivers. I've also done partial conversion for powerpc and MIPS - these at least compile with minimal configurations. This will affect all archs. Mostly the changes should be relatively easy. Take do_IRQ(), store the regs pointer at the beginning, saving the old one: struct pt_regs *old_regs = set_irq_regs(regs); And put the old one back at the end: set_irq_regs(old_regs); Don't pass regs through to generic_handle_irq() or __do_IRQ(). In timer_interrupt(), this sort of change will be necessary: - update_process_times(user_mode(regs)); - profile_tick(CPU_PROFILING, regs); + update_process_times(user_mode(get_irq_regs())); + profile_tick(CPU_PROFILING); I'd like to move update_process_times()'s use of get_irq_regs() into itself, except that i386, alone of the archs, uses something other than user_mode(). Some notes on the interrupt handling in the drivers: (*) input_dev() is now gone entirely. The regs pointer is no longer stored in the input_dev struct. (*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking. It does something different depending on whether it's been supplied with a regs pointer or not. (*) Various IRQ handler function pointers have been moved to type irq_handler_t. Signed-Off-By: David Howells <dhowells@redhat.com> (cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)
2006-09-25[PATCH] WE-21 for ipw2200Jean Tourrilhes
Signed-off-by: Jean Tourrilhes <jt@hpl.hp.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-09-13drivers/net: const-ify ethtool_ops declarationsJeff Garzik
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-09-06Merge branch 'upstream' of ↵Jeff Garzik
master.kernel.org:/pub/scm/linux/kernel/git/linville/wireless-2.6 into upstream
2006-08-29[PATCH] ipw2200: Fix compile error when CONFIG_IPW2200_DEBUG is not selectedZhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: Update version stamp to 1.1.4Zhu Yi
Update version ipw2200 stamp to 1.1.4 Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: enable wireless extension passive scanZhu Yi
This patch enables the ipw2200 driver to support passive scanning as offered by the wireless extensions. For this, I enhanced the ipw_wx_set_scan function in such a way that it differentiates between a passive and an active scan request. Additionally, I added a new function called ipw_request_passive_scan that is similiar to the ipw_request_scan function to perform passive scans. Last but not least, I added a field (in fact it is a work_struct struct) called request_passive_scan to the ipw_priv struct. Signed-off-by: Thomas King <king@informatik.uni-mannheim.de> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: Add pci .shutdown handlerZhu Yi
If we don't disable the card in the pci .shutdown method, there might be pending interrupts still in the interrupt line after a reboot on some platform. This patch fixes the problem by disable the hardware in the pci .shutdown method. Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: mark "iwconfig retry 255" as invalidZhu Yi
The ipw2200 firmware/ucode only support values from 0 to 254. So mark 255 as invalid. Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: remove the MAC timestamp present field from radiotap headZhu Yi
IEEE80211_RADIOTAP_TSFT is defined as the Value in microseconds of the MAC's 64-bit 802.11 Time Synchronization Function timer when the first bit of the MPDU arrived at the MAC. Since ipw2200 hardware doesn't provide this value, we disable this feature from the radiotap header present flag. Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: Fix ipw2200 QOS parameters endian issueZhu Yi
Signed-off-by: Jackie Wu <jackie.wu@intel.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: remove unused struct ipw_rx_bufferZhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: Reassociate even if set the same essid.Zhu Yi
This patch traps the case when the essid is being set to its current value. If the essid is being set again and we are already associated, chances are some other parameters have also been altered. I think it is safer to do the re-association for this case. Signed-off-by: Bill Moss <bmoss@clemson.edu> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: ipw_wx_set_essid fixZhu Yi
This patch cleanups the ipw_wx_set_essid code and forces a reassociation when setting the essid to "any". I have tested this patch with iwconfig. It makes ipw2200 compliant with all the cases mentioned in the iwconfig man page. The commands iwconfig iface essid any iwconfig iface essid -- any iwconfig iface essid off iwconfig iface essid on all seemed to work correctly. None of this worked before the patch. Note, this patch treats iwconfig iface essid iwconfig iface essid "" The same. It produces an error message: essid: Unknown host. Since an essid of "" is not mentioned in the iwconfig man page. Signed-off-by: Bill Moss <bmoss@clemson.edu> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: SIOCGIWFREQ ioctl returns frequency rather than channelZhu Yi
The SIOCGIWFREQ ioctl fills the request structure's freq field by setting the exponent to 0 and the mantissa to the current channel number. The iwconfig tool works around this behaviour by looking up the frequency from the channel table if a frequency below 1kHz is returned, other tools (e.g. kwlaninfo) don't. According to the comment in the iwconfig source the driver is supposed to return the frequency, not the channel number. Signed-off-by: Ingo van Lil <inguin@gmx.de> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-29[PATCH] ipw2200: always enable frequently used debugging codeZhu Yi
Moving part of the debugging code from IPW_DEBUG to IPW_LL_DEBUG (low level debugging) and make IPW_DEBUG be always enabled. IPW_LL_DEBUG still needs to be enabled by selecting CONFIG_IPW2200_DEBUG. But it is highly deprecated for normal users since it adds higher debug verbosity in driver hot paths. Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-08-19drivers/net: Remove deprecated use of pci_module_init()Jeff Garzik
From: Michal Piotrowski <michal.k.k.piotrowski@gmail.com> Signed-off-by: Michal Piotrowski <michal.k.k.piotrowski@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-07-27[PATCH] cleanup // comments from ipw2200Pavel Machek
ipw2200 uses // comments, and uses them for removing unneeded code. Clean it up a bit. Signed-off-by: Pavel Machek <pavel@suse.cz> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-07-02[PATCH] irq-flags: drivers/net: Use the new IRQF_ constantsThomas Gleixner
Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@elte.hu> Cc: "David S. Miller" <davem@davemloft.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Jeff Garzik <jeff@garzik.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-06-27[PATCH] Remove redundant NULL checks before [kv]free - in drivers/Jesper Juhl
Remove redundant NULL chck before kfree + tiny CodingStyle cleanup for drivers/ Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-06-15[PATCH] ipw2200 locking fixZhu Yi
Well, this is not 100% if when the card fires two consecutive interrupts. Though unlikely, it's better to protect early than seeing some "weird" bugs one day. I proposed attached patch. If you can help to test, that will be appreciated (I cannot see the lockdep warning on my box somehow). Cc: Frederik Deweerdt <deweerdt@free.fr> Cc: Arjan van de Ven <arjan@infradead.org> Cc: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: Fix wpa_supplicant association problemZhu Yi
The new ipw2200 scan completion event feature will cause a potential event race condition in wpa_supplicant. The patch fixes this problem by move the ipw_disassociate() to the IW_AUTH_WPA_ENABLED event handling code. Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: remove priv->last_noise referenceZhu Yi
priv->last_noise is not used with the exponential averaging algorithm Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: rename CONFIG_IEEE80211_RADIOTAP to CONFIG_IPW2200_RADIOTAPZhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: rename CONFIG_IPW_QOS to CONFIG_IPW2200_QOSZhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: update version stamp to 1.1.2Zhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: version string reworkZhu Yi
Added version string fields so the version string indicates what is configured (ie, you'll see 1.1.1kpmd if you are using a GIT snapshot (Kernel.. previously -git), promiscuous (p), monitor (m), debug (d) build. Signed-off-by: James Ketrenos <jketreno@linux.intel.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: Enable rtap interface for RF promiscuous mode while associatedZhu Yi
With this patch, a new promiscuous mode is enabled. If the module is loaded with the rtap_iface=1 module parameter, two interfaces will be created (instead of just one). The second interface is prefixed 'rtap' and provides received 802.11 frames on the current channel to user space in a radiotap header format. Example usage: % modprobe ipw2200 rtap_iface=1 % iwconfig eth1 essid MyNetwork % dhcpcd eth1 % tcpdump -i rtap0 If you do not specify 'rtap_iface=1' then the rtap interface will not be created and you will need to turn it on via: % echo 1 > /sys/bus/pci/drivers/ipw2200/*/rtap_iface You can filter out what type of information is passed to user space via the rtap_filter sysfs entry. Currently you can tell the driver to transmit just the headers (which will provide the RADIOTAP and IEEE 802.11 header but not the payload), to filter based on frame control type (Management, Control, or Data), and whether to report transmitted frames, received frames, or both. The transmit frame reporting is based on a patch by Stefan Rompf. Filters can be get and set via a sysfs interface. For example, set the filter to only send headers (0x7), don't report Tx'd frames (0x10), and don't report data frames (0x100): % echo 0x117 > /sys/bus/pci/drivers/ipw2200/*/rtap_filter All your packets are belong to us: % tethereal -n -i rtap0 Signed-off-by: James Ketrenos <jketreno@linux.intel.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: Fix endian issues with v3.0 fw image formatZhu Yi
This patch corrects endian issues with the v3.0 fw image format. Signed-off-by: James Ketrenos <jketreno@linux.intel.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: Set the 'fixed' flags in wext get_rateZhu Yi
Signed-off-by: Jean Tourrilhes <jt@hpl.hp.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: turn off signal debug logZhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: Do not continue loading the firmware if kmalloc failsZhu Yi
Signed-off-by: Ingo Molnar <mingo@elte.hu> Cc: "Zhu, Yi" <yi.zhu@intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: fix compile warning when !CONFIG_IPW2200_DEBUGZhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: add module_param support for antenna selectionZhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: generates a scan event after a scan has completedZhu Yi
The patch make ipw2200 generate the scan event every time a scan has completed, so that user space know when to get fresh results. Dan Williams would like to go towards this model in Network Manager rather than having to poll. Signed-off-by: Jean Tourrilhes <jt@hpl.hp.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: Fix TX QoS enabled frames problemZhu Yi
This patch works with the ieee80211 stack to set the correct QoS bit to the ipw2200 card. It fixed the TX failure problem for using WPA with QoS. Signed-off-by: Hong Liu <hong.liu@intel.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-24[PATCH] ipw2200: Exponential averaging for signal and noise LevelZhu Yi
This patch replaces sliding averaging by exponential averaging for reporting the wireless statistics for signal and noise level for ipw2200. See details from: http://www.ces.clemson.edu/linux/ipw2200_averages.shtml Signed-off-by: Bill Moss <bmoss@clemson.edu> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-04-02BUG_ON() Conversion in drivers/net/Eric Sesterhenn
this changes if() BUG(); constructs to BUG_ON() which is cleaner, contains unlikely() and can better optimized away. Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de> Signed-off-by: Adrian Bunk <bunk@stusta.de>
2006-03-17[PATCH] ipw2x00: expend Copyright to 2006Zhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] drivers/net/wireless/ipw2200.c: fix an array overunAdrian Bunk
This patch fixes a big array overun found by the Coverity checker. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] ipw2200: Update ipw2200 version stamp to 1.1.1Zhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] ipw2200: switch to the new ipw2200-fw-3.0 image formatJames Ketrenos
This patch modifies the driver to support the ipw2200-fw-3.0 image format. The 3.0 fw image does not add any new capabilities, but as a result of image format changes, it should fix two problems experienced by users: 1) Race conditions with the request_firmware interface and udev/hotplug are improved as only a single request_firmware call is now required to load the firmware and microcode (vs. 3 separate calls previously) 2) The monitor mode firmware (sniffer) is now packaged with the correct boot image so it can now function without frequent restarts. Note: Once you apply this patch, you will also need to upgrade your firmware image to the 3.0 version available from: http://ipw2200.sf.net/firmware.php Signed-off-by: James Ketrenos <jketreno@linux.intel.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] ipw2200: wireless extension sensitivity threshold supportOlivier Hochreutiner
The patch allows the user to set the handover threshold, i.e. the number of consecutively missed beacons that will trigger a roaming attempt. The disassociation threshold is set to 3 times the handover threshold. Signed-off-by: Olivier Hochreutiner <olivier.hochreutiner@epfl.ch> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] ipw2200: Enables the "slow diversity" algorithmCahill, Ben M
This forces one antenna or the other, if the background noise is significantly quieter in one than the other. It favors the quieter antenna, and won't kick in unless the difference is significant. Signed-off-by: Cahill, Ben M <ben.m.cahill@intel.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] ipw2200: Set a meaningful silence threshold valueCahill, Ben M
Set a meaningful silence threshold value (replacing our previous "0" default), which gets rid of the gratuitous "Link deterioration" notifications that we've been receiving from firmware. This notification feature tells the driver information to help it determine when to pre-emptively restart the firmware/ucode in anticipation of firmware errors! But since setting this new threshold, I haven't seen any such notifications. At least it keeps the logs a little less busy. Signed-off-by: Cahill, Ben M <ben.m.cahill@intel.com> Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] ipw2200: export `debug' module param only if CONFIG_IPW2200_DEBUGZhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] ipw2200: Change debug level for firmware error loggingZhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] ipw2200: Filter unsupported channels out in ad-hoc modeZhu Yi
Currently iwlist ethX freq[uency]/channel lists all the channels the card supported for the current region, which includes some channels can only be used in infrastructure mode. This patch filters these channels out if the card is currently in ad-hoc mode. Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] ipw2200: Fix ipw_sw_reset() implementation inconsistent with commentZhu Yi
Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-17[PATCH] ipw2200: Fix rf_kill is activated after mode change with 'disable=1'Zhu Yi
When loading the ipw2200 module with disabled=1, rf_kill is activated after every mode change. This is caused by ipw_sw_reset() is called when a mode is changed. The patch fixed the problem by distinguishing the purposes with the 'option' paramenter. Signed-off-by: Zhu Yi <yi.zhu@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>