Commit Graph

855396 Commits

Author SHA1 Message Date
YueHaibing b0d08afda8 staging: rtl8723bs: remove set but not used variable 'FirstConnect'
Fixes gcc '-Wunused-but-set-variable' warning:

drivers/staging/rtl8723bs/hal/odm.c: In function 'odm_RSSIMonitorCheckCE':
drivers/staging/rtl8723bs/hal/odm.c:1258:7: warning:
 variable 'FirstConnect' set but not used [-Wunused-but-set-variable]

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Link: https://lore.kernel.org/r/20190731140903.304-1-yuehaibing@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-01 18:38:08 +02:00
YueHaibing d698b0a096 staging: rtl8723bs: remove set but not used variables 'prspbuf' and 'auth'
Fixes gcc '-Wunused-but-set-variable' warning:

drivers/staging/rtl8723bs/core/rtw_cmd.c: In function rtw_cmd_thread:
drivers/staging/rtl8723bs/core/rtw_cmd.c:405:16: warning: variable prspbuf set but not used [-Wunused-but-set-variable]
drivers/staging/rtl8723bs/core/rtw_cmd.c: In function rtw_joinbss_cmd:
drivers/staging/rtl8723bs/core/rtw_cmd.c:771:6: warning: variable auth set but not used [-Wunused-but-set-variable]

They are never used, so can be removed.

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Link: https://lore.kernel.org/r/20190731135953.16784-1-yuehaibing@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-01 18:38:08 +02:00
Navid Emamdoost 09acf29c82 staging: rtl8192u: null check the kzalloc
In rtl8192_init_priv_variable allocation for priv->pFirmware may fail,
so a null check is necessary.priv->pFirmware is accessed later in
rtl8192_adapter_start. I added the check and made appropriate changes
to propagate the errno to the caller.

Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com>

Link: https://lore.kernel.org/r/20190731141925.29268-1-navid.emamdoost@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-01 18:38:08 +02:00
YueHaibing 572d8be0d4 staging: rtl8723bs: remove set but not used variable 'bEEPROMCheck'
Fixes gcc '-Wunused-but-set-variable' warning:

drivers/staging/rtl8723bs//hal/odm_CfoTracking.c: In function 'odm_SetCrystalCap':
drivers/staging/rtl8723bs//hal/odm_CfoTracking.c:14:7: warning:
 variable 'bEEPROMCheck' set but not used [-Wunused-but-set-variable]

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Link: https://lore.kernel.org/r/20190801015307.44572-1-yuehaibing@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-01 18:31:15 +02:00
Colin Ian King 9ba2986ff5 staging: rtl8188eu: remove redundant assignment to variable rtstatus
Variable rtstatus is being initialized with a value that is never read
and rtstatus is being re-assigned a little later on. The assignment is
redundant and hence can be removed.  Also, make rtstatus a bool to
match the function return type.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20190731094736.28637-1-colin.king@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-31 13:37:13 +02:00
Chris Chiu f7d120d9e0 staging: rtl8723bs: indicate disconnection when disconnecting
The Realtek RTL8723BS only connects successfully at the very first
time, then it always fails attempting to switch to another AP. No
authentication/association observed from the air capture for each
attempt due to the cfg80211 believes the device is still connected.

Fix this by forcing to indicate the disconnection events during
disconnection so the cfg80211_connect can connect to a different
AP without problem.

Signed-off-by: Chris Chiu <chiu@endlessm.com>
Link: https://lore.kernel.org/r/20190731103517.66903-1-chiu@endlessm.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-31 13:37:13 +02:00
Greg Kroah-Hartman 9a675a13c3 Revert "staging: kpc2000: Convert put_page() to put_user_page*()"
This reverts commit 8e7cb7352e.

Bharath writes:
	Could you drop this patch from the staging-next tree? This is
	because John is making some changes to the put_user_page*()
	functions. He has submitted a patch recently removing
	put_user_page_dirty() function which is being used in this
	patch. This might break the kernel build if John's patch gets
	merged in.

	I ll submit a patch once the put_user_page*() apis are fixed.

Reported-by: Bharath Vedartham <linux.bhar@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-31 07:28:04 +02:00
Stephen Boyd 04d15d5cad staging: Remove dev_err() usage after platform_get_irq()
We don't need dev_err() messages when platform_get_irq() fails now that
platform_get_irq() prints an error message itself when something goes
wrong. Let's remove these prints with a simple semantic patch.

// <smpl>
@@
expression ret;
struct platform_device *E;
@@

