Re: [PATCH v2] staging: bcm2835-audio: Disconnect and free vchi_instance on module_exit()

2018-04-25 Thread Dan Carpenter
Greg deleted your patch already... regards, dan carpenter ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

Re: [PATCH v3 1/3] resource: Use list_head to link sibling resource

2018-04-25 Thread kbuild test robot
Hi Baoquan, I love your patch! Yet something to improve: [auto build test ERROR on linus/master] [also build test ERROR on v4.17-rc2 next-20180424] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url:

Re: [PATCH v3 1/3] resource: Use list_head to link sibling resource

2018-04-25 Thread kbuild test robot
Hi Baoquan, I love your patch! Yet something to improve: [auto build test ERROR on linus/master] [also build test ERROR on v4.17-rc2 next-20180424] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url:

Re: [PATCH] staging: fsl-dpaa2/eth: Add support for hardware timestamping

2018-04-25 Thread Richard Cochran
On Wed, Apr 25, 2018 at 05:17:49PM +0800, Yangbo Lu wrote: > +/* PTP nominal frequency 1GHz */ > +#define DPAA2_PTP_NOMINAL_FREQ_PERIOD_NS 1 Nit: Frequency is the inverse of the period. It can be one or the other, not both. Why not call it simply DPAA2_PTP_CLK_PERIOD_NS? You haven't

Re: [PATCH 06/40] proc: introduce proc_create_single{,_data}

2018-04-25 Thread Finn Thain
On Wed, 25 Apr 2018, Christoph Hellwig wrote: > > -/* > - * /proc/nubus stuff > - */ > - I don't think that the introduction of proc_create_single{,_data} alters the value of that comment. That comment and similar comments in the same file do have a purpose, which is to keep separate the

Re: [PATCH v3 1/3] resource: Use list_head to link sibling resource

2018-04-25 Thread Wei Yang
On Thu, Apr 19, 2018 at 08:18:46AM +0800, Baoquan He wrote: >The struct resource uses singly linked list to link siblings. It's not >easy to do reverse iteration on sibling list. So replace it with list_head. > Hi, Baoquan Besides changing the data structure, I have another proposal to do the

Re: simplify procfs code for seq_file instances

2018-04-25 Thread Alexey Dobriyan
On Tue, Apr 24, 2018 at 06:06:53PM +0200, Christoph Hellwig wrote: > On Tue, Apr 24, 2018 at 08:19:16AM -0700, Andrew Morton wrote: > > > > I want to ask if it is time to start using poorman function overloading > > > > with _b_c_e(). There are millions of allocation functions for example, > > > >

Re: [PATCH 27/40] rtc/proc: switch to proc_create_single_data

2018-04-25 Thread Alexandre Belloni
On 25/04/2018 17:48:14+0200, Christoph Hellwig wrote: > And stop trying to get a reference on the submodule, procfs code deals > with release after and unloaded module and thus removed proc entry. small typo here^ > > Signed-off-by: Christoph Hellwig Acked-by: Alexandre

[PATCH 3/5] X86: Hyper-V: Enhanced IPI enlightenment

2018-04-25 Thread kys
From: "K. Y. Srinivasan" Support enhanced IPI enlightenments (to target more than 64 CPUs). Signed-off-by: K. Y. Srinivasan --- arch/x86/hyperv/hv_apic.c | 49 -- arch/x86/include/asm/hyperv-tlfs.h | 1 +

[PATCH 0/5] X86: Hyper-V: APIC enlightenments

2018-04-25 Thread kys
From: "K. Y. Srinivasan" Implement APIC related enlightenments. K. Y. Srinivasan (5): X86: Hyper-V: Enlighten APIC access X86: Hyper-V: Enable IPI enlightenments X86: Hyper-V: Enhanced IPI enlightenment X86: Hyper-V: Consolidate code for converting cpumask to vpset

[PATCH 4/5] X86: Hyper-V: Consolidate code for converting cpumask to vpset

2018-04-25 Thread kys
From: "K. Y. Srinivasan" Consolidate code for converting cpumask to vpset. Signed-off-by: K. Y. Srinivasan --- arch/x86/hyperv/hv_apic.c | 2 +- arch/x86/hyperv/mmu.c | 45 +++---

[PATCH 2/5] X86: Hyper-V: Enable IPI enlightenments

2018-04-25 Thread kys
From: "K. Y. Srinivasan" Hyper-V supports hypercalls to implement IPI; use them. Signed-off-by: K. Y. Srinivasan --- arch/x86/hyperv/hv_apic.c | 125 + arch/x86/hyperv/hv_init.c | 17 +

