Re: [PATCH 19/20] staging/wilc1000: use more regular probing

2015-11-10 Thread Andy Shevchenko
On Wed, Nov 11, 2015 at 1:42 AM, Arnd Bergmann wrote: > So far, my patches tried to do equivalent conversions of the > existing code. This one goes beyond that by restructuring > how the devices get probed. In particular, the spi driver > no longer creates the netdev until the device is probed, >

Re: [PATCH v2] staging/rdma/hfi1: set Gen3 half-swing for integrated devices

2015-11-10 Thread Dan Carpenter
That's fine. I feel like the first option is better because those long names really are cumbersome. I sometimes cut and paste bugs caused by using really long names because it's hard to spot the differences between two really long names which are 80% the same filler text. (I'm using a static che

[PATCH 11/13] staging/rdma/hfi1: Remove unneeded variable index

2015-11-10 Thread Jubin John
From: Dean Luick The variable "index" increments the same as dd->ndevcntrs. Just use the later. Remove uneeded usage of "index" in the fill loop - it is not used there or later in the function. Reviewed-by: Dennis Dalessandro Signed-off-by: Dean Luick Signed-off-by: Jubin John --- drivers/s

[PATCH 13/13] staging/rdma/hfi1: Adjust EPROM partitions, add EPROM commands

2015-11-10 Thread Jubin John
From: Dean Luick Add a new EPROM partition, adjusting partition placement. Add EPROM range commands as a supserset of the partition commands. Remove old partition commands. Enhance EPROM erase, creating a range function and using the largest erase (sub) commands when possible. Reviewed-by: De

[PATCH 04/13] staging/rdma/hfi: Remove rcv bubbles code

2015-11-10 Thread Jubin John
From: Ira Weiny Rcv bubbles were improperly calculated for HFIs, fix that here. Reviewed-by: Mike Marciniszyn Reviewed-by: Arthur Kepner Signed-off-by: Ira Weiny Signed-off-by: Jubin John --- drivers/staging/rdma/hfi1/mad.c | 64 +- 1 files changed, 2 i

[PATCH 03/13] staging/rdma/hfi1: remove RxCtxRHQS from hfi1stats

2015-11-10 Thread Jubin John
From: Vennila Megavannan Removed the RxCtxRHQS counter being dumped into dev_cntrs Reviewed-by: Dennis Dalessandro Signed-off-by: Vennila Megavannan Signed-off-by: Jubin John --- drivers/staging/rdma/hfi1/chip.c |2 -- drivers/staging/rdma/hfi1/chip.h |1 - driver

[PATCH 07/13] staging/rdma/hfi1: rework is_a0() and is_bx()

2015-11-10 Thread Jubin John
From: Mike Marciniszyn The current is_bx() will incorrectly match on other steppings. is_a0() is removed in favor of is_ax(). Reviewed-by: Mark Debbage Signed-off-by: Mike Marciniszyn Signed-off-by: Jubin John --- drivers/staging/rdma/hfi1/chip.c | 46 ++---

[PATCH 12/13] staging/rdma/hfi1: Read EFI variable for device description

2015-11-10 Thread Jubin John
From: Dean Luick Read an EFI variable for the device description. Create the infrastructure for additional variable reads. Reviewed-by: Easwar Hariharan Signed-off-by: Dean Luick Signed-off-by: Jubin John --- drivers/staging/rdma/hfi1/Makefile |2 +- drivers/staging/rdma/hfi1/chip.c |

[PATCH 10/13] staging/rdma/hfi1: adding per SDMA engine stats to hfistats

2015-11-10 Thread Jubin John
From: Vennila Megavannan Added the following per sdma engine stats: - SendDmaDescFetchedCnt - software maintained count of SDMA interrupts (SDmaInt, SDmaIdleInt, SDmaProgressInt) - software maintained counts of SDMA error cases Reviewed-by: Dennis Dalessandro Signed-off-by: Mike

[PATCH 05/13] staging/rdma/hfi1: Add space between concatenated string elements

2015-11-10 Thread Jubin John
Space between concantenated string elements is more human readable and fixes the checkpatch issue: CHECK: Concatenated strings should use spaces between elements Reviewed-by: Mike Marciniszyn Signed-off-by: Jubin John --- drivers/staging/rdma/hfi1/chip.c | 10 +- drivers/staging/rdm

[PATCH 06/13] staging/rdma/hfi1: Move s_sde to the read mostly portion of the hfi1_qp structure

2015-11-10 Thread Jubin John
From: Harish Chegondi This would reduce L2 cache misses on s_sde in the _hfi1_schedule_send function when invoked from post_send thereby improving performance of post_send. Reviewed-by: Mike Marciniszyn Signed-off-by: Harish Chegondi Signed-off-by: Jubin John --- drivers/staging/rdma/hfi1/ve

[PATCH 08/13] staging/rdma/hfi1: change krcvqs module parameter type from byte to uint

2015-11-10 Thread Jubin John
From: Mark F. Brown The krcvqs parameter is displayed incorrectly in sysfs. The workaround is to set the param type as uint. Reviewed-by: Mike Marciniszyn Reviewed-by: Mitko Haralanov Signed-off-by: Mark F. Brown Signed-off-by: Jubin John --- drivers/staging/rdma/hfi1/hfi.h |2 +- driv

[PATCH 09/13] staging/rdma/hfi1: Change default krcvqs

2015-11-10 Thread Jubin John
Change the default number of krcvqs to number of numa nodes + 1 based on the performance data collected. Reviewed-by: Mike Marciniszyn Signed-off-by: Jubin John --- drivers/staging/rdma/hfi1/chip.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/staging/rdma/hf

[PATCH 02/13] staging/rdma/hfi1: Fix downgrade race

2015-11-10 Thread Jubin John
From: Dean Luick A link downgrade can race with link up. Avoid the race in two ways. First, by having the downgrade application logic take the link state mutex for all of its checking. Second, by waiting for the link to move out of the going up state. Reviewed-by: Dennis Dalessandro Signed-off-

[PATCH 01/13] staging/rdma/hfi1: Use BIT macro

2015-11-10 Thread Jubin John
This patch fixes the checkpatch issue: CHECK: Prefer using the BIT macro Reviewed-by: Dean Luick Reviewed-by: Ira Weiny Reviewed-by: Mike Marciniszyn Signed-off-by: Jubin John --- drivers/staging/rdma/hfi1/chip.h | 48 ++-- drivers/staging/rdma/hfi1/common.

Re: [PATCH] staging/rdma/hfi1: Reduce number of parameters passed to send handlers

2015-11-10 Thread Leon Romanovsky
On Wed, Nov 11, 2015 at 12:34:37AM -0500, ira.we...@intel.com wrote: > From: Dennis Dalessandro > > +int snoop_send_dma_handler(struct hfi1_qp *qp, struct hfi1_pkt_state *ps, > +u64 pbc) > { > - pr_alert("Snooping/Capture of Send DMA Packets Is Not Supported!\n"); >

Re: [PATCH v4 5/9] staging/rdma/hfi1: Add function stubs for TID caching

2015-11-10 Thread ira.weiny
> > > > Ok, patch 7-9 of this series do not depend on this patch nor number 6. I > > will > > resend those 3 while I figure out what to do about these 2: > > > > staging/rdma/hfi1: Add function stubs for TID caching > > staging/rdma/hfi1: Implement Expected Receive TID caching > > > > Frankly

Re: [BUG] IB/hfi1: might sleep under spinlock in hfi1_ioctl()

2015-11-10 Thread ira.weiny
On Fri, Oct 30, 2015 at 07:58:18PM -0400, ira. weiny wrote: > On Sat, Oct 31, 2015 at 12:32:29AM +0300, Alexey Khoroshilov wrote: > > Hello, > > > > hfi1_ioctl() contains many calls to might sleep functions with > > dd->hfi1_snoop.snoop_lock spinlock held (for example, access_ok, > > copy_from_use

[PATCH 2/8] staging/rdma/hfi1: Fix camel case variables

2015-11-10 Thread ira . weiny
From: Ira Weiny physState, linkState, and devState should be phys_state, link_state, and dev_state Signed-off-by: Dennis Dalessandro Signed-off-by: Ira Weiny --- drivers/staging/rdma/hfi1/diag.c | 24 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/dri

[PATCH 8/8] staging/rdma/hfi1: Return immediately on error

2015-11-10 Thread ira . weiny
From: Dennis Dalessandro Now that the spinlock is not taken throughout hfi1_ioctl it is safe to return early rather than setting a variable and falling through the switch. Reviewed-by: Mike Marciniszyn Signed-off-by: Dennis Dalessandro Signed-off-by: Ira Weiny --- drivers/staging/rdma/hfi1/d

[PATCH 0/8] Fix hfi1_ioctl locking

2015-11-10 Thread ira . weiny
From: Ira Weiny It was identified that hfi1_ioctl may sleep with a spin lock held. This was identified publicly here: http://www.spinics.net/lists/linux-rdma/msg29926.html As well as by our internal development. This series cleans up the code and parameter checks, as well as fixing the lockin

[PATCH 1/8] staging/rdma/hfi1: diag.c Correct code style issues

2015-11-10 Thread ira . weiny
From: Jubin John Using the latest checkpatch correct the checks on diag.c Reviewed-by: Dennis Dalessandro Reviewed-by: Mike Marciniszyn Signed-off-by: Jubin John Signed-off-by: Ira Weiny --- drivers/staging/rdma/hfi1/diag.c | 81 ++-- 1 file changed, 37 i

[PATCH 4/8] staging/rdma/hfi1: remove unneeded goto done

2015-11-10 Thread ira . weiny
From: Ira Weiny This goto done is followed by an if (ret) break in the outer switch clause. It is unnecessary. Signed-off-by: Dennis Dalessandro Signed-off-by: Ira Weiny --- drivers/staging/rdma/hfi1/diag.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/staging

[PATCH 5/8] staging/rdma/hfi1: return early if setlink state was specified

2015-11-10 Thread ira . weiny
From: Ira Weiny Set link state was not supported and so we can return early in the parameter checks rather than falling through the switch clause. Signed-off-by: Dennis Dalessandro Signed-off-by: Ira Weiny --- drivers/staging/rdma/hfi1/diag.c | 8 +++- 1 file changed, 3 insertions(+), 5 d

[PATCH 7/8] staging/rdma/hfi1: Reduce snoop locking scope in IOCTL handler.

2015-11-10 Thread ira . weiny
From: Dennis Dalessandro This patch avoids issues while calling into copy from/to user while holding the lock by only taking the lock when it is absolutely required. The only commands which require the snoop lock are: *Set Filter *Clear Filter *Clear Queue Reported-by: Alexey Khoroshilov Revie

[PATCH 3/8] staging/rdma/hfi1: Return early from hfi1_ioctl parameter errors

2015-11-10 Thread ira . weiny
From: Ira Weiny Rather than have a switch in a large else clause make the parameter checks return immediately. Signed-off-by: Dennis Dalessandro Signed-off-by: Ira Weiny --- drivers/staging/rdma/hfi1/diag.c | 348 +++ 1 file changed, 173 insertions(+), 175

[PATCH 6/8] staging/rdma/hfi1: Further clean up hfi1_ioctl parameter checks

2015-11-10 Thread ira . weiny
From: Ira Weiny Final clean up of the if/then/else clause for the parameter checks of hfi1_ioctl Signed-off-by: Dennis Dalessandro Signed-off-by: Ira Weiny --- drivers/staging/rdma/hfi1/diag.c | 26 +++--- 1 file changed, 15 insertions(+), 11 deletions(-) diff --git a/dri

[PATCH] staging/rdma/hfi1: Handle packets with invalid RHF on context 0

2015-11-10 Thread ira . weiny
From: Niranjana Vishwanathapura Context 0 (which handles the error packets) can potentially receive an invalid rhf. Hence, it can not depend on RHF sequence number and can only use DMA_RTAIL mechanism. Detect such packets with invalid rhf using rhf sequence counting mechanism and drop them. As D

[PATCH] staging/rdma/hfi1: Reduce number of parameters passed to send handlers

2015-11-10 Thread ira . weiny
From: Dennis Dalessandro The current send function handlers are passed a bunch of parameters that are already part of the data structure that is passed in first (qp). This patch removes all of this and just passes the QP. Reviewed-by: Mike Marciniszyn Signed-off-by: Dennis Dalessandro Signed-o

Re: [PATCH 01/20] staging/wilc1000: add struct net_device declaration

2015-11-10 Thread Greg Kroah-Hartman
On Wed, Nov 11, 2015 at 01:13:33AM +0100, Arnd Bergmann wrote: > On Tuesday 10 November 2015 16:02:48 Greg Kroah-Hartman wrote: > > On Wed, Nov 11, 2015 at 12:42:21AM +0100, Arnd Bergmann wrote: > > I think this is already fixed in my staging-testing branch, right? > > Ah right. I only got it with

[PATCH 09/11] Drivers: hv: vmbus: release relid on error in vmbus_process_offer()

2015-11-10 Thread K. Y. Srinivasan
From: Dexuan Cui We want to simplify vmbus_onoffer_rescind() by not invoking hv_process_channel_removal(NULL, ...). Signed-off-by: Dexuan Cui Signed-off-by: K. Y. Srinivasan --- drivers/hv/channel_mgmt.c | 21 +++-- 1 files changed, 15 insertions(+), 6 deletions(-) diff --g

[PATCH 06/11] Drivers: hv: vmbus: serialize process_chn_event() and vmbus_close_internal()

2015-11-10 Thread K. Y. Srinivasan
From: Dexuan Cui process_chn_event(), running in the tasklet, can race with vmbus_close_internal() in the case of SMP guest, e.g., when the former is accessing channel->inbound.ring_buffer, the latter could be freeing the ring_buffer pages. To resolve the race, we can serialize them by disabling

[PATCH 01/11] Drivers: hv: vss: run only on supported host versions

2015-11-10 Thread K. Y. Srinivasan
From: Olaf Hering The Backup integration service on WS2012 has appearently trouble to negotiate with a guest which does not support the provided util version. Currently the VSS driver supports only version 5/0. A WS2012 offers only version 1/x and 3/x, and vmbus_prep_negotiate_resp correctly retu

[PATCH 07/11] Drivers: hv: vmbus: do sanity check of channel state in vmbus_close_internal()

2015-11-10 Thread K. Y. Srinivasan
From: Dexuan Cui This fixes an incorrect assumption of channel state in the function. Signed-off-by: Dexuan Cui Signed-off-by: K. Y. Srinivasan --- drivers/hv/channel.c | 12 1 files changed, 12 insertions(+), 0 deletions(-) diff --git a/drivers/hv/channel.c b/drivers/hv/chann

[PATCH 02/11] Drivers: hv: vmbus: Use uuid_le type consistently

2015-11-10 Thread K. Y. Srinivasan
Consistently use uuid_le type in the Hyper-V driver code. Signed-off-by: K. Y. Srinivasan --- drivers/hv/channel_mgmt.c |2 +- drivers/hv/vmbus_drv.c | 10 ++-- include/linux/hyperv.h | 92 +- include/linux/mod_devicetable.h |

[PATCH 10/11] Drivers: hv: vmbus: channge vmbus_connection.channel_lock to mutex

2015-11-10 Thread K. Y. Srinivasan
From: Dexuan Cui spinlock is unnecessary here. mutex is enough. Signed-off-by: Dexuan Cui Signed-off-by: K. Y. Srinivasan --- drivers/hv/channel_mgmt.c | 12 ++-- drivers/hv/connection.c |7 +++ drivers/hv/hyperv_vmbus.h |2 +- 3 files changed, 10 insertions(+), 11 del

[PATCH 08/11] Drivers: hv: vmbus: fix rescind-offer handling for device without a driver

2015-11-10 Thread K. Y. Srinivasan
From: Dexuan Cui In the path vmbus_onoffer_rescind() -> vmbus_device_unregister() -> device_unregister() -> ... -> __device_release_driver(), we can see for a device without a driver loaded: dev->driver is NULL, so dev->bus->remove(dev), namely vmbus_remove(), isn't invoked. As a result, vmbus_

[PATCH 05/11] Drivers: hv: vmbus: Get rid of the unused irq variable

2015-11-10 Thread K. Y. Srinivasan
The irq we extract from ACPI is not used - we deliver hypervisor interrupts on a special vector. Make the necessary adjustments. Signed-off-by: K. Y. Srinivasan --- drivers/hv/vmbus_drv.c | 16 +++- 1 files changed, 3 insertions(+), 13 deletions(-) diff --git a/drivers/hv/vmbus_dr

[PATCH 04/11] Drivers: hv: vmbus: Get rid of the unused macro

2015-11-10 Thread K. Y. Srinivasan
The macro VMBUS_DEVICE() is unused; get rid of it. Signed-off-by: K. Y. Srinivasan --- include/linux/hyperv.h | 13 - 1 files changed, 0 insertions(+), 13 deletions(-) diff --git a/include/linux/hyperv.h b/include/linux/hyperv.h index ee243a7..437c9c8 100644 --- a/include/linux/hy

[PATCH 11/11] drivers:hv: Allow for MMIO claims that span ACPI _CRS records

2015-11-10 Thread K. Y. Srinivasan
From: Jake Oshins This patch makes 16GB GPUs work in Hyper-V VMs, since, for compatibility reasons, the Hyper-V BIOS lists MMIO ranges in 2GB chunks in its root bus's _CRS object. Signed-off-by: Jake Oshins Signed-off-by: K. Y. Srinivasan --- drivers/hv/vmbus_drv.c | 16 1

[PATCH 03/11] Drivers: hv: vmbus: Use the macro for comparing GUIDs

2015-11-10 Thread K. Y. Srinivasan
Use the uuid_le_cmp() macro for comparing GUIDs. Signed-off-by: K. Y. Srinivasan --- drivers/hv/channel_mgmt.c |3 +-- drivers/hv/vmbus_drv.c|4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index 38470aa..dc

[PATCH 00/11] Drivers: hv: vmbus: Miscellaneous fixes and cleanup

2015-11-10 Thread K. Y. Srinivasan
Miscellaneous fixes and cleanup. Dexuan Cui (5): Drivers: hv: vmbus: serialize process_chn_event() and vmbus_close_internal() Drivers: hv: vmbus: do sanity check of channel state in vmbus_close_internal() Drivers: hv: vmbus: fix rescind-offer handling for device without a driver

Re: [PATCH 01/20] staging/wilc1000: add struct net_device declaration

2015-11-10 Thread Arnd Bergmann
On Tuesday 10 November 2015 16:02:48 Greg Kroah-Hartman wrote: > On Wed, Nov 11, 2015 at 12:42:21AM +0100, Arnd Bergmann wrote: > I think this is already fixed in my staging-testing branch, right? Ah right. I only got it with some rare randconfig builds, and assumed the problem was still there bec

Re: [PATCH 01/20] staging/wilc1000: add struct net_device declaration

2015-11-10 Thread Greg Kroah-Hartman
On Wed, Nov 11, 2015 at 12:42:21AM +0100, Arnd Bergmann wrote: > A recent cleanup added a reference to struct net_device, but > that structure is not always visible in the context of the > declaration, so we may get a compile-time error: > > In file included from wilc1000/host_interface.c:5:0: > w

Re: [PATCH 01/20] staging/wilc1000: add struct net_device declaration

2015-11-10 Thread Arnd Bergmann
On Tuesday 10 November 2015 15:47:02 Joe Perches wrote: > On Wed, 2015-11-11 at 00:42 +0100, Arnd Bergmann wrote: > > A recent cleanup added a reference to struct net_device, but > > that structure is not always visible in the context of the > > declaration, so we may get a compile-time error: > >

Re: [PATCH v2] staging/rdma/hfi1: set Gen3 half-swing for integrated devices

2015-11-10 Thread ira.weiny
On Tue, Nov 10, 2015 at 12:59:29PM +0300, Dan Carpenter wrote: > Gar... No. Please please get rid of the PC() macro. It makes the code > impossible to understand because instead of hitting CTRL-[ you have > decode it and then manually type out > > :cs find g CCE_PCIE_CTRL_XMT_MARGIN_GEN1_GEN2_O

[PATCH 04/20] staging/wilc1000: use proper naming for global symbols

2015-11-10 Thread Arnd Bergmann
There are many global symbols in the wilc1000 driver, some of them with names like "DEBUG_LEVEL" or "probe" that are not acceptable for globals in the linux kernel as they may easily conflict with other (equally broken) drivers. This renames all the globals that do not already start with wilc or a

[PATCH 20/20] staging/wilc1000: pass struct wilc to most linux_wlan.c functions

2015-11-10 Thread Arnd Bergmann
We want to get rid of all global variables in this driver, and instead pass device structures from one function to another. This changes the linux_wlan.c and wilc_wlan.c to do this for the most part. There are a few exceptions where these functions are themselves called from another part of the dri

[PATCH 15/20] staging/wilc1000: pass hif operations through initialization

2015-11-10 Thread Arnd Bergmann
The wilc_hif_spi and wilc_hif_sdio structures are part of the bus specific code, and the generic code should have no knowledge of their addresses. This changes the code to reference them only from the bus specific initialization code, which we can then use to split up the driver into separate modu

[PATCH 16/20] staging/wilc1000: turn enable_irq/disable_irq into callbacks

2015-11-10 Thread Arnd Bergmann
As a preparation for turning the SDIO side of wilc1000 into a separate module, this removes the last direct caller from the core module into the sdio specific portion. All calls to wilc_sdio_enable_interrupt() and wilc_sdio_disable_interrupt() now go through a function pointer in wilc_hif_func. We

[PATCH 18/20] staging/wilc1000: split out bus specific modules

2015-11-10 Thread Arnd Bergmann
The SPI and SDIO specific code is now separate enough that we just need to restructure the Makefile and Kconfig logic a bit and export a couple of symbols from the common module to have separate bus glue drivers. Signed-off-by: Arnd Bergmann --- drivers/staging/wilc1000/Kconfig| 66 +

[PATCH 11/20] staging/wilc1000: unify device pointer

2015-11-10 Thread Arnd Bergmann
struct wilc has two pointers to store the device, one for sdio_func and one for spi_device. By changing the pointer to a 'struct device', we can simplify the logic and avoid a few #ifdefs. Signed-off-by: Arnd Bergmann --- drivers/staging/wilc1000/linux_wlan.c | 25 +++- d

[PATCH 17/20] staging/wilc1000: remove WILC_SDIO/WILC_SPI macros

2015-11-10 Thread Arnd Bergmann
The last remaining user of WILC_SDIO macro checks for the correct time to wait in an interrupt for the PLL to settle. We can replace this with a runtime check and remove both WILC_SDIO and WILC_SPI, as we no longer need conditional compilation based on the hardware type. Signed-off-by: Arnd Bergma

[PATCH 19/20] staging/wilc1000: use more regular probing

2015-11-10 Thread Arnd Bergmann
So far, my patches tried to do equivalent conversions of the existing code. This one goes beyond that by restructuring how the devices get probed. In particular, the spi driver no longer creates the netdev until the device is probed, and I've removed the global wilc_sdio_func and wilc_spi_dev vari

[PATCH 13/20] staging/wilc1000: use device pointer for phy creation

2015-11-10 Thread Arnd Bergmann
wilc_create_wiphy tries to get a pointer to a device from the global wilc_sdio_func variable. This is a layering violation and we can use the wilc_dev->dev pointer instead. Signed-off-by: Arnd Bergmann --- drivers/staging/wilc1000/linux_wlan.c | 2 +- drivers/staging/wilc1000/linux_w

[PATCH 12/20] staging/wilc1000: pass io_type to wilc_netdev_init

2015-11-10 Thread Arnd Bergmann
In order to avoid some of the #ifdefs, this passes the io_type and device pointer as an argument to wilc_netdev_init. Signed-off-by: Arnd Bergmann --- drivers/staging/wilc1000/linux_wlan.c | 18 -- drivers/staging/wilc1000/linux_wlan_sdio.c| 4 ++-- drivers/staging/w

[PATCH 14/20] staging/wilc1000: get rid of WILC_SDIO_IRQ_GPIO

2015-11-10 Thread Arnd Bergmann
Whether the SDIO function uses an internal or external interrupt should not be a compiletime decision but be determined at runtime. This changes the code to pass a GPIO number from the init code as early as possible, and leaves just one #ifdef WILC_SDIO_IRQ_GPIO to preserve the previous behavior.

[PATCH 10/20] staging/wilc1000: move init/exit functions to driver files

2015-11-10 Thread Arnd Bergmann
The driver interfaces are in linux_wlan_sdio.c and linux_wlan_spi.c, so this is where the init and exit functions should be. Splitting this up enables further cleanups, including eventually allowing both modules to be built together. Signed-off-by: Arnd Bergmann --- drivers/staging/wilc1000/linu

[PATCH 09/20] staging/wilc1000: move wilc_wlan_inp_t into struct wilc

2015-11-10 Thread Arnd Bergmann
wilc_wlan_inp_t is an unnecessary indirection and requires linux_wlan.c to have knowledge of the specific sdio and spi front-ends. This removes the structure and places io_type directly inside the struct wilc. Signed-off-by: Arnd Bergmann --- drivers/staging/wilc1000/linux_wlan.c | 21 ++

[PATCH 03/20] staging/wilc1000: make symbols static if possible

2015-11-10 Thread Arnd Bergmann
All symbols that are only referenced in the file that defines them can be declared 'static' to avoid namespace pollution, to produce better object code, and to make the source more readable. Signed-off-by: Arnd Bergmann --- drivers/staging/wilc1000/Makefile | 3 +- drivers/stagi

[PATCH 08/20] staging/wilc1000: remove linux_wlan_{device_power, device_detection}

2015-11-10 Thread Arnd Bergmann
The driver provides an interface for custom power management and detection that is meant to be filled by people customizing the driver. The default implementation of this is empty, and we don't actually want people to have to modify the source code. If anybody needs this, they need to describe the

[PATCH 05/20] staging/wilc1000: move extern declarations to headers

2015-11-10 Thread Arnd Bergmann
'extern' declarations belong into a header file rather than a .c file, to ensure that the definition matches the declaration. This moves all declarations into a header file that seems most appropriate for it. Signed-off-by: Arnd Bergmann --- drivers/staging/wilc1000/host_interface.c |

[PATCH 06/20] staging/wilc1000: use NO_SECURITY instead of NO_ENCRYPT

2015-11-10 Thread Arnd Bergmann
The linux_wlan.c file uses a set of enums from wilc_wlan_if.h, with the exception of the NO_ENCRYPT that comes from wilc_wfi_cfgoperations.h. The two sets of enums clearly have the same intention but are defined a bit different. To prepare to clean up the ones in wilc_wfi_cfgoperations.h, this fir

[PATCH 07/20] staging/wilc1000: avoid static definitions in header

2015-11-10 Thread Arnd Bergmann
The wilc_wfi_cfgoperations.h header defines the ieee80211_txrx_stypes and cipher_suites variables that are only used in wilc_wfi_cfgoperations.c and should not be shared in a header file. This moves over all that data into the .c file, and also moves all the macro definitions from the file that ar

[PATCH 00/20] staging/wilc1000: cleanups once again

2015-11-10 Thread Arnd Bergmann
I have rebased the patches once more on top of a lot of renames, and would prefer not to rebase them again. This is the series of fixups that I've posted before, now for today's staging-testing branch. Please apply. Arnd Bergmann (20): staging/wilc1000: add struct net_device declaration stagi

[PATCH 02/20] staging/wilc1000: remove unused functions

2015-11-10 Thread Arnd Bergmann
A number of symbols in the wilc1000 driver are completely unused and can be removed. This includes two variables that are only written but not read. Signed-off-by: Arnd Bergmann --- drivers/staging/wilc1000/host_interface.c | 295 -- drivers/staging/wilc1000/host_inte

[PATCH 01/20] staging/wilc1000: add struct net_device declaration

2015-11-10 Thread Arnd Bergmann
A recent cleanup added a reference to struct net_device, but that structure is not always visible in the context of the declaration, so we may get a compile-time error: In file included from wilc1000/host_interface.c:5:0: wilc1000/host_interface.h:705:46: warning: 'struct net_device' declared insi

[PATCH] Staging: panel: Fixed a spacing after cast coding style issue

2015-11-10 Thread Daniel H. Hemmingsen
Fixed a spacing after cast coding style issue. Signed-off-by: Daniel H. Hemmingsen --- drivers/staging/panel/panel.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/panel/panel.c b/drivers/staging/panel/panel.c index 79ac192..96920ef 100644 --- a/drivers/stagi

[PATCH] realtek: rtlwifi: rtl8821ae: Fix lockups on boot

2015-11-10 Thread Larry Finger
In commit 54328e64047a5 ("rtlwifi: rtl8821ae: Fix system lockups on boot"), an attempt was made to fix a regression introduced in commit 1277fa2ab2f9 ("rtlwifi: Remove the clear interrupt routine from all drivers"). Unfortunately, there were logic errors in that patch that prevented affected boxes

[PATCH v2] staging: comedi: use kmalloc_array instead of kmalloc

2015-11-10 Thread Geliang Tang
Use kmalloc_array instead of kmalloc to allocate memory for an array. Signed-off-by: Geliang Tang --- Changes in v2: - preserve the existing whitespace style. --- drivers/staging/comedi/drivers/amplc_pci224.c | 11 +++ drivers/staging/comedi/drivers/ni_670x.c | 5 +++-- 2 files c

[PATCH 2/2] staging/rdma/hfi1: add ACK coalescing logic

2015-11-10 Thread Mike Marciniszyn
Implement ACK coalesing logic using a 8 bit counter. The algorithm is send pio ack when: - fecn present - this is the first packet in an interrupt session - counter is >= HFI1_PSN_CREDIT Otherwise the ack is defered. Reviewed-by: Dennis Dalessandro Signed-off-by: Mike Marciniszyn --- drivers/

[PATCH 1/2] staging/rdma/hfi1: add common routine for queuing acks

2015-11-10 Thread Mike Marciniszyn
This patch is a prelimary patch required to coalesce acks. The routine to "schedule" a QP for sending a NAK is now centralized in rc_defer_ack(). The flag is changed for clarity since the all acks will potentially use the deferral mechanism. Reviewed-by: Dennis Dalessandro Signed-off-by: Mike

Re: [PATCH] staging: board: Set PM domain before probe

2015-11-10 Thread Geert Uytterhoeven
Hi Tomeu, On Tue, Oct 27, 2015 at 3:55 PM, Geert Uytterhoeven wrote: > On Tue, Oct 27, 2015 at 3:27 PM, Tomeu Vizoso > wrote: >> PM domains shouldn't be modified after a device is probed, so set it >> before device registration to be sure of that. >> >> In the future the PM domain pointer will b

Re: [PATCH v2] staging/rdma/hfi1: set Gen3 half-swing for integrated devices

2015-11-10 Thread Dan Carpenter
Gar... No. Please please get rid of the PC() macro. It makes the code impossible to understand because instead of hitting CTRL-[ you have decode it and then manually type out :cs find g CCE_PCIE_CTRL_XMT_MARGIN_GEN1_GEN2_OVERWRITE_ENABLE_SHIFT which is the length of a typical college essay. I

Re: [PATCH 02/12] staging: rtl8188eu: return value and argument types changed in _rtl88e_write_fw function

2015-11-10 Thread Ivan Safonov
On 11/09/2015 03:24 AM, Andy Shevchenko wrote: On Sun, Nov 8, 2015 at 1:26 PM, Ivan Safonov wrote: On 11/08/2015 05:11 PM, Andy Shevchenko wrote: On Sun, Nov 8, 2015 at 8:37 AM, Ivan Safonov wrote: Ideally the function should not change the variables outside of its body. -static void _rtl88e

Re: [PATCH v2 01/12] staging: rtl8188eu: if/else replaced by min_t

2015-11-10 Thread Ivan Safonov
On 11/09/2015 12:10 AM, Greg Kroah-Hartman wrote: On Sun, Nov 08, 2015 at 02:07:11PM +0700, Ivan Safonov wrote: Duplicated code removed. Signed-off-by: Ivan Safonov --- drivers/staging/rtl8188eu/core/rtw_cmd.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) You sent 3 versions