Commit Graph

707487 Commits

Author SHA1 Message Date
Gustavo A. R. Silva 116d8eea59 staging: typec: tcpci: mark expected switch fall-through in tcpci_to_typec_cc
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:42:28 +02:00
Colin Ian King bc7d21ca2c staging: wilc1000: replace redundant computations with 0
Shifting and masking strHostIfSetMulti->enabled is redundant since
enabled is a bool and so all the shifted and masked values will be
zero. Replace them with zero to simplify the code.

Detected by CoverityScan, CID#1339458 ("Bad shift operation") and
CID#1339506 ("Operands don't affect result").

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:42:28 +02:00
Sebastian Andrzej Siewior 2d10b85704 greybus: audio: don't inclide rwlock.h directly.
rwlock.h should not be included directly. Instead linux/splinlock.h
should be included. One thing it does is to break the RT build.

Cc: Vaibhav Agarwal <vaibhav.sr@gmail.com>
Cc: Johan Hovold <johan@kernel.org>
Cc: Alex Elder <elder@kernel.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: greybus-dev@lists.linaro.org
Cc: devel@driverdev.osuosl.org
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Reviewed-by: Mark Greer <mgreer@animalcreek.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:42:28 +02:00
Jia-Ju Bai 42c8eb3f6e vt6655: Fix a possible sleep-in-atomic bug in vt6655_suspend
The driver may sleep under a spinlock, and the function call path is:
vt6655_suspend (acquire the spinlock)
  pci_set_power_state
    __pci_start_power_transition (drivers/pci/pci.c)
      msleep --> may sleep

To fix it, pci_set_power_state is called without having a spinlock.

This bug is found by my static analysis tool and my code review.

Signed-off-by: Jia-Ju Bai <baijiaju1990@163.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:42:28 +02:00
Branislav Radocaj 6e047ac922 Staging: bcm2048 fix bare use of 'unsigned' in radio-bcm2048.c
This is a patch to the radio-bcm2048.c file that fixes up
a warning found by the checkpatch.pl tool.

Signed-off-by: Branislav Radocaj <branislav@radocaj.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:42:27 +02:00
Gustavo A. R. Silva a784e3ebdd staging: greybus: mark expected switch fall-through in check_urb_status
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Acked-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:21:27 +02:00
Gustavo A. R. Silva ddb35ab8d9 staging: vt6656: card: mark expected switch fall-throughs
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:21:26 +02:00
Gustavo A. R. Silva a14731129a staging: r8822be: mark expected switch fall-throughs
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:21:26 +02:00
Gustavo A. R. Silva 583d6a93a5 staging: ks7010: ks_wlan_net: mark expected switch fall-throughs
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Addresses-Coverity-ID: 1364489
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:21:26 +02:00
Kees Cook 1f233190f1 staging/wilc1000: Convert timers to use timer_setup()
As part of removing the timer_list.data field, this converts the wilc1000
driver to using from_timer and an explicit per-timer data field, since
there doesn't appear to be a way to sanely resolve vif from hif_drv.

Cc: Aditya Shankar <aditya.shankar@microchip.com>
Cc: Ganesh Krishna <ganesh.krishna@microchip.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: linux-wireless@vger.kernel.org
Cc: devel@driverdev.osuosl.org
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:18:31 +02:00
Kees Cook 36aeebd485 staging: rtl8712: Convert timers to use timer_setup()
In preparation for unconditionally passing the struct timer_list pointer to
all timer callbacks, switch to using the new timer_setup() and from_timer()
to pass the timer pointer explicitly.

Cc: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Florian Schilhabel <florian.c.schilhabel@googlemail.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Tejaswini Poluri <tejaswinipoluri3@gmail.com>
Cc: Scott Matheina <scott@matheina.com>
Cc: Varsha Rao <rvarsha016@gmail.com>
Cc: Julia Lawall <julia.lawall@lip6.fr>
Cc: Aleksey Kurbatov <alkbt@yandex.ru>
Cc: Vijai Kumar K <vijaikumar.kanagarajan@gmail.com>
Cc: Wei Yongjun <weiyongjun1@huawei.com>
Cc: "Raphaël Beamonte" <raphael.beamonte@gmail.com>
Cc: Jannik Becher <becher.jannik@gmail.com>
Cc: Joseph Wright <rjosephwright@gmail.com>
Cc: devel@driverdev.osuosl.org
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:18:31 +02:00
Kees Cook e8c5027d85 staging: dgnc: Convert timers to use timer_setup()
In preparation for unconditionally passing the struct timer_list pointer to
all timer callbacks, switch to using the new timer_setup() and from_timer()
to pass the timer pointer explicitly.

