20 Feb, 2010

3 commits

  • The most needed command from nl80211, which Wireless Extensions had,
    is support for power save mode. Add a simple command to make it possible
    to enable and disable power save via nl80211.

    I was also planning about extending the interface, for example adding the
    timeout value, but after thinking more about this I decided not to do it.
    Basically there were three reasons:

    Firstly, the parameters for power save are very much hardware dependent.
    Trying to find a unified interface which would work with all hardware, and
    still make sense to users, will be very difficult.

    Secondly, IEEE 802.11 power save implementation in Linux is still in state
    of flux. We have a long way to still to go and there is no way to predict
    what kind of implementation we will have after few years. And because we
    need to support nl80211 interface a long time, practically forever, adding
    now parameters to nl80211 might create maintenance problems later on.

    Third issue are the users. Power save parameters are mostly used for
    debugging, so debugfs is better, more flexible, interface for this.
    For example, wpa_supplicant currently doesn't configure anything related
    to power save mode. It's better to strive that kernel can automatically
    optimise the power save parameters, like with help of pm qos network
    and other traffic parameters.

    Later on, when we have better understanding of power save, we can extend
    this command with more features, if there's a need for that.

    Signed-off-by: Kalle Valo
    Signed-off-by: John W. Linville

    Kalle Valo
     
  • fix off by one error in the queue size check of p54_tx_qos_accounting_alloc()

    Coverity CID: 13314

    Signed-off-by: Darren Jenkins
    Signed-off-by: John W. Linville

    Darren Jenkins
     
  • ...and use it in hostap_cs and orinoco_cs.

    Another PCMCIA device with Intersil Prism chipset has been reported:

    Socket 0:
    product info: "Gigabyte", "GN-WLM01_P25L_ADAPTER", "ISL37300P", "Eval-RevA"
    manfid: 0x02e0, 0x1011
    function: 6 (network)

    As it's the case with some other Prism based devices, the third ID
    string contains a design name that should be sufficient to identify the
    card as having Intersil Prism chipset and thus compatible with both
    orinoco_cs and hostap_cs.

    Introduce PCMCIA_DEVICE_PROD_ID3 that matches the third ID string only.

    Use it in orinoco_cs and hostap_cs to match cards with the third ID
    string indicating Prism chipset. Remove corresponding entries that use
    PCMCIA_DEVICE_PROD_ID123.

    Reported-by: Ozzy
    Signed-off-by: Pavel Roskin
    Signed-off-by: John W. Linville

    Pavel Roskin
     

17 Feb, 2010

3 commits

  • Instead of hardcoding the lowest rate for Beacon frames, use the rate
    index specified in the mac80211 TX info in AP mode.

    Signed-off-by: Jouni Malinen
    Signed-off-by: John W. Linville

    Jouni Malinen
     
  • Currently, ieee80211_drop_unencrypted is called
    from management and data frame context, and the
    different contexts pass different frames. This
    could lead to it processing an 802.3 frame as an
    802.11 frame when MFP is enabled.

    Move the MFP part of ieee80211_drop_unencrypted
    into a new function that is only called for mgmt
    frames.

    Cc: Jouni Malinen
    Signed-off-by: Johannes Berg
    Signed-off-by: John W. Linville

    Johannes Berg
     
  • Use spin_[un]lock_bh in mwl8k_sta_notify(). The sta_notify handler is
    required to be atomic, yet it can be called in process context, so make
    sure one call won't preempt another.

    Signed-off-by: Pavel Roskin
    Signed-off-by: John W. Linville

    Pavel Roskin
     

16 Feb, 2010

