Hante Meuleman [Sat, 21 Jun 2014 10:11:15 +0000 (12:11 +0200)]
brcmfmac: Change USB probe routine to support Composite USB
Some of the USB devices also have Bluetooth inside. These devices
can with specific firmware result in a composite USB device. This
change will update the driver such that it will also accept the
correct interface of composite devices. It is backward compatible
with old non-composite USB fw.
Reviewed-by: Arend Van Spriel <arend@broadcom.com> Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com> Signed-off-by: Hante Meuleman <meuleman@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Arend van Spriel [Sat, 21 Jun 2014 10:11:14 +0000 (12:11 +0200)]
brcmfmac: clear ht info during attach phase
After updating 2G bandwidth capability clear ht info. This will be properly
set upon calling brcmf_update_wiphy_bands().
Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Rasmus Villemoes [Sun, 22 Jun 2014 18:50:40 +0000 (20:50 +0200)]
net/wireless/brcm80211/brcmfmac: Make return type and name reflect actual semantics
Applying ++ to a bool is equivalent to setting it true, regardless of
its initial value (bools are not uint1_t). Hence the function
wl_get_vif_state_all can only ever return true/false. The only in-tree
caller uses its return value as a boolean. So update its return type,
and since the list traversal and bit testing have no side effects,
just return true immediately. Its return value tells if any vif is in
the specified state, so also rename it to brcmf_get_vif_state_any.
Reviewed-by: Arend van Spriel<arend@broadcom.com> Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Bing Zhao [Fri, 20 Jun 2014 04:38:58 +0000 (21:38 -0700)]
mwifiex: print sleep_confirm cmd/response and power save events
Sleep Confirm command is sent separately while other commands
are handled through cmd_pending_q. Print sleep_confirm cmd and
its response as well as power save events so that we have a
clearer picture of power save handshake in driver log.
Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Xinming Hu [Fri, 20 Jun 2014 04:38:56 +0000 (21:38 -0700)]
mwifiex: add hscfg to debugfs
Some SDIO controllers do not support MMC_PM_KEEP_POWER properly.
To test host sleep feature without putting the system into sleep
we need to simulate host sleep configuration & handshake between
driver and firmware using customized parameters.
This patch adds hscfg debugfs item, with which user could change
host sleep parameters for debugging.
Signed-off-by: Xinming Hu <huxm@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Amitkumar Karwar [Fri, 20 Jun 2014 04:38:53 +0000 (21:38 -0700)]
mwifiex: use generic 'iface_work' workqueue for SDIO interface
Existing dedicated card_reset work queue is replaced with the
interface specific workqueue pointer provided by mwifiex module.
Also new work flag is added for card reset task.
Signed-off-by: Amitkumar Karwar <akarwar@marvell.com> Signed-off-by: Bing Zhao <bzhao@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Michal Kazior [Wed, 25 Jun 2014 10:35:09 +0000 (12:35 +0200)]
mac80211: use chanctx reservation for STA CSA
Channel switch finalization is now 2-step. First
step is when driver calls chswitch_done(), the
other is when reservation is actually finalized
(which be defered for in-place reservation).
It is now safe to call ieee80211_chswitch_done()
more than once.
Also remove the ieee80211_vif_change_channel()
because it is no longer used.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Wed, 25 Jun 2014 10:35:08 +0000 (12:35 +0200)]
mac80211: use chanctx reservation for AP CSA
Channel switch finalization is now 2-step. First
step is when driver calls csa_finish(), the other
is when reservation is actually finalized (which
can be deferred for in-place reservation).
It is now safe to call ieee80211_csa_finish() more
than once.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
David Spinadel [Thu, 6 Feb 2014 14:15:23 +0000 (16:15 +0200)]
mac80211: split sched scan IEs
Split sched scan IEs to band specific and not band specific
blocks. Common IEs blocks may be sent to the FW once per command,
instead of per band.
This allows optimization of size of the command, which may be
required by some drivers (eg. iwlmvm with newer firmware version).
As this changes the mac80211 API, update all drivers to use the
new version correctly, even if they don't (yet) make use of the
split data.
Signed-off-by: David Spinadel <david.spinadel@intel.com> Reviewed-by: Alexander Bondar <alexander.bondar@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
David Spinadel [Wed, 5 Feb 2014 13:21:13 +0000 (15:21 +0200)]
mac80211: support more than one band in scan request
Some drivers (such as iwlmvm) can handle multiple bands in a single
HW scan request. Add a HW flag to indicate that the driver support
this. To hold the required data, create a separate structure for
HW scan request that holds cfg scan request and data about
different parts of the scan IEs.
As this changes the mac80211 API, update all drivers using it to
use the correct new function type/argument.
Signed-off-by: David Spinadel <david.spinadel@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Wed, 30 Apr 2014 14:34:45 +0000 (16:34 +0200)]
iwlwifi: mvm: handle device start failures during restart
If the device fails during a restart, mac80211 now handles the
situation better but we still have a little bit of cleanup to
do in the driver - add the required code.
David Spinadel [Thu, 27 Feb 2014 14:41:52 +0000 (16:41 +0200)]
iwlwifi: mvm: support extended beacon notification
Use extended beacon notification when supported by FW.
Set last beacon system time to AP or GO interface.
System time of last beacon can be used to avoid TBTT overlapping
between two interfaces, CSA and other uses.
Signed-off-by: David Spinadel <david.spinadel@intel.com> Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
iwlwifi: mvm: Introduce an API to set STA_FLG_DISABLE_TX flag
Introduce new station flag STA_FLG_DISABLE_TX, which is modified with ADD_STA
command. This flag, when set, disables tx to the STA.
Provide an API (iwl_mvm_sta_modify_disable_tx) to modify this flag, which
should be used in channel switch and immediate quiet flows.
Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com> Reviewed-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Eliad Peller [Sun, 15 Jun 2014 08:12:38 +0000 (11:12 +0300)]
iwlwifi: mvm: disable beacon filtering escape timer in d0i3
The beacon filtering configuration in d0i3 currently uses
the max value defined as 1024. However, with beacon interval
of 100ms we end up with too-frequent wakeups.
Instead, configure the escape timer to 0, asking the fw
to disable it altogether.
iwlwifi: mvm: BT Coex - avoid the shared antenna for management frames
If BT is active, we need to refrain from using the shared
antenna. This logic is done in the firmware when we use the
link quality tables. But for management frames, the rate is
written in the Tx command by the driver.
Hence the driver needs to make sure not use the shared
antenna when BT is active for any frames that don't use
the rate scale table such as management frames or multicast.
Reviewed-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
We can Tx in MIMO rates when we are in TxTx Disallow mode
just like we can when we are in Tight mode.
Same if we are in 5Ghz regardless of the mode we are.
Change the code to allow MIMO in these cases.
Liad Kaufman [Wed, 21 May 2014 11:37:00 +0000 (14:37 +0300)]
iwlwifi: mvm: assure no overflows occur while reading otp
Just in case sizes change in the OTP without proper SW
updating, an additional check is inserted when reading OTP
sections to assure no overflows occur.
Liad Kaufman [Sun, 1 Jun 2014 14:21:33 +0000 (17:21 +0300)]
iwlwifi: update trans->hw_rev 8000 hw family format
The format of the CSR_HW_REV register has changed in 8000
HW family. To keep backwards compatibility, we store the
value of this register as usual in trans->hw_rev, only we
store it in the old format in this variable.
iwlwifi: add device / firmware to fw-error-dump file
This can be useful later for parsing since the parsing may
differ based on the device's family / bus.
Also add the human readable version of the firmware.
Johannes Berg [Wed, 4 Jun 2014 08:13:50 +0000 (10:13 +0200)]
iwlwifi: mvm: add back support for low-priority scan
The low-priority scan feature can be useful, e.g. for OBSS
scans (if those are required by the AP); add back support
for it, restoring the maximum out time to the value it was
for low-priority scan before that was removed.
Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Arik Nemtsov [Wed, 11 Jun 2014 14:18:27 +0000 (17:18 +0300)]
mac80211: protect TDLS discovery session
After sending a TDLS discovery-request, we expect a reply to arrive on
the AP's channel. We must stay on the channel (no PSM, scan, etc.), since
a TDLS setup-response is a direct packet not buffered by the AP.
Add a new mac80211 driver callback to allow discovery session protection.
Arik Nemtsov [Wed, 11 Jun 2014 14:18:26 +0000 (17:18 +0300)]
mac80211: make sure TDLS peer STA exists during setup
Make sure userspace added a TDLS peer station before invoking the
transmission of the first setup frame. This ensures packets to the peer
won't go through the AP path.
Signed-off-by: Arik Nemtsov <arikx.nemtsov@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Arik Nemtsov [Wed, 11 Jun 2014 14:18:24 +0000 (17:18 +0300)]
mac80211: implement proper Tx path flushing for TDLS
As the spec mandates, flush data in the AP path before transmitting the
first setup frame. Data packets transmitted during setup are already
dropped in the Tx path.
For the teardown flow, flush all packets in the direct path before
transmitting the teardown frame. Un-authorize the peer sta after teardown
is sent, forcing all subsequent Tx to the peer through the AP.
Make sure to flush the queues when disabling the link to get the
teardown packet out.
Signed-off-by: Arik Nemtsov <arikx.nemtsov@intel.com>
[adjust to Luca's new quuee API and stop only vif queues] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Arik Nemtsov [Wed, 11 Jun 2014 14:18:23 +0000 (17:18 +0300)]
mac80211: split tdls_mgmt function
There are setup/teardown specific actions to be done that accompany
the sending of a TDLS management packet. Split the main function to
simplify future additions.
Signed-off-by: Arik Nemtsov <arikx.nemtsov@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Arik Nemtsov [Wed, 11 Jun 2014 14:18:22 +0000 (17:18 +0300)]
mac80211: use TDLS initiator in tdls_mgmt operations
The TDLS initiator is set once during link setup. If determines the
address ordering in the link identifier IE.
Use the value from userspace in order to have a correct teardown packet.
With the current code, a teardown from the responder side fails the TDLS
MIC check because of a bad link identifier IE.
Signed-off-by: Arik Nemtsov <arikx.nemtsov@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Arik Nemtsov [Wed, 11 Jun 2014 14:18:19 +0000 (17:18 +0300)]
mac80211: set auth flags after other station info
For TDLS, the AUTHORIZED flag arrives with all other important station
info (supported rates, HT/VHT caps, ...). Make sure to set the station
state in the low-level driver after transferring this information to
the mac80211 STA entry.
This aligns the STA information during sta_state callbacks with the
non-TDLS case.
Luciano Coelho [Fri, 13 Jun 2014 13:30:07 +0000 (16:30 +0300)]
mac80211: stop only the queues assigned to the vif during channel switch
Instead of stopping all the hardware queues during channel switch,
which is especially bad when we have large CSA counts, stop only the
queues that are assigned to the vif that is performing the channel
switch.
Additionally, check for (sdata->csa_block_tx) instead of calling
ieee80211_csa_needs_block_tx(), which can now be removed.
Signed-off-by: Luciano Coelho <luciano.coelho@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Luciano Coelho [Fri, 13 Jun 2014 13:30:06 +0000 (16:30 +0300)]
mac80211: add functions to stop and wake all queues assigned to a vif
In some cases we may want to stop the queues of a single vif (for
instance during a channel-switch). Add a function that stops all the
queues that are assigned to a vif. If a queue is assigned to more
than one vif, the corresponding netdev subqueue of the other vif(s)
will also be stopped. If the HW doesn't set the
IEEE80211_HW_QUEUE_CONTROL flag, then all queues are stopped.
Also add a corresponding function to wake the queues of a vif back.
Signed-off-by: Luciano Coelho <luciano.coelho@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Luciano Coelho [Fri, 13 Jun 2014 13:30:05 +0000 (16:30 +0300)]
mac80211: introduce refcount for queue_stop_reasons
Sometimes different vifs may be stopping the queues for the same
reason (e.g. when several interfaces are performing a channel switch).
Instead of using a bitmask for the reasons, use an integer that holds
a refcount instead. In order to keep it backwards compatible,
introduce a boolean in some functions that tell us whether the queue
stopping should be refcounted or not. For now, use not refcounted for
all calls to keep it functionally the same as before.
Signed-off-by: Luciano Coelho <luciano.coelho@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Thomas Gleixner [Wed, 11 Jun 2014 23:59:18 +0000 (23:59 +0000)]
net: Mac80211: Remove silly timespec dance
Converting time from one format to another seems to give coders a warm
and fuzzy feeling.
Use the proper interfaces.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: John Stultz <john.stultz@linaro.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: John W. Linville <linville@tuxdriver.com>
[fix compile error] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Thu, 12 Jun 2014 20:34:49 +0000 (22:34 +0200)]
mac80211_hwsim: clean up own address matching
Using perm_addr is always wrong, it may be reassigned by
anyone using standard netdev APIs. Remove that from the
match function and also use the match function where only
the perm_addr was used now.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Thu, 5 Jun 2014 12:21:37 +0000 (14:21 +0200)]
mac80211: use csa counter offsets instead of csa_active
vif->csa_active is protected by mutexes only. This
means it is unreliable to depend on it on codeflow
in non-sleepable beacon and CSA code. There was no
guarantee to have vif->csa_active update be
visible before beacons are updated on SMP systems.
Using csa counter offsets which are embedded in
beacon struct (and thus are protected with single
RCU assignment) is much safer.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Michal Kazior [Thu, 5 Jun 2014 12:21:36 +0000 (14:21 +0200)]
mac80211: move csa counters from sdata to beacon/presp
Having csa counters part of beacon and probe_resp
structures makes it easier to get rid of possible
races between setting a beacon and updating
counters on SMP systems by guaranteeing counters
are always consistent against given beacon struct.
While at it relax WARN_ON into WARN_ON_ONCE to
prevent spamming logs and racing.
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
[remove pointless array check] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Janusz Dziedzic [Thu, 5 Jun 2014 06:12:57 +0000 (08:12 +0200)]
mac80211: allow tx via monitor iface when DFS
Allow send frames using monitor interface
when DFS chandef and we pass CAC (beaconing
allowed).
This fix problem when old kernel and new backports used,
in such case hostapd create/use also monitor interface.
Before this patch all frames hostapd send using monitor
iface were dropped when AP was configured on DFS channel.
Signed-off-by: Janusz Dziedzic <janusz.dziedzic@tieto.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Wed, 4 Jun 2014 15:31:56 +0000 (17:31 +0200)]
cfg80211: make ethtool the driver's responsibility
Currently, cfg80211 tries to implement ethtool, but that doesn't
really scale well, with all the different operations. Make the
lower-level driver responsible for it, which currently only has
an effect on mac80211. It will similarly not scale well at that
level though, since mac80211 also has many drivers.
To cleanly implement this in mac80211, introduce a new file and
move some code to appropriate places.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Antonio Ospite <ao2@ao2.it> Cc: Luis Carlos Cobo <luisca@cozybit.com> Cc: Johannes Berg <johannes@sipsolutions.net> Cc: linux-wireless@vger.kernel.org Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Bob Copeland [Wed, 4 Jun 2014 13:27:31 +0000 (09:27 -0400)]
mac80211: remove ignore_plink_timer flag
The mesh_plink code is doing some interesting things with the
ignore_plink_timer flag. It seems the original intent was to
handle this race:
cpu 0 cpu 1
----- -----
start timer handler for state X
acquire sta_lock
change state from X to Y
mod_timer() / del_timer()
release sta_lock
acquire sta_lock
execute state Y timer too soon
However, using the mod_timer()/del_timer() return values to
detect these cases is broken. As a result, timers get ignored
unnecessarily, and stations can get stuck in the peering state
machine.
Instead, we can detect the case by looking at the timer expiration.
In the case of del_timer, just ignore the timers in the following
(LISTEN/ESTAB) states since they won't have timers anyway.
Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Johannes Berg [Tue, 27 May 2014 14:32:27 +0000 (16:32 +0200)]
mac80211: fix station/driver powersave race
It is currently possible to have a race due to the station PS
unblock work like this:
* station goes to sleep with frames buffered in the driver
* driver blocks wakeup
* station wakes up again
* driver flushes/returns frames, and unblocks, which schedules
the unblock work
* unblock work starts to run, and checks that the station is
awake (i.e. that the WLAN_STA_PS_STA flag isn't set)
* we process a received frame with PM=1, setting the flag again
* ieee80211_sta_ps_deliver_wakeup() runs, delivering all frames
to the driver, and then clearing the WLAN_STA_PS_DRIVER and
WLAN_STA_PS_STA flags
In this scenario, mac80211 will think that the station is awake,
while it really is asleep, and any TX'ed frames should be filtered
by the device (it will know that the station is sleeping) but then
passed to mac80211 again, which will not buffer it either as it
thinks the station is awake, and eventually the packets will be
dropped.
Fix this by moving the clearing of the flags to exactly where we
learn about the situation. This creates a problem of reordering,
so introduce another flag indicating that delivery is being done,
this new flag also queues frames and is cleared only while the
spinlock is held (which the queuing code also holds) so that any
concurrent delivery/TX is handled correctly.
Reported-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/ath/ath9k/main.c:299 ath_reset_internal()
error: we previously assumed 'hchan' could be null (see line 293)
Cc: Felix Fietkau <nbd@openwrt.org> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Rajkumar Manoharan <rmanohar@qti.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
On some platforms, cycles_t is 64-bit, and gcc generates call to
__udivdi3 for straight division of cycles_t/cycles_t. This leads
to compilation failure, as this function is not exist in the kernel
runtime. do_div() to rescue
Fabian Frederick [Wed, 18 Jun 2014 17:55:38 +0000 (19:55 +0200)]
PCMCIA_HERMES: ioport_map/unmap relies on HAS_IOPORT_MAP
Fixing following sh-allmodconfig errors reported on kisskb
"
drivers/net/wireless/orinoco/orinoco_cs.c:153:2: error: implicit declaration of function 'ioport_map' [-Werror=implicit-function-declaration]
drivers/net/wireless/orinoco/orinoco_cs.c:205:3: error: implicit declaration of function 'ioport_unmap' [-Werror=implicit-function-declaration]
"
Cc: "John W. Linville" <linville@tuxdriver.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: linux-wireless@vger.kernel.org Signed-off-by: Fabian Frederick <fabf@skynet.be> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Fabian Frederick [Wed, 18 Jun 2014 17:48:02 +0000 (19:48 +0200)]
LIBERTAS_CS: ioport_map/unmap relies on HAS_IOPORT_MAP
Fixing following sh-allmodconfig errors reported on kisskb
"
drivers/net/wireless/libertas/if_cs.c:826:3: error: implicit declaration of function 'ioport_unmap' [-Werror=implicit-function-declaration]
drivers/net/wireless/libertas/if_cs.c:878:2: error: implicit declaration of function 'ioport_map' [-Werror=implicit-function-declaration]
"
Cc: "John W. Linville" <linville@tuxdriver.com> Cc: Dan Williams <dcbw@redhat.com> Cc: linux-wireless@vger.kernel.org Signed-off-by: Fabian Frederick <fabf@skynet.be> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Fabian Frederick [Wed, 18 Jun 2014 17:43:31 +0000 (19:43 +0200)]
SPECTRUM_CS: ioport_map/unmap relies on HAS_IOPORT_MAP
Fixing following sh-allmodconfig errors reported on kisskb
"
drivers/net/wireless/orinoco/spectrum_cs.c:216:2: error: implicit declaration of function 'ioport_map' [-Werror=implicit-function-declaration]
drivers/net/wireless/orinoco/spectrum_cs.c:273:3: error: implicit declaration of function 'ioport_unmap' [-Werror=implicit-function-declaration]
"
Cc: "John W. Linville" <linville@tuxdriver.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: linux-wireless@vger.kernel.org Signed-off-by: Fabian Frederick <fabf@skynet.be> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Fabian Frederick [Wed, 18 Jun 2014 14:51:29 +0000 (16:51 +0200)]
drivers/net/wireless/rt2x00/rt2x00dev.c: remove null test before kfree
Fix checkpatch warning:
WARNING: kfree(NULL) is safe this check is probably not required
Cc: Ivo van Doorn <IvDoorn@gmail.com> Cc: Helmut Schaa <helmut.schaa@googlemail.com> Signed-off-by: Fabian Frederick <fabf@skynet.be> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Track number of interrupts and Tx/Rx packets;
expose through debugfs 'info'. Reset upon read.
Used to analyse effectivness of interrupt coalescing and NAPI.
Read twice with some interval like
cat info > /dev/null; sleep 1; cat info
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Use 'info' debugfs entry for misc. assorted information.
Start with indication whether platform is AC-powered;
will use it later for power related decisions
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
wil6210: work around for platforms with broken INTx
There are platforms where INTx can't be routed by ACPI,
this leads to pci_enable_device failure. Re-try pretending we have
MSI already configured; in this case pci_enable_device do not try
to configure INTx. However, MSI could still work.
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
On Tx path, when vring for the destination not found,
it was considered as error and message was printed unconditionally.
However, this situation is normal after disconnect. If disconnect was while
heavy traffic load, lots of Tx packets will be dropped and this would
cause significant amount of prints in dmesg.
Demote messages priority from 'error' to 'debug'.
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>