openwrt/staging/blogic.git
6 years agostaging: lustre: use memdup_user to allocate memory and copy from user
Dafna Hirschfeld [Mon, 19 Feb 2018 19:57:37 +0000 (21:57 +0200)]
staging: lustre: use memdup_user to allocate memory and copy from user

Replace a call to kmalloc and a call to copy_from_user with a
call to memdup_user to simplify the code.
Issue found with coccicheck.

Signed-off-by: Dafna Hirschfeld <dafna3@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: Split subtraction across 2 lines
Eisha Chen-yen-su [Tue, 20 Feb 2018 00:47:26 +0000 (01:47 +0100)]
staging: pi433: Split subtraction across 2 lines

Split a subtraction across 2 lines in order to make these lines
no longer than 80 columns. Problem found with checkpatch.

Signed-off-by: Eisha Chen-yen-su <chenyensu0@gmail.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: Split some function calls
Eisha Chen-yen-su [Tue, 20 Feb 2018 00:47:25 +0000 (01:47 +0100)]
staging: pi433: Split some function calls

Split some function calls on several lines in order to make these
lines no longer than 80 columns. Problem found with checkpatch.

Signed-off-by: Eisha Chen-yen-su <chenyensu0@gmail.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: remove Unnecessary parentheses around 'hif_set_mc->cnt'
Ajay Singh [Mon, 19 Feb 2018 15:29:44 +0000 (20:59 +0530)]
staging: wilc1000: remove Unnecessary parentheses around 'hif_set_mc->cnt'

Fix "Unnecessary parentheses around 'hif_set_mc->cnt'" issue found by
checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename wilc_remove_key() parameters to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:43 +0000 (20:59 +0530)]
staging: wilc1000: rename wilc_remove_key() parameters to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename GetPeriodicRSSI to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:42 +0000 (20:59 +0530)]
staging: wilc1000: rename GetPeriodicRSSI to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename ListenTimerCB to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:41 +0000 (20:59 +0530)]
staging: wilc1000: rename ListenTimerCB to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename functions starting with TimerCB_ to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:40 +0000 (20:59 +0530)]
staging: wilc1000: rename functions starting with TimerCB_ to avoid camelCase

Fix "Avoid camelCase" issues found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename functions starting with Handle_ to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:39 +0000 (20:59 +0530)]
staging: wilc1000: rename functions starting with Handle_ to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename pstrRcvdNetworkInfo to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:38 +0000 (20:59 +0530)]
staging: wilc1000: rename pstrRcvdNetworkInfo to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename pstrRcvdGnrlAsyncInfo to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:37 +0000 (20:59 +0530)]
staging: wilc1000: rename pstrRcvdGnrlAsyncInfo to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename strHostIfStaInactiveT to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:36 +0000 (20:59 +0530)]
staging: wilc1000: rename strHostIfStaInactiveT to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename pstrHostIfRegisterFrame to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:35 +0000 (20:59 +0530)]
staging: wilc1000: rename pstrHostIfRegisterFrame to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename pstrHostIfRemainOnChan to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:34 +0000 (20:59 +0530)]
staging: wilc1000: rename pstrHostIfRemainOnChan to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename host_int_get_assoc_res_info() parameters to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:33 +0000 (20:59 +0530)]
staging: wilc1000: rename host_int_get_assoc_res_info() parameters to avoid camelCase

Fix "Avoid camelCase" issues reported by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename strHostIfSetMulti to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:32 +0000 (20:59 +0530)]
staging: wilc1000: rename strHostIfSetMulti to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename s8PowerMode & strPowerMgmtParam to avoid camelCase
Ajay Singh [Mon, 19 Feb 2018 15:29:31 +0000 (20:59 +0530)]
staging: wilc1000: rename s8PowerMode & strPowerMgmtParam to avoid camelCase

Fix "Avoid camelCase" issues found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agoStaging: gdm724x: tty: Remove unused macro 'gdm_tty_send_control'.
Quytelda Kahja [Sun, 18 Feb 2018 20:26:55 +0000 (12:26 -0800)]
Staging: gdm724x: tty: Remove unused macro 'gdm_tty_send_control'.

Remove the macro 'gdm_tty_send_control' which adds unnecessary complexity,
is unused, and has arguments that could mistakenly be evaluated multiple
times.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agoStaging: gdm724x: tty: Remove unnecessary macro 'gdm_tty_recv'.
Quytelda Kahja [Sun, 18 Feb 2018 20:26:54 +0000 (12:26 -0800)]
Staging: gdm724x: tty: Remove unnecessary macro 'gdm_tty_recv'.

Remove the macro 'gdm_tty_recv' which adds unnecessary complexity and has
arguments that could mistakenly be evaluated multiple times.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agoStaging: gdm724x: tty: Remove unnecessary macro 'gdm_tty_send'.
Quytelda Kahja [Sun, 18 Feb 2018 20:26:53 +0000 (12:26 -0800)]
Staging: gdm724x: tty: Remove unnecessary macro 'gdm_tty_send'.

Remove the macro 'gdm_tty_send' which adds unnecessary complexity and has
arguments that could mistakenly be evaluated multiple times.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agoStaging: gdm724x: mux: Check return value of register_lte_tty_driver().
Quytelda Kahja [Sun, 18 Feb 2018 07:06:35 +0000 (23:06 -0800)]
Staging: gdm724x: mux: Check return value of register_lte_tty_driver().

Check the return value of of the register_lte_tty_driver() call in the
module initialization function.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agoStaging: gdm724x: LTE: Fix argument list not aligned with parenthesis.
Quytelda Kahja [Fri, 16 Feb 2018 21:46:23 +0000 (13:46 -0800)]
Staging: gdm724x: LTE: Fix argument list not aligned with parenthesis.

Fix coding style warning from checkpatch.pl.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:r8188eu: Use lib80211 to decrypt WEP-frames
Ivan Safonov [Sun, 18 Feb 2018 11:37:38 +0000 (14:37 +0300)]
staging:r8188eu: Use lib80211 to decrypt WEP-frames