14 commits

  • This implements a new command to register for action frames
    that userspace wants to handle instead of the in-kernel
    rejection. It is then responsible for rejecting ones that
    it decided not to handle. There is no unregistration, but
    the socket can be closed for that.

    Frames that are not registered for will not be forwarded
    to userspace and will be rejected by the kernel, the
    cfg80211 API helps implementing that.

    Additionally, this patch adds a new command that allows
    doing action frame transmission from userspace. It can be
    used either to exchange action frames on the current
    operational channel (e.g., with the AP with which we are
    currently associated) or to exchange off-channel Public
    Action frames with the remain-on-channel command.

    Signed-off-by: Jouni Malinen
    Signed-off-by: Johannes Berg
    Signed-off-by: John W. Linville

    Jouni Malinen
     
  • 802.11-2007 7.3.1.11 mandates that we need to
    reject action frames we don't handle by setting
    the 0x80 bit in the category and returning them
    to the sender, so do that. In AP mode, hostapd
    is responsible for this.

    Additionally, drop completely malformed action
    frames or ones that should've been encrypted as
    unusable, userspace shouldn't see those.

    Signed-off-by: Johannes Berg
    Signed-off-by: Jouni Malinen
    Signed-off-by: John W. Linville

    Johannes Berg
     
  • Support for rt30xx- and rt35xx-based devices is currently not functional
    in rt2800pci and rt2800usb.
    In order to not confuse users we shouldn't claim the PCI and USB device
    ID's for these devices. However, to allow for testing it is good to still
    have them available, although disabled by default.
    Make support for these device configuration options that default to off.

    For rt2800usb a 3rd class of devices is added, which are the unknown
    devices. For these devices it is known that they are either based on
    rt28xx, rt30xx or rt35xx, but it is not known on what chipset exactly.
    These devices are disabled by default as well, until it can be established
    on what chipset exactly they are based.

    Signed-off-by: Gertjan van Wingerde
    Signed-off-by: John W. Linville

    Gertjan van Wingerde
     
  • The recent rt2800 devices are no longer really identified by their PCI
    ID's, but rather by the contents of their CSR0 register. Also for the
    other chipsets is the contents of this CSR0 register important.
    Change the chipset determination logic to be more aligned with the rt2800
    model.
    Preparation for the support of rt3070 / rt3090 based devices.

    Signed-off-by: Gertjan van Wingerde
    Acked-by: Ivo van Doorn
    Signed-off-by: John W. Linville

    Gertjan van Wingerde
     
  • Don't set the RT chipset for a device from within the generic PCI/SOC code,
    but rather from the individual drivers, so that individual drivers have
    more control over what RT chipset is set.
    Preparation for chip handling updates for rt2800 devices.

    Signed-off-by: Gertjan van Wingerde
    Acked-by: Ivo van Doorn
    Signed-off-by: John W. Linville

    Gertjan van Wingerde
     
  • Introduce the SoC interface type to detect SoC devices, instead of having
    them mimic being PCI devices.
    This allows for easier detection of SoC devices.

    Signed-off-by: Gertjan van Wingerde
    Acked-by: Ivo van Doorn
    Signed-off-by: John W. Linville

    Gertjan van Wingerde
     
  • Signed-off-by: Shimada Hirofumi
    Signed-off-by: YOSHIFUJI Hideaki
    Signed-off-by: John W. Linville

    Shimada Hirofumi
     
  • Cc: Michael Buesch
    Signed-off-by: Hauke Mehrtens
    Signed-off-by: John W. Linville

    Hauke Mehrtens
     
  • Cc: Herton Ronaldo Krzesinski
    Cc: Larry Finger
    Signed-off-by: Hauke Mehrtens
    Acked-by: Hin-Tak Leung
    Signed-off-by: John W. Linville

    Hauke Mehrtens
     
  • Cc: Larry Finger
    Cc: Stefano Brivio
    Signed-off-by: Hauke Mehrtens
    Signed-off-by: John W. Linville

    Hauke Mehrtens
     
  • When WEXT_PRIV is not enabled, airo_cs has build errors.
    It needs to include net/iw_handler.h and it should select
    WEXT_PRIV, like the airo driver does.

    drivers/net/wireless/airo.c:7655: error: unknown field 'num_private' specified in initializer
    drivers/net/wireless/airo.c:7655: warning: initialization makes pointer from integer without a cast
    drivers/net/wireless/airo.c:7656: error: unknown field 'num_private_args' specified in initializer
    drivers/net/wireless/airo.c:7656: warning: excess elements in struct initializer
    drivers/net/wireless/airo.c:7656: warning: (near initialization for 'airo_handler_def')
    drivers/net/wireless/airo.c:7658: error: unknown field 'private' specified in initializer
    drivers/net/wireless/airo.c:7658: warning: initialization makes integer from pointer without a cast
    drivers/net/wireless/airo.c:7658: error: initializer element is not computable at load time
    drivers/net/wireless/airo.c:7658: error: (near initialization for 'airo_handler_def.num_standard')
    drivers/net/wireless/airo.c:7659: error: unknown field 'private_args' specified in initializer
    drivers/net/wireless/airo.c:7659: warning: initialization from incompatible pointer type

    Signed-off-by: Randy Dunlap
    Signed-off-by: John W. Linville

    Randy Dunlap
     
  • As discussed in linux-wireless mailing list, adding and removing
    stations for mesh topologies is not necessary. Since doing it triggers
    bugs, the sugestion was to simply disable it.

    Tested using a custom iw command "station new". Works only after using
    hostapd. "station del" command also works.

    Signed-off-by: Thadeu Lima de Souza Cascardo
    Cc: Johannes Berg
    Cc: Simon Raffeiner
    Cc: Andrey Yurovsky
    Cc: Javier Cardona
    Signed-off-by: John W. Linville

    Thadeu Lima de Souza Cascardo
     
  • Fix a copy bug introduced by

    commit 47846c9b0c10808d9337d2e7d09361f3e0a0a71a
    Author: Johannes Berg
    Date: Wed Nov 25 17:46:19 2009 +0100

    mac80211: reduce reliance on netdev

    This manifested itself only in debug messages
    and in the debugfs rename failure that would
    always happen due to trying to rename the dir
    over itself.

    Signed-off-by: Johannes Berg
    Tested-by: Pavel Roskin
    Signed-off-by: John W. Linville

    Johannes Berg
     
  • …t/iwlwifi/iwlwifi-2.6

    John W. Linville
     