[PATCH 1/5] X86: Hyper-V: Enlighten APIC access

2018-04-25 Thread kys
From: "K. Y. Srinivasan" Hyper-V supports MSR based APIC access; implement the enlightenment. Signed-off-by: K. Y. Srinivasan --- arch/x86/hyperv/Makefile| 2 +- arch/x86/hyperv/hv_apic.c | 98 +

Re: [PATCH v3 2/5] efi: Add embedded peripheral firmware support

2018-04-25 Thread Luis R. Rodriguez
On Wed, Apr 25, 2018 at 01:00:09AM -0400, Mimi Zohar wrote: > On Tue, 2018-04-24 at 23:42 +, Luis R. Rodriguez wrote: > > On Tue, Apr 24, 2018 at 12:07:01PM -0400, Mimi Zohar wrote: > > > On Tue, 2018-04-24 at 17:09 +0200, Hans de Goede wrote: > > > > On 23-04-18 23:11, Luis R. Rodriguez

[PATCH v2 20/21] staging: wilc1000: change function to static in linux_wlan

2018-04-25 Thread Ajay Singh
Defined function as static which are used only in single file. And also removed their declaration from header file. Below function are changed to static wilc_wlan_initialize() wilc_wlan_deinitialize() wilc_wlan_get_firmware() Signed-off-by: Ajay Singh ---

[PATCH v2 16/21] staging: wilc1000: remove unused elements in 'wilc_priv' struct

2018-04-25 Thread Ajay Singh
Cleanup patch to remove unused element from 'wilc_priv' structure. Below elements are removed in 'wilc_priv' structure: struct WILC_WFI_packet *ppool; struct WILC_WFI_packet *rx_queue; /* List of incoming packets */ int rx_int_enabled; int tx_packetlen; u8 *tx_packetdata; struct napi_struct

[PATCH v2 21/21] staging: wilc1000: reorder functions to avoid forward declaration in linux_wlan

2018-04-25 Thread Ajay Singh
Reorder the functions in linux_wlan.c file to avoid having explicit declaration of static functions. Forward declaration is avoided with the help of reordering the function. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/linux_wlan.c | 106

[PATCH v2 19/21] staging: wilc1000: remove inner block '{}' in handle_remain_on_chan()

2018-04-25 Thread Ajay Singh
Cleanup patch to remove unnecessary inner block {\* *\} in handle_remain_on_chan(). Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/host_interface.c | 19 --- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git

[PATCH v2 18/21] staging: wilc1000: rename P2P_LISTEN_STATE variable to use lowercase

2018-04-25 Thread Ajay Singh
Rename P2P_LISTEN_STATE variable to avoid using uppercase for variable name to follow linux coding style. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/host_interface.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git

[PATCH v2 12/21] staging: wilc1000: rename mac status macros and moved related #define together

2018-04-25 Thread Ajay Singh
Rename the mac status macro to follow the same naming style. Also move them to keep together. Renamed like below >From > To WILC_MAC_STATUS_INIT -> MAC_STATUS_INIT MAC_CONNECTED > MAC_STATUS_CONNECTED MAC_DISCONNECTED -> MAC_STATUS_DISCONNECTED

[PATCH v2 17/21] staging: wilc1000: remove unused enum 'stats_flags'

2018-04-25 Thread Ajay Singh
Cleanup patch to remove the unused enum. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_wfi_netdevice.h | 5 - 1 file changed, 5 deletions(-) diff --git a/drivers/staging/wilc1000/wilc_wfi_netdevice.h b/drivers/staging/wilc1000/wilc_wfi_netdevice.h

[PATCH v2 15/21] staging: wilc1000: rename wlan init and deinit function prefixed with wil1000

2018-04-25 Thread Ajay Singh
Rename wilc1000_wlan_init() & wilc1000_wlan_deinit() function to avoid unecessary 'wilc1000' prefix in function to be inline with other function naming convension. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/linux_wlan.c | 10 +-

[PATCH v2 13/21] staging: wilc1000: rename WILC_WFI_stats to avoid uppercase

2018-04-25 Thread Ajay Singh
Cleanup patch to have struct name as per linux coding style. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_wfi_netdevice.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/wilc1000/wilc_wfi_netdevice.h

[PATCH v2 14/21] staging: wilc1000: rename num_reg_frame macro to have uppercase in macro name

2018-04-25 Thread Ajay Singh
Cleanup patch to follow name as per linux coding style. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_wfi_netdevice.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/wilc1000/wilc_wfi_netdevice.h

[PATCH v2 10/21] staging: wilc1000: remove used #define HIF_SDIO_GPIO_IRQ