Cc: Lidza Louina <lidza.louina@gmail.com>
Cc: Mark Hounschell <markh@compro.net>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: driverdev-devel@linuxdriverproject.org
Cc: devel@driverdev.osuosl.org
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:18:31 +02:00
Kees Cook b28bbb7362 staging/fwserial: Convert timers to use timer_setup()
In preparation for unconditionally passing the struct timer_list pointer to
all timer callbacks, switch to using the new timer_setup() and from_timer()
to pass the timer pointer explicitly. Also removes redundant initialization
of fw transaction timer, which already gets initialized per-transaction.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Bhumika Goyal <bhumirks@gmail.com>
Cc: devel@driverdev.osuosl.org
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:18:31 +02:00
Frank A. Cancio Bello b728b54fd5 staging: net: netlogic: Fix alignment issue
Fix alignment to match open parenthesis and comply in that way with the
preferred coding style for the linux kernel.

Credits to 'checkpatch'. The 'checkpatch' message was:
'CHECK: Alignment should match open parenthesis'

Signed-off-by: Frank A. Cancio Bello <frank@generalsoftwareinc.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:17:14 +02:00
Mihaela Muraru 96591eaef2 staging: vc04_services: Use __func__ instead of function name
Use identifier __func__ instead of the name of the function.

Issue found by checkpatch.pl.

Signed-off-by: Mihaela Muraru <mihaela.muraru21@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:15:34 +02:00
Mihaela Muraru 2ffd3860a8 staging: vc04_services: Fix comment block coding style
Remove the unnecessary '*' character and align the comment block to fit
the coding style used by linux kernel organization.

Signed-off-by: Mihaela Muraru <mihaela.muraru21@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:15:34 +02:00
Gustavo A. R. Silva 95f539b653 staging: vc04_services: vchiq_core: mark expected switch fall-through
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Acked-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:15:34 +02:00
Shreeya Patel 1813b3c3fb Staging: irda: Remove trailing whitespace errors
Remove trailing whitespace checkpatch errors.

Signed-off-by: Shreeya Patel <shreeya.patel23498@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:12:27 +02:00
Icenowy Zheng 7aebff11af staging: rtl8723bs: hide "nolinked power save" info when not debugging
Currently the rtl8723bs driver will print "nolinked power save enter"
and "nolinked power save leave" per minute if it's not connected to any
network.

These messages are meaningless and annoying to regular users.

Hide them when it's not debugging.

Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:10:36 +02:00
Gustavo A. R. Silva 76ec4e8ed4 staging: rtl8723bs: rtw_mlme_ext: mark expected switch fall-through
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:10:36 +02:00
Masanari Iida d67051abd2 staging: rtl8723bs: Fix typos in printk
This patch fixes typos found in rtl8723bs_xmit.c and odm_DIG.c.

Signed-off-by: Masanari Iida <standby24x7@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:10:36 +02:00
Aishwarya Pant 42b3b621d9 staging: rtl8723bs: remove implicit int->bool conversions
Implicit type conversions are bad; they hinder readability of code and
have potential to cause bugs. Here the variable wait_ack is always
supplied a bool value while in function declarations it is defined as an
int type. Fix it by defining wait_ack a bool type in all usages.

Signed-off-by: Aishwarya Pant <aishpant@gmail.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:10:36 +02:00
Aastha Gupta b739ea4136 staging: rtl8723bs: remove useless variable rtw_AcceptAddbaReq
rtw_AcceptAddbaReq is a static variable, it is set once and never
modified. It is referenced only once, to assign its value to a member
of struct registry_priv.

Remove the variable, and move the meaningful part of the comment
near the declaration of the relevant field of struct registry_priv.

Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:07:49 +02:00
Aastha Gupta 2646633f9e staging: rtl8723bs: rename camelcase bAcceptAddbaReq
bAcceptAddbaReq uses camelcase which is not according to Linux kernel
coding style.
There is a 'bAcceptAddbaReq' field both in struct mlme_ext_info and
in struct registry_priv.Rename both of them.

Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:07:49 +02:00
Aastha Gupta 4c249545ab staging: rtl8723bs: convert type to bool
Here the variable bips_processing is always supplied a bool value
while inside struct definition it is defined as an uint type.
Fix it by defining bips_processing a bool type.

Also a restore_iqk_rst = (pwrpriv->bips_processing == true) is same
as restore_iqk_rst = pwrpriv->bips_processing

Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:07:49 +02:00
Aastha Gupta dec77f8afe staging: rtl8723bs: Change type to bool
res and Match have only either 'true' or 'false' values.
So making them of type bool for better readability of code.

Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:07:49 +02:00
Aastha Gupta 77537ebae2 staging: rtl8723bs: remove unused variables
It seems these two operations are just dead code. The values of these
variables are not used subsequently.

Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:07:49 +02:00
Aastha Gupta 95b3b42385 staging: rtl8723bs: remove ternary operators in assignmet statments
Remove unnecessary ternary operators in assignments statments.