Use native lib80211 WEP decrypt instead of custom implementation.

Signed-off-by: Ivan Safonov <insafonov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8712: fix signedness of length to rtl8717_set_ie
Stefano Manni [Sun, 18 Feb 2018 19:52:13 +0000 (20:52 +0100)]
staging: rtl8712: fix signedness of length to rtl8717_set_ie

rtl8717_set_it() takes an unsigned int pointer as length,
fixed signedness in code using it.

Sparse warnings:

drivers/staging/rtl8712/ieee80211.c:191:53: warning: incorrect type in argument 5 (different signedness)
drivers/staging/rtl8712/ieee80211.c:191:53:    expected unsigned int [usertype] *frlen
drivers/staging/rtl8712/ieee80211.c:191:53:    got int *<noident>
drivers/staging/rtl8712/ieee80211.c:197:57: warning: incorrect type in argument 5 (different signedness)
drivers/staging/rtl8712/ieee80211.c:197:57:    expected unsigned int [usertype] *frlen
drivers/staging/rtl8712/ieee80211.c:197:57:    got int *<noident>
drivers/staging/rtl8712/ieee80211.c:199:63: warning: incorrect type in argument 5 (different signedness)
drivers/staging/rtl8712/ieee80211.c:199:63:    expected unsigned int [usertype] *frlen
drivers/staging/rtl8712/ieee80211.c:199:63:    got int *<noident>
drivers/staging/rtl8712/ieee80211.c:202:67: warning: incorrect type in argument 5 (different signedness)
drivers/staging/rtl8712/ieee80211.c:202:67:    expected unsigned int [usertype] *frlen
drivers/staging/rtl8712/ieee80211.c:202:67:    got int *<noident>
drivers/staging/rtl8712/ieee80211.c:206:73: warning: incorrect type in argument 5 (different signedness)
drivers/staging/rtl8712/ieee80211.c:206:73:    expected unsigned int [usertype] *frlen
drivers/staging/rtl8712/ieee80211.c:206:73:    got int *<noident>
drivers/staging/rtl8712/ieee80211.c:209:75: warning: incorrect type in argument 5 (different signedness)
drivers/staging/rtl8712/ieee80211.c:209:75:    expected unsigned int [usertype] *frlen
drivers/staging/rtl8712/ieee80211.c:209:75:    got int *<noident>

Signed-off-by: Stefano Manni <stefano.manni@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8712: make unsigned length for rtl8717_get{_wpa_, _wpa2_, _}ie
Stefano Manni [Sun, 18 Feb 2018 19:52:12 +0000 (20:52 +0100)]
staging: rtl8712: make unsigned length for rtl8717_get{_wpa_, _wpa2_, _}ie

Fixed r8712_get_ie, r8712_get_wpa_ie, r8712_get_wpa2_ie
to have a length as unsigned int pointer instead of signed.

Sparse warnings:

drivers/staging/rtl8712/rtl871x_ioctl_linux.c:173:27: warning: incorrect type in argument 3 (different signedness)
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:173:27:    expected signed int *len
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:173:27:    got unsigned int *<noident>
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:613:35: warning: incorrect type in argument 3 (different signedness)
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:613:35:    expected signed int *len
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:613:35:    got unsigned int *<noident>
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1411:67: warning: incorrect type in argument 3 (different signedness)
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1411:67:    expected signed int *len
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1411:67:    got unsigned int *<noident>
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1992:33: warning: incorrect type in argument 2 (different signedness)
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1992:33:    expected int *rsn_ie_len
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1992:33:    got unsigned int *<noident>
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1998:33: warning: incorrect type in argument 2 (different signedness)
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1998:33:    expected int *rsn_ie_len
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1998:33:    got unsigned int *<noident>
drivers/staging/rtl8712/rtl871x_mlme.c:1701:59: warning: incorrect type in argument 3 (different signedness)
drivers/staging/rtl8712/rtl871x_mlme.c:1701:59:    expected signed int *len
drivers/staging/rtl8712/rtl871x_mlme.c:1701:59:    got unsigned int *<noident>

Signed-off-by: Stefano Manni <stefano.manni@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: comedi: Use '"%s:", __func__' instead of function name
Eisha Chen-yen-su [Sun, 18 Feb 2018 13:27:07 +0000 (14:27 +0100)]
staging: comedi: Use '"%s:", __func__' instead of function name

Replace an occurrence of the function name in a string by a reference
to __func__, to improve robustness. Problem found with checkpatch.

Signed-off-by: Eisha Chen-yen-su <chenyensu0@gmail.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: clean up conditionals
Dafna Hirschfeld [Sun, 18 Feb 2018 16:43:04 +0000 (18:43 +0200)]
staging: rtl8723bs: clean up conditionals

Move all closing braces and parentheses to the end of the line.
Remove braces from 'if' statements with a single 'then' line.
Move logical operators to the end of lines in multiline conditional.
Remove unnecessary parentheses.
Issues found with checkpatch.pl

Signed-off-by: Dafna Hirschfeld <dafna3@gmail.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: comedi: Add a missing space
Eisha Chen-yen-su [Sun, 18 Feb 2018 17:11:38 +0000 (18:11 +0100)]
staging: comedi: Add a missing space

Add a missing space so that the * is properly aligned with
the rest of the block comment. Problem found with checkpatch.

Signed-off-by: Eisha Chen-yen-su <chenyensu0@gmail.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8188eu: Replace function name in string with __func__
Dafna Hirschfeld [Sun, 18 Feb 2018 20:08:34 +0000 (22:08 +0200)]
staging: rtl8188eu: Replace function name in string with __func__

Replace hard coded function name FillH2CCmd_88E with __func__
and break the line to avoid more then 80 characters line.
Issue found using checkpatch.pl

Signed-off-by: Dafna Hirschfeld <dafna3@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: vt6655: remove additional blank line
Santha Meena Ramamoorthy [Sun, 18 Feb 2018 23:02:00 +0000 (15:02 -0800)]
staging: vt6655: remove additional blank line

