Vasanthakumar Thiagarajan [Tue, 28 Feb 2012 14:50:20 +0000 (20:20 +0530)]
ath6kl: Initialize netdev hw_features for every interface
Move netdev->hw_features setting from ath6kl_core_init() to
init_netdev() so that it is done for every interface.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Tue, 28 Feb 2012 14:50:19 +0000 (20:20 +0530)]
ath6kl: Group wiphy initialization into ath6kl_cfg80211_init()
There are some code which initializes various wiphy members
left outside ath6kl_cfg80211_init(), in ath6kl_core_init().
Move them into a single palce.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Mon, 27 Feb 2012 06:14:19 +0000 (11:44 +0530)]
ath6kl: Register driver ht capabilities in wiphy
Register driver's ht capabilities in wiphy to avoid failures
in setting ht channels from hostapd.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Raja Mani [Wed, 22 Feb 2012 06:33:51 +0000 (12:03 +0530)]
ath6kl: Lower SDIO pad drive strength for hw2.1.1 board
Without this change, SDIO shuts down due to CRC error during
data communication to the firmware in some of the platform.
for example, scan request issued to the firmware doesn't
return scan completed events and cause the socket interface
to always return -16 (device busy).
SDIO pad drive strength should be reduced for hw2.1.1 board
to avoid such errors.
Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Tue, 21 Feb 2012 10:00:42 +0000 (15:30 +0530)]
ath6kl: Make foreground scan a deterministic one
This makes the device get into scan state as soon as a
scan request is received, instead of blocking the scan
request till the traffic comes down. It is necessary
for the deterministic foreground scan particularly when
having multiple vif operating where, if the scan is non-
deterministic, scan on one interface will not start
as long as there are traffic on the other interface. This
change passes 50 msec as foreground scan interval to fix this.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Fri, 10 Feb 2012 15:10:33 +0000 (20:40 +0530)]
ath6kl: Fix memory leak of rx packets in endpoint 0
htc_packet and htc_packet->buf_start are separately allocated
for endpoint 0. This is different for other endpoints where
packets are allocated as skb where htc_packet is skb->head
and they are freed properly. Free htc_packet and htc_packet->buf_start
separatly for endpoint 0.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Fri, 10 Feb 2012 15:10:32 +0000 (20:40 +0530)]
ath6kl: Make sure to allocate rx buffers after the endpoint connection
Rx buffers should be allocated for control and best effort endpoints only
after the enpoints connection is esablished. But this is done before the
endpoint connection is complete, we don't even the control and BE endpoints
that time. Move the buffer allocation after endpoint connection is over,
after ath6kl_init_hw_start(). Found in review, never seen any real issue
with this.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Tue, 14 Feb 2012 15:03:00 +0000 (20:33 +0530)]
ath6kl: Remove bogus non-NULL pointer check
In ath6kl_cfg80211_add_key(), params is checked for non-NULL
but this pointer has been deferenced many times before this check. This
gives the following smatch warning. add_key() can never carry NULL as
params, remove this bogus check.
ath6kl_cfg80211_add_key(86) warn: variable dereferenced before check 'params'
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Tue, 14 Feb 2012 15:02:59 +0000 (20:32 +0530)]
ath6kl: Fix missing release of semaphore in ath6kl_stop_txrx()
This fixes smatch warning "inconsistent returns sem:&ar->sem".
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Chilam Ng [Thu, 9 Feb 2012 10:17:01 +0000 (02:17 -0800)]
ath6kl: assign Tx packet drop threshold per endpoint based on AC priority
Tx packets will begin to drop when there are multiple traffic priorities
and the current traffic is not the highest priority and the remaining
cookies drop below a certain number, which is fixed for all AC. It is
possilbe that lower priority AC have more traffic which will consume
more cookies and lock out higher priority AC from having any. Assign
each endpoint (AC) with a different Tx-packet-drop threshold so lower
priority AC is more likely to drop packets and the cookies become more
available to higher priority AC.
Signed-off-by: Chilam Ng <chilamng@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Naveen Gangadharan [Thu, 9 Feb 2012 01:51:36 +0000 (17:51 -0800)]
ath6kl: Add unicast mgmt frame buffering
PS buffering of unicast Action frames that are sent in a context
of a BSS. In AP mode when the recepient station goes to powersave
and PS_POLL flag is not set, we would buffer the frames. Send out
unicast mgmt bufferred frame when PS_POLL is received.
This fixes a bug in P2P GO behavior when sending a GO Discoverability
Request to a client that is in sleep mode.
kvalo: indentation fixes
Signed-off-by: Thirumalai Pachamuthu <tpachamu@qca.qualcomm.com>
Signed-off-by: Naveen Gangadharan <ngangadh@qca.qualcomm.com>
Signed-off-by: Aarthi Thiruvengadam <athiruve@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Naveen Gangadharan [Wed, 8 Feb 2012 06:53:32 +0000 (22:53 -0800)]
ath6kl: Fix firmware crash dump
The firmware crash dump printout was wrong as it was using incorrect
offsets.
kvalo: improve commit log, change the "%d:" to print word indexes, not bytes
Signed-off-by: Naveen Gangadharan <ngangadh@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Prasanna Kumar [Tue, 7 Feb 2012 22:58:54 +0000 (14:58 -0800)]
ath6kl: add support for AR6003 2048 byte board file
AR6003 2.1.1 supports both 1792 and 2048 byte board files.
Add support for 2048 byte board file.
kvalo: add ath6kl prefix to the title
Signed-off-by: Prasanna Kumar <kumarpra@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Chilam Ng [Tue, 7 Feb 2012 09:33:00 +0000 (01:33 -0800)]
ath6kl: prioritize Tx bundling based on AC priorities
Tx bundling is the more efficient use of SDIO bus and allows more packet
transfers with fewer bus transactions, and is a way to improve overall
throughput. However, Tx bundling has only 4 scatter request resources available.
When there are multiple traffic streams of different priorities, it's possible
that lower priority traffic may hog all the scatter requests and lock out the
higher prioirty traffic from bundling.
Tx bundling is now enabled per AC. When an AC do a scatter request and
the remaining scatter request resources is lower than a configurable
threshold, it will disable Tx bundling for all AC's of lower priorities.
When an AC has Tx bundling disabled and has no Tx bundles sent in a
consecutive and configurable number of packets, Tx bundling will be re-enabled
for that AC.
Signed-off-by: Chilam Ng <chilamng@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Mon, 6 Feb 2012 14:45:53 +0000 (20:15 +0530)]
ath6kl: Update license header
Update license header with the copyright to Qualcomm Atheros, Inc.
for the year 2011-2012.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Mon, 6 Feb 2012 06:23:40 +0000 (08:23 +0200)]
ath6kl: add blocking debugfs file for retrieving firmware logs
When debugging firmware issues it's not always enough to get
the latest firmware logs, sometimes we need to get logs from a longer
period. To make this possible, add a debugfs file named fwlog_block. When
reading from this file ath6kl will send firmware logs whenever available
and otherwise it will block and wait for new logs.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Mon, 6 Feb 2012 06:23:27 +0000 (08:23 +0200)]
ath6kl: store firmware logs in skbuffs
Currently firmware logs are stored in a circular buffer, but this was
not very flexible and fragile. It's a lot easier to store logs to struct
skbuffs and store them in a skb queue. Also this makes it possible
to easily increase the buffer size, even dynamically if we so want (but
that's not yet supported).
From user space point of view nothing should change.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Chilam Ng [Wed, 1 Feb 2012 09:03:37 +0000 (01:03 -0800)]
ath6kl: initialize the 'nominal_phy' field in the 'wmi_create_pstream_cmd' struct for create_qos command
The nominal_phy field is uninitialized. Initialize it to min_phy_rate for
create_qos.
kvalo: simplified the equation as checkpatch complained for a too long line
Signed-off-by: Chilam Ng <chilamng@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 31 Jan 2012 19:26:22 +0000 (21:26 +0200)]
ath6kl: fix compiler warning in ath6kl_init_hw_params()
Both Luis and John reported that they see a compiler warning:
drivers/net/wireless/ath/ath6kl/init.c: In function 'ath6kl_init_hw_params':
drivers/net/wireless/ath/ath6kl/init.c:1377:26: warning: ‘hw’
may be used uninitialized in this function
Oddly enough I have never seen it. But AFAICT the code is correct and
hw is not used uninitalized so add uninitialized_var() to inform that to
the compiler.
Reported-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Reported-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Masanari Iida [Tue, 31 Jan 2012 14:32:55 +0000 (23:32 +0900)]
ath6kl: Fix typo in cfg80211.c
Correct spelling "spported" to "supported" in
drivers/net/wireless/ath/ath6kl/cfg80211.c
Signed-off-by: Masanari Iida <standby24x7@gmail.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Santosh Sajjan [Mon, 30 Jan 2012 20:02:26 +0000 (22:02 +0200)]
ath6kl: Workaround to support Deep Sleep with MSM.
Set the host pm flag MMC_PM_WAKE_SDIO_IRQ to allow host
to disable the sdc2_clk and sdc2_h_clk,so that the MSM device
enter into TCXO shutdown.
Signed-off-by: Santosh Sajjan <ssajjan@codeaurora.org>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Raja Mani [Mon, 30 Jan 2012 11:43:12 +0000 (17:13 +0530)]
ath6kl: Return a proper error code when not in connected state
Error code ENOTCONN is more suitable than EINVAL to report
when the driver is not in connected state in ath6kl_wow_suspend().
I found this during code review.
Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Raja Mani [Mon, 30 Jan 2012 11:43:11 +0000 (17:13 +0530)]
ath6kl: Wait for host sleep mode cmd processed event during WOW suspend
For every WMI_SET_HOST_SLEEP_MODE_CMDID command (send from the host),
the firmware sends WMI_SET_HOST_SLEEP_MODE_CMD_PROCESSED_EVENTID as
an acknowledgement to the host.
In order to being sync with the firmware, the host has to wait for
WMI_SET_HOST_SLEEP_MODE_CMD_PROCESSED_EVENT event before going to
the suspend state. This patch ensures ath6kl_wow_suspend() waits
until it gets this event after sending set host sleep mode command.
This patch adds,
* New command WMI_SET_HOST_SLEEP_MODE_CMD_PROCESSED_EVENTID in
WMI event table.
* New WMI function ath6kl_wmi_host_sleep_mode_cmd_prcd_evt_rx()
to process the event.
* New flag HOST_SLEEP_MODE_CMD_PROCESSED in VIF flags to record
the arrival of the event.
Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Raja Mani [Mon, 30 Jan 2012 11:43:10 +0000 (17:13 +0530)]
ath6kl: Configure WOW patterns while going to wow_suspend
First preference is given to the user configured WOW patterns.
If the user doesn't configure any patterns (for ex, via iw command),
the default patterns will be configured based on the current mode
(vif->nw_type) while going to WOW suspend.
Summary of changes:
* ath6kl_wow_ap() is added to configure the below default
patterns when the system enters into WOW suspend in AP mode.
+ Unicast IP, EAPOL-like and ARP packet pattern
+ ARP packet pattern
+ mDNS/SSDP/LLMNR pattern
+ DHCP broadcast pattern
* ath6kl_wow_sta() is added to configure the below default
patterns when the system enters into WOW suspend in STA mode.
+ Unicast packet pattern
+ mDNS/SSDP/LLMNR pattern
* Move the user provided WOW patterns configuration code
from ath6kl_wow_suspend() to a separate function called
ath6kl_wow_usr().
* Two argument variable's ('filter' and 'mask) data type in
ath6kl_wmi_add_wow_pattern_cmd() are changed from 'u8 *' to
'const u8 *'. This is needed to make all pattern and mask
arrays to be 'static const u8' in the caller function.
* New conditional check is added to make sure user
configured pattern count is within the limit (WOW_MAX_FILTERS_PER_LIST).
Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Raja Mani [Mon, 30 Jan 2012 11:43:09 +0000 (17:13 +0530)]
ath6kl: Re-architect suspend mode handling in ath6kl_sdio_suspend
Using this patch, the user can bypass existing auto
suspend mode selection logic and force ath6kl to enter
into the suspend mode what he/she wants.
If the user doesn't choose any suspend mode while doing
insmod of the driver, auto suspend mode selection logic
will kick in and choose suspend mode based on the host
SDIO controller capability.
Generic module parameter is required to specify suspend
mode including Deep Sleep and WOW while doing insmod.
Renaming existing mod param variable suspend_cutpower
would be sufficient to meet this requirement.
New module parameter suspend_mode can take any one of
the below suspend state,
1. cut power
2. deep sleep
3. wow
Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Thu, 26 Jan 2012 07:47:18 +0000 (13:17 +0530)]
ath6kl: Fix kernel panic during rx aggregation
"ath6kl: Define a structure for connection specific aggregation information"
introduces this. In aggr_conn_init(), vif->aggr_cntxt is assigned to
aggr_conn->aggr_info, but vif->aggr_cntxt is not initialized at this
point, this would end up accessing an invalid pointer in aggregation
receive path. Fix this by passing the correct aggr_info to aggr_conn_init().
The panic trace would look like.
[<
ffffffff8159e02e>] panic+0xa1/0x1c6
[<
ffffffff8103773d>] ? kmsg_dump+0xfd/0x160
[<
ffffffff815a2f6a>] oops_end+0xea/0xf0
[<
ffffffff8102b95d>] no_context+0x11d/0x2d0
[<
ffffffff8102bc5d>] __bad_area_nosemaphore+0x14d/0x230
[<
ffffffff815a5c4d>] ? do_page_fault+0x30d/0x520
[<
ffffffff8102bd53>] bad_area_nosemaphore+0x13/0x20
[<
ffffffff815a5cfd>] do_page_fault+0x3bd/0x520
[<
ffffffff8108bd60>] ? __lock_acquire+0x320/0x1680
[<
ffffffff812e3a9d>] ? trace_hardirqs_off_thunk+0x3a/0x3c
[<
ffffffff815a2385>] page_fault+0x25/0x30
[<
ffffffffa0487a5f>] ? aggr_slice_amsdu+0xdf/0x170 [ath6kl_core]
[<
ffffffffa0487bac>] aggr_deque_frms+0xbc/0x190 [ath6kl_core]
[<
ffffffffa0488404>] ath6kl_rx+0x3e4/0xae0 [ath6kl_core]
[<
ffffffffa047ae77>] ath6kl_htc_rxmsg_pending_handler+0x8b7/0xf10 [ath6kl_core]
[<
ffffffffa00c82f0>] ? mmc_do_release_host+0x70/0x90 [mmc_core]
[<
ffffffffa00c833a>] ? mmc_release_host+0x2a/0x50 [mmc_core]
[<
ffffffffa04865c0>] ? ath6kl_alloc_amsdu_rxbuf+0x140/0x140 [ath6kl_core]
[<
ffffffffa0477772>] ath6kl_hif_intr_bh_handler+0x362/0x510 [ath6kl_core]
[<
ffffffffa01f1000>] ath6kl_sdio_irq_handler+0x60/0xb0 [ath6kl_sdio]
[<
ffffffffa00d30bc>] sdio_irq_thread+0xec/0x320 [mmc_core]
[<
ffffffffa00d2fd0>] ? sdio_claim_irq+0x220/0x220 [mmc_core]
[<
ffffffffa00d2fd0>] ? sdio_claim_irq+0x220/0x220 [mmc_core]
[<
ffffffff8105b21e>] kthread+0xbe/0xd0
[<
ffffffff815ab574>] kernel_thread_helper+0x4/0x10
[<
ffffffff815a2174>] ? retint_restore_args+0x13/0x13
[<
ffffffff8105b160>] ? __init_kthread_worker+0x70/0x70
[<
ffffffff815ab570>] ? gs_change+0x13/0x13
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 24 Jan 2012 11:50:16 +0000 (13:50 +0200)]
ath6kl: fix testmode when fw-2.bin or fw-3.bin is used
Testmode (TCMD and ART) was not enabled when fw-2.bin or fw-3.bin files
were available, fix that by fetching testmode file just after the
board file but before rest of the firmware files are fetched.
I also added testmode field to struct ath6kl and moved the module parameter
to core.c. Now all module parameters are grouped in one place.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Sat, 21 Jan 2012 09:52:53 +0000 (15:22 +0530)]
ath6kl: Fix bug in maintaining aggregation state in AP mode
Currently rx aggregation related states are maintained per
vif, but this will not properly work when operating in AP mode.
Aggregation is completely broken when more than one
11n stations are connected to AP mode vif. Fix this issue
by keeping station specific aggregation state in sta_list.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Sat, 21 Jan 2012 09:52:52 +0000 (15:22 +0530)]
ath6kl: Fix bug in using tid given by addba/delba req events
The tid which is given in addba/delba req event is not
just tid but also muxed with the assoc id (MSB 4 bits)
which can be used to determine the corresponding connected
station in softap mode. The actual tid is LSB 4 bits. Using
the tid as it is with rx_tid[] would result in OOB or invalid
memory access in AP mode.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Sat, 21 Jan 2012 09:52:51 +0000 (15:22 +0530)]
ath6kl: Pass vif instead of ar to ath6kl_add_new_sta()
This will be used when initializing station specific aggregation
information.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Sat, 21 Jan 2012 09:52:50 +0000 (15:22 +0530)]
ath6kl: Define a structure for connection specific aggregation information
This patch just groups connection specific aggregation information
from struct aggr_info into a new structure (struct aggr_info_conn)
so that, in softAP mode, this can be used when each connected station
is made to have it's own aggregation state.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Sat, 21 Jan 2012 09:52:49 +0000 (15:22 +0530)]
ath6kl: Fix memory leak when unloading ath6kl_sdio
The patch "ath6kl: create core.c" removes wiphy_free() from
ath6kl_cfg80211_cleanup() and misses to free wiphy in
ath6kl_sdio_remove(). This patch fixes this regression.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Sat, 21 Jan 2012 09:52:48 +0000 (15:22 +0530)]
ath6kl: Make sure to delete rx aggregation timer in aggr_reset_state()
The timer which is used to flush rx aggregation frames needs to
be disabled when resetting the aggregation state. This is found
in code review.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 18:09:45 +0000 (20:09 +0200)]
ath6kl: add back beginnings of USB support
John Linville had to revert the part of USB support which was already
in ath6kl due to build problems in commit
cb00ec382b ("ath6kl: revert
USB support"). Now that I fixed the build problems properly by adding
ath6kl_core.ko kernel module it's possible to add back the
(incomplete) USB support. This patch is a revert of John's patch and
adds back the USB code which as already in ath6kl, only difference
being minor changes in Makefile and adapting usb.c to new core
function names.
Note that USB support in ath6kl is not complete yet. This code only
makes it possible to boot firmware but as HTC layer does not yet
support USB it's not possible to send any WMI commands nor data
packets to the firmware. That will be added soon.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 18:09:36 +0000 (20:09 +0200)]
ath6kl: create ath6kl_core.ko
Now ath6kl is ready for splitting core code to ath6kl_core.ko module.
This also makes it possible to link both sdio and usb code to kernel
at the same time, which earlier failed miserably.
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 18:09:27 +0000 (20:09 +0200)]
ath6kl: convert ath6kl_dbg() and ath6kl_dbg_dump() into functions
That way it's possible to not export debug_mask outside the upcoming
ath6kl_core.ko and that makes it easier to ath6kl_core.ko in the
following patch.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 18:09:19 +0000 (20:09 +0200)]
ath6kl: get rid of AR_DBG_LVL_CHECK()
We don't need it as debug calls already have a log level and compiler
should be smart enough to optimise away the code when ath6kl debug code
is not enabled. Also it makes it easier to abstract core code to
ath6kl_core.ko.
In ath6kl_dump_registers() I had to change the debug level from ANY to IRQ
as I removed the AR_DBG_LVL_CHECK() check before calling the function.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 18:09:05 +0000 (20:09 +0200)]
ath6kl: create core.c
Currently core functions are spread between various files, group all
the functions into file and rename the functions to follow the style
used elsewhere in the driver. This will make it easier to a separate core
module.
Also fix a bug where wiphy is freed too early.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 18:08:56 +0000 (20:08 +0200)]
ath6kl: add ATH6KL_CONF_UART_DEBUG
Add ATH6KL_CONF_UART_DEBUG which is set whenever uart_debug module
parameter is enabled. This way we can keep the uart_debug parameter
static when core.c file is introduced.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 18:08:40 +0000 (20:08 +0200)]
ath6kl: unify cfg80211 init/cleanup functions
Group them together and change the naming to follow the common style in
ath6kl. No functional changes.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 18:08:27 +0000 (20:08 +0200)]
ath6kl: rename vif init and cleanup functions
ath6kl_cfg80211_vif_init/cleanup() follow more closely the style used
elsewhere in ath6kl.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Alex Yang [Tue, 17 Jan 2012 13:32:29 +0000 (15:32 +0200)]
ath6kl: add testmode 2 for 6003 ART
Add testmode 2 for 6003 ART. When you insmod ath6kl_sdio.ko testmode=2, ath6kl
will load ART firmware utf.bin and testscript nullTestFlow.bin. These files
should be put in the firmware folder.
kvalo: add "ath6kl:" to the title, word wrap the commit log and remove
extra line in the code
Signed-off-by: Alex Yang <xiaojuny@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 13:05:46 +0000 (15:05 +0200)]
ath6kl: fix uninitialized warning in ath6kl_process_uapsdq()
Before I commited patch
c1762a3fe ("ath6kl: Add support for uAPSD") I
did a minor change how up variable is initialised in
ath6kl_process_uapsdq(). But I was sloppy and caused this compiler
warning:
txrx.c:88:5: warning: 'up' may be used uninitialized in this function
Revert my change to fix the warning.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 13:05:32 +0000 (15:05 +0200)]
ath6kl: remove -D__CHECK_ENDIAN__ from Makefile
As drivers/net/wireless/ath/Makefile contains the flag to enable
endian checks there's no need to have it in ath6kl makefile anymore.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Tue, 17 Jan 2012 13:05:19 +0000 (15:05 +0200)]
ath6kl: use netdev_features_t
Commit
c8f44affb7 ("net: introduce and use netdev_features_t for
device features sets") added netdev_features_t to ndo_set_features.
Change ath6kl to use the new type.
This fixes a warning:
ath6kl/main.c:1170: warning: initialization from incompatible pointer type
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Kalle Valo [Fri, 13 Jan 2012 11:57:45 +0000 (13:57 +0200)]
Merge remote branch 'wireless-next/master' into ath6kl-next
Conflicts:
drivers/net/wireless/ath/ath6kl/usb.c
Raja Mani [Thu, 12 Jan 2012 09:31:48 +0000 (15:01 +0530)]
ath6kl: Remove useless initialization in ath6kl_read_fwlogs()
ath6kl_read_fwlogs() assigns the value zero to the variable 'ret'
at the time of declaration. Later, return value of ath6kl_diag_read32()
repalces the init value. Hence removing useless zero assignment.
Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Thirumalai Pachamuthu [Thu, 12 Jan 2012 12:51:39 +0000 (18:21 +0530)]
ath6kl: Add support for uAPSD
* A new APSD power save queue is added in the station structure.
* When a station has APSD capability and goes to power save, the frame
designated to the station will be buffered in APSD queue.
* When the host receives a frame which the firmware marked as trigger,
host delivers the buffered frame from the APSD power save queue.
Number of frames to deliver is decided by MAX SP length.
* When a station moves from sleep to awake state, all frames buffered
in APSD power save queue are sent to the firmware.
* When a station is disconnected, all frames bufferes in APSD power save
queue are dropped.
* When the host queues the first frame to the APSD queue or removes the
last frame from the APSD queue, it is indicated to the firmware using
WMI_AP_APSD_BUFFERED_TRAFFIC_CMD.
kvalo: fix buggy handling of sks queues, made it more obvious
the user priority when wmm is disabled, remove unneed else block and
combined some variable declarations
Signed-off-by: Thirumalai Pachamuthu <tpachamu@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Sujith Manoharan [Tue, 10 Jan 2012 04:24:10 +0000 (09:54 +0530)]
ath6kl: Fix listen interval handling
This patch addresses a few problems with the commit:
"ath6kl: Implement support for listen interval from userspace"
* The debugfs file required for reading/writing the listen interval
wasn't created. Fix this.
* The interface index was being hardcoded to zero. Fix this.
* Two separate parameters, "listen_interval_time and listen_interval_beacons"
were being used. This fails to work as expected because the FW assigns
higher precedence to "listen_interval_beacons" and "listen_interval_time"
ends up being never used at all.
To handle this, fix the host driver to exclusively use listen interval
based on units of beacon intervals.
To set the listen interval, a user would now do something like this:
echo "10" > /sys/kernel/debug/ieee80211/*/ath6kl/listen_interval
kvalo: fix two checkpatch warnings
Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Sujith Manoharan [Tue, 10 Jan 2012 04:23:53 +0000 (09:53 +0530)]
ath6kl: Initialize a variable properly
This prevents 'comp_pktq' from being used in an
incorrect manner.
Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Sujith Manoharan [Tue, 10 Jan 2012 04:23:38 +0000 (09:53 +0530)]
ath6kl: Remove redundant pointer check
'params' is already used earlier and there is no point
in checking for a NULL condition again.
Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Sujith Manoharan [Tue, 10 Jan 2012 04:23:23 +0000 (09:53 +0530)]
ath6kl: Fix SDIO error path
sdio_release_host() would be called twice if sdio_set_block_size()
fails for some reason, which would result in the following warning.
WARNING: at /home/sujith/dev/wireless-testing/drivers/mmc/core/core.c:828 mmc_release_host+0x42/0x50 [mmc_core]()
Call Trace:
[<
ffffffff81064fdf>] warn_slowpath_common+0x7f/0xc0
[<
ffffffff8106503a>] warn_slowpath_null+0x1a/0x20
[<
ffffffffa03beb42>] mmc_release_host+0x42/0x50 [mmc_core]
[<
ffffffffa03c917e>] sdio_release_host+0x1e/0x30 [mmc_core]
[<
ffffffffa053fac7>] ath6kl_sdio_config+0xc7/0x110 [ath6kl_sdio]
[<
ffffffffa053fd2c>] ath6kl_sdio_probe+0x21c/0x320 [ath6kl_sdio]
[<
ffffffffa03beb2a>] ? mmc_release_host+0x2a/0x50 [mmc_core]
[<
ffffffffa03c7d2a>] sdio_bus_probe+0xfa/0x130 [mmc_core]
[<
ffffffff813015ae>] driver_probe_device+0x7e/0x1b0
[<
ffffffff8130178b>] __driver_attach+0xab/0xb0
[<
ffffffff813016e0>] ? driver_probe_device+0x1b0/0x1b0
[<
ffffffff813016e0>] ? driver_probe_device+0x1b0/0x1b0
[<
ffffffff81300504>] bus_for_each_dev+0x64/0xa0
[<
ffffffff8130123e>] driver_attach+0x1e/0x20
[<
ffffffff81300e80>] bus_add_driver+0x1b0/0x280
[<
ffffffffa0065000>] ? 0xffffffffa0064fff
[<
ffffffff81301d06>] driver_register+0x76/0x140
[<
ffffffffa0065000>] ? 0xffffffffa0064fff
[<
ffffffffa03c7b71>] sdio_register_driver+0x21/0x30 [mmc_core]
[<
ffffffffa0065012>] ath6kl_sdio_init+0x12/0x35 [ath6kl_sdio]
[<
ffffffff81002042>] do_one_initcall+0x42/0x180
[<
ffffffff810b025f>] sys_init_module+0x8f/0x200
[<
ffffffff81425ac2>] system_call_fastpath+0x16/0x1b
Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Ben Hutchings [Mon, 9 Jan 2012 22:06:46 +0000 (14:06 -0800)]
igmp: Avoid zero delay when receiving odd mixture of IGMP queries
Commit
5b7c84066733c5dfb0e4016d939757b38de189e4 ('ipv4: correct IGMP
behavior on v3 query during v2-compatibility mode') added yet another
case for query parsing, which can result in max_delay = 0. Substitute
a value of 1, as in the usual v3 case.
Reported-by: Simon McVittie <smcv@debian.org>
References: http://bugs.debian.org/654876
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
stephen hemminger [Thu, 5 Jan 2012 19:10:25 +0000 (19:10 +0000)]
netdev: make net_device_ops const
More drivers where net_device_ops should be const.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
stephen hemminger [Thu, 5 Jan 2012 19:10:24 +0000 (19:10 +0000)]
bcm63xx: make ethtool_ops const
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
stephen hemminger [Thu, 5 Jan 2012 19:10:23 +0000 (19:10 +0000)]
usbnet: make ethtool_ops const
The ethtool_ops table of function pointers should be const.
Fix all the usb network drivers.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
David S. Miller [Mon, 9 Jan 2012 21:44:23 +0000 (13:44 -0800)]
net: Fix build with INET disabled.
> net/core/sock.c: In function 'sk_update_clone':
> net/core/sock.c:1278:3: error: implicit declaration of function 'sock_update_memcg'
Reported-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Jiri Pirko [Mon, 9 Jan 2012 06:36:54 +0000 (06:36 +0000)]
net: introduce netif_addr_lock_nested() and call if when appropriate
dev_uc_sync() and dev_mc_sync() are acquiring netif_addr_lock for
destination device of synchronization. Since netif_addr_lock is
already held at the time for source device, this triggers lockdep
deadlock warning.
There's no way this deadlock can happen so use spin_lock_nested() to
silence the warning.
Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Jiri Pirko [Mon, 9 Jan 2012 06:18:34 +0000 (06:18 +0000)]
net: correct lock name in dev_[uc/mc]_sync documentations.
Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Stephen Hemminger [Thu, 5 Jan 2012 18:39:48 +0000 (10:39 -0800)]
ath6kl: make net_device_ops const
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Wed, 4 Jan 2012 10:27:19 +0000 (15:57 +0530)]
ath6kl: Use a mutex_lock to avoid race in diabling and handling irq
Currently this race is handled but in a messy way an atomic
variable is being checked in a loop which sleeps upto ms
in every iteration. Remove this logic and use a mutex
to make sure irq is not disabled when irq handling is in
progress.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Tue, 3 Jan 2012 09:58:53 +0000 (15:28 +0530)]
ath6kl: Change ielen in ath6kl_add_new_sta() from u8 to size_t
Otherwise if (ielen <= ATH6KL_MAX_IE) is dead code. It looks safe to
change the type of ielen from u8 to size_t instead of removing this
if check, this ielen can have the length of more than one ies in future.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Tue, 3 Jan 2012 09:49:02 +0000 (15:19 +0530)]
ath6kl: Remove deadcode in main.c
In ath6kl_reset_device(), since control can never reach switch..case
when the target_type is neither TARGET_TYPE_AR6003 nor TARGET_TYPE_AR6004,
remove the default option of switch statement.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Tue, 3 Jan 2012 09:12:01 +0000 (14:42 +0530)]
ath6kl: Implement ndo_set_rx_mode()
There are maximum of seven multicast filter are supported
by hw. When the requested number of filters exceeds the
maximum supported one, multicast filtering is completely
disabled, the requested filters will be configured in
firmware and the only multicast frames that host is interested
in will be passed to host for further processing otherwise.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Tue, 3 Jan 2012 09:12:00 +0000 (14:42 +0530)]
ath6kl: Add a function in wmi.c to add/delete a multicast filter
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Vasanthakumar Thiagarajan [Tue, 3 Jan 2012 09:11:59 +0000 (14:41 +0530)]
ath6kl: Add a function in wmi to send WMI_MCAST_FILTER_CMDID
This will be used to disable/enable multicast receive.
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Stephen Rothwell [Mon, 9 Jan 2012 05:33:16 +0000 (16:33 +1100)]
net: sk_update_clone is only used in net/core/sock.c
so move it there. Fixes build errors when CONFIG_INET is not defined:
In file included from include/linux/tcp.h:211:0,
from include/linux/ipv6.h:221,
from include/net/ipv6.h:16,
from include/linux/sunrpc/clnt.h:26,
from include/linux/nfs_fs.h:50,
from init/do_mounts.c:20:
include/net/sock.h: In function 'sk_update_clone':
include/net/sock.h:1109:3: error: implicit declaration of function 'sock_update_memcg' [-Werror=implicit-function-declaration]
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
françois romieu [Sun, 8 Jan 2012 13:41:33 +0000 (13:41 +0000)]
8139cp: fix missing napi_gro_flush.
The driver uses __napi_complete and napi_gro_receive. Without it, the
driver hits the BUG_ON(n->gro_list) assertion hard in __napi_complete.
Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
Tested-by: Marin Glibic <zhilla2@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Dan Carpenter [Fri, 6 Jan 2012 03:13:47 +0000 (03:13 +0000)]
pktgen: set correct max and min in pktgen_setup_inject()
In
882716604ec "pktgen: fix multiple queue warning" we added special
logic to handle the case where ntxq is zero. It's not clear to me that
ntxq can actually be zero. But if it were then we would set
->queue_map_min and ->queue_map_max to USHRT_MAX when probably we want
to set them to zero?
Signed-off-by: David S. Miller <davem@davemloft.net>
David S. Miller [Sat, 7 Jan 2012 20:22:11 +0000 (12:22 -0800)]
smsc911x: Unconditionally include linux/smscphy.h in smsc911x.h
The energy detect enable/disable code in the driver uses some
register defines in this header unconditionally, so guarding
the smscphy.h header include with CONFIG_SMSC_PHY leads to
build failures in some configurations.
Reported-by: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Aurelien Jacobs [Sat, 7 Jan 2012 20:15:16 +0000 (12:15 -0800)]
asix: fix infinite loop in rx_fixup()
At this point if skb->len happens to be 2, the subsequant skb_pull(skb, 4)
call won't work and the skb->len won't be decreased and won't ever reach 0,
resulting in an infinite loop.
With an ASIX 88772 under heavy load, without this patch, rx_fixup() reaches
an infinite loop in less than a minute. With this patch applied,
no infinite loop even after hours of heavy load.
Signed-off-by: Aurelien Jacobs <aurel@gnuage.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
David S. Miller [Sat, 7 Jan 2012 20:13:06 +0000 (12:13 -0800)]
net: Default UDP and UNIX diag to 'n'.
Signed-off-by: David S. Miller <davem@davemloft.net>
Cesar Eduardo Barros [Sat, 7 Jan 2012 05:13:17 +0000 (05:13 +0000)]
r6040: fix typo in use of MCR0 register bits
Commit
4e16d6ebd65b4f2c4e3f780b4c5704beef64019c (r6040: define more MCR0
register bits) added #define values for MCR0 register bits and converted
uses of hardcoded magic values to uses of these defines.
However, one of the conversions looks suspicious:
#define MCR0 0x00 /* Control register 0 */
+#define MCR0_RCVEN 0x0002 /* Receive enable */
+#define MCR0_XMTEN 0x1000 /* Transmission enable */
/* Init RDC private data */
- lp->mcr0 = 0x1002;
+ lp->mcr0 = MCR0_XMTEN | MCR0;
I believe what was meant here was MCR0_XMTEN | MCR0_RCVEN, which makes
sense and matches the original values.
Signed-off-by: Cesar Eduardo Barros <cesarb@cesarb.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Glauber Costa [Thu, 5 Jan 2012 20:16:39 +0000 (20:16 +0000)]
net: fix sock_clone reference mismatch with tcp memcontrol
Sockets can also be created through sock_clone. Because it copies
all data in the sock structure, it also copies the memcg-related pointer,
and all should be fine. However, since we now use reference counts in
socket creation, we are left with some sockets that have no reference
counts. It matters when we destroy them, since it leads to a mismatch.
Signed-off-by: Glauber Costa <glommer@parallels.com>
CC: David S. Miller <davem@davemloft.net>
CC: Greg Thelen <gthelen@google.com>
CC: Hiroyouki Kamezawa <kamezawa.hiroyu@jp.fujitsu.com>
CC: Laurent Chavey <chavey@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Linus Torvalds [Sat, 7 Jan 2012 02:28:12 +0000 (18:28 -0800)]
Merge branch 'for-linus' of git://git./linux/kernel/git/geert/linux-m68k
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k: (21 commits)
m68k/mac: Make CONFIG_HEARTBEAT unavailable on Mac
m68k/serial: Remove references to obsolete serial config options
m68k/net: Remove obsolete IRQ_FLG_* users
m68k: Don't comment out syscalls used by glibc
m68k/atari: Move declaration of atari_SCC_reset_done to header file
m68k/serial: Remove references to obsolete CONFIG_SERIAL167
m68k/hp300: Export hp300_ledstate
m68k: Initconst section fixes
m68k/mac: cleanup macro case
mac_scsi: fix mac_scsi on some powerbooks
m68k/mac: fix powerbook 150 adb_type
m68k/mac: fix baboon irq disable and shutdown
m68k/mac: oss irq fixes
m68k/mac: fix nubus slot irq disable and shutdown
m68k/mac: enable via_alt_mapping on performa 580
m68k/mac: cleanup forward declarations
m68k/mac: cleanup mac_irq_pending
m68k/mac: cleanup mac_clear_irq
m68k/mac: early console
m68k/mvme16x: Add support for EARLY_PRINTK
...
Fix up trivial conflict in arch/m68k/Kconfig.debug due to new
EARLY_PRINTK config option addition clashing with movement of the
BOOTPARAM options.
Linus Torvalds [Sat, 7 Jan 2012 02:15:25 +0000 (18:15 -0800)]
Merge branch 'for-linus' of git://ftp.arm.linux.org.uk/pub/linux/arm/kernel/git-cur/linux-2.6-arm
* 'for-linus' of git://ftp.arm.linux.org.uk/pub/linux/arm/kernel/git-cur/linux-2.6-arm: (207 commits)
ARM: 7267/1: Remove BUILD_BUG_ON from asm/bug.h
ARM: 7269/1: mach-sa1100: fix sched_clock breakage
ARM: 7198/1: arm/imx6: add restart support for imx6q
ARM: restart: remove the now empty arch_reset()
ARM: restart: remove comments about adding code to arch_reset()
ARM: restart: lpc32xx & u300: remove unnecessary printk
ARM: restart: plat-samsung: remove plat/reset.h and s5p_reset_hook
ARM: restart: w90x900: use new restart hook
ARM: restart: Versatile Express: use new restart hook
ARM: restart: versatile: use new restart hook
ARM: restart: u300: use new restart hook
ARM: restart: tegra: use new restart hook
ARM: restart: spear: use new restart hook
ARM: restart: shark: use new restart hook
ARM: restart: sa1100: use new restart hook
ARM: 7252/1: restart: S5PV210: use new restart hook
ARM: 7251/1: restart: S5PC100: use new restart hook
ARM: 7250/1: restart: S5P64X0: use new restart hook
ARM: 7266/1: restart: S3C64XX: use new restart hook
ARM: 7265/1: restart: S3C24XX: use new restart hook
...
Fix up trivial conflict in arch/arm/mm/init.c due to removal of
memblock_init() clashing with the movement of the sorting of the meminfo
array.
Linus Torvalds [Sat, 7 Jan 2012 02:03:30 +0000 (18:03 -0800)]
Merge branch 'amba-modalias' of git://ftp.arm.linux.org.uk/pub/linux/arm/kernel/git-cur/linux-2.6-arm
* 'amba-modalias' of git://ftp.arm.linux.org.uk/pub/linux/arm/kernel/git-cur/linux-2.6-arm:
sound: aaci: Enable module alias autogeneration for AMBA drivers
watchdog: sp805: Enable module alias autogeneration for AMBA drivers
fbdev: amba: Enable module alias autogeneration for AMBA drivers
serial: pl011: Enable module alias autogeneration for AMBA drivers
serial: pl010: Enable module alias autogeneration for AMBA drivers
spi: pl022: Enable module alias autogeneration for AMBA drivers
rtc: pl031: Enable module alias autogeneration for AMBA drivers
rtc: pl030: Enable module alias autogeneration for AMBA drivers
mmc: mmci: Enable module alias autogeneration for AMBA drivers
input: ambakmi: Enable module alias autogeneration for AMBA drivers
gpio: pl061: Enable module alias autogeneration for AMBA drivers
dmaengine: pl330: Enable module alias autogeneration for AMBA drivers
dmaengine: pl08x: Enable module alias autogeneration for AMBA drivers
hwrng: nomadik: Enable module alias autogeneration for AMBA drivers
ARM: amba: Auto-generate AMBA driver module aliases during modpost
ARM: amba: Move definition of struct amba_id to mod_devicetable.h
Linus Torvalds [Sat, 7 Jan 2012 02:03:02 +0000 (18:03 -0800)]
Merge branch 'pstore' of git://git./linux/kernel/git/aegl/linux
* 'pstore' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux:
pstore: gracefully handle NULL pstore_info functions
pstore: pass reason to backend write callback
Linus Torvalds [Sat, 7 Jan 2012 02:02:43 +0000 (18:02 -0800)]
Merge branch 'misc-3.3' of git://git./linux/kernel/git/aegl/linux
* 'misc-3.3' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux:
ia64: pcibr: Use kmemdup rather than duplicating its implementation
ia64: sn: Use kmemdup rather than duplicating its implementation
ia64: tioca: Use kmemdup rather than duplicating its implementation
[IA64] Merge overlapping reserved regions at boot
Linus Torvalds [Sat, 7 Jan 2012 01:59:33 +0000 (17:59 -0800)]
Merge branch 'for-next' of git://git./linux/kernel/git/gerg/m68knommu
* 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu: (56 commits)
m68k: allow ColdFire 547x and 548x CPUs to be built with MMU enabled
m68k/Kconfig: Separate classic m68k and coldfire early
m68k: add ColdFire with MMU enabled support to the m68k mem init code
m68k: do not use m68k startup or interrupt code for ColdFire CPUs
m68k: add ColdFire FPU support for the V4e ColdFire CPUs
m68k: adjustments to stack frame for ColdFire with MMU enabled
m68k: use non-MMU linker script for ColdFire MMU builds
m68k: ColdFire with MMU enabled uses same clocking code as non-MMU
m68k: add code to setup a ColdFire 54xx platform when MMU enabled
m68k: use non-MMU entry.S code when compiling for ColdFire CPU
m68k: create ColdFire MMU pgalloc code
m68k: compile appropriate mm arch files for ColdFire MMU support
m68k: ColdFire V4e MMU paging init code and miss handler
m68k: use ColdFire MMU read/write bit flags when ioremapping
m68k: modify cache push and clear code for ColdFire with MMU enable
m68k: use tracehook_report_syscall_entry/exit for ColdFire MMU ptrace path
m68k: ColdFire V4e MMU context support code
m68k: MMU enabled ColdFire needs 8k ELF alignment
m68k: set ColdFire MMU page size
m68k: define PAGE_OFFSET_RAW for ColdFire CPU with MMU enabled
...
Linus Torvalds [Sat, 7 Jan 2012 01:58:22 +0000 (17:58 -0800)]
Merge branch 'next' of git://git./linux/kernel/git/benh/powerpc
* 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc: (185 commits)
powerpc: fix compile error with 85xx/p1010rdb.c
powerpc: fix compile error with 85xx/p1023_rds.c
powerpc/fsl: add MSI support for the Freescale hypervisor
arch/powerpc/sysdev/fsl_rmu.c: introduce missing kfree
powerpc/fsl: Add support for Integrated Flash Controller
powerpc/fsl: update compatiable on fsl 16550 uart nodes
powerpc/85xx: fix PCI and localbus properties in p1022ds.dts
powerpc/85xx: re-enable ePAPR byte channel driver in corenet32_smp_defconfig
powerpc/fsl: Update defconfigs to enable some standard FSL HW features
powerpc: Add TBI PHY node to first MDIO bus
sbc834x: put full compat string in board match check
powerpc/fsl-pci: Allow 64-bit PCIe devices to DMA to any memory address
powerpc: Fix unpaired probe_hcall_entry and probe_hcall_exit
offb: Fix setting of the pseudo-palette for >8bpp
offb: Add palette hack for qemu "standard vga" framebuffer
offb: Fix bug in calculating requested vram size
powerpc/boot: Change the WARN to INFO for boot wrapper overlap message
powerpc/44x: Fix build error on currituck platform
powerpc/boot: Change the load address for the wrapper to fit the kernel
powerpc/44x: Enable CRASH_DUMP for 440x
...
Fix up a trivial conflict in arch/powerpc/include/asm/cputime.h due to
the additional sparse-checking code for cputime_t.
Linus Torvalds [Sat, 7 Jan 2012 01:22:09 +0000 (17:22 -0800)]
Merge git://git./linux/kernel/git/davem/net-next
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1958 commits)
net: pack skb_shared_info more efficiently
net_sched: red: split red_parms into parms and vars
net_sched: sfq: extend limits
cnic: Improve error recovery on bnx2x devices
cnic: Re-init dev->stats_addr after chip reset
net_sched: Bug in netem reordering
bna: fix sparse warnings/errors
bna: make ethtool_ops and strings const
xgmac: cleanups
net: make ethtool_ops const
vmxnet3" make ethtool ops const
xen-netback: make ops structs const
virtio_net: Pass gfp flags when allocating rx buffers.
ixgbe: FCoE: Add support for ndo_get_fcoe_hbainfo() call
netdev: FCoE: Add new ndo_get_fcoe_hbainfo() call
igb: reset PHY after recovering from PHY power down
igb: add basic runtime PM support
igb: Add support for byte queue limits.
e1000: cleanup CE4100 MDIO registers access
e1000: unmap ce4100_gbe_mdio_base_virt in e1000_remove
...
Linus Torvalds [Fri, 6 Jan 2012 23:02:37 +0000 (15:02 -0800)]
Merge branch 'x86-mce-for-linus' of git://git./linux/kernel/git/tip/tip
* 'x86-mce-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
x86: add IRQ context simulation in module mce-inject
x86, mce, therm_throt: Don't report power limit and package level thermal throttle events in mcelog
x86, MCE: Drain mcelog buffer
x86, mce: Add wrappers for registering on the decode chain
Linus Torvalds [Fri, 6 Jan 2012 23:02:14 +0000 (15:02 -0800)]
Merge branch 'x86-microcode-for-linus' of git://git./linux/kernel/git/tip/tip
* 'x86-microcode-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
x86, microcode, AMD: Update copyrights
x86, microcode, AMD: Exit early on success
x86, microcode, AMD: Simplify ucode verification
x86, microcode, AMD: Add a reusable buffer
x86, microcode, AMD: Add a vendor-specific exit function
Linus Torvalds [Fri, 6 Jan 2012 23:02:00 +0000 (15:02 -0800)]
Merge branch 'x86-rdrand-for-linus' of git://git./linux/kernel/git/tip/tip
* 'x86-rdrand-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
random: Use arch_get_random_int instead of cycle counter if avail
Linus Torvalds [Fri, 6 Jan 2012 22:00:44 +0000 (14:00 -0800)]
Merge branch 'x86-cpu-for-linus' of git://git./linux/kernel/git/tip/tip
* 'x86-cpu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
x86, centaur: Enable cx8 for VIA Eden too
Linus Torvalds [Fri, 6 Jan 2012 22:00:12 +0000 (14:00 -0800)]
Merge branch 'x86-cleanups-for-linus' of git://git./linux/kernel/git/tip/tip
* 'x86-cleanups-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
x86: Use "do { } while(0)" for empty lock_cmos()/unlock_cmos() macros
x86: Use "do { } while(0)" for empty flush_tlb_fix_spurious_fault() macro
x86, CPU: Drop superfluous get_cpu_cap() prototype
arch/x86/mm/pageattr.c: Quiet sparse noise; local functions should be static
arch/x86/kernel/ptrace.c: Quiet sparse noise
x86: Use kmemdup() in copy_thread(), rather than duplicating its implementation
x86: Replace the EVT_TO_HPET_DEV() macro with an inline function
Linus Torvalds [Fri, 6 Jan 2012 21:59:14 +0000 (13:59 -0800)]
Merge branch 'x86-asm-for-linus' of git://git./linux/kernel/git/tip/tip
* 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (21 commits)
x86: Fix atomic64_xxx_cx8() functions
x86: Fix and improve cmpxchg_double{,_local}()
x86_64, asm: Optimise fls(), ffs() and fls64()
x86, bitops: Move fls64.h inside __KERNEL__
x86: Fix and improve percpu_cmpxchg{8,16}b_double()
x86: Report cpb and eff_freq_ro flags correctly
x86/i386: Use less assembly in strlen(), speed things up a bit
x86: Use the same node_distance for 32 and 64-bit
x86: Fix rflags in FAKE_STACK_FRAME
x86: Clean up and extend do_int3()
x86: Call do_notify_resume() with interrupts enabled
x86/div64: Add a micro-optimization shortcut if base is power of two
x86-64: Cleanup some assembly entry points
x86-64: Slightly shorten line system call entry and exit paths
x86-64: Reduce amount of redundant code generated for invalidate_interruptNN
x86-64: Slightly shorten int_ret_from_sys_call
x86, efi: Convert efi_phys_get_time() args to physical addresses
x86: Default to vsyscall=emulate
x86-64: Set siginfo and context on vsyscall emulation faults
x86: consolidate xchg and xadd macros
...
Linus Torvalds [Fri, 6 Jan 2012 21:58:21 +0000 (13:58 -0800)]
Merge branch 'x86-apic-for-linus' of git://git./linux/kernel/git/tip/tip
* 'x86-apic-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
x86: Skip cpus with apic-ids >= 255 in !x2apic_mode
x86, x2apic: Allow "nox2apic" to disable x2apic mode setup by BIOS
x86, x2apic: Fallback to xapic when BIOS doesn't setup interrupt-remapping
x86, acpi: Skip acpi x2apic entries if the x2apic feature is not present
x86, apic: Add probe() for apic_flat
x86: Simplify code by removing a !SMP #ifdefs from 'struct cpuinfo_x86'
x86: Convert per-cpu counter icr_read_retry_count into a member of irq_stat
x86: Add per-cpu stat counter for APIC ICR read tries
pci, x86/io-apic: Allow PCI_IOAPIC to be user configurable on x86
x86: Fix the !CONFIG_NUMA build of the new CPU ID fixup code support
x86: Add NumaChip support
x86: Add x86_init platform override to fix up NUMA core numbering
x86: Make flat_init_apic_ldr() available
Linus Torvalds [Fri, 6 Jan 2012 21:57:44 +0000 (13:57 -0800)]
Merge branch 'timers-core-for-linus' of git://git./linux/kernel/git/tip/tip
* 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
x86, tsc: Skip TSC synchronization checks for tsc=reliable
clocksource: Convert tcb_clksrc to use clocksource_register_hz/khz
clocksource: cris: Convert to clocksource_register_khz
clocksource: xtensa: Convert to clocksource_register_hz/khz
clocksource: um: Convert to clocksource_register_hz/khz
clocksource: parisc: Convert to clocksource_register_hz/khz
clocksource: m86k: Convert to clocksource_register_hz/khz
time: x86: Replace LATCH with PIT_LATCH in i8253 clocksource driver
time: x86: Remove CLOCK_TICK_RATE from acpi_pm clocksource driver
time: x86: Remove CLOCK_TICK_RATE from mach_timer.h
time: x86: Remove CLOCK_TICK_RATE from tsc code
time: Fix spelling mistakes in new comments
time: fix bogus comment in timekeeping_get_ns_raw
Linus Torvalds [Fri, 6 Jan 2012 16:33:28 +0000 (08:33 -0800)]
Merge branch 'sched-core-for-linus' of git://git./linux/kernel/git/tip/tip
* 'sched-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (40 commits)
sched/tracing: Add a new tracepoint for sleeptime
sched: Disable scheduler warnings during oopses
sched: Fix cgroup movement of waking process
sched: Fix cgroup movement of newly created process
sched: Fix cgroup movement of forking process
sched: Remove cfs bandwidth period check in tg_set_cfs_period()
sched: Fix load-balance lock-breaking
sched: Replace all_pinned with a generic flags field
sched: Only queue remote wakeups when crossing cache boundaries
sched: Add missing rcu_dereference() around ->real_parent usage
[S390] fix cputime overflow in uptime_proc_show
[S390] cputime: add sparse checking and cleanup
sched: Mark parent and real_parent as __rcu
sched, nohz: Fix missing RCU read lock
sched, nohz: Set the NOHZ_BALANCE_KICK flag for idle load balancer
sched, nohz: Fix the idle cpu check in nohz_idle_balance
sched: Use jump_labels for sched_feat
sched/accounting: Fix parameter passing in task_group_account_field
sched/accounting: Fix user/system tick double accounting
sched/accounting: Re-use scheduler statistics for the root cgroup
...
Fix up conflicts in
- arch/ia64/include/asm/cputime.h, include/asm-generic/cputime.h
usecs_to_cputime64() vs the sparse cleanups
- kernel/sched/fair.c, kernel/time/tick-sched.c
scheduler changes in multiple branches
Linus Torvalds [Fri, 6 Jan 2012 16:02:58 +0000 (08:02 -0800)]
Merge branch 'perf-core-for-linus' of git://git./linux/kernel/git/tip/tip
* 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (106 commits)
perf kvm: Fix copy & paste error in description
perf script: Kill script_spec__delete
perf top: Fix a memory leak
perf stat: Introduce get_ratio_color() helper
perf session: Remove impossible condition check
perf tools: Fix feature-bits rework fallout, remove unused variable
perf script: Add generic perl handler to process events
perf tools: Use for_each_set_bit() to iterate over feature flags
perf tools: Unify handling of features when writing feature section
perf report: Accept fifos as input file
perf tools: Moving code in some files
perf tools: Fix out-of-bound access to struct perf_session
perf tools: Continue processing header on unknown features
perf tools: Improve macros for struct feature_ops
perf: builtin-record: Document and check that mmap_pages must be a power of two.
perf: builtin-record: Provide advice if mmap'ing fails with EPERM.
perf tools: Fix truncated annotation
perf script: look up thread using tid instead of pid
perf tools: Look up thread names for system wide profiling
perf tools: Fix comm for processes with named threads
...
Linus Torvalds [Fri, 6 Jan 2012 16:02:40 +0000 (08:02 -0800)]
Merge branch 'core-rcu-for-linus' of git://git./linux/kernel/git/tip/tip
* 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (64 commits)
cpu: Export cpu_up()
rcu: Apply ACCESS_ONCE() to rcu_boost() return value
Revert "rcu: Permit rt_mutex_unlock() with irqs disabled"
docs: Additional LWN links to RCU API
rcu: Augment rcu_batch_end tracing for idle and callback state
rcu: Add rcutorture tests for srcu_read_lock_raw()
rcu: Make rcutorture test for hotpluggability before offlining CPUs
driver-core/cpu: Expose hotpluggability to the rest of the kernel
rcu: Remove redundant rcu_cpu_stall_suppress declaration
rcu: Adaptive dyntick-idle preparation
rcu: Keep invoking callbacks if CPU otherwise idle
rcu: Irq nesting is always 0 on rcu_enter_idle_common
rcu: Don't check irq nesting from rcu idle entry/exit
rcu: Permit dyntick-idle with callbacks pending
rcu: Document same-context read-side constraints
rcu: Identify dyntick-idle CPUs on first force_quiescent_state() pass
rcu: Remove dynticks false positives and RCU failures
rcu: Reduce latency of rcu_prepare_for_idle()
rcu: Eliminate RCU_FAST_NO_HZ grace-period hang
rcu: Avoid needlessly IPIing CPUs at GP end
...
Linus Torvalds [Fri, 6 Jan 2012 16:01:59 +0000 (08:01 -0800)]
Merge branch 'core-printk-for-linus' of git://git./linux/kernel/git/tip/tip
* 'core-printk-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
printk, lockdep: Switch to tracked irq ops
printk, lockdep: Remove superfluous preempt_disable()
printk, lockdep: Disable lock debugging on zap_locks()
Linus Torvalds [Fri, 6 Jan 2012 15:54:53 +0000 (07:54 -0800)]
Merge branch 'core-memblock-for-linus' of git://git./linux/kernel/git/tip/tip
* 'core-memblock-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (52 commits)
memblock: Reimplement memblock allocation using reverse free area iterator
memblock: Kill early_node_map[]
score: Use HAVE_MEMBLOCK_NODE_MAP
s390: Use HAVE_MEMBLOCK_NODE_MAP
mips: Use HAVE_MEMBLOCK_NODE_MAP
ia64: Use HAVE_MEMBLOCK_NODE_MAP
SuperH: Use HAVE_MEMBLOCK_NODE_MAP
sparc: Use HAVE_MEMBLOCK_NODE_MAP
powerpc: Use HAVE_MEMBLOCK_NODE_MAP
memblock: Implement memblock_add_node()
memblock: s/memblock_analyze()/memblock_allow_resize()/ and update users
memblock: Track total size of regions automatically
powerpc: Cleanup memblock usage
memblock: Reimplement memblock_enforce_memory_limit() using __memblock_remove()
memblock: Make memblock functions handle overflowing range @size
memblock: Reimplement __memblock_remove() using memblock_isolate_range()
memblock: Separate out memblock_isolate_range() from memblock_set_node()
memblock: Kill memblock_init()
memblock: Kill sentinel entries at the end of static region arrays
memblock: Add __memblock_dump_all()
...
Linus Torvalds [Fri, 6 Jan 2012 15:53:52 +0000 (07:53 -0800)]
Merge branch 'core-locking-for-linus' of git://git./linux/kernel/git/tip/tip
* 'core-locking-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
lockdep/waitqueues: Add better annotation
lockdep, bug: Exclude TAINT_OOT_MODULE from disabling lock debugging
lockdep: Print lock name in lockdep_init_error()
init/main.c: Execute lockdep_init() as early as possible
lockdep, kmemcheck: Annotate ->lock in lockdep_init_map()
lockdep, rtmutex, bug: Show taint flags on error
lockdep, bug: Exclude TAINT_FIRMWARE_WORKAROUND from disabling lockdep
lockdep: Always try to set ->class_cache in register_lock_class() lockdep_init_map()
Linus Torvalds [Fri, 6 Jan 2012 15:53:34 +0000 (07:53 -0800)]
Merge branch 'core-debugobjects-for-linus' of git://git./linux/kernel/git/tip/tip
* 'core-debugobjects-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
timer: Use debugobjects to catch deletion of uninitialized timers
timer: Setup uninitialized timer with a stub callback
debugobjects: Extend to assert that an object is initialized
debugobjects: Be smarter about static objects
Linus Torvalds [Thu, 5 Jan 2012 23:40:12 +0000 (15:40 -0800)]
vfs: fix up ENOIOCTLCMD error handling
We're doing some odd things there, which already messes up various users
(see the net/socket.c code that this removes), and it was going to add
yet more crud to the block layer because of the incorrect error code
translation.
ENOIOCTLCMD is not an error return that should be returned to user mode
from the "ioctl()" system call, but it should *not* be translated as
EINVAL ("Invalid argument"). It should be translated as ENOTTY
("Inappropriate ioctl for device").
That EINVAL confusion has apparently so permeated some code that the
block layer actually checks for it, which is sad. We continue to do so
for now, but add a big comment about how wrong that is, and we should
remove it entirely eventually. In the meantime, this tries to keep the
changes localized to just the EINVAL -> ENOTTY fix, and removing code
that makes it harder to do the right thing.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Ian Campbell [Thu, 5 Jan 2012 07:13:39 +0000 (07:13 +0000)]
net: pack skb_shared_info more efficiently
nr_frags can be 8 bits since 256 is plenty of fragments. This allows it to be
packed with tx_flags.
Also by moving ip6_frag_id and dataref (both 4 bytes) next to each other we can
avoid a hole between ip6_frag_id and frag_list on 64 bit systems.
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Eric Dumazet [Thu, 5 Jan 2012 02:25:16 +0000 (02:25 +0000)]
net_sched: red: split red_parms into parms and vars
This patch splits the red_parms structure into two components.
One holding the RED 'constant' parameters, and one containing the
variables.
This permits a size reduction of GRED qdisc, and is a preliminary step
to add an optional RED unit to SFQ.
SFQRED will have a single red_parms structure shared by all flows, and a
private red_vars per flow.
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
CC: Dave Taht <dave.taht@gmail.com>
CC: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>