This patch is with the help of following Coccinelle script:

@@
expression a, b, c;
binary operator op = {==, !=, <=, >=, <, >, &&, ||};
@@

c =
- (a op b) ? true : false
+ a op b

Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:07:49 +02:00
Harsha Sharma 33536569fa staging: rtl8723bs: Add space after ','
Space is required after ',' according to linux-kernel coding style.

Signed-off-by: Harsha Sharma <harshasharmaiitr@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:04:29 +02:00
Srishti Sharma 512bbd7bbf Staging: rtl8723bs: core: rtw_cmd: Remove cast to pointer types in kfree
The cast to pointer types in kfree is not needed and can be dropped.
This was done using the following semantic patch by coccinelle,
except kfree((unsigned char*) pcmd->parmbuf) which was transformed by
hand because coccinelle didn't have enough type information.

@r@
type T,P;
T* x;
@@

kfree(
-(P *)
x )

Signed-off-by: Srishti Sharma <srishtishar@gmail.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 16:04:29 +02:00
Alfonso Lima Astor 8d8825b420 staging: fbtft: differentiate between buffer and data types to fix sparse warning
sparse was complaning about an incorrect type cast:
drivers/staging/fbtft/fbtft-bus.c:60:1: warning: incorrect type in assignment (different base types)
drivers/staging/fbtft/fbtft-bus.c:60:1:    expected unsigned short [unsigned] [short] [usertype] <noident>
drivers/staging/fbtft/fbtft-bus.c:60:1:    got restricted __be16 [usertype] <noident>
drivers/staging/fbtft/fbtft-bus.c:60:1: warning: incorrect type in assignment (different base types)
drivers/staging/fbtft/fbtft-bus.c:60:1:    expected unsigned short [unsigned] [short] [usertype] <noident>
drivers/staging/fbtft/fbtft-bus.c:60:1:    got restricted __be16 [usertype] <noident>

The solution is to add an extra parameter to the macro to
differentiate between buffer type and data type.

Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Alfonso Lima Astor <alfonsolimaastor@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:58:33 +02:00
Aastha Gupta 4aca3ca4b7 staging: fbtft: remove unnecessary parantheses around assignment
Parentheses are not needed around the right hand side of an assignment.
This patch is done using Coccinelle:

@@
expression a, b;
@@

b =
-(
a
-)

Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:58:33 +02:00
Marcin Ciupak db8c7f2b64 staging: pi433: rf69.c style fix - space before asterisk
This patch fixes the following checkpatch.pl error:

ERROR: "(foo*)" should be "(foo *)"

in rf69.c file as requested by TODO file.

Additionally some style warnings remain valid here and could be fixed by
another patch.

Signed-off-by: Marcin Ciupak <marcin.s.ciupak@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:56:32 +02:00
Marcin Ciupak b3fbc42249 staging: pi433: rf69.c style fix - code indent should use tabs
This patch fixes the following checkpatch.pl error:

ERROR: code indent should use tabs where possible

in rf69.c file as requested by TODO file.

Additionally some style warnings remain valid here and could be fixed by
another patch.

Signed-off-by: Marcin Ciupak <marcin.s.ciupak@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:56:32 +02:00
Marcin Ciupak 329822a02f staging: pi433: rf69.c style fix - spaces before/after
his patch fixes the following checkpatch.pl errors:

ERROR: space prohibited after that open parenthesis '('
ERROR: space prohibited before that ',' (ctx:WxV)
ERROR: space prohibited before that close parenthesis ')'
ERROR: space required after that ',' (ctx:VxV)
ERROR: space required before the open parenthesis '('

in rf69.c file as requested by TODO file.

Additionally some style warnings remain valid here and could be fixed by
another patch.

Signed-off-by: Marcin Ciupak <marcin.s.ciupak@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:56:32 +02:00
Marcin Ciupak 308d32efc4 staging: pi433: rf69.c style fix - spaces required around
This patch fixes the following checkpatch.pl errors:

ERROR: spaces required around that '+=' (ctx:WxV)
ERROR: spaces required around that '=' (ctx:VxV)
ERROR: spaces required around that '<' (ctx:VxV)

in rf69.c file as requested by TODO file.

Additionally some style warnings remain valid here and could be fixed by
another patch.

Signed-off-by: Marcin Ciupak <marcin.s.ciupak@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:56:32 +02:00
Marcin Ciupak 4a74749a50 staging: pi433: rf69.c style fix - trailing statements
This patch fixes the following checkpatch.pl error:

ERROR: trailing statements should be on next line

in rf69.c file as requested by TODO file.

Note:
ERROR: spaces required around that '=' (ctx:VxV)
remains valid here and is going to be fixed by the next patch in set.

Additionally some style warnings remain valid here and could be fixed by
another patch.