Remove extra blank line inside a function to conform to Linux
kernel coding style. Problem detected using checkpatch.

Signed-off-by: Santha Meena Ramamoorthy <santhameena13@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: comedi: Remove a newline inside a dereference
Eisha Chen-yen-su [Mon, 19 Feb 2018 16:04:22 +0000 (17:04 +0100)]
staging: comedi: Remove a newline inside a dereference

Remove a new line inside a dereference so that it is not on
multiple lines.
And avoid making the line go over 80 columns by moving the whole
dma_alloc_coherent() call back 4 columns. Problem found with
checkpatch.

Signed-off-by: Eisha Chen-yen-su <chenyensu0@gmail.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 chars in wilc_wlan_handle_txq()
Ajay Singh [Fri, 16 Feb 2018 15:11:49 +0000 (20:41 +0530)]
staging: wilc1000: fix line over 80 chars in wilc_wlan_handle_txq()

Fix "line over 80 characters" issue reported by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 chars in wilc_wlan_txq_filter_dup_tcp_ack()
Ajay Singh [Fri, 16 Feb 2018 15:11:48 +0000 (20:41 +0530)]
staging: wilc1000: fix line over 80 chars in wilc_wlan_txq_filter_dup_tcp_ack()

Fix "line over 80 characters" issue reported by checkpatch.pl.
Use temporary variable to avoid checkpatch.pl issue.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 characters in tcp_process()
Ajay Singh [Fri, 16 Feb 2018 15:11:47 +0000 (20:41 +0530)]
staging: wilc1000: fix line over 80 characters in tcp_process()

Fix "line over 80 characters" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 chars in add_tcp_pending_ack()
Ajay Singh [Fri, 16 Feb 2018 15:11:46 +0000 (20:41 +0530)]
staging: wilc1000: fix line over 80 chars in add_tcp_pending_ack()

Fix "line over 80 characters" issue reported by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 chars in wilc_wlan_cfg_get_wid_value()
Ajay Singh [Fri, 16 Feb 2018 15:11:45 +0000 (20:41 +0530)]
staging: wilc1000: fix line over 80 chars in wilc_wlan_cfg_get_wid_value()

Fix "line over 80 character" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 chars in wilc_wlan_cfg_indicate_rxi()
Ajay Singh [Fri, 16 Feb 2018 15:11:44 +0000 (20:41 +0530)]
staging: wilc1000: fix line over 80 chars in wilc_wlan_cfg_indicate_rxi()

Cleanup patch to fix "line over 80 characters" issue reported by
checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: remove blank line before close brace in wilc_wlan_cfg_get_wid_value()
Ajay Singh [Fri, 16 Feb 2018 15:11:43 +0000 (20:41 +0530)]
staging: wilc1000: remove blank line before close brace in wilc_wlan_cfg_get_wid_value()

Cleanup patch to remove "Blank lines aren't necessary before a close
brace '}'" issue reported by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 char in wilc_wlan_cfg_set_str()
Ajay Singh [Fri, 16 Feb 2018 15:11:42 +0000 (20:41 +0530)]
staging: wilc1000: fix line over 80 char in wilc_wlan_cfg_set_str()

Fix "line over 80 characters" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix open parenthesis alignment mismatch in wilc_parse_network_info()
Ajay Singh [Fri, 16 Feb 2018 15:11:41 +0000 (20:41 +0530)]
staging: wilc1000: fix open parenthesis alignment mismatch in wilc_parse_network_info()

Fix "Alignment should match open parenthesis" issue found by
checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 characters in sdio_clear_int_ext()
Ajay Singh [Fri, 16 Feb 2018 15:11:40 +0000 (20:41 +0530)]
staging: wilc1000: fix line over 80 characters in sdio_clear_int_ext()

Fix "line over 80 characters" issue found by checkpatch.pl script by
modifying the comment description.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix too many leading tabs warning in sdio_clear_int_ext()
Ajay Singh [Fri, 16 Feb 2018 15:11:39 +0000 (20:41 +0530)]
staging: wilc1000: fix too many leading tabs warning in sdio_clear_int_ext()

Refactor sdio_clear_int_ext() function to remove "Too many leading tabs"
warning reported by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: remove unnecessary comments to avoid line over 80 char issue
Ajay Singh [Fri, 16 Feb 2018 15:11:38 +0000 (20:41 +0530)]
staging: wilc1000: remove unnecessary comments to avoid line over 80 char issue

Fix "line over 80 characters" issue reported by checkpatch.pl script by
removing unnecessary comments.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: android: ion: Combine cache and uncache pools
Yisheng Xie [Mon, 12 Feb 2018 10:43:14 +0000 (18:43 +0800)]
staging: android: ion: Combine cache and uncache pools

Now we call dma_map in the dma_buf API callbacks and handle explicit
caching by the dma_buf sync API, which make cache and uncache pools
in the same handling flow, which can be combined.

Acked-by: Sumit Semwal <sumit.semwal@linaro.org>
Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: android: ion: Cleanup ion_page_pool_alloc_pages
Yisheng Xie [Mon, 12 Feb 2018 10:43:13 +0000 (18:43 +0800)]
staging: android: ion: Cleanup ion_page_pool_alloc_pages

ion_page_pool_alloc_pages calls alloc_pages to allocate pages for page
pools. If alloc_pages return NULL, it will return NULL, or it will
return the pages allocate from alloc_pages. So we can just return
alloc_pages without any judgement.

Acked-by: Sumit Semwal <sumit.semwal@linaro.org>
Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: android: ion: Return void instead of int
Yisheng Xie [Mon, 12 Feb 2018 10:43:12 +0000 (18:43 +0800)]
staging: android: ion: Return void instead of int

Now, nobody care about the return value of ion_page_pool_add, therefore
we can just make it return void.

Acked-by: Laura Abbott <labbott@redhat.com>
Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: android: ion: Remove dead code in ion_page_pool_free
Yisheng Xie [Mon, 12 Feb 2018 10:43:11 +0000 (18:43 +0800)]
staging: android: ion: Remove dead code in ion_page_pool_free