2018-04-25 Thread Ajay Singh
Cleanup patch to remove unused #define. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_wlan_if.h | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/staging/wilc1000/wilc_wlan_if.h b/drivers/staging/wilc1000/wilc_wlan_if.h index eb8d819..e8a56f4

[PATCH v2 08/21] staging: wilc1000: remove unused variable scan_while_connected

2018-04-25 Thread Ajay Singh
Cleanup patch to remove the unused variable. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/host_interface.c | 17 - 1 file changed, 17 deletions(-) diff --git a/drivers/staging/wilc1000/host_interface.c

[PATCH v2 03/21] staging: wilc1000: remove unnecessary assingment from 'if' conditions

2018-04-25 Thread Ajay Singh
Cleanup patch to remove the unnecessary use of '==' check used in if conditions. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_sdio.c | 12 ++-- drivers/staging/wilc1000/wilc_spi.c | 6 +++--- 2 files changed, 9 insertions(+), 9 deletions(-)

[PATCH v2 00/21] staging: wilc1000: remove unused code and reorder functions

2018-04-25 Thread Ajay Singh
This patch series contains fixes to remove the unused code. It also has patches to reorganize the function and simplify the function logic. Ajay Singh (21): staging: wilc1000: replace crc7_byte() with inline macro CRC7_BYTE staging: wilc1000: align the #define in wilc_spi file staging:

[PATCH v2 11/21] staging: wilc1000: remove unused #define related to MAC status

2018-04-25 Thread Ajay Singh
Remove below #define which are not used in code: WILC_MAC_STATUS_READY WILC_MAC_STATUS_CONNECT Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_wlan_if.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/staging/wilc1000/wilc_wlan_if.h

[PATCH v2 02/21] staging: wilc1000: align the #define in wilc_spi file

2018-04-25 Thread Ajay Singh
Cleanup patch to align the #define used in wilc_spi.c file by adding the tabs. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_spi.c | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git

[PATCH v2 04/21] staging: wilc1000: remove 'cmd' variable in wilc_spi functions

2018-04-25 Thread Ajay Singh
Cleanup patch to remove the 'cmd' variable in wilc_spi.c. Instead of using cmd now passing the command directly. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_spi.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git

[PATCH v2 09/21] staging: wilc1000: remove unsed typedef wilc_debug_func

2018-04-25 Thread Ajay Singh
Cleanup patch to remove the unused typedef and also removed the unecessary comment about that typedef. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_wlan.h | 7 --- 1 file changed, 7 deletions(-) diff --git a/drivers/staging/wilc1000/wilc_wlan.h

[PATCH v2 06/21] staging: wilc1000: remove inner {} in wilc_parse_network_info()

2018-04-25 Thread Ajay Singh
Cleanup patch to remove the unnecessary {/**/} block in wilc_parse_network_info(). Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/coreconfigurator.c | 77 ++--- 1 file changed, 37 insertions(+), 40 deletions(-) diff --git

[PATCH v2 07/21] staging: wilc1000: simplified if conditions in spi_data_write()

2018-04-25 Thread Ajay Singh
Cleanup patch to simplify the if conditions logic in spi_data_write(). Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_spi.c | 23 +-- 1 file changed, 9 insertions(+), 14 deletions(-) diff --git a/drivers/staging/wilc1000/wilc_spi.c

[PATCH v2 05/21] staging: wicl1000: removed the unsed variables in wilc_parse_network_info()

2018-04-25 Thread Ajay Singh
Cleanup patch to remove the unused variables in wilc_parse_network_info(). The value is assinged to these local variables but assinged value is not used in that function. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/coreconfigurator.c | 7 --- 1 file

[PATCH v2 01/21] staging: wilc1000: replace crc7_byte() with inline macro CRC7_BYTE

2018-04-25 Thread Ajay Singh
Replace the function call for crc7_byte() with macro CRC7_BYTE. crc7_byte() was called in close while(), so replaced it with macro to avoid extra functional call depth. Signed-off-by: Ajay Singh --- drivers/staging/wilc1000/wilc_spi.c | 7 ++- 1 file changed, 2

Re: [PATCH] staging: ks7010: fix ks_wlan_start_xmit()'s return type

2018-04-25 Thread Janusz Lisiecki
W dniu 2018-04-24 o 15:18, Luc Van Oostenryck pisze: The method ndo_start_xmit() is defined as returning an 'netdev_tx_t', which is a typedef for an enum type, but the implementation in this driver returns an 'int'. Fix this by returning 'netdev_tx_t' in this driver too. Signed-off-by: Luc Van