Signed-off-by: Marcin Ciupak <marcin.s.ciupak@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:56:32 +02:00
Srishti Sharma 69af5d92da Staging: pi433: Fix the position of brace after if
Fix the position of the brace after if when it is on the next line.
Done using the following semantic patch by coccinelle.

@r1@
position p1, p2;
@@

if(...)@p1 {@p2
...
}

@script: python r2@
p1 << r1.p1;
p2 << r1.p2;
@@

l1 = int (p1[0].line)
l2 = int (p2[0].line)
c1 = int (p1[0].column_end)
c2 = int (p2[0].column)

if l1 == l2 and c1+1 == c2:
        cocci.include_match(False)

@r3@
position r1.p1, r1.p2;
@@

if(...
- )@p1
-{@p2
+) {
...
}

Signed-off-by: Srishti Sharma <srishtishar@gmail.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:55:09 +02:00
Frank A. Cancio Bello 38b2b2e822 staging: rtlwifi: phydm: Remove useless parentheses
Remove unnecessary parentheses to comply with preferred coding style for
the linux kernel and avoid the following checkpatch's message:
'CHECK: Unnecessary parentheses around'.

Credits to checkpatch.

Signed-off-by: Frank A. Cancio Bello <frank@generalsoftwareinc.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:53:50 +02:00
Frank A. Cancio Bello a221cb0911 staging: rtlwifi: Remove unnecessary parentheses
Remove unnecessary parentheses to comply with preferred coding style for
the linux kernel and avoid the following checkpatch's message:
'CHECK: Unnecessary parentheses around'.

Credits to checkpatch.

Signed-off-by: Frank A. Cancio Bello <frank@generalsoftwareinc.com>
Acked-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:53:50 +02:00
Larry Finger df0f0e71fc rtlwifi: Fix typo in if ... else if ... else construct
The kbuild test robot reports two conditions with no effect (if == else).
These are the result of copy and paste typographical errors.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Ping-Ke Shih <pkshih@realtek.com>
Cc: Yan-Hsuan Chuang <yhchuang@realtek.com>
Cc: Birming Chiu <birming@realtek.com>
Cc: Shaofu <shaofu@realtek.com>
Cc: Steven Ting <steventing@realtek.com>
Cc: kbuild-all@01.org
Cc: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:53:50 +02:00
Gustavo A. R. Silva 7d2e2a881c staging: rtlwifi: halmac: mark expected switch fall-through
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:53:50 +02:00
Gustavo A. R. Silva 640019bba4 staging: rtlwifi: mark expected switch fall-through in rtl_make_smps_action
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:53:50 +02:00
Kees Cook f8af6a3233 staging: rtlwifi: Convert timers to use timer_setup()
In preparation for unconditionally passing the struct timer_list pointer to
all timer callbacks, switch to using the new timer_setup() and from_timer()
to pass the timer pointer explicitly. Also drops unused odm timer code.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Kalle Valo <kvalo@codeaurora.org>
Cc: Ping-Ke Shih <pkshih@realtek.com>
Cc: shaofu <shaofu@realtek.com>
Cc: devel@driverdev.osuosl.org
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:52:39 +02:00
Anton Dozenko 682455befd staging: comedi: adv_pci_dio: update for PCI-1761
Advantech PCI-1761 device support to the driver adv_pci_dio has been
added. Patch has been successfully tested on a real card (8 digital
outs, 8 digital inputs).

Signed-off-by: Anton Dozenko <anton.dozenko@gmail.com>
Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:45:48 +02:00
Arvind Yadav 526739265e staging: comedi: dt282x: fix IRQ assignment for dev->irq.
Here, dev->irq is not assigned with irq. comedi_legacy_detach()
is using dev->irq for release irq and dt282x_attach() is using dev->irq
for initialize comedi_subdevice.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:45:48 +02:00
Gustavo A. R. Silva 0cb7e343de staging: comedi: s526: mark expected switch fall-through
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:45:48 +02:00
Kees Cook e44d4907f8 staging/comedi: Convert timers to use timer_setup()
In preparation for unconditionally passing the struct timer_list pointer
to all timer callbacks, switch to using the new timer_setup() and
from_timer() to pass the timer pointer explicitly. Adds pointer back to
comedi device from private struct.

Cc: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: devel@driverdev.osuosl.org
Signed-off-by: Kees Cook <keescook@chromium.org>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:45:48 +02:00
Gustavo A. R. Silva f67ffd6158 staging: rtl8192e: mark expected switch fall-through
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:44:39 +02:00
Mihaela Muraru c476b2ec70 staging: rtl8192e: Use __func__ instead of function name
Use identifier __func__ instead of the name of the function.

Issue found by checkpatch.pl.

Signed-off-by: Mihaela Muraru <mihaela.muraru21@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18 15:44:39 +02:00