12 May, 2011

7 commits


11 May, 2011

26 commits

  • Some of the BCM43xx chips contain cores that are attached to the SSB, but are
    inactive as they do not connect to the external environment. These must not be
    registered. Several of these types are handled in driver ssb; however, the
    specific case of an inactive 802.11 cores is now treated in b43 and b43legacy.
    Although the current setup works, this minor change will place all such
    workarounds in ssb, and simplify the code in drivers b43 and b43legacy.

    Signed-off-by: Rafał Miłecki
    Tested-by: Larry Finger
    Acked-by: Larry Finger
    Signed-off-by: John W. Linville

    Rafał Miłecki
     
  • The structure definition is
    struct mwifiex_opt_sleep_confirm_buffer {
    u8 hdr[4];
    struct mwifiex_opt_sleep_confirm ps_cfm_sleep;
    } __packed;

    For sleep_confirm command we already reserve 4 bytes (using skb_reserve())
    for an interface header. It will be filled later by interface specific code.
    We don't need "hdr[4]" element in above structure. So we can use
    "struct mwifiex_opt_sleep_confirm" directly instead of
    "struct mwifiex_opt_sleep_confirm_buffer".

    Signed-off-by: Amitkumar Karwar
    Signed-off-by: Yogesh Ashok Powar
    Signed-off-by: Bing Zhao
    Signed-off-by: John W. Linville

    Amitkumar Karwar
     
  • Broadcom has released cards based on a new AMBA-based bus type. From a
    programming point of view, this new bus type differs from AMBA and does
    not use AMBA common registers. It also differs enough from SSB. We
    decided that a new bus driver is needed to keep the code clean.

    In its current form, the driver detects devices present on the bus and
    registers them in the system. It allows registering BCMA drivers for
    specified bus devices and provides them basic operations. The bus driver
    itself includes two important bus managing drivers: ChipCommon core
    driver and PCI(c) core driver. They are early used to allow correct
    initialization.

    Currently code is limited to supporting buses on PCI(e) devices, however
    the driver is designed to be used also on other hosts. The host
    abstraction layer is implemented and already used for PCI(e).

    Support for PCI(e) hosts is working and seems to be stable (access to
    80211 core was tested successfully on a few devices). We can still
    optimize it by using some fixed windows, but this can be done later
    without affecting any external code. Windows are just ranges in MMIO
    used for accessing cores on the bus.

    Cc: Greg KH
    Cc: Michael Büsch
    Cc: Larry Finger
    Cc: George Kashperko
    Cc: Arend van Spriel
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: Russell King
    Cc: Arnd Bergmann
    Cc: Andy Botting
    Cc: linuxdriverproject
    Cc: linux-kernel@vger.kernel.org
    Signed-off-by: Rafał Miłecki
    Signed-off-by: John W. Linville

    Rafał Miłecki
     
  • This seems to be a leftover from the old days, when we didn't support
    any frames that didn't contain the full ieee802.11 header. This is
    not the case anymore. It does not cause problems now, because they
    are only dropped during scan. But when scheduled scans get merged,
    this would become a problem because we would drop all small frames
    while scheduled scan is running.

    To fix this, return RX_CONTINUE instead of RX_DROP_MONITOR.

    Cc: Johannes Berg
    Signed-off-by: Luciano Coelho
    Signed-off-by: John W. Linville

    Luciano Coelho
     
  • This beacon rssi will be used to set noisefloor during ani reset.

    Signed-off-by: Rajkumar Manoharan
    Signed-off-by: John W. Linville

    Rajkumar Manoharan
     
  • The average beacon rssi which will be used by ani is not updated
    in adhoc mode.

    Signed-off-by: Rajkumar Manoharan
    Signed-off-by: John W. Linville

    Rajkumar Manoharan
     
  • By changing DCU backoff threshold for AR9340 to 1, helps to
    reduce rx overrurns seen while running bidirectional traffic.

    Signed-off-by: Rajkumar Manoharan
    Signed-off-by: John W. Linville

    Rajkumar Manoharan
     
  • Signed-off-by: Rajkumar Manoharan
    Signed-off-by: John W. Linville

    Rajkumar Manoharan
     
  • Found via coccinelle script

    @@
    type T;
    T* ptr;
    expression E1;
    @@
    * memset(E1, 0, sizeof(ptr));

    Signed-off-by: Joe Perches
    Signed-off-by: John W. Linville

    Joe Perches
     
  • currently ath9k_hw_getchan_noise is not used anywhere

    Signed-off-by: Mohammed Shafi Shajakhan
    Signed-off-by: John W. Linville

    Mohammed Shafi Shajakhan
     
  • This can be helpful when we decide to add support for other buses.

    Signed-off-by: Rafał Miłecki
    Signed-off-by: John W. Linville

    Rafał Miłecki
     
  • This patch:
    - adds kfree() where necessary
    - prevents potential null dereferences
    - makes use of kfree_skb()
    - replaces -1 for failed kzallocs with -ENOMEM

    Signed-off-by: Christoph Fritz
    Reviewed-by: Kiran Divekar
    Tested-by: Amitkumar Karwar
    Acked-by: Bing Zhao
    Signed-off-by: John W. Linville

    Christoph Fritz
     
  • Remove the code to detect inactive 802.11 cores, as that function is now done
    in ssb.

    Signed-off-by: Rafał Miłecki
    Tested-by: Larry Finger
    Acked-by: Larry Finger
    Signed-off-by: John W. Linville

    Rafał Miłecki
     
  • Remove the code to detect inactive 802.11 cores, as that function is now done
    in ssb.

    Signed-off-by: Rafał Miłecki
    Tested-by: Larry Finger
    Acked-by: Larry Finger
    Signed-off-by: John W. Linville

    Rafał Miłecki
     
  • txstatus_timer should only be deleted for USB devices, as it is only
    initialized for USB devices.

    Reported-by: Andreas Hartmann
    Signed-off-by: Gertjan van Wingerde
    Signed-off-by: Ivo van Doorn
    Signed-off-by: John W. Linville

    Gertjan van Wingerde
     
  • p54pci.c: In function ‘p54p_tx’:
    p54pci.c:334:6: warning: variable ‘device_idx’ set but not used

    Signed-off-by: Christian Lamparter
    Signed-off-by: John W. Linville

    Christian Lamparter
     
  • tx.c: In function ‘carl9170_tx_accounting_free’:
    tx.c:159:28: warning: variable ‘txinfo’ set but not used
    tx.c: In function ‘carl9170_tx_status_process_ampdu’:
    tx.c:383:27: warning: variable ‘ar_info’ set but not used
    tx.c: In function ‘__carl9170_tx_process_status’:
    tx.c:626:27: warning: variable ‘arinfo’ set but not used
    tx.c: In function ‘carl9170_tx_ampdu_queue’:
    tx.c:1324:15: warning: variable ‘max’ set but not used

    Signed-off-by: Christian Lamparter
    Signed-off-by: John W. Linville

    Christian Lamparter
     
  • When this driver was initially submitted, the system would crash unless
    ASPM was disabled. This problem has been fixed.

    This patch also adds a printk that outputs the name of the firmware
    file that is used.

    Signed-off-by: Chaoming_Li
    Signed-off-by: Larry Finger
    Signed-off-by: John W. Linville

    Chaoming Li
     
  • In driver rtlwifi, efuse_read() places two relatively large arrays on the
    stack - a 1D u8 array of size 128, and a 2D array of u16 with 128 * 4 elements.
    With driver rtl8192de, the sizes will be 256 and 256 * 4 respectively. As that
    will make the 2D array be 2048 bytes, I have changed the code to use kmalloc to
    allocate the space.

    Signed-off-by: Larry Finger
    Signed-off-by: John W. Linville

    Larry Finger
     
  • The function iwl_is_any_associated() was intended
    to check both contexts, but due to an oversight
    it only checks the BSS context. This leads to a
    problem with scanning since the passive dwell
    time isn't restricted appropriately and a scan
    that includes passive channels will never finish
    if only the PAN context is associated since the
    default dwell time of 120ms won't fit into the
    normal 100 TU DTIM interval.

    Fix the function by using for_each_context() and
    also reorganise the other functions a bit to take
    advantage of each other making the code easier to
    read.

    Cc: stable@kernel.org
    Signed-off-by: Johannes Berg
    Signed-off-by: Wey-Yi Guy
    Signed-off-by: John W. Linville

    Johannes Berg
     
  • Processing TSF out of range before RX helps to update beacon
    timers so early in the succeeding rx process.

    Signed-off-by: Rajkumar Manoharan
    Signed-off-by: John W. Linville

    Rajkumar Manoharan
     
  • The assumsion is that while processing ath9k tasklet,
    interrupts were already disabled and it will be enabled
    at the completion of ath9k tasklet. But whenever TSFOOR is raised,
    the driver configures the beacon timers after having received a
    beacon frame from the AP which inturn enables the interrupts.

    Cc: stable@kernel.org
    Signed-off-by: Rajkumar Manoharan
    Signed-off-by: John W. Linville

    Rajkumar Manoharan
     
  • When mac80211 is built without CONFIG_PM being defined, the following errors
    are output:

    net/mac80211/main.c: In function ‘ieee80211_register_hw’:
    net/mac80211/main.c:700: error: ‘const struct ieee80211_ops’ has no member named ‘suspend’
    net/mac80211/main.c:700: error: ‘const struct ieee80211_ops’ has no member named ‘resume’
    make[2]: *** [net/mac80211/main.o] Error 1
    make[1]: *** [net/mac80211] Error 2
    make[1]: *** Waiting for unfinished jobs....
    make: *** [net] Error 2

    Signed-off-by: Larry Finger
    Signed-off-by: John W. Linville

    Larry Finger
     
  • commit 5ed540aecc2aae92d5c97b9a9306a5bf88ad5574 change the led behavior
    for iwlwifi driver; the side effect cause led blink all the time.

    Modify the led blink table to fix this problem

    Signed-off-by: Wey-Yi Guy
    Signed-off-by: John W. Linville

    Wey-Yi Guy
     
  • These warnings are exposed by gcc 4.6.
    net/wireless/reg.c: In function 'freq_reg_info_regd':
    net/wireless/reg.c:675:38: warning: variable 'pr' set but not used
    [-Wunused-but-set-variable]
    net/wireless/lib80211_crypt_wep.c: In function 'lib80211_wep_build_iv':
    net/wireless/lib80211_crypt_wep.c:99:12: warning: variable 'len' set but
    not used [-Wunused-but-set-variable]

    Signed-off-by: Rajkumar Manoharan
    Signed-off-by: John W. Linville

    Rajkumar Manoharan
     
  • …t/iwlwifi/iwlwifi-2.6

    John W. Linville
     