Re: [PATCH] staging: ks7010: fix ks_wlan_start_xmit()'s return type

2018-04-25 Thread Janusz Lisiecki
W dniu 2018-04-24 o 15:18, Luc Van Oostenryck pisze: The method ndo_start_xmit() is defined as returning an 'netdev_tx_t', which is a typedef for an enum type, but the implementation in this driver returns an 'int'. Fix this by returning 'netdev_tx_t' in this driver too. Signed-off-by: Luc Van

Re: [PATCH] staging/wilc1000: fix wilc_mac_xmit()'s return type

2018-04-25 Thread Claudiu Beznea
Hi Luc, I'm resending this since last time I only send it to staging ml. Could you, please, change the "return 0;"s inside wilc_mac_xmit() with "return NETDEV_TX_OK" ? Thank you, Claudiu On 24.04.2018 15:18, Luc Van Oostenryck wrote: > The method ndo_start_xmit() is defined as returning an

Re: [PATCH] ion: Consider ion pool pages as indirectly reclaimable

2018-04-25 Thread Laura Abbott
On 04/24/2018 08:43 PM, vji...@codeaurora.org wrote: From: Vijayanand Jitta An issue is observed where mallocs are failing due to overcommit failure. The failure happens when there is high ION page pool since ION page pool is not considered reclaimable by the overcommit

[PATCH 38/40] ide: remove ide_driver_proc_write

2018-04-25 Thread Christoph Hellwig
The driver proc file hasn't been writeable for a long time, so this is just dead code. Signed-off-by: Christoph Hellwig --- drivers/ide/ide-proc.c | 46 -- 1 file changed, 46 deletions(-) diff --git a/drivers/ide/ide-proc.c

[PATCH 39/40] ide: replace ->proc_fops with ->proc_show

2018-04-25 Thread Christoph Hellwig
Just set up the show callback in the tty_operations, and use proc_create_single_data to create the file without additional boilerplace code. Signed-off-by: Christoph Hellwig --- drivers/ide/ide-cd.c | 15 +--- drivers/ide/ide-disk_proc.c | 62 ++--

[PATCH 36/40] isdn: replace ->proc_fops with ->proc_show

2018-04-25 Thread Christoph Hellwig
And switch to proc_create_single_data. Signed-off-by: Christoph Hellwig --- drivers/isdn/capi/kcapi.c | 3 ++- drivers/isdn/gigaset/capi.c| 16 +--- drivers/isdn/hardware/avm/avmcard.h| 4 ++-- drivers/isdn/hardware/avm/b1.c | 17

[PATCH 33/40] bluetooth: switch to proc_create_seq_data

2018-04-25 Thread Christoph Hellwig
And use proc private data directly instead of doing a detour through seq->private and private state. Signed-off-by: Christoph Hellwig --- net/bluetooth/af_bluetooth.c | 40 +--- 1 file changed, 5 insertions(+), 35 deletions(-) diff --git

[PATCH 40/40] tty: replace ->proc_fops with ->proc_show

2018-04-25 Thread Christoph Hellwig
Just set up the show callback in the tty_operations, and use proc_create_single_data to create the file without additional boilerplace code. Signed-off-by: Christoph Hellwig --- arch/ia64/hp/sim/simserial.c| 15 +-- arch/xtensa/platforms/iss/console.c | 15

[PATCH 37/40] proc: don't detour through seq->private to get the inode

2018-04-25 Thread Christoph Hellwig
Signed-off-by: Christoph Hellwig --- fs/proc/array.c | 18 -- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/fs/proc/array.c b/fs/proc/array.c index ae2c807fd719..b34796b562ef 100644 --- a/fs/proc/array.c +++ b/fs/proc/array.c @@ -677,7 +677,7 @@

[PATCH 35/40] atm: switch to proc_create_seq_private

2018-04-25 Thread Christoph Hellwig
And remove proc boilerplate code. Signed-off-by: Christoph Hellwig --- net/atm/proc.c | 72 +- 1 file changed, 13 insertions(+), 59 deletions(-) diff --git a/net/atm/proc.c b/net/atm/proc.c index f272b0f59d82..0b0495a41bbe 100644 ---

[PATCH 31/40] netfilter/xt_hashlimit: switch to proc_create_{seq, single}_data

2018-04-25 Thread Christoph Hellwig
And use proc private data directly instead of doing a detour through seq->private. Signed-off-by: Christoph Hellwig --- net/netfilter/xt_hashlimit.c | 92 +++- 1 file changed, 18 insertions(+), 74 deletions(-) diff --git

[PATCH 32/40] netfilter/x_tables: switch to proc_create_seq_private