13 Feb, 2010

1 commit

  • Adding support for setting the coverage class in some cases broke
    association and data transfer, as it overwrote the initial ACK timeout
    value from the initvals with a smaller value.
    I don't know why the new value works in 5 GHz (matches the initval
    there), but not in 2.4 GHz (initvals use 64us here), so until the
    problem is fully understood, the value should be increased again.

    Signed-off-by: Felix Fietkau
    Signed-off-by: John W. Linville

    Felix Fietkau
     

12 Feb, 2010

12 commits

  • This change monitors the tx statistics to detect the drop in throughput.
    When the throughput drops, the ratio of the actual_ack_count and the expected_
    ack_count also drops. At the same time, the aggregated ba_timeout (the number
    of ba timeout retries) also rises. If the actual_ack_count/expected_ack_count
    ratio is 0 and the number of ba timeout retries rises to 16, no tx packets
    (tcp, udp, or ping - icmp) can be delivered. The driver recovers from this
    situation by reseting the uCode firmware. If the actual_ack_count/expected_
    ack_count ratio drops below 50% (but not 0) and the aggregated ba_timeout
    retries just exceed 5 (but not 16), then the driver can reset the radio to
    bring the throughput up.

    Signed-off-by: Trieu 'Andrew' Nguyen
    Signed-off-by: Reinette Chatre

    Trieu 'Andrew' Nguyen
     
  • All the queues are awake and ready to use after loading firmware,
    for firmware reload case, if any queues was stopped before
    reload, mac80211 will wake those queues after restart hardware, so make
    sure all the flag used to keep track of the queue status are
    reset correctly.

    Signed-off-by: Wey-Yi Guy
    Signed-off-by: Reinette Chatre

    Wey-Yi Guy
     
  • Change pci_alloc_consistent() to dma_alloc_coherent() so we can use
    GFP_KERNEL flag.

    Signed-off-by: Stanislaw Gruszka
    Signed-off-by: Reinette Chatre

    Stanislaw Gruszka
     
  • While testing the station with the NIC 1000 family, it is found that
    the plcp error can easily exceed 50 value in 100mSecs. This creates
    unneccessary radio reset/tuning. This patch raises the PLCP error
    threshold of the NIC 1000 from 50 to 200 error count.

    Signed-off-by: Trieu 'Andrew' Nguyen
    Signed-off-by: Reinette Chatre

    Trieu 'Andrew' Nguyen
     
  • To ensure that card is in a sane state during probe we add a reset call.
    This change was prompted by users of kdump who was not able to bring up the
    wireless driver in the kdump kernel. The problem here was that the primary
    kernel, which is not running at the time, left the wireless card up and
    running. When the kdump kernel starts it is thus possible to immediately
    receive interrupts from firmware after registering interrupt, but without
    being ready to deal with interrupts from firmware yet.

    Reported-by: Stanislaw Gruszka
    Signed-off-by: Reinette Chatre

    Reinette Chatre
     
  • There is a problem if an "internal short scan" is in progress when a
    mac80211 requested scan arrives. If this new scan request arrives within
    the "next_scan_jiffies" period then driver will immediately return success
    and complete the scan. The problem here is that the scan has not been
    fully initialized at this time (is_internal_short_scan is still set to true
    because of the currently running scan), which results in the scan
    completion never to be sent to mac80211. At this time also, evan though the
    internal short scan is still running the state (is_internal_short_scan)
    will be set to false, so when the internal scan does complete then mac80211
    will receive a scan completion.

    Fix this by checking right away if a scan is in progress when a scan
    request arrives from mac80211.

    Signed-off-by: Reinette Chatre

    Reinette Chatre
     
  • Cleanup return values and removes unnecessary code.

    Signed-off-by: Abhijeet Kolekar
    Signed-off-by: Reinette Chatre

    Abhijeet Kolekar
     
  • Number of calibration op-code are not used by driver, remove those from
    iwl-commands.h

    Signed-off-by: Wey-Yi Guy
    Signed-off-by: Reinette Chatre

    Wey-Yi Guy
     
  • Error checking for aggregation frames should go into aggregation queue,
    if aggregation queue not available, use legacy queue instead.
    Also make sure the aggregation queue is available to activate,
    if driver and mac80211 is out-of-sync, try to disable the queue and
    sync-up with mac80211.

    Signed-off-by: Wey-Yi Guy
    Signed-off-by: Reinette Chatre

    Wey-Yi Guy
     
  • Adding function to force reset radio or reload firmware from debugfs.

    Signed-off-by: Wey-Yi Guy
    Signed-off-by: Reinette Chatre

    Wey-Yi Guy
     
  • Provide the function to perform different type of uCode reset/reload operation.
    When uCode detect error and can not fix itself, this iwl_force_reset()
    function allow driver to perform the necessary reset/reload functions and help
    to bring uCode back to normal operation state.

    Currently only 2 type of force reset are available:
    - reset radio
    - reload firmware

    Signed-off-by: Wey-Yi Guy
    Signed-off-by: Reinette Chatre

    Wey-Yi Guy
     
  • Reset and clear all the tx queues when finished downloading runtime
    uCode and ready to go into operation mode.

    Signed-off-by: Wey-Yi Guy
    Signed-off-by: Reinette Chatre

    Wey-Yi Guy
     

11 Feb, 2010

3 commits


10 Feb, 2010

2 commits


09 Feb, 2010

2 commits

  • The current mac80211 implementation enables power save if there
    is no Tx traffic for a specific timeout. Hence, PS is triggered
    even if there is a continuous Rx only traffic(like UDP) going on.
    This makes the drivers to wait on the tim bit in the next beacon
    to awake which leads to redundant sleep-wake cycles.
    Fix this by restarting the dynamic ps timer on receiving every
    data packet.

    Signed-off-by: Vivek Natarajan
    CC: stable@kernel.org
    Signed-off-by: John W. Linville

    Vivek Natarajan
     
  • rate_control_alloc is not used by anything outside of
    ieee80211_init_rate_ctrl_alg. Both are in rate.c; there's no reason to make
    rate_control_alloc visible outside of it.

    Signed-off-by: Andres Salomon
    Signed-off-by: John W. Linville

    Andres Salomon