ion_page_pool_add will always return 0, however ion_page_pool_free will
call ion_page_pool_free_pages when ion_page_pool_add's return value is
not 0, so it is a dead code which can be removed.

Acked-by: Laura Abbott <labbott@redhat.com>
Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: android: ion: Remove lable debugfs_done
Yisheng Xie [Mon, 12 Feb 2018 10:43:10 +0000 (18:43 +0800)]
staging: android: ion: Remove lable debugfs_done

When failed to create debug_root, we will go on initail other part of
ion, so we can just info this message to user and do not need a lable
to jump.

Acked-by: Laura Abbott <labbott@redhat.com>
Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: android: ion: Avoid NULL point in error path
Yisheng Xie [Mon, 12 Feb 2018 10:43:09 +0000 (18:43 +0800)]
staging: android: ion: Avoid NULL point in error path

If we failed to create debugfs for ion at ion_device_create, the
debug_root of ion_device will be NULL, and then when try to create debug
file for shrinker of heap it will be create on the top of debugfs. If we
also failed to create this the debug file, it call dentry_path to found
the path of debug_root, then a NULL point will occur.

Fix this by avoiding call dentry_path, but show the debug name only when
failed to create debug file for shrinker.

Acked-by: Laura Abbott <labbott@redhat.com>
Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: android: ion: Nuke ion_page_pool_init
Yisheng Xie [Mon, 12 Feb 2018 10:43:08 +0000 (18:43 +0800)]
staging: android: ion: Nuke ion_page_pool_init

ion_page_pool.c now is used to apply pool APIs for system heap, which do
not need do any initial at device_initcall. Therefore ion_page_pool_init
can be nuked.

Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: android: ion: Remove unused include files for ion_page_pool.c
Yisheng Xie [Mon, 12 Feb 2018 10:43:07 +0000 (18:43 +0800)]
staging: android: ion: Remove unused include files for ion_page_pool.c

After rewrite of ion_page_pool, some of its include file is no need
anymore, just remove it.

Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: android: ion: Remove unused declaration ion_buffer_fault_user_mappings
Yisheng Xie [Mon, 12 Feb 2018 10:43:06 +0000 (18:43 +0800)]
staging: android: ion: Remove unused declaration ion_buffer_fault_user_mappings

ion_buffer_fault_user_mappings's definition has been removed and not be
used anymore, just remove its useless declaration.

Acked-by: Laura Abbott <labbott@redhat.com>
Signed-off-by: Yisheng Xie <xieyisheng1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:r8188eu: Remove unused struct pkt_file
Ivan Safonov [Sun, 4 Feb 2018 19:27:39 +0000 (22:27 +0300)]
staging:r8188eu: Remove unused struct pkt_file

Struct pkt_file is unused now, so remove it and correponding functions.

Signed-off-by: Ivan Safonov <insafonov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:r8188eu: Remove struct pkt_file from rtw_xmitframe_coalesce()
Ivan Safonov [Sun, 4 Feb 2018 19:27:38 +0000 (22:27 +0300)]
staging:r8188eu: Remove struct pkt_file from rtw_xmitframe_coalesce()

Struct pkt_file is a base to simple wrapper for skb_copy_bits().
Eliminate struct pkt_file usage in rtw_xmitframe_coalesce().

Signed-off-by: Ivan Safonov <insafonov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:r8188eu: Remove struct pkt_file from update_attrib()
Ivan Safonov [Sun, 4 Feb 2018 19:27:37 +0000 (22:27 +0300)]
staging:r8188eu: Remove struct pkt_file from update_attrib()

Struct pkt_file is a base to simple wrapper for skb_copy_bits().
Do not use struct pkt_file in update_attrib().

Signed-off-by: Ivan Safonov <insafonov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:r8188eu: Remove struct pkt_file from set_qos()
Ivan Safonov [Sun, 4 Feb 2018 19:27:36 +0000 (22:27 +0300)]
staging:r8188eu: Remove struct pkt_file from set_qos()

Struct pkt_file is a base to simple wrapper for skb_copy_bits().
Use skb_copy_bits() without wrappers.

Signed-off-by: Ivan Safonov <insafonov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: unisys: visorinput: use the full 80 characters of the screen
David Kershner [Wed, 31 Jan 2018 16:41:17 +0000 (11:41 -0500)]
staging: unisys: visorinput: use the full 80 characters of the screen

Several of the comments in the code were not using the full 80 characters
of the screen. This patch combines the lines to make full use of the
screen.

Signed-off-by: David Kershner <david.kershner@unisys.com>
Reviewed-by: Tim Sell <timothy.sell@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: unisys: visorinput: Fix spacing after open paranthesis
David Kershner [Wed, 31 Jan 2018 16:41:16 +0000 (11:41 -0500)]
staging: unisys: visorinput: Fix spacing after open paranthesis

Checkpatch was giving errors about an open parenthesis being the last thing
on a line. This patch cleans up some names and removes the checkpatch
warnings.

Signed-off-by: David Kershner <david.kershner@unisys.com>
Reviewed-by: Tim Sell <timothy.sell@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: unisys: visorinput: combine ultrainputreport.h with visorinput.c
David Kershner [Wed, 31 Jan 2018 16:41:15 +0000 (11:41 -0500)]
staging: unisys: visorinput: combine ultrainputreport.h with visorinput.c

The file ultrainputreport.h was just being used by visorinput.c. Move the
definitions into visorinput.c and get rid of the file.

Signed-off-by: David Kershner <david.kershner@unisys.com>
Reviewed-by: Tim Sell <timothy.sell@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: unisys: visorinput: remove duplicate comments
David Kershner [Wed, 31 Jan 2018 16:41:14 +0000 (11:41 -0500)]
staging: unisys: visorinput: remove duplicate comments

Comments were based on individual entries, if we group the entries, we can
get rid of duplicate comments.