2018-04-25 Thread Christoph Hellwig
And remove proc boilerplate code. Signed-off-by: Christoph Hellwig --- net/netfilter/x_tables.c | 42 ++-- 1 file changed, 6 insertions(+), 36 deletions(-) diff --git a/net/netfilter/x_tables.c b/net/netfilter/x_tables.c index

[PATCH 30/40] neigh: switch to proc_create_seq_data

2018-04-25 Thread Christoph Hellwig
And use proc private data directly instead of doing a detour through seq->private. Signed-off-by: Christoph Hellwig --- net/core/neighbour.c | 31 ++- 1 file changed, 6 insertions(+), 25 deletions(-) diff --git a/net/core/neighbour.c

[PATCH 27/40] rtc/proc: switch to proc_create_single_data

2018-04-25 Thread Christoph Hellwig
And stop trying to get a reference on the submodule, procfs code deals with release after and unloaded module and thus removed proc entry. Signed-off-by: Christoph Hellwig --- drivers/rtc/rtc-proc.c | 33 ++--- 1 file changed, 2 insertions(+), 31

[PATCH 15/40] proc: introduce proc_create_net{,_data}

2018-04-25 Thread Christoph Hellwig
Variants of proc_create{,_data} that directly take a struct seq_operations and deal with network namespaces in ->open and ->release. All callers of proc_create + seq_open_net converted over, and seq_{open,release}_net are removed entirely. Signed-off-by: Christoph Hellwig ---

[PATCH 25/40] resource: switch to proc_create_seq_data

2018-04-25 Thread Christoph Hellwig
And use the root resource directly from the proc private data. Signed-off-by: Christoph Hellwig --- kernel/resource.c | 43 +-- 1 file changed, 5 insertions(+), 38 deletions(-) diff --git a/kernel/resource.c b/kernel/resource.c index

[PATCH 21/40] afs: simplify procfs code

2018-04-25 Thread Christoph Hellwig
Use remove_proc_subtree to remove the whole subtree on cleanup, and unwind the registration loop into individual calls. Switch to use proc_create_seq where applicable. Signed-off-by: Christoph Hellwig --- fs/afs/proc.c | 134 ++ 1

[PATCH 28/40] bonding: switch to proc_create_seq_data

2018-04-25 Thread Christoph Hellwig
And use proc private data directly instead of doing a detour through seq->private. Signed-off-by: Christoph Hellwig --- drivers/net/bonding/bond_procfs.c | 36 ++- 1 file changed, 6 insertions(+), 30 deletions(-) diff --git

[PATCH 22/40] ext4: simplify procfs code

2018-04-25 Thread Christoph Hellwig
Use remove_proc_subtree to remove the whole subtree on cleanup, and unwind the registration loop into individual calls. Switch to use proc_create_seq where applicable. Signed-off-by: Christoph Hellwig --- fs/ext4/ext4.h| 2 +- fs/ext4/mballoc.c | 29

[PATCH 29/40] hostap: switch to proc_create_{seq,single}_data

2018-04-25 Thread Christoph Hellwig
And use proc private data directly instead of doing a detour through seq->private. Signed-off-by: Christoph Hellwig --- .../net/wireless/intersil/hostap/hostap_ap.c | 70 ++--- .../net/wireless/intersil/hostap/hostap_hw.c | 17 +-- .../wireless/intersil/hostap/hostap_proc.c

[PATCH 23/40] jfs: simplify procfs code

2018-04-25 Thread Christoph Hellwig
Use remove_proc_subtree to remove the whole subtree on cleanup, and unwind the registration loop into individual calls. Switch to use proc_create_seq where applicable. Signed-off-by: Christoph Hellwig --- fs/jfs/jfs_debug.c| 43 ++-

[PATCH 24/40] staging/rtl8192u: simplify procfs code

2018-04-25 Thread Christoph Hellwig
Unwind the registration loop into individual calls. Switch to use proc_create_single where applicable. Signed-off-by: Christoph Hellwig --- drivers/staging/rtl8192u/r8192U_core.c | 67 ++ 1 file changed, 14 insertions(+), 53 deletions(-) diff --git

[PATCH 19/40] megaraid: simplify procfs code

2018-04-25 Thread Christoph Hellwig
Use remove_proc_subtree to remove the whole subtree on cleanup, and unwind the registration loop into individual calls. Switch to use proc_create_single. Signed-off-by: Christoph Hellwig --- drivers/scsi/megaraid.c | 140 +++-

[PATCH 20/40] sg: simplify procfs code