ret =
(
platform_get_irq(E, ...)
|
platform_get_irq_byname(E, ...)
);

if ( \( ret < 0 \| ret <= 0 \) )
{
(
-if (ret != -EPROBE_DEFER)
-{ ...
-dev_err(...);
-... }
|
...
-dev_err(...);
)
...
}
// </smpl>

While we're here, remove braces on if statements that only have one
statement (manually).

Signed-off-by: Stephen Boyd <swboyd@chromium.org>
Link: https://lore.kernel.org/r/20190730181557.90391-43-swboyd@chromium.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 20:50:04 +02:00
Ioana Ciornei 939878fe06 staging: fsl-dpaa2/ethsw: add .ndo_fdb[add|del] callbacks
Add the .ndo_fdb_[add|del] callbacks so that FDB entries not associated
with a master device still end up offloaded.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Link: https://lore.kernel.org/r/1564416712-16946-6-git-send-email-ioana.ciornei@nxp.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 18:46:54 +02:00
Ioana Ciornei e1e6a04d97 staging: fsl-dpaa2/ethsw: check added_by_user flag
We do not want to offload FDB entries if not added by user as static
entries. Check the added_by_user flag and break if not set.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Link: https://lore.kernel.org/r/1564416712-16946-5-git-send-email-ioana.ciornei@nxp.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 18:46:54 +02:00
Ioana Ciornei de01ac2e49 staging: fsl-dpaa2/ethsw: add .ndo_fdb_dump callback
Implement the .ndo_fdb_dump callback for the switch net devices.  The
list of all offloaded FDB entries is retrieved through the dpsw_fdb_dump()
firmware call. Filter the entries by the switch port on which the
callback was called and for each of them create a new neighbour message.
Also remove the requirement from the TODO list.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Link: https://lore.kernel.org/r/1564416712-16946-4-git-send-email-ioana.ciornei@nxp.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 18:46:54 +02:00
Ioana Ciornei b380a4e6e5 staging: fsl-dpaa2/ethsw: notify switchdev of offloaded entry
Notify switchdev in case the FDB entry was successfully offloaded.
This will help users to make the distinction between entries known to
the HW switch and those that are held only on the software bridge.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Link: https://lore.kernel.org/r/1564416712-16946-3-git-send-email-ioana.ciornei@nxp.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 18:46:53 +02:00
Ioana Ciornei e2724c77ca staging: fsl-dpaa2/ethsw: remove unused structure
The dpsw_cfg structure is only used when creating a new dpsw DPAA2
object. In the DPAA2 architecture, objects are created at boot time by
the firmware or dynamically from userspace while drivers on the fsl-mc
bus only configure those objects.
Remove the structure since it's of no use.