Signed-off-by: David Kershner <david.kershner@unisys.com>
Reviewed-by: Tim Sell <timothy.sell@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: unisys: visorinput: Clean up Makefile includes
David Kershner [Wed, 31 Jan 2018 16:41:13 +0000 (11:41 -0500)]
staging: unisys: visorinput: Clean up Makefile includes

The driver no longer needs to include drivers/staging/unisys/include, so we
can get rid of it.

Signed-off-by: David Kershner <david.kershner@unisys.com>
Reviewed-by: Tim Sell <timothy.sell@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: unisys: visorinput: remove need for 'depends on FB'
Tim Sell [Wed, 31 Jan 2018 16:41:12 +0000 (11:41 -0500)]
staging: unisys: visorinput: remove need for 'depends on FB'

Previously, we used a hack to determine the max x,y resolution of the
visor virtual mouse: we just looked at the resolution of the
first-registered framebuffer device, using the currently-valid assumption
that in a Unisys s-Par guest environment the video will be provided by an
efifb framebuffer device.

This hack has been removed, by instead determining the default mouse
resolution by looking at fields within the visor mouse channel memory,
mouse.x_res and mouse.y_res.  If these fields are 0, a default resolution
of 1024x768 is assumed.

Signed-off-by: Tim Sell <Timothy.Sell@unisys.com>
Signed-off-by: David Kershner <david.kershner@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: sm750fb: Remove typedefs from enums
Christian Luetke-Stetzkamp [Sun, 11 Feb 2018 17:23:17 +0000 (18:23 +0100)]
staging: sm750fb: Remove typedefs from enums

Fixes checkpatch.pl warning: do not add new typedefs.

Signed-off-by: Christian Luetke-Stetzkamp <christian@lkamp.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: vt6656: Remove unnecessary 'out of memory' message
Dileep Sankhla [Mon, 12 Feb 2018 11:34:27 +0000 (17:04 +0530)]
staging: vt6656: Remove unnecessary 'out of memory' message

This patch removes the unnecessary out of memory message fixing the
following checkpatch.pl warning in usbpipe.c:
WARNING: Possible unnecessary 'out of memory' message

Signed-off-by: Dileep Sankhla <sankhla.dileep96@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: make 'myid' function to follow kernel coding rules
Maciek Fijalkowski [Tue, 13 Feb 2018 00:03:14 +0000 (01:03 +0100)]
staging: rtl8723bs: make 'myid' function to follow kernel coding rules

Checkpatch.pl produced errors regarding inline keyword placement and
parenthesis around returned value in 'myid'.
Place inline after static keyword and remove mentioned parenthesis.

Signed-off-by: Maciek Fijalkowski <macfij7@wp.pl>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtlwifi: add identifier names to function definition arguments
Erik Liodden [Sun, 28 Jan 2018 14:05:34 +0000 (15:05 +0100)]
staging: rtlwifi: add identifier names to function definition arguments

Add identifier names to function definition arguments to comply with
the kernel coding style and the naming convention in the rest of the
file.

Issues found by checkpatch.

Signed-off-by: Erik Liodden <erik.liodden@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agoStaging: fsl-dpaa2: ethernet: dpaa2-eth.c: Fixed a style issue
Santha Meena Ramamoorthy [Thu, 15 Feb 2018 18:15:48 +0000 (10:15 -0800)]
Staging: fsl-dpaa2: ethernet: dpaa2-eth.c: Fixed a style issue

Fixed the checkpatch warning "Please don't use multiple blank lines"

Signed-off-by: Santha Meena Ramamoorthy <santhameena13@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agoStaging: wlan-ng: fix unnecessary parantheses in prism2mgmt.c
Yash Omer [Fri, 16 Feb 2018 07:35:20 +0000 (13:05 +0530)]
Staging: wlan-ng: fix unnecessary parantheses in prism2mgmt.c

This patch fixes up a unncessary paratheses warning found by checkpatch.pl script.

Signed-off-by: Yash Omer <yashomer0007@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: fix CamelCase for regValue
Valentin Vidic [Sat, 27 Jan 2018 09:42:16 +0000 (10:42 +0100)]
staging: pi433: fix CamelCase for regValue

Local variable storing the new value for dio register
so replace with dio_value.  Update regaddr to dio_addr
to match.

Fixes checkpatch warnings:

  CHECK: Avoid CamelCase: <regValue>

Signed-off-by: Valentin Vidic <Valentin.Vidic@CARNet.hr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: fix CamelCase for newValue
Valentin Vidic [Sat, 27 Jan 2018 09:42:15 +0000 (10:42 +0100)]
staging: pi433: fix CamelCase for newValue

Local variable storing the new value for bandwidth register
so replace with bandwidth.

Fixes checkpatch warnings:

  CHECK: Avoid CamelCase: <newValue>

Signed-off-by: Valentin Vidic <Valentin.Vidic@CARNet.hr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: fix CamelCase for currentValue
Valentin Vidic [Sat, 27 Jan 2018 09:42:14 +0000 (10:42 +0100)]
staging: pi433: fix CamelCase for currentValue

Local variable storing the value for modulation register so replace
with modulation_reg.

Fixes checkpatch warnings:

  CHECK: Avoid CamelCase: <currentValue>

Signed-off-by: Valentin Vidic <Valentin.Vidic@CARNet.hr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: fix CamelCase for Ohm identifiers
Valentin Vidic [Sat, 27 Jan 2018 09:42:13 +0000 (10:42 +0100)]
staging: pi433: fix CamelCase for Ohm identifiers

Fixes checkpatch warnings:

  CHECK: Avoid CamelCase: <fiftyOhm>
  CHECK: Avoid CamelCase: <twohundretOhm>

Signed-off-by: Valentin Vidic <Valentin.Vidic@CARNet.hr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: fix CamelCase for antennaImpedance
Valentin Vidic [Sat, 27 Jan 2018 09:42:12 +0000 (10:42 +0100)]
staging: pi433: fix CamelCase for antennaImpedance

Fixes checkpatch warnings:

  CHECK: Avoid CamelCase: <antennaImpedance>