2018-04-25 Thread Christoph Hellwig
Use remove_proc_subtree to remove the whole subtree on cleanup, and unwind the registration loop into individual calls. Switch to use proc_create_seq where applicable. Signed-off-by: Christoph Hellwig --- drivers/scsi/sg.c | 124 +- 1

[PATCH 18/40] sgi-gru: simplify procfs code

2018-04-25 Thread Christoph Hellwig
Use remove_proc_subtree to remove the whole subtree on cleanup, and unwind the registration loop into individual calls. Switch to use proc_create_seq where applicable. Signed-off-by: Christoph Hellwig --- drivers/misc/sgi-gru/gruprocfs.c | 81 ++-- 1

[PATCH 09/40] ipv{4,6}/ping: simplify proc file creation

2018-04-25 Thread Christoph Hellwig
Remove the pointless ping_seq_afinfo indirection and make the code look like most other protocols. Signed-off-by: Christoph Hellwig --- include/net/ping.h | 11 -- net/ipv4/ping.c| 50 +- net/ipv6/ping.c| 35

[PATCH 17/40] acpi/battery: simplify procfs code

2018-04-25 Thread Christoph Hellwig
Use remove_proc_subtree to remove the whole subtree on cleanup, and unwind the registration loop into individual calls. Switch to use proc_create_seq where applicable. Signed-off-by: Christoph Hellwig Reviewed-by: Rafael J. Wysocki ---

[PATCH 16/40] proc: introduce proc_create_net_single

2018-04-25 Thread Christoph Hellwig
Variant of proc_create_data that directly take a seq_file show callback and deals with network namespaces in ->open and ->release. All callers of proc_create + single_open_net converted over, and single_{open,release}_net are removed entirely. Signed-off-by: Christoph Hellwig ---

[PATCH 11/40] ipv6/flowlabel: simplify pid namespace lookup

2018-04-25 Thread Christoph Hellwig
The shole seq_file sequence already operates under a single RCU lock pair, so move the pid namespace lookup into it, and stop grabbing a reference and remove all kinds of boilerplate code. Signed-off-by: Christoph Hellwig --- net/ipv6/ip6_flowlabel.c | 28

[PATCH 14/40] net: move seq_file_single_net to

2018-04-25 Thread Christoph Hellwig
This helper deals with single_{open,release}_net internals and thus belongs here. Signed-off-by: Christoph Hellwig --- include/linux/seq_file_net.h | 13 + include/net/ip_vs.h | 12 2 files changed, 13 insertions(+), 12 deletions(-) diff --git

[PATCH 13/40] netfilter/x_tables: simplify ѕeq_file code

2018-04-25 Thread Christoph Hellwig
Just use the address family from the proc private data instead of copying it into per-file data. Signed-off-by: Christoph Hellwig --- net/netfilter/x_tables.c | 39 +++ 1 file changed, 11 insertions(+), 28 deletions(-) diff --git

[PATCH 12/40] net/kcm: simplify proc registration

2018-04-25 Thread Christoph Hellwig
Remove a couple indirections to make the code look like most other protocols. Signed-off-by: Christoph Hellwig --- net/kcm/kcmproc.c | 71 --- 1 file changed, 17 insertions(+), 54 deletions(-) diff --git a/net/kcm/kcmproc.c

[PATCH 08/40] ipv{4,6}/tcp: simplify procfs registration

2018-04-25 Thread Christoph Hellwig
Avoid most of the afinfo indirections and just call the proc helpers directly. Signed-off-by: Christoph Hellwig --- include/net/tcp.h | 11 ++ net/ipv4/tcp_ipv4.c | 85 + net/ipv6/tcp_ipv6.c | 27 +- 3 files changed, 53

[PATCH 10/40] ipv{4, 6}/raw: simplify ѕeq_file code

2018-04-25 Thread Christoph Hellwig
Pass the hashtable to the proc private data instead of copying it into the per-file private data. Signed-off-by: Christoph Hellwig --- include/net/raw.h | 4 net/ipv4/raw.c| 36 net/ipv6/raw.c| 6 -- 3 files changed, 16

[PATCH 04/40] proc: introduce proc_create_seq{,_data}

2018-04-25 Thread Christoph Hellwig
Variants of proc_create{,_data} that directly take a struct seq_operations argument and drastically reduces the boilerplate code in the callers. All trivial callers converted over. Signed-off-by: Christoph Hellwig --- arch/ia64/hp/common/sba_iommu.c | 15 +-

[PATCH 06/40] proc: introduce proc_create_single{,_data}

2018-04-25 Thread Christoph Hellwig
Variants of proc_create{,_data} that directly take a seq_file show callback and drastically reduces the boilerplate code in the callers. All trivial callers converted over. Signed-off-by: Christoph Hellwig --- arch/arm/kernel/dma.c | 14 +---