Signed-off-by: Ioana Ciornei <ioana.ciornei@nxp.com>
Link: https://lore.kernel.org/r/1564416712-16946-2-git-send-email-ioana.ciornei@nxp.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 18:46:53 +02:00
Michael Straube 2c0e81ec21 staging: rtl8188eu: cleanup comparsion to NULL in usb_halinit.c
Use if(!x) instead of if(x == NULL).
Reported by checkpatch.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Link: https://lore.kernel.org/r/20190726180448.2290-6-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:58:23 +02:00
Michael Straube 1f5bfba56f staging: rtl8188eu: add spaces around '-' and '*' in usb_halinit.c
Add spaces around '-' and '*' to improve readability and follow kernel
coding style. Reported by checkpatch.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Link: https://lore.kernel.org/r/20190726180448.2290-5-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:58:23 +02:00
Michael Straube 8f4686cb7d staging: rtl8188eu: add spaces around '<<' and '>>' in usb_halinit.c
Add spaces around '<<' and '>>' to improve readability and follow
kernel coding style. Reported by checkpatch.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Link: https://lore.kernel.org/r/20190726180448.2290-4-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:58:22 +02:00
Michael Straube fe6c0d20bb staging: rtl8188eu: add spaces around '|' in usb_halinit.c
Add spaces around '|' to improve readability and follow kernel
coding style. Reported by checkpatch.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Link: https://lore.kernel.org/r/20190726180448.2290-3-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:58:22 +02:00
Michael Straube 6d7ff73611 staging: rtl8188eu: add spaces around '&' in usb_halinit.c
Add spaces around '&' to improve readability and follow kernel
coding style. Reported by checkpatch.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Link: https://lore.kernel.org/r/20190726180448.2290-2-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:58:22 +02:00
Michael Straube 3455db0e05 staging: rtl8188eu: add spaces around '+' in usb_halinit.c
Add spaces around '+' to improve readability and follow kernel
coding style. Reported by checkpatch.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Link: https://lore.kernel.org/r/20190726180448.2290-1-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:58:22 +02:00
Adham Abozaeid 25f12201a4 staging: wilc1000: remove manual sleep mode
manual sleep mode was used to put the wilc1000 chip in sleep while in
disconnected state. This is taken care of in the firmware

Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
Link: https://lore.kernel.org/r/20190725213125.2810-7-adham.abozaeid@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:56:46 +02:00
Adham Abozaeid 7e0cf3e3bf staging: wilc1000: apply power management regardless of open interfaces
Don't ignore power management if 2 interfaces are open

Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
Link: https://lore.kernel.org/r/20190725213125.2810-6-adham.abozaeid@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:56:46 +02:00
Adham Abozaeid ded11ab181 staging: wilc1000: avoid overriding powersave state
Don't override powersave state with respect to the open interfaces and
let the firmware take care of when it's appropriate to do so

Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
Link: https://lore.kernel.org/r/20190725213125.2810-5-adham.abozaeid@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:56:45 +02:00
Adham Abozaeid 5a28d3fd40 staging: wilc1000: remove unused members
remove obtaining_ip from struct wilc_vif

Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
Link: https://lore.kernel.org/r/20190725213125.2810-4-adham.abozaeid@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:56:45 +02:00
Adham Abozaeid 98af3e7ed6 staging: wilc1000: remove ip timeout timer
during_ip_timer is not required after removing the code that disables
powersave while the ip is being obtained.
Its handler clear_during_ip is also removed

Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
Link: https://lore.kernel.org/r/20190725213125.2810-3-adham.abozaeid@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:56:45 +02:00
Adham Abozaeid f68dc00ee7 staging: wilc1000: remove inetaddr notifier
Driver registers an inetaddr notifier to disable powersave while the ip
address is being obtained which should be controlled only by cfg80211.

Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
Link: https://lore.kernel.org/r/20190725213125.2810-2-adham.abozaeid@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:56:45 +02:00
Bharath Vedartham 8e7cb7352e staging: kpc2000: Convert put_page() to put_user_page*()
For pages that were retained via get_user_pages*(), release those pages
via the new put_user_page*() routines, instead of via put_page().

This is part a tree-wide conversion, as described in commit fc1d8e7cca
("mm: introduce put_user_page*(), placeholder versions").

Cc: Ira Weiny <ira.weiny@intel.com>
Cc: John Hubbard <jhubbard@nvidia.com>
Cc: Jérôme Glisse <jglisse@redhat.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Matt Sickler <Matt.Sickler@daktronics.com>
Cc: devel@driverdev.osuosl.org
Cc: linux-kernel@vger.kernel.org
Cc: linux-mm@kvack.org
Reviewed-by: John Hubbard <jhubbard@nvidia.com>
Signed-off-by: Bharath Vedartham <linux.bhar@gmail.com>
Link: https://lore.kernel.org/r/1564058658-3551-1-git-send-email-linux.bhar@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:54:48 +02:00
Colin Ian King 36475456f3 staging: rtl8188eu: remove redundant assignment to rtstatus
Variable rtstatus is initialized to a value that is never read and it
is re-assigned later. The initialization is redundant and can be
removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20190726124803.11349-1-colin.king@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:54:48 +02:00
Abhinav Jain 91e590851f Staging: rtl8192e: fixed a function prototype definition issue
Added the identifier name in the function prototype definition.

Signed-off-by: Abhinav Jain <crazypsychild@gmail.com>
Link: https://lore.kernel.org/r/20190726190146.10875-1-ubuntu@ip-172-31-129-142.ec2.internal
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:54:48 +02:00
Michael Straube c47f77eed0 staging: rtl8188eu: replace hal_EfusePgCheckAvailableAddr()
Function hal_EfusePgCheckAvailableAddr() contains just a single if
test. Remove the function and replace the call to it with the if test.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20190725170922.16465-1-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:52:05 +02:00
Christophe JAILLET 9d6b3ee001 Staging: fbtft: Fix some typo. pdc8544 --> pcd8544
The driver is related to 'pcd8544'.
However, 2 strings are about pdc8544 (c and d switched)
Fix it.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Link: https://lore.kernel.org/r/20190725183856.17616-1-christophe.jaillet@wanadoo.fr
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:52:04 +02:00
Sebastian Andrzej Siewior a20eefaee6 staging: most: Use DEFINE_SPINLOCK() instead of struct spinlock
For spinlocks the type spinlock_t should be used instead of "struct
spinlock".

