Replace Host AP version of WEP, TKIP, CCMP implementation with
net/ieee80211 that has more or less identical implementation (since
it is based on the Host AP implementation). Remove Host AP specific
implementation and modules from drivers/net/wireless/hostap.
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Preparations for starting to use net/ieee80211 instead of private
IEEE 802.11 implementation. Include net/ieee80211.h and
net/ieee80211_crypt.h into files that will be needed these in the
future. Remove duplicate definitions from hostap_common.h and
rename WLAN_FC_GET_{TYPE,STYPE} macros for now sinc net/ieee80211.h
is using incompatible definitions. This will be resolved in the
future by updating Host AP to use the versions that do not shift
type/stype.
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Fixed beacon frame when moving from monitor mode to master mode
(workaround for firmware bug that left IBSS IE in the Beacon
frames). This is using the same workaround that was previously used
when moving from adhoc mode to master mode.
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Warning fix for 64-bit platforms
Hello!
The patch fixes following warning seen on 64-bit platforms (in my case -
x86_64, gcc-4.0):
In file included from /usr/local/src/hostap/driver/modules/hostap_cs.c:203:
/usr/local/src/hostap/driver/modules/hostap_hw.c: In function ?prism2_transmit_cb?:
/usr/local/src/hostap/driver/modules/hostap_hw.c:1674: warning: cast from pointer to integer of different size
/usr/local/src/hostap/driver/modules/hostap_hw.c: In function ?prism2_transmit?:
/usr/local/src/hostap/driver/modules/hostap_hw.c:1758: warning: cast to pointer from integer of different size
prism2_transmit_cb uses a (void *) argument to get an integer. A
simple fix would be to use double cast from pointer to long and then to
int (and vice versa when int is passed as a pointer). But I prefer a
slightly longer patch.
I believe that whenever an argument can hold both a pointer and an
integer, it should be declared long. long can hold both pointers and
integers (except win64, but we are not coding for Windows), it can be
cast to both of them and it's never assumed to be a valid pointer, which
could be useful for some automatic code checkers.
Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
line 129 of hostap_80211_rx.c should read:
LWNG_SETVAL(mactime, 2, 0, 4, rx_stats->mac_time);
not:
LWNG_SETVAL(mactime, 2, 0, 0, rx_stats->mac_time);
The length field is incorrect.
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Firmware seems to be getting into odd state in host_roaming mode 2
when hostscan is used without join command, so try to fix this by
re-joining the current AP. This does not actually trigger a new
association if the current AP is still in the scan results.
This makes background scans (iwlist wlan0 scan) not to break data
connection when in host_roaming 2 mode, e.g., when using wpa_supplicant.
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Cleaned up scan result processing by converting struct
hfa384x_scan_result into struct hfa384x_hostscan_result. This removes
special cases from result processing since the results are only used
in one, hostscan, format.
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Added support for setting channel mask for scan requests
('iwpriv wlan0 scan_channels 0x00ff' masks scans to use channels 1-8).
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Add MODULE_VERSION information for the Host AP kernel modules and
update the version string to indicate which version of the external
Host AP driver is included in the kernel tree.
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
pcmcia id_table for hostap_cs.c
Hi Jouni,
Here's a patch for adding a pcmcia id_table to hostap_cs.c as introduced
by the PCMCIA subsystem changes in linux-2.6.13-rc1. The id_table allows
hotplug (along with pcmciautils [1]) to load the driver without the need
for the pcmcia-cs cardmgr daemon.
The id_table was generated from the CVS version of hostap_cs.conf using
a script borrowed from Dominik Brodowski. I have removed any duplicate
entries, but I have only been able to test the functionality of the
patch with a Linksys WPC11v3.
Sincerely,
Brix
[1]: http://www.kernel.org/pub/linux/utils/kernel/pcmcia/
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Create sysfs "device" files for hostap
I was writing some scripts to automatically build kismet source lines,
and I noticed that hostap devices don't have device files, unlike my
prism54 and ipw2200 cards:
$ ls -l /sys/class/net/eth0/device
/sys/class/net/eth0/device -> ../../../devices/pci0000:00/0000:00:1e.0/0000:02:01.0
$ ls -l /sys/class/net/wifi0
ls: /sys/class/net/wifi0/device: No such file or directory
$ ls -l /sys/class/net/wlan0
ls: /sys/class/net/wlan0/device: No such file or directory
The following (quite small) patch makes sure that both the wlan and wifi
net devices have that pointer to the bus device.
This way, I can do things like
for i in /sys/class/net/*; do
if ! [ -e $i/device/drive ]; then
continue;
fi;
driver=$(basename $(readlink $i/device/driver))
case $driver in
hostap*)
echo -- hostap,$i,$i-$driver
break;
ipw2?00)
echo -- $driver,$i,$i-$driver
break;
prism54)
echo prism54g,$i
esac
done
Which should generate a working set of source lines for kismet no matter
what order I plug the cards in.
It might also be handy to have a link between the two net devices, but
that's a patch for another day.
That patch is against 2.6.13-rc1-mm1.
-- Dave
Signed-off-by: Dave Hansen <haveblue@us.ibm.com>
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
hostap_cs: Remove irq_list, irq_mask and pcmcia/version.h
Remove irq_list, irq_mask and pcmcia/version.h as suggested in
http://kernel.org/pub/linux/utils/kernel/pcmcia/pcmcia.html
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
EXPORT_SYMTAB does nothing. There's no need to define something if it
doesn't have any effect.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Update hostap_cs to use new PCMCIA event callback registration.
Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi>
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
When leaving S3 state, the AGP bridge may not have all PCI configuration
registers set in the same way as they were at boot. This should be fixed
by pci_restore_state - however, the APBASE register cannot be set to
conflict with the APSIZE register. If APSIZE is larger than it was before
suspend, pci_restore_state will not restore APBASE correctly. The attached
patch adds an extra item to the agp_bridge_data structure and uses it to
store the value of APBASE. On resume, this is then written after APSIZE
has been set. This patch only touches the path used for Intel chipsets
without integrated graphics, and may need to be extended to work with the
others.
Without this patch, I get the symptoms described in bug 4921 - APBASE ends
up overlapping various PCI devices, and as a result they fail to work after
resume.
Signed-off-by: Matthew Garrett <mjg59@srcf.ucam.org>
Acked-by: Dave Jones <davej@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Close a small window where a device may be not operational again after senseid
finished and the "same device" check fails due to dev=0000 by checking for dnv
after stsch() by then setting the device to not operational. (No need to
check for dnv in ccw_device_handle_oper() again since we don't do stsch() into
the subchannel's schib in the meantime and will get a crw anyway if the device
becomes not oper again).
Signed-off-by: Cornelia Huck <cohuck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
The patch that introduced waiting for interrupts after resetting the reader
can cause the boot to fail because the system is waiting for an interrupt that
will never arrive. Add code to check if an interrupt is supposed to arrive
before waiting endlessly.
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
The #if/#ifdef cleanup exposed a bug in UML's ELF header processing. With
this bug fixed, UML recognizes the vsyscall info coming from the host. On
FC4, there is a vsyscall page low in the address space, which UML doesn't
provide. This causes an infinite page fault loop and a hang on boot.
This patch works around that by making this look like a no-vsyscall system.
Signed-off-by: Jeff Dike <jdike@addtoit.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Do not use memcpy in fb_pad_aligned_buffer. It is suboptimal because only
a few bytes are moved at a time. Replace with a for-loop.
Signed-off-by: Antonino Daplas <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
The patch addresses a problem with ACPI SCI interrupt entry, which gets
re-used, and the IRQ is assigned to another unrelated device. The patch
corrects the code such that SCI IRQ is skipped and duplicate entry is
avoided. Second issue came up with VIA chipset, the problem was caused by
original patch assigning IRQs starting 16 and up. The VIA chipset uses
4-bit IRQ register for internal interrupt routing, and therefore cannot
handle IRQ numbers assigned to its devices. The patch corrects this
problem by allowing PCI IRQs below 16.
Signed-off by: Natalie Protasevich <Natalie.Protasevich@unisys.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
>> vesafb: mode is 800x600x16, linelength=1600, pages=16
>> vesafb: scrolling: redraw
>> vesafb: Truecolor: size=0:5:6:5, shift=0:11:5:0
>> mtrr: type mismatch for fc000000,1000000 old: write-back new: write-
>> combining
Range is already set to write-back, vesafb attempts to add a write-combining
mtrr (default for vesafb).
>> mtrr: size and base must be multiples of 4 kiB
This is a bug, vesafb attempts to add a size < PAGE_SIZE triggering
the messages below.
To eliminate the warning messages, you can add the option mtrr:2 to add a
write-back mtrr for vesafb. Or just use nomtrr option.
1. Fix algorithm for finding the best power of 2 size with mtrr_add().
2. Add option to choose the mtrr type by extending the mtrr boot option:
mtrr:n where n
0 = no mtrr (equivalent to using the nomtrr option)
1 = uncachable
2 = write back
3 = write combining (default)
4 = write through
Signed-off-by: Antonino Daplas <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Add support for UARTs in MMIO space and clean up a little whitespace.
HP legacy-free ia64 machines need this.
Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
sync_tsc was using smp_call_function to ask the boot processor to report
it's tsc value. smp_call_function performs an IPI_send_allbutself which is
a broadcast ipi. There is a window during processor startup during which
the target cpu has started and before it has initialized it's interrupt
vectors so it can properly process an interrupt. Receveing an interrupt
during that window will triple fault the cpu and do other nasty things.
Why cli does not protect us from that is beyond me.
The simple fix is to match ia64 and provide a smp_call_function_single.
Which avoids the broadcast and is more efficient.
This certainly fixes the problem of getting stuck on boot which was
very easy to trigger on my SMP Hyperthreaded Xeon, and I think
it fixes it for the right reasons.
Minor changes by AK
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
While reserving KVA for lmem_maps of node, we have to make sure that
node_remap_start_pfn[] is aligned to a proper pmd boundary.
(node_remap_start_pfn[] gets its value from node_end_pfn[])
Signed-off-by: Ravikiran Thirumalai <kiran@scalex86.org>
Signed-off-by: Shai Fultheim <shai@scalex86.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
It seems that I see a bug in hidinput_hid_event. The check for NULL can never
work, becaue &hidinput->input is nonzero at all times.
Cc: <vojtech@suse.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This patch does the same swap, i.e. use the ISO macro if (isoc).
Additionally, it fixes the return value - the usb_calc_bus_time function
returns the time in nanoseconds (I didn't notice that before) while the
HS_USECS and HS_USECS_ISO are microseconds. This fixes the function to
return nanoseconds always, and adjusts ehci-q.c (the only high-speed
caller of the function) to wrap the call in NS_TO_US().
Signed-off-by: Dan Streetman <ddstreet@ieee.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
USB (OHCI) Host driver for S3C2410/S3C2440 based systems
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Gigabyte GN-WLBZ201 wifi usb dongle works very well, using the zd1201
driver. the only missing part is that the corresponding usbid is not
declared. The following patch should fix this.
From: "Mathieu" <matt@minas-morgul.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This patch enables a support of KYOCERA AH-K3001V, one of the most
popular cell phone in Japan. This device has vendor specific ID but works
with acm driver by adding USB ID. This device already works on
FreeBSD and OS X by native USB ACM driver with USB ID added.
This device is probed as NO_UNION_NORMAL not to hang up when probing.
Signed-off-by: Masahito Omote <omote@utyuuzin.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This patch handles a rarely-encountered failure mode in usbcore. It's
legal for device_add to fail (although now it happens even more rarely
than before since failure to bind a driver is no longer fatal). So when
we destroy the interfaces in a configuration, we shouldn't try to delete
ones which weren't successfully registered. Also, failure to register an
interface shouldn't be fatal either -- I think; you may disagree about
this part of the patch.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
The only uses of both variables were recently removed.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This patch fixes an information leak in the usbfs snoop facility:
uninitialized data from __get_free_page can be returned to userspace and
written to the system log. It also improves the snoop output by printing
the wLength value.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
ftdi_sio: Fix timeouts in a couple of usb_control_msg() calls due to
change of units from jiffies to milliseconds in 2.6.12.
Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
ftdi_sio: Update RTS and DTR simultaneously, using a single control URB
instead of separate control URBs for RTS and DTR. Reinhard Bergmann
observed time differences of up to 680 ms with his application on a
2.4.22 kernel when RTS and DTR were updated using separate control
URBs, which is unacceptable.
Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
The attached patch adds the following new devices to the ftdi_sio driver:
* microHAM USB-Y6 and USB-Y8 devices submitted by Justin Burket (KL1RL).
* Evolution Robotics ER1 Control Module submitted by Shawn M. Lavelle.
Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
In the patch from:
http://www.uwsg.iu.edu/hypermail/linux/kernel/0506.3/0985.html
Is the the following line suppose inside the if CONFIG_PCI=n
#define pci_dma_burst_advice(pdev, strat, strategy_parameter) do { } while (0)
Signed-off-by: Kumar Gala <kumar.gala@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
The setup-bus code doesn't work correctly for configurations
with more than one display adapter in the same PCI domain.
This stuff actually is a leftover of an early 2.4 PCI setup code
and apparently it stopped working after some "bridge_ctl" changes.
So the best thing we can do is just to remove it and rely on the fact
that any firmware *has* to configure VGA port forwarding for the boot
display device properly.
But then we need to ensure that the bus->bridge_ctl will always
contain valid information collected at the probe time, therefore
the following change in pci_scan_bridge() is needed.
Signed-off-by: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
There are ROMs reporting that their size exceeds their PCI ROM
resource window. This patch returns the minimum of the resource window
size or the size in the ROM. An example of this breakage is the XGI
Volari Z7.
Signed-off-by: Jon Smirl <jonsmirl@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This patch was sent first time very long time ago,
but magically was disapeared, it probably exists
in your queue, but to be sure, I resend it.
If can not be applied cleanly after your w1 queue is flushed
into upstrem tree, just drop it.
Thanks.
Patch from Michael Farmbauer <michl@baldrian.franken.de>.
Signed-off-by: Evgeniy Polyakov <johnpol@2ka.mipt.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
The 24RF08 corruption prevention in the eeprom and max6875 drivers wasn't
complete. For one thing, the additional quick write should happen as soon
as possible and unconditionally, while both drivers had error paths before.
For another, when a given chip is forced, the core does not emit a quick
write, so a second quick write would cause the corruption rather than
prevent it.
I plan to move the corruption prevention in the core in the long run, so
that individual drivers don't have to care anymore. But I need to merge
i2c_probe and i2c_detect before I do (work in progress).
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Two log messages lack their trailing new line in i2c-core. I'd swear I had
fixed them already, but it seems not. Bonus: improved coding style.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
A few i2c drivers were not updated to use time_after() yet.
Signed-off-by: Marcelo Feitoza Parisi <marcelo@feitoza.com.br>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>