[PATCH 07/40] ipv{4,6}/udp{,lite}: simplify proc registration

2018-04-25 Thread Christoph Hellwig
Remove a couple indirections to make the code look like most other protocols. Signed-off-by: Christoph Hellwig --- include/net/udp.h | 20 -- net/ipv4/udp.c | 99 +- net/ipv4/udplite.c | 21 +++--- net/ipv6/udp.c | 30

[PATCH 05/40] proc: introduce proc_create_seq_private

2018-04-25 Thread Christoph Hellwig
Variant of proc_create_data that directly take a struct seq_operations argument + a private state size and drastically reduces the boilerplate code in the callers. All trivial callers converted over. Signed-off-by: Christoph Hellwig --- fs/locks.c | 16

[PATCH 03/40] proc: add a proc_create_reg helper

2018-04-25 Thread Christoph Hellwig
Common code for creating a regular file. Factor out of proc_create_data, to be reused by other functions soon. Signed-off-by: Christoph Hellwig --- fs/proc/generic.c | 44 +--- fs/proc/internal.h | 2 ++ 2 files changed, 27 insertions(+),

[PATCH 02/40] proc: simplify proc_register calling conventions

2018-04-25 Thread Christoph Hellwig
Return registered entry on success, return NULL on failure and free the passed in entry. Also expose it in internal.h as we'll start using it in proc_net.c soon. Signed-off-by: Christoph Hellwig --- fs/proc/generic.c | 44 ++--

[PATCH 01/40] net/can: single_open_net needs to be paired with single_release_net

2018-04-25 Thread Christoph Hellwig
Otherwise we will leak a reference to the network namespace. Signed-off-by: Christoph Hellwig --- net/can/bcm.c | 2 +- net/can/proc.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/net/can/bcm.c b/net/can/bcm.c index ac5e5e34fee3..8073fa14e143 100644

Re: [PATCH] staging/wilc1000: fix wilc_mac_xmit()'s return type

2018-04-25 Thread Claudiu Beznea
Could you, please, change the "return 0;"s inside wilc_mac_xmit() with "return NETDEV_TX_OK" ? Thank you, Claudiu On 24.04.2018 15:18, Luc Van Oostenryck wrote: > The method ndo_start_xmit() is defined as returning an 'netdev_tx_t', > which is a typedef for an enum type, but the implementation

Re: [PATCH 06/18] staging: ks7010: use GPL-2.0+ SPDX license identifier

2018-04-25 Thread Sergio Paracuellos
On Wed, Apr 25, 2018 at 03:49:19PM +0200, Greg KH wrote: > On Tue, Apr 24, 2018 at 03:49:55PM +0200, Sergio Paracuellos wrote: > > The summary text for the GPL is not needed since the SPDX identifier > > is a legally binding shorthand that can be used instead. > > > > Signed-off-by: Sergio

[PATCH 10/16] staging: ks7010: refactor ks_wlan_set_wap function

2018-04-25 Thread Sergio Paracuellos
Make use of ether_addr_copy instead of memcpy for copying ethernet address data in ks_wlan_set_wap function and avoid an 'else' just changing if logic to check invalid values first. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 14

[PATCH 15/16] staging: ks7010: avoid blank line between declarations in ks_wlan_get_aplist

2018-04-25 Thread Sergio Paracuellos
This commit removes a blank line which is included between declarations and it has not sense at all. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/staging/ks7010/ks_wlan_net.c

[PATCH 16/16] staging: ks7010: refactor ks_wlan_translate_scan function

2018-04-25 Thread Sergio Paracuellos
This commit refactors ks_wlan_translate_scan function with the following changes: - reorder local variables - use ether_addr_copy to copy ethernet addresses - change style in 'current_ev' variable assignments - make use of some ternaries avoiding if-else code - use preferred

[PATCH 08/16] staging: ks7010: use ether_addr_copy in ks_wlan_set_encode_ext

2018-04-25 Thread Sergio Paracuellos
Instead of manually memcpy ethernet addresses use ether_addr_copy function for this purpose. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH 12/16] staging: ks7010: avoid an 'else' in ks_wlan_set_power

2018-04-25 Thread Sergio Paracuellos
Change if logic to handle invalid case for operation_mode at first avoiding an 'else' path. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git

[PATCH 13/16] staging: ks7010: avoid if-else condition in ks_wlan_get_power

2018-04-25 Thread Sergio Paracuellos
The if-else code in ks_wlan_get_power function is not needed at all and can be achieved with a simple boolean assignation. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff

[PATCH 09/16] staging: ks7010: align values in frequency_list array

2018-04-25 Thread Sergio Paracuellos
To avoid a long line align values in static array frequency_list array. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/staging/ks7010/ks_wlan_net.c

[PATCH 11/16] staging: ks7010: use ether_addr_copy in ks_wlan_get_wap

2018-04-25 Thread Sergio Paracuellos
Use ether_addr_copy to copy ethernet addresses instead of a custom memcpy. This improves readability. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH 14/16] staging: ks7010: use ether_addr_copy in ks_wlan_get_aplist

2018-04-25 Thread Sergio Paracuellos
Use ether_addr_copy to copy ethernet addresses instead of using custom memcpy for that. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git

[PATCH 04/16] staging: ks7010: refactor ks_wlan_set_power_mgmt function

2018-04-25 Thread Sergio Paracuellos
This commit change logic to simplify conditional paths in ks_wlan_set_power_mgmt function. It handles invalid's first and just finally assign a valid value. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 23 --- 1

[PATCH 05/16] staging: ks7010: refactor ks_wlan_set_preamble function

2018-04-25 Thread Sergio Paracuellos
Change if logic to handle invalid values first and just assign at the end the valid one if it is the case. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git

[PATCH 06/16] staging: ks7010: refactor ks_wlan_set_cts_mode function

2018-04-25 Thread Sergio Paracuellos
This commit refactors ks_wlan_set_cts_mode function to handle invalid values first and then assign the good one changing a bit logic to use a ternary operator. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 17 ++--- 1 file

[PATCH 02/16] staging: ks7010: refactor ks_wlan_set_beacon_lost function

2018-04-25 Thread Sergio Paracuellos
Change if condition to handle invalid value first and avoid nonsense else's path improving readability. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git

[PATCH 00/16] staging: ks7010: next cleanups

2018-04-25 Thread Sergio Paracuellos
This patch series includes some new cleanups in code. It also includes a remaining patch (PATCH 1/16) about SPDX identifiers in files which wasn't be applied. Sergio Paracuellos (16): staging: ks7010: add SPDX identifiers to all files staging: ks7010: refactor ks_wlan_set_beacon_lost

[PATCH 03/16] staging: ks7010: refactor ks_wlan_set_scan_type function

2018-04-25 Thread Sergio Paracuellos
This commit changes logic to handle invalid values first and just assign valid ones afterwards. Signed-off-by: Sergio Paracuellos --- drivers/staging/ks7010/ks_wlan_net.c | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff --git

[PATCH 01/16] staging: ks7010: add SPDX identifiers to all files

2018-04-25 Thread Sergio Paracuellos
It's good to have SPDX identifiers in all files to make it easier to audit the kernel tree for correct licenses. Fix up the all of the staging ks7010 files to have a proper SPDX identifier, based on the license text in the file itself. The SPDX identifier is a legally binding shorthand, which

Re: [PATCH] staging: ks7010: fix ks_wlan_start_xmit()'s return type

2018-04-25 Thread Greg Kroah-Hartman
On Tue, Apr 24, 2018 at 03:18:21PM +0200, Luc Van Oostenryck wrote: > The method ndo_start_xmit() is defined as returning an 'netdev_tx_t', > which is a typedef for an enum type, but the implementation in this > driver returns an 'int'. > > Fix this by returning 'netdev_tx_t' in this driver too.

Re: [PATCH 06/18] staging: ks7010: use GPL-2.0+ SPDX license identifier

2018-04-25 Thread Greg KH
On Tue, Apr 24, 2018 at 03:49:55PM +0200, Sergio Paracuellos wrote: > The summary text for the GPL is not needed since the SPDX identifier > is a legally binding shorthand that can be used instead. > > Signed-off-by: Sergio Paracuellos > --- >

[PATCH 2/2] staging: gdm724x: remove redundant license information

2018-04-25 Thread Greg Kroah-Hartman
Now that the SPDX tag is in all gdm724x files, that identifies the license in a specific and legally-defined manner. So the extra GPL text wording can be removed as it is no longer needed at all. This is done on a quest to remove the 700+ different ways that files in the kernel describe the GPL

[PATCH 1/2] staging: gdm724x: add SPDX identifiers to all files.

2018-04-25 Thread Greg Kroah-Hartman
It's good to have SPDX identifiers in all files to make it easier to audit the kernel tree for correct licenses. Fix up the all of the staging gdm724x files to have a proper SPDX identifier, based on the license text in the file itself. The SPDX identifier is a legally binding shorthand, which

  1   2   >