Signed-off-by: Valentin Vidic <Valentin.Vidic@CARNet.hr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: fix CamelCase for powerLevel
Valentin Vidic [Sat, 27 Jan 2018 09:42:11 +0000 (10:42 +0100)]
staging: pi433: fix CamelCase for powerLevel

Fixes checkpatch warnings:

  CHECK: Avoid CamelCase: <powerLevel>

Signed-off-by: Valentin Vidic <Valentin.Vidic@CARNet.hr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: fix CamelCase for syncValues
Valentin Vidic [Sat, 27 Jan 2018 09:42:10 +0000 (10:42 +0100)]
staging: pi433: fix CamelCase for syncValues

Fixes checkpatch warnings:

  CHECK: Avoid CamelCase: <syncValues>

Signed-off-by: Valentin Vidic <Valentin.Vidic@CARNet.hr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: ccree: fixed pointer signedness warnings.
Jeremy Sowden [Sat, 20 Jan 2018 15:08:27 +0000 (15:08 +0000)]
staging: ccree: fixed pointer signedness warnings.

The driver uses a mixture of signed and unsigned integer variables for
holding arrays lengths and indices, which gives rise to the following
sparse warnings when the addresses of signed variables are passed to
functions expecting pointers to unsigned integers:

  drivers/staging/ccree/cc_buffer_mgr.c:1050:46: warning: incorrect type in argument 4 (different signedness)
  drivers/staging/ccree/cc_buffer_mgr.c:1050:46:    expected unsigned int [usertype] *lbytes
  drivers/staging/ccree/cc_buffer_mgr.c:1050:46:    got int *<noident>
  drivers/staging/ccree/cc_buffer_mgr.c:1083:62: warning: incorrect type in argument 7 (different signedness)
  drivers/staging/ccree/cc_buffer_mgr.c:1083:62:    expected unsigned int [usertype] *lbytes
  drivers/staging/ccree/cc_buffer_mgr.c:1083:62:    got int *<noident>
  drivers/staging/ccree/cc_buffer_mgr.c:1092:46: warning: incorrect type in argument 4 (different signedness)
  drivers/staging/ccree/cc_buffer_mgr.c:1092:46:    expected unsigned int [usertype] *lbytes
  drivers/staging/ccree/cc_buffer_mgr.c:1092:46:    got int *<noident>
  drivers/staging/ccree/cc_buffer_mgr.c:1120:49: warning: incorrect type in argument 4 (different signedness)
  drivers/staging/ccree/cc_buffer_mgr.c:1120:49:    expected unsigned int [usertype] *src_last_bytes
  drivers/staging/ccree/cc_buffer_mgr.c:1120:49:    got int *<noident>
  drivers/staging/ccree/cc_buffer_mgr.c:1121:49: warning: incorrect type in argument 5 (different signedness)
  drivers/staging/ccree/cc_buffer_mgr.c:1121:49:    expected unsigned int [usertype] *dst_last_bytes
  drivers/staging/ccree/cc_buffer_mgr.c:1121:49:    got int *<noident>
  drivers/staging/ccree/cc_buffer_mgr.c:1124:49: warning: incorrect type in argument 2 (different signedness)
  drivers/staging/ccree/cc_buffer_mgr.c:1124:49:    expected unsigned int [usertype] *src_last_bytes
  drivers/staging/ccree/cc_buffer_mgr.c:1124:49:    got int *<noident>
  drivers/staging/ccree/cc_buffer_mgr.c:1125:44: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_buffer_mgr.c:1125:44:    expected unsigned int [usertype] *dst_last_bytes
  drivers/staging/ccree/cc_buffer_mgr.c:1125:44:    got int *<noident>
  drivers/staging/ccree/cc_cipher.c:697:67: warning: incorrect type in argument 6 (different signedness)
  drivers/staging/ccree/cc_cipher.c:697:67:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_cipher.c:697:67:    got int *<noident>
  drivers/staging/ccree/cc_cipher.c:700:31: warning: incorrect type in argument 8 (different signedness)
  drivers/staging/ccree/cc_cipher.c:700:31:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_cipher.c:700:31:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:480:57: warning: incorrect type in argument 6 (different signedness)
  drivers/staging/ccree/cc_hash.c:480:57:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:480:57:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:530:57: warning: incorrect type in argument 6 (different signedness)
  drivers/staging/ccree/cc_hash.c:530:57:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:530:57:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:1305:43: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_hash.c:1305:43:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:1305:43:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:1307:43: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_hash.c:1307:43:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:1307:43:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:1317:69: warning: incorrect type in argument 6 (different signedness)
  drivers/staging/ccree/cc_hash.c:1317:69:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:1317:69:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:1390:43: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_hash.c:1390:43:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:1390:43:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:1393:43: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_hash.c:1393:43:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:1393:43:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:1404:69: warning: incorrect type in argument 6 (different signedness)
  drivers/staging/ccree/cc_hash.c:1404:69:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:1404:69:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:1469:43: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_hash.c:1469:43:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:1469:43:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:1472:43: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_hash.c:1472:43:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:1472:43:    got int *<noident>
  drivers/staging/ccree/cc_hash.c:1483:69: warning: incorrect type in argument 6 (different signedness)
  drivers/staging/ccree/cc_hash.c:1483:69:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_hash.c:1483:69:    got int *<noident>
  drivers/staging/ccree/cc_aead.c:2011:37: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_aead.c:2011:37:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_aead.c:2011:37:    got int *<noident>
  drivers/staging/ccree/cc_aead.c:2017:45: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_aead.c:2017:45:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_aead.c:2017:45:    got int *<noident>
  drivers/staging/ccree/cc_aead.c:2020:45: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_aead.c:2020:45:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_aead.c:2020:45:    got int *<noident>
  drivers/staging/ccree/cc_aead.c:2024:44: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_aead.c:2024:44:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_aead.c:2024:44:    got int *<noident>
  drivers/staging/ccree/cc_aead.c:2026:44: warning: incorrect type in argument 3 (different signedness)
  drivers/staging/ccree/cc_aead.c:2026:44:    expected unsigned int *seq_size
  drivers/staging/ccree/cc_aead.c:2026:44:    got int *<noident>