Use DEFINE_SPINLOCK() and spare the run time initialization

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lkml.kernel.org/r/20190704153803.12739-5-bigeasy@linutronix.de
Link: https://lore.kernel.org/r/alpine.DEB.2.21.1907261319100.1791@nanos.tec.linutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:52:04 +02:00
Jerry Lin 5f251e986d staging: olpc_dcon: Remove TODO item
All uses of old GPIO API have been converted to new API.
This item can be removed from TODO file.

Signed-off-by: Jerry Lin <wahahab11@gmail.com>
Link: https://lore.kernel.org/r/20190729023544.GA25930@compute1
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:52:04 +02:00
YueHaibing db0e6a573e staging: vc04_services: fix unused-but-set-variable warning
Fix gcc used-but-set-variable warning:

drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c: In function vchiq_release_internal:
drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c:2827:16: warning:
 variable local_entity_uc set but not used [-Wunused-but-set-variable]
drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c:2827:6: warning:
 variable local_uc set but not used [-Wunused-but-set-variable]

Remove the unused variables 'local_entity_uc' and 'local_uc'

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Acked-by: Stefan Wahren <wahrenst@gmx.net>
Link: https://lore.kernel.org/r/20190727013524.33168-1-yuehaibing@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:52:04 +02:00
YueHaibing 149726d3d7 staging: rtl8723bs: os_dep: remove two set but not used variables
Fixes gcc '-Wunused-but-set-variable' warning:

drivers/staging/rtl8723bs//os_dep/osdep_service.c: In function 'rtw_buf_free':
drivers/staging/rtl8723bs//os_dep/osdep_service.c:321:6: warning:
 variable 'ori_len' set but not used [-Wunused-but-set-variable]
drivers/staging/rtl8723bs//os_dep/ioctl_linux.c: In function 'rtw_ioctl_wext_private':
drivers/staging/rtl8723bs//os_dep/ioctl_linux.c:4915:6: warning:
 variable 'num_priv' set but not used [-Wunused-but-set-variable]

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Link: https://lore.kernel.org/r/20190726140959.15008-1-yuehaibing@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:52:03 +02:00
YueHaibing 30833b4b4b staging: rtl8723bs: remove set but not used variable 'pszBBRegMpFile'
Fixes gcc '-Wunused-but-set-variable' warning:

drivers/staging/rtl8723bs/hal/rtl8723b_phycfg.c: In function phy_BB8723b_Config_ParaFile:
drivers/staging/rtl8723bs/hal/rtl8723b_phycfg.c:436:77:
 warning: variable pszBBRegMpFile set but not used [-Wunused-but-set-variable]

It is never used so can be removed.

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Link: https://lore.kernel.org/r/20190726140734.39564-1-yuehaibing@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:52:03 +02:00
YueHaibing 07ca9aa4a4 staging: rtl8723bs: remove set but not used variable 'bWifiBusy'
Fixes gcc '-Wunused-but-set-variable' warning:

 In function halbtc8723b1ant_TdmaDurationAdjustForAcl:
drivers/staging/rtl8723bs/hal/HalBtc8723b1Ant.c:1761:7: warning:
 variable bWifiBusy set but not used [-Wunused-but-set-variable]

It is never used so can be removed.

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Link: https://lore.kernel.org/r/20190726140321.19200-1-yuehaibing@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-30 09:52:03 +02:00
J. Bruce Fields e59fc52529 staging: rtl8192*: display ESSIDs using %pE
Everywhere else in the kernel ESSIDs are printed using %pE, and I can't
see why there should be an exception here.

Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Link: https://lore.kernel.org/r/1562799574-13315-1-git-send-email-bfields@redhat.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 14:38:52 +02:00
Hariprasad Kelam 0f073df7e7 staging: rtl8723bs: hal: Remove unneeded variable pU1Tmp
Both pu8 and pU1Tmp are of same data type u8. So replace pU1Tmp with u8.