07 May, 2011

7 commits

  • DMA mappings can fail, but the current code
    doesn't check for that. Add checking, which
    requires some restructuring for proper error
    paths.

    Signed-off-by: Johannes Berg
    Signed-off-by: Wey-Yi Guy

    Johannes Berg
     
  • All AGN devices need the bytecount table, so
    remove the indirection and make the functions
    static again.

    Signed-off-by: Johannes Berg
    Signed-off-by: Wey-Yi Guy

    Johannes Berg
     
  • The device doesn't use the bytecount table for the
    command queue, only for aggregation queues to make
    aggregation decisions. So don't update it for the
    command queue (and we even updated it with wrong
    values).

    Signed-off-by: Johannes Berg
    Signed-off-by: Wey-Yi Guy

    Johannes Berg
     
  • The variable 'len' here is set but never used.

    Signed-off-by: Johannes Berg
    Signed-off-by: Wey-Yi Guy

    Johannes Berg
     
  • The frame pre-allocation is quite a bit of complex
    code, all to avoid a single allocation. Remove it
    and consolidate the beacon sending code.

    Signed-off-by: Johannes Berg
    Signed-off-by: Wey-Yi Guy

    Johannes Berg
     
  • There's no need for this, all commands are the right size.

    Signed-off-by: Johannes Berg
    Signed-off-by: Wey-Yi Guy

    Johannes Berg
     
  • This patch adds the feature to support the test mode operation through
    the generic netlink channel NL80211_CMD_TESTMODE between intel
    wireless device iwlwifi and the user space application svtool.

    The main purpose is to create a transportation layer between the iwlwifi
    device and the user space application so that the interaction between the
    user space application svtool and the iwlwifi device in the kernel space is
    in a way of generic netlink messaging.

    The detail specific functions are:

    1. The function iwl_testmode_cmd() is added to digest the svtool test command
    from the user space application. The svtool test commands are categorized to
    three types : commands to be processed by the device ucode, commands to access
    the registers, and commands to be processed at the driver level(such as reload
    the ucode). iwl_testmode_cmd() dispatches the commands the corresponding handlers
    and reply to user space regarding the command execution status. Extra data is
    returned to the user space application if there's any.

    2. The function iwl_testmode_ucode_rx_pkt() is added to multicast all the spontaneous
    messages from the iwlwifi device to the user space. Regardless the message types,
    whenever there is a valid spontaneous message received by the iwlwifi ISR,
    iwl_testmode_ucode_rx_pkt() is invoked to multicast the message content to user
    space. The message content is not attacked and the message parsing is left to
    the user space application.

    Implementation guidelines:

    1. The generic netlink messaging for iwliwif test mode is through NL80211_CMD_TESTMODE
    channel, therefore, the codes need to follow the regulations set by cfg80211.ko
    to get the actual device instance ieee80211_ops via cfg80211.ko, so that the iwlwifi
    device is indicated with ieee80211_ops and can be actually accessed.

    Therefore, a callback iwl_testmode_cmd() is added to the structure
    iwlagn_hw_ops in iwl-agn.c.

    2. It intends to utilize those low level device access APIs from iwlwifi device driver
    (ie. iwlagn.ko) rather than creating it's own set of device access functions.
    For example, iwl_send_cmd(), iwl_read32(), iwl_write8(), and iwl_write32() are reused.

    3. The main functions are maintained in new files instead of spreading all over the
    existing iwlwifi driver files.

    The new files added are :

    drivers/net/wireless/iwlwifi/iwl-sv-open.c
    - to handle the user space test mode application command
    and reply the respective command status to the user space application.
    - to multicast the spontaneous messages from device to user space.

    drivers/net/wireless/iwlwifi/iwl-testmode.h
    - the commonly referenced definitions for the TLVs used in
    the generic netlink messages

    Signed-off-by: Cindy H. Kao
    Signed-off-by: Johannes Berg
    Signed-off-by: Wey-Yi Guy

    Cindy H. Kao