This patch fixes those warnings by converting those signed variables to
unsigned as follows:

  * changed the types of a number of index and length variables from
    signed to unsigned integer types.

  * changed the return-types of a couple of functions that return length
    values which are assigned to one of these variables from signed to
    unsigned integer types.

Signed-off-by: Jeremy Sowden <jeremy@azazel.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 chars in wilc_spi_clear_int_ext()
Ajay Singh [Wed, 14 Feb 2018 11:10:15 +0000 (16:40 +0530)]
staging: wilc1000: fix line over 80 chars in wilc_spi_clear_int_ext()

Refactor wilc_spi_clear_int_ext() to fix the "line over 80 char" issue
reported by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 characters in wilc_spi_read_int()
Ajay Singh [Wed, 14 Feb 2018 11:10:14 +0000 (16:40 +0530)]
staging: wilc1000: fix line over 80 characters in wilc_spi_read_int()

Refactor wilc_spi_read_int() to fix the line over 80 char issues reported
by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 characters in wilc_spi_init()
Ajay Singh [Wed, 14 Feb 2018 11:10:13 +0000 (16:40 +0530)]
staging: wilc1000: fix line over 80 characters in wilc_spi_init()

Modified wilc_spi_init() to fix the line over 80 char issues reported
by checkpatch.pl script.
To overcome the checkpatch.pl reported issue modified debug logs and
comments used in wilc_spi_init().

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: fix line over 80 characters in spi_cmd_complete()
Ajay Singh [Wed, 14 Feb 2018 11:10:12 +0000 (16:40 +0530)]
staging: wilc1000: fix line over 80 characters in spi_cmd_complete()

Refactor spi_cmd_complete() to fix the line over 80 char issues reported
by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: removed the unnecessary commented code
Ajay Singh [Wed, 14 Feb 2018 11:10:11 +0000 (16:40 +0530)]
staging: wilc1000: removed the unnecessary commented code

Cleanup patch to remove the unused commented code.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: modified code comments as per linux coding style
Ajay Singh [Wed, 14 Feb 2018 11:10:10 +0000 (16:40 +0530)]
staging: wilc1000: modified code comments as per linux coding style

Cleanup patch to follow the comments style as per the Linux coding
style.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename Handle_Key() and Handle_ConnectTimeout()
Ajay Singh [Tue, 30 Jan 2018 16:50:33 +0000 (22:20 +0530)]
staging: wilc1000: rename Handle_Key() and Handle_ConnectTimeout()

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Reviewed-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename Handle_ScanDone function to avoid camelCase
Ajay Singh [Tue, 30 Jan 2018 16:50:32 +0000 (22:20 +0530)]
staging: wilc1000: rename Handle_ScanDone function to avoid camelCase

Fix "Avoid camelCase" issue reported by checkpatch.pl.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Reviewed-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename pu8CurrByte variable to avoid camelCase
Ajay Singh [Tue, 30 Jan 2018 16:50:31 +0000 (22:20 +0530)]
staging: wilc1000: rename pu8CurrByte variable to avoid camelCase

Fix "Avoid camelCase" issue reported by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Reviewed-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename u32WidsCount to avoid camelCase
Ajay Singh [Tue, 30 Jan 2018 16:50:30 +0000 (22:20 +0530)]
staging: wilc1000: rename u32WidsCount to avoid camelCase

Fix "Avoid camleCase" issue reported by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Reviewed-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename strWIDList variable to avoid camelCase
Ajay Singh [Tue, 30 Jan 2018 16:50:29 +0000 (22:20 +0530)]
staging: wilc1000: rename strWIDList variable to avoid camelCase

Fix "Avoid camelCase" issue found by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Reviewed-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename Handle_DelAllSta() and its variable using camelCase
Ajay Singh [Tue, 30 Jan 2018 16:50:28 +0000 (22:20 +0530)]
staging: wilc1000: rename Handle_DelAllSta() and its variable using camelCase

Fix "Avoid camelCase" issue reported by checkpatch.pl script.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Reviewed-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: wilc1000: rename variables using camelCase in host_int_ParseJoinBssParam()
Ajay Singh [Tue, 30 Jan 2018 16:50:27 +0000 (22:20 +0530)]
staging: wilc1000: rename variables using camelCase in host_int_ParseJoinBssParam()

Fix "Avoid CamelCase:" issue reported by checkpatch.pl script.
Rename host_int_ParseJoinBssParam() & its variables using camelCase.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Reviewed-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: vc04_services: merge vchiq_kern_lib.c into vchiq_arm.c
Arnd Bergmann [Fri, 2 Feb 2018 15:01:46 +0000 (16:01 +0100)]
staging: vc04_services: merge vchiq_kern_lib.c into vchiq_arm.c

There are two incompatible definitions of 'vchiq_instance_struct', so
passing them through vchiq_initialise(), vchiq_connect() or another
such interface is broken, as shown by building the driver with link-time
optimizations:

drivers/staging/vc04_services/interface/vchiq_arm/vchiq_if.h:129:0: error: type of 'vchiq_initialise' does not match original declaration [-Werror=lto-type-mismatch]
 extern VCHIQ_STATUS_T vchiq_initialise(VCHIQ_INSTANCE_T *pinstance);

drivers/staging/vc04_services/interface/vchiq_arm/vchiq_kern_lib.c:68:0: note: 'vchiq_initialise' was previously declared here
 VCHIQ_STATUS_T vchiq_initialise(VCHIQ_INSTANCE_T *instance_out)

drivers/staging/vc04_services/interface/vchiq_arm/vchiq_kern_lib.c:68:0: note: code may be misoptimized unless -fno-strict-aliasing is used
drivers/staging/vc04_services/interface/vchiq_arm/vchiq_if.h:131:0: error: type of 'vchiq_connect' does not match original declaration [-Werror=lto-type-mismatch]
 extern VCHIQ_STATUS_T vchiq_connect(VCHIQ_INSTANCE_T instance);