Signed-off-by: Hariprasad Kelam <hariprasad.kelam@gmail.com>
Link: https://lore.kernel.org/r/20190725032325.GA16473@hari-Inspiron-1545
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 10:01:37 +02:00
Nishka Dasgupta 4da947b27c staging: rtl8723bs: Remove unused function prototype ODM_SetAntenna()
Remove unused function prototype ODM_SetAntenna.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190725052645.2372-9-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:59:40 +02:00
Nishka Dasgupta f79670abd5 staging: rtl8723bs: Replace function ODM_TXPowerTrackingCheck()
Remove function ODM_TXPowerTrackingCheck as all it does is call
odm_TXPowerTrackingCheckCE.
Rename odm_TXPowerTrackingCheckCE to ODM_TXPowerTrackingCheck to
maintain compatibility with call site.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190725052645.2372-8-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:59:40 +02:00
Nishka Dasgupta 4e8cc1c2df staging: rtl8723bs: Replace function odm_TXPowerTrackingInit()
Remove function odm_TXPowerTrackingInit as all it does is call
odm_TXPowerTrackingThermalMeterInit.
Rename odm_TXPowerTrackingThermalMeterInit to
odm_TXPowerTrackingInit to maintain compatibility with call sites.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190725052645.2372-7-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:59:39 +02:00
Nishka Dasgupta d40e29d7e2 staging: rtl8723bs: Replace function beacon_timing_control()
Remove function beacon_timing_control as it does nothing except call
rtw_hal_bcn_related_reg_setting.
Rename rtw_hal_bcn_related_reg_setting to beacon_timing_control to
maintain compatibility with call site.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190725052645.2372-6-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:59:39 +02:00
Nishka Dasgupta 7a9a7332b6 staging: rtl8723bs: hal: Replace function rtl8723b_set_ap_wowlan_cmd()
Remove function rtl8723b_set_ap_wowlan_cmd as all it does is call
rtl8723b_set_AP_FwWoWlanRelated_cmd.
Rename rtl8723b_set_AP_FwWoWlanRelated_cmd to
rtl8723b_set_ap_wowlan_cmd to maintain compatibility with call site.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190725052645.2372-5-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:59:39 +02:00
Nishka Dasgupta 0528096df3 staging: rtl8723bs: hal: Replace function rtl8723b_set_wowlan_cmd()
Remove function rtl8723b_set_wowlan_cmd as all it does is call
rtl8723b_set_FwWoWlanRelated_cmd.
Rename rtl8723b_set_FwWoWlanRelated_cmd to rtl8723b_set_wowlan_cmd to
maintain compatibility with call site.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190725052645.2372-4-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:58:27 +02:00
Nishka Dasgupta 9dd2f1d9a1 staging: rtl8723bs: hal: Replace function PHY_GetTxPowerIndex()
Remove function PHY_GetTxPowerIndex as it does nothing except call
PHY_GetTxPowerIndex_8723B.
Rename PHY_GetTxPowerIndex_8723B to PHY_GetTxPowerIndex to maintain
compatibility with call site.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190725052645.2372-3-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:58:26 +02:00
Nishka Dasgupta fe2ffeb5fd staging: rtl8723bs: hal: Replace function PHY_SetTxPowerIndex()
Remove function PHY_SetTxPowerIndex as it does nothing except call
PHY_SetTxPowerIndex_8723B.
Rename PHY_SetTxPowerIndex_8723B to PHY_SetTxPowerIndex to maintain
compatibility with call site.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190725052645.2372-2-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:58:26 +02:00
Nishka Dasgupta 2e20a5ac67 staging: rtl8723bs: rtw_pwrctrl: Change true/false checks
Change comparisons to true to the variable itself.
Change comparisons to false to the negation of the variable.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190725052645.2372-1-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:58:26 +02:00
Colin Ian King 4b2c85cacd drivers/staging/rtl8192u: fix indentation issue, remove extra tab
A statement is indented one level too deeply; clean this up by
removing a tab.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20190723145022.11608-1-colin.king@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:58:26 +02:00
Sergio Paracuellos 7f9b583358 staging: mt7621-pci: avoid use 'err' local variable
Function 'mt7621_pcie_request_resources' is using 'err'
local variable to get value returned from 'devm_request_pci_bus_resources'
and returning after that. This is not needed at all. Instead of that
just directly return returned value by the function which is also
returning zero on success.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Link: https://lore.kernel.org/r/20190720072908.16795-1-sergio.paracuellos@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:58:26 +02:00
YueHaibing 756e4624dd staging: rtl8192e: remove set but not used variable 'payload '
Fixes gcc '-Wunused-but-set-variable' warning:

drivers/staging/rtl8192e/rtllib_rx.c: In function rtllib_rx_InfraAdhoc:
drivers/staging/rtl8192e/rtllib_rx.c:1303:6: warning:
 variable payload set but not used [-Wunused-but-set-variable]

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Link: https://lore.kernel.org/r/20190717143551.29200-1-yuehaibing@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-07-25 09:58:26 +02:00