drivers/staging/vc04_services/interface/vchiq_arm/vchiq_kern_lib.c:168:0: note: 'vchiq_connect' was previously declared here
 VCHIQ_STATUS_T vchiq_connect(VCHIQ_INSTANCE_T instance)

It's possible that only one of the two sides actually access the members,
but it's clear that they need to agree on the layout. The easiest way
to achieve this appears to be to merge the two files into one. I tried
moving the structure definition into a shared header first, but ended
up running into too many interdependencies that way.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: vc04_services: remove unused files
Corentin Labbe [Thu, 1 Feb 2018 20:39:03 +0000 (20:39 +0000)]
staging: vc04_services: remove unused files

All thoses files are not used by anybody.
Lets just remove them.

Signed-off-by: Corentin Labbe <clabbe@baylibre.com>
Acked-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: lustre: remove l_wait_event() and related code
NeilBrown [Mon, 12 Feb 2018 23:47:59 +0000 (10:47 +1100)]
staging: lustre: remove l_wait_event() and related code

These macros are no longer used, so they can
be removed.

Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Patrick Farrell <paf@cray.com>
Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: lustre: replace l_wait_event_exclusive_head() with wait_event_idle_exclusive
NeilBrown [Mon, 12 Feb 2018 23:47:59 +0000 (10:47 +1100)]
staging: lustre: replace l_wait_event_exclusive_head() with wait_event_idle_exclusive

This l_wait_event_exclusive_head() will wait indefinitely
if the timeout is zero.  If it does wait with a timeout
and times out, the timeout for next time is set to zero.

The can be mapped to a call to either
 wait_event_idle_exclusive()
or
 wait_event_idle_exclusive_timeout()
depending in the timeout setting.

The current code arranges for LIFO queuing of waiters,
but include/event.h doesn't support that yet.
Until it does, fall back on FIFO with
wait_event_idle_exclusive{,_timeout}().

Reviewed-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: NeilBrown <neilb@suse.com>
Reviewed-by: Patrick Farrell <paf@cray.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: lustre: remove l_wait_event from ptlrpc_set_wait
NeilBrown [Mon, 12 Feb 2018 23:47:59 +0000 (10:47 +1100)]
staging: lustre: remove l_wait_event from ptlrpc_set_wait

This is the last remaining use of l_wait_event().
It is the only use of LWI_TIMEOUT_INTR_ALL() which
has a meaning that timeouts can be interrupted.
Only interrupts by "fatal" signals are allowed, so
introduce l_wait_event_abortable_timeout() to
support this.

Reviewed-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: NeilBrown <neilb@suse.com>
Reviewed-by: Patrick Farrell <paf@cray.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: lustre: use explicit poll loop in ptlrpc_unregister_reply
NeilBrown [Mon, 12 Feb 2018 23:47:59 +0000 (10:47 +1100)]
staging: lustre: use explicit poll loop in ptlrpc_unregister_reply

replace l_wait_event() with wait_event_idle_timeout() and explicit
loop.  This approach is easier to understand.

Reviewed-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: NeilBrown <neilb@suse.com>
Reviewed-by: Patrick Farrell <paf@cray.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: lustre: use explicit poll loop in ptlrpc_service_unlink_rqbd
NeilBrown [Mon, 12 Feb 2018 23:47:59 +0000 (10:47 +1100)]
staging: lustre: use explicit poll loop in ptlrpc_service_unlink_rqbd

Rather an using l_wait_event(), use wait_event_idle_timeout()
with an explicit loop so it is easier to see what is happening.

Reviewed-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: NeilBrown <neilb@suse.com>
Reviewed-by: Patrick Farrell <paf@cray.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: lustre: improve waiting in sptlrpc_req_refresh_ctx
NeilBrown [Mon, 12 Feb 2018 23:47:59 +0000 (10:47 +1100)]
staging: lustre: improve waiting in sptlrpc_req_refresh_ctx

Replace l_wait_event with wait_event_idle_timeout() and call the
handler function explicitly.  This makes it more clear
what is happening.

Reviewed-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: NeilBrown <neilb@suse.com>
Reviewed-by: Patrick Farrell <paf@cray.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: lustre: use wait_event_idle_timeout in ptlrpcd()
NeilBrown [Mon, 12 Feb 2018 23:47:59 +0000 (10:47 +1100)]
staging: lustre: use wait_event_idle_timeout in ptlrpcd()

We can replace l_wait_event() with
wait_event_idle_timeout() here providing we call the
timeout function when wait_event_idle_timeout() returns zero.

As ptlrpc_expired_set() returns 1, the l_wait_event() aborts of the
first timeout.

Reviewed-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: NeilBrown <neilb@suse.com>
Reviewed-by: Patrick Farrell <paf@cray.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: lustre: make polling loop in ptlrpc_unregister_bulk more obvious
NeilBrown [Mon, 12 Feb 2018 23:47:59 +0000 (10:47 +1100)]
staging: lustre: make polling loop in ptlrpc_unregister_bulk more obvious

This use of l_wait_event() is a polling loop that re-checks
every second.  Make this more obvious with a while loop
and wait_event_idle_timeout().

Reviewed-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: NeilBrown <neilb@suse.com>
Reviewed-by: Patrick Farrell <paf@cray.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: lustre: remove back_to_sleep()
NeilBrown [Mon, 12 Feb 2018 23:47:59 +0000 (10:47 +1100)]
staging: lustre: remove back_to_sleep()

When 'back_to_sleep()' is passed as the 'timeout' function,
the effect is to wait indefinitely for the event, polling
once after the timeout.
If LWI_ON_SIGNAL_NOOP is given, then after the timeout
we allow fatal signals to interrupt the wait.

Make this more obvious in both places "back_to_sleep()" is
used but using two explicit sleeps.

The code in ptlrpcd_add_req() looks odd - why not just have one
wait_event_idle()?  However I believe this is a faithful
transformation of the existing code.

Reviewed-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: NeilBrown <neilb@suse.com>
Reviewed-by: Patrick Farrell <paf@cray.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>