platform/kernel/linux-starfive.git
2 years agostaging: r8188eu: rename camelcase variable uintPeerChannel
Alberto Merciai [Tue, 4 Jan 2022 16:09:39 +0000 (17:09 +0100)]
staging: r8188eu: rename camelcase variable uintPeerChannel

Rename camelcase hungarian notated variable uintPeerChannel into
peer_channel.

Signed-off-by: Alberto Merciai <alb3rt0.m3rciai@gmail.com>
Link: https://lore.kernel.org/r/20220104160945.460113-1-alb3rt0.m3rciai@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make BW20_24G_Diff a 1-D array
Martin Kaiser [Wed, 5 Jan 2022 08:34:26 +0000 (09:34 +0100)]
staging: r8188eu: make BW20_24G_Diff a 1-D array

Make BW20_24G_Diff a one-dimensional array. This driver uses only
BW20_24G_Diff[0].

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220105083426.177128-8-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make OFDM_24G_Diff a 1-D array
Martin Kaiser [Wed, 5 Jan 2022 08:34:25 +0000 (09:34 +0100)]
staging: r8188eu: make OFDM_24G_Diff a 1-D array

Make OFDM_24G_Diff one-dimensional array. This driver uses only
OFDM_24G_Diff[0].

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220105083426.177128-7-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: BW40_24G_Diff is set but not used
Martin Kaiser [Wed, 5 Jan 2022 08:34:24 +0000 (09:34 +0100)]
staging: r8188eu: BW40_24G_Diff is set but not used

The BW40_24G_Diff array is set but not used. Remove it.

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220105083426.177128-6-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: CCK_24G_Diff is set but not used
Martin Kaiser [Wed, 5 Jan 2022 08:34:23 +0000 (09:34 +0100)]
staging: r8188eu: CCK_24G_Diff is set but not used

The CCK_24G_Diff array is set but not used. Remove it.

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220105083426.177128-5-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make Index24G_BW40_Base a 1-D array
Martin Kaiser [Wed, 5 Jan 2022 08:34:22 +0000 (09:34 +0100)]
staging: r8188eu: make Index24G_BW40_Base a 1-D array

Make Index24G_BW40_Base a one-dimensional array. This driver uses
only Index24G_BW40_Base[0].

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220105083426.177128-4-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make Index24G_CCK_Base a 1-D array
Martin Kaiser [Wed, 5 Jan 2022 08:34:21 +0000 (09:34 +0100)]
staging: r8188eu: make Index24G_CCK_Base a 1-D array

Make Index24G_CCK_Base a one-dimensional array. This driver uses only
Index24G_CCK_Base[0].

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220105083426.177128-3-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: rfPath is always 0
Martin Kaiser [Wed, 5 Jan 2022 08:34:20 +0000 (09:34 +0100)]
staging: r8188eu: rfPath is always 0

The rfPath variable in Hal_ReadTxPowerInfo88E is always 0. Remove the
variable and use 0 directly.

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220105083426.177128-2-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unneeded parameter from rtl8188e_SetHalODMVar
Michael Straube [Tue, 4 Jan 2022 09:07:32 +0000 (10:07 +0100)]
staging: r8188eu: remove unneeded parameter from rtl8188e_SetHalODMVar

Function rtl8188e_SetHalODMVar is always called with HAL_ODM_STA_INFO.
Remove the unneeded parameter eVariable from the function.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220104090732.13994-1-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: pi433: add comment to rx_lock mutex definition
Paulo Miguel Almeida [Mon, 3 Jan 2022 23:26:16 +0000 (12:26 +1300)]
staging: pi433: add comment to rx_lock mutex definition

Checkpatch reports: CHECK: struct mutex definition without comment.
Fix this by documenting what rx_mutex struct is used for in pi433
driver.

Signed-off-by: Paulo Miguel Almeida <paulo.miguel.almeida.rodenas@gmail.com>
Link: https://lore.kernel.org/r/20220103232616.GA11161@mail.google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: pi433: fix frequency deviation check
Paulo Miguel Almeida [Mon, 3 Jan 2022 22:23:34 +0000 (11:23 +1300)]
staging: pi433: fix frequency deviation check

rf69 datasheet states that frequency deviation must exceed 600 Hz but
also that frequency deviation + (bitrate / 2) should be less than equal
to 500 kHz to ensure proper modulation.

This patch validates that both conditions are met so RF intersymbol
interference is less likely to happen due to misconfiguration of the uC

Signed-off-by: Paulo Miguel Almeida <paulo.miguel.almeida.rodenas@gmail.com>
Link: https://lore.kernel.org/r/20220103222334.GA6814@mail.google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: vc04_services: rename BM2835 to BCM2835 in headers comments
Gaston Gonzalez [Wed, 5 Jan 2022 20:35:48 +0000 (17:35 -0300)]
staging: vc04_services: rename BM2835 to BCM2835 in headers comments

In the kernel, when referring to the chip BCM2835, it is more suitable
to use BCM2835 to BM2835. To avoid confusion, and to make things more
consistent, rename the headers titles accordingly.

Suggested-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: Gaston Gonzalez <gascoar@gmail.com>
Link: https://lore.kernel.org/r/19acea9e9da0d3ebb1a7e6bce511a3c09e8c80c3.1641414449.git.gascoar@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: vc04_services: rename string literal containing bm2835_* to bcm2835*_
Gaston Gonzalez [Wed, 5 Jan 2022 20:35:46 +0000 (17:35 -0300)]
staging: vc04_services: rename string literal containing bm2835_* to bcm2835*_

In the kernel, all names related to the chip BCM2835 are always named
bcm2835_*. To avoid confusion, and to make things more consistent,
rename the string term bm2835_* to bcm2835_*.

While at it, some realignments were made to improve readability.

Suggested-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: Gaston Gonzalez <gascoar@gmail.com>
Link: https://lore.kernel.org/r/91caae07fce0e4511f283388304e935526ba29ed.1641414449.git.gascoar@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: vc04_services: rename variables containing bm2835_* to bcm2835_*
Gaston Gonzalez [Wed, 5 Jan 2022 20:35:45 +0000 (17:35 -0300)]
staging: vc04_services: rename variables containing bm2835_* to bcm2835_*

In the kernel, all names related to the chip BCM2835 are always named
bcm2835_*. To avoid confusion, and to make things more consistent,
rename all variables using bm2835_* to bcm2835_*.

While at it, some realignments were made to improve readability.

Suggested-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: Gaston Gonzalez <gascoar@gmail.com>
Link: https://lore.kernel.org/r/a0af5deacebc2da9b21772c7677e1a9627edbed6.1641414449.git.gascoar@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: vc04_services: rename functions containing bm2835_* to bcm2835_*
Gaston Gonzalez [Wed, 5 Jan 2022 20:35:44 +0000 (17:35 -0300)]
staging: vc04_services: rename functions containing bm2835_* to bcm2835_*

In the kernel, all names related to the chip BCM2835 are always named
bcm2835_*. To avoid confusion, and to make things more consistent,
rename functions using bm2835_* to bcm2835_*.

While at it, some realignments were made to improve readability.

Suggested-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: Gaston Gonzalez <gascoar@gmail.com>
Link: https://lore.kernel.org/r/d3b6f67421c75829105f793cfb9ec1414b926bf6.1641414449.git.gascoar@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: vc04_services: rename structures bm2835_mmal_dev and bm2835_mmal_v4l2_ctrl
Gaston Gonzalez [Wed, 5 Jan 2022 20:35:43 +0000 (17:35 -0300)]
staging: vc04_services: rename structures bm2835_mmal_dev and bm2835_mmal_v4l2_ctrl

In the kernel, all names related to the chip BCM2835 are always named
bcm2835_*. To avoid confusion, and to make things more consistent,
rename the structures bm2835_mmal_dev and bm2835_mmal_v4l2_ctrl
accordingly.

While at it, one realignment was made to improve readability.

Suggested-by: Stefan Wahren <stefan.wahren@i2se.com>
Signed-off-by: Gaston Gonzalez <gascoar@gmail.com>
Link: https://lore.kernel.org/r/a893f24fc5ee6c276ea982f141b42ec0a00d7194.1641414449.git.gascoar@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: greybus: audio: Check null pointer
Jiasheng Jiang [Tue, 4 Jan 2022 15:06:28 +0000 (23:06 +0800)]
staging: greybus: audio: Check null pointer

As the possible alloc failure of devm_kcalloc(), it could return null
pointer.
Therefore, 'strings' should be checked and return NULL if alloc fails to
prevent the dereference of the NULL pointer.
Also, the caller should also deal with the return value of the
gb_generate_enum_strings() and return -ENOMEM if returns NULL.
Moreover, because the memory allocated with devm_kzalloc() will be
freed automatically when the last reference to the device is dropped,
the 'gbe' in gbaudio_tplg_create_enum_kctl() and
gbaudio_tplg_create_enum_ctl() do not need to free manually.
But the 'control' in gbaudio_tplg_create_widget() and
gbaudio_tplg_process_kcontrols() has a specially error handle to
cleanup.
So it should be better to cleanup 'control' when fails.

Fixes: e65579e335da ("greybus: audio: topology: Enable enumerated control support")
Reviewed-by: Alex Elder <elder@linaro.org>
Signed-off-by: Jiasheng Jiang <jiasheng@iscas.ac.cn>
Link: https://lore.kernel.org/r/20220104150628.1987906-1-jiasheng@iscas.ac.cn
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: add spaces around P2P_AP_P2P_CH_SWITCH_PROCESS_WK
Alberto Merciai [Mon, 3 Jan 2022 11:56:25 +0000 (12:56 +0100)]
staging: r8188eu: add spaces around P2P_AP_P2P_CH_SWITCH_PROCESS_WK

Remove checkpatch.pl error by adding spaces
around P2P_AP_P2P_CH_SWITCH_PROCESS_WK.

Signed-off-by: Alberto Merciai <alb3rt0.m3rciai@gmail.com>
Link: https://lore.kernel.org/r/20220103115633.221853-1-alb3rt0.m3rciai@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: turbo scan is always off for r8188eu
Martin Kaiser [Sun, 2 Jan 2022 17:59:32 +0000 (18:59 +0100)]
staging: r8188eu: turbo scan is always off for r8188eu

Turbo scan is always disabled. Remove the TurboScanOff variable and
related checks.

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220102175932.89127-6-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: cmd_issued_cnt is set but not used
Martin Kaiser [Sun, 2 Jan 2022 17:59:31 +0000 (18:59 +0100)]
staging: r8188eu: cmd_issued_cnt is set but not used

cmd_issued_cnt in struct cmd_priv is set but not used. It can
be removed.

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220102175932.89127-5-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: fix_rate is set but not used.
Martin Kaiser [Sun, 2 Jan 2022 17:59:30 +0000 (18:59 +0100)]
staging: r8188eu: fix_rate is set but not used.

fix_rate in struct adapter is set but not used. Remove the variable and
the private ioctl code to set it.

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220102175932.89127-4-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: internal autosuspend is always false
Martin Kaiser [Sun, 2 Jan 2022 17:59:29 +0000 (18:59 +0100)]
staging: r8188eu: internal autosuspend is always false

bInternalAutoSuspend is always false. Remove the variable and related
checks.

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220102175932.89127-3-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unused power management defines
Martin Kaiser [Sun, 2 Jan 2022 17:59:28 +0000 (18:59 +0100)]
staging: r8188eu: remove unused power management defines

Remove unused defines from enum power_mgnt.

Acked-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20220102175932.89127-2-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unused defines from rtw_eeprom.h
Michael Straube [Sun, 2 Jan 2022 13:11:41 +0000 (14:11 +0100)]
staging: r8188eu: remove unused defines from rtw_eeprom.h

Remove unused defines from rtw_eeprom.h.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-12-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unused defines from Hal8188EPhyCfg.h
Michael Straube [Sun, 2 Jan 2022 13:11:40 +0000 (14:11 +0100)]
staging: r8188eu: remove unused defines from Hal8188EPhyCfg.h

Remove unused defines from Hal8188EPhyCfg.h.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-11-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unneeded comments from Hal8188EPhyCfg.h
Michael Straube [Sun, 2 Jan 2022 13:11:39 +0000 (14:11 +0100)]
staging: r8188eu: remove unneeded comments from Hal8188EPhyCfg.h

Remove unneeded comments from Hal8188EPhyCfg.h.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-10-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: enum hw90_block is not used
Michael Straube [Sun, 2 Jan 2022 13:11:38 +0000 (14:11 +0100)]
staging: r8188eu: enum hw90_block is not used

The enumeration hw90_block is not used. Remove it.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-9-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: struct odm_sta_info is not used
Michael Straube [Sun, 2 Jan 2022 13:11:37 +0000 (14:11 +0100)]
staging: r8188eu: struct odm_sta_info is not used

The structure odm_sta_info is not used. Remove it.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-8-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: clean up struct sw_ant_switch
Michael Straube [Sun, 2 Jan 2022 13:11:36 +0000 (14:11 +0100)]
staging: r8188eu: clean up struct sw_ant_switch

Remove unused fields from struct sw_ant_switch.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-7-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: clean up struct rtw_dig
Michael Straube [Sun, 2 Jan 2022 13:11:35 +0000 (14:11 +0100)]
staging: r8188eu: clean up struct rtw_dig

Remove unused and set but never used fields from struct rtw_dig.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-6-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: struct rx_hpc is not used
Michael Straube [Sun, 2 Jan 2022 13:11:34 +0000 (14:11 +0100)]
staging: r8188eu: struct rx_hpc is not used

The structure rx_hpc is not used. Remove it.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-5-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unused enum and defines
Michael Straube [Sun, 2 Jan 2022 13:11:33 +0000 (14:11 +0100)]
staging: r8188eu: remove unused enum and defines

Remove the unused enum rf90_radio_path and some unused defines.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-4-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove struct rt_channel_plan_2g
Michael Straube [Sun, 2 Jan 2022 13:11:32 +0000 (14:11 +0100)]
staging: r8188eu: remove struct rt_channel_plan_2g

The structures rt_channel_plan and rt_channel_plan_2g are identical.
Keep rt_channel_plan and remove rt_channel_plan_2g.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-3-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove MAX_CHANNEL_NUM_2G
Michael Straube [Sun, 2 Jan 2022 13:11:31 +0000 (14:11 +0100)]
staging: r8188eu: remove MAX_CHANNEL_NUM_2G

The constants MAX_CHANNEL_NUM_2G and MAX_CHANNEL_NUM have the same
value. Remove MAX_CHANNEL_NUM_2G and fix the place where it is used.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220102131141.12310-2-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: FwRsvdPageStartOffset is set but never used
Michael Straube [Sat, 1 Jan 2022 08:49:37 +0000 (09:49 +0100)]
staging: r8188eu: FwRsvdPageStartOffset is set but never used

The field FwRsvdPageStartOffset of struct hal_data_8188e is set but
never used. Remove it.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220101084937.3411-8-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: IntArray and C2hArray are set but never used
Michael Straube [Sat, 1 Jan 2022 08:49:36 +0000 (09:49 +0100)]
staging: r8188eu: IntArray and C2hArray are set but never used

The fields IntArray and C2hArray of struct hal_data_8188e are set but
never used. Remove them and remove interrupt_handler_8188eu() since it
does nothing now.

While at it, remove the unsed defines USB_INTR_CONTENT_CPWM1_OFFSET
and USB_INTR_CONTENT_CPWM2_OFFSET as well.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220101084937.3411-7-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unused fields from struct hal_data_8188e
Michael Straube [Sat, 1 Jan 2022 08:49:35 +0000 (09:49 +0100)]
staging: r8188eu: remove unused fields from struct hal_data_8188e

Remove unused fields from struct hal_data_8188e.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220101084937.3411-6-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: bAPKThermalMeterIgnore is set but never used
Michael Straube [Sat, 1 Jan 2022 08:49:34 +0000 (09:49 +0100)]
staging: r8188eu: bAPKThermalMeterIgnore is set but never used

The field bAPKThermalMeterIgnore of struct hal_data_8188e is set but
never used. Remove it.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220101084937.3411-5-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: bTXPowerDataReadFromEEPORM is set but never used
Michael Straube [Sat, 1 Jan 2022 08:49:33 +0000 (09:49 +0100)]
staging: r8188eu: bTXPowerDataReadFromEEPORM is set but never used

The field bTXPowerDataReadFromEEPORM of struct hal_data_8188e is set
but never used. Remove it.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220101084937.3411-4-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: UsbRxHighSpeedMode is set but never used
Michael Straube [Sat, 1 Jan 2022 08:49:32 +0000 (09:49 +0100)]
staging: r8188eu: UsbRxHighSpeedMode is set but never used

The field UsbRxHighSpeedMode of struct hal_data_8188e is set but
never used. Remove it.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220101084937.3411-3-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: bRDGEnable is always false
Michael Straube [Sat, 1 Jan 2022 08:49:31 +0000 (09:49 +0100)]
staging: r8188eu: bRDGEnable is always false

The field bRDGEnable in struct hal_data_8188e is never set. It stays
at its default value 0. Remove bRDGEnable and related dead code.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220101084937.3411-2-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: pi433: add docs to packet_format and tx_start_condition enum
Paulo Miguel Almeida [Fri, 31 Dec 2021 00:19:33 +0000 (13:19 +1300)]
staging: pi433: add docs to packet_format and tx_start_condition enum

While pi433 driver deals with the nuances of the different possible
config combinations, it's hard (at first) to understand the rationale
for some of the tx/rx-related source code unless you're fairly familiar
with the rf69's inner workings.

This patch documents the expected behaviour and limits of both
packet_format and tx_start_condition enum fields.

Signed-off-by: Paulo Miguel Almeida <paulo.miguel.almeida.rodenas@gmail.com>
Link: https://lore.kernel.org/r/20211231001933.GA6779@mail.google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: vc04_services: update TODO file
Gaston Gonzalez [Thu, 30 Dec 2021 11:31:29 +0000 (08:31 -0300)]
staging: vc04_services: update TODO file

There are no struct typedef remaining inside vc04_services/. Hence, remove the
task from the TODO file.

While at it, fix the items sequential numbering.

Signed-off-by: Gaston Gonzalez <gascoar@gmail.com>
Link: https://lore.kernel.org/r/3f560a75063a0bb744bb34c410e49f792d2c3d21.1640776340.git.gascoar@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: vc04_services: bcm2835-camera: avoid the use of typedef for function pointers
Gaston Gonzalez [Thu, 30 Dec 2021 11:31:27 +0000 (08:31 -0300)]
staging: vc04_services: bcm2835-camera: avoid the use of typedef for function pointers

Replace typedef bm2835_mmal_v4l2_ctrl_cb with equivalent declaration to
better align with the linux kernel coding style.

Signed-off-by: Gaston Gonzalez <gascoar@gmail.com>
Link: https://lore.kernel.org/r/0418e6e19e1580fff4abfc4bb2f4269dc206df44.1640776340.git.gascoar@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: vc04_services: bcm2835-audio: avoid the use of typedef for function pointers
Gaston Gonzalez [Thu, 30 Dec 2021 11:31:25 +0000 (08:31 -0300)]
staging: vc04_services: bcm2835-audio: avoid the use of typedef for function pointers

Replace typedefs bcm2835_audio_newpcm_func and bcm2835_audio_newctl_func
with equivalent declarations to better align with the linux kernel
coding style.

Signed-off-by: Gaston Gonzalez <gascoar@gmail.com>
Link: https://lore.kernel.org/r/b53a77682994bbc3ccb9b89d617dec23d0785059.1640776340.git.gascoar@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove header odm_precomp.h
Michael Straube [Wed, 29 Dec 2021 20:51:08 +0000 (21:51 +0100)]
staging: r8188eu: remove header odm_precomp.h

After previous cleanups the header odm_precomp.h only contains
includes and one unused define now. Remove the header and adjust
the includes in affected files.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-33-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unnecessary comments
Michael Straube [Wed, 29 Dec 2021 20:51:07 +0000 (21:51 +0100)]
staging: r8188eu: remove unnecessary comments

Remove some unnecessary comments in odm.c.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-32-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_EdcaTurboCheck() static
Michael Straube [Wed, 29 Dec 2021 20:51:06 +0000 (21:51 +0100)]
staging: r8188eu: make odm_EdcaTurboCheck() static

Function odm_EdcaTurboCheck() is only used in odm.c. Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-31-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make ODM_EdcaTurboInit() static
Michael Straube [Wed, 29 Dec 2021 20:51:05 +0000 (21:51 +0100)]
staging: r8188eu: make ODM_EdcaTurboInit() static

Function ODM_EdcaTurboInit() is only used in odm.c. Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-30-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_HwAntDiv() static
Michael Straube [Wed, 29 Dec 2021 20:51:04 +0000 (21:51 +0100)]
staging: r8188eu: make odm_HwAntDiv() static

Function odm_HwAntDiv() is only used in odm.c. Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-29-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_InitHybridAntDiv() static
Michael Straube [Wed, 29 Dec 2021 20:51:03 +0000 (21:51 +0100)]
staging: r8188eu: make odm_InitHybridAntDiv() static

Function odm_InitHybridAntDiv() is only used in odm.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-28-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_TXPowerTrackingThermalMeterInit() static
Michael Straube [Wed, 29 Dec 2021 20:51:02 +0000 (21:51 +0100)]
staging: r8188eu: make odm_TXPowerTrackingThermalMeterInit() static

Function odm_TXPowerTrackingThermalMeterInit() is only used in odm.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-27-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove odm_TXPowerTrackingInit()
Michael Straube [Wed, 29 Dec 2021 20:51:01 +0000 (21:51 +0100)]
staging: r8188eu: remove odm_TXPowerTrackingInit()

odm_TXPowerTrackingInit() is just a wrapper around
odm_TXPowerTrackingThermalMeterInit(). Remove it.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-26-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_RSSIMonitorCheck() static
Michael Straube [Wed, 29 Dec 2021 20:51:00 +0000 (21:51 +0100)]
staging: r8188eu: make odm_RSSIMonitorCheck() static

Function odm_RSSIMonitorCheck() is only used in odm.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-25-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_CCKPacketDetectionThresh() static
Michael Straube [Wed, 29 Dec 2021 20:50:59 +0000 (21:50 +0100)]
staging: r8188eu: make odm_CCKPacketDetectionThresh() static

Function odm_CCKPacketDetectionThresh() is only used in odm.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-24-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_FalseAlarmCounterStatistics() static
Michael Straube [Wed, 29 Dec 2021 20:50:58 +0000 (21:50 +0100)]
staging: r8188eu: make odm_FalseAlarmCounterStatistics() static

Function odm_FalseAlarmCounterStatistics() is only used in odm.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-23-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_DynamicBBPowerSavingInit() static
Michael Straube [Wed, 29 Dec 2021 20:50:57 +0000 (21:50 +0100)]
staging: r8188eu: make odm_DynamicBBPowerSavingInit() static

Function odm_DynamicBBPowerSavingInit() is only used in odm.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-22-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_RefreshRateAdaptiveMask() static
Michael Straube [Wed, 29 Dec 2021 20:50:56 +0000 (21:50 +0100)]
staging: r8188eu: make odm_RefreshRateAdaptiveMask() static

Function odm_RefreshRateAdaptiveMask() is only used in odm.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-21-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_RateAdaptiveMaskInit() static
Michael Straube [Wed, 29 Dec 2021 20:50:55 +0000 (21:50 +0100)]
staging: r8188eu: make odm_RateAdaptiveMaskInit() static

Function odm_RateAdaptiveMaskInit() is only used in odm.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-20-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_CommonInfoSelfUpdate() static
Michael Straube [Wed, 29 Dec 2021 20:50:54 +0000 (21:50 +0100)]
staging: r8188eu: make odm_CommonInfoSelfUpdate() static

Function odm_CommonInfoSelfUpdate() is only used in odm.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-19-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_CommonInfoSelfInit() static
Michael Straube [Wed, 29 Dec 2021 20:50:53 +0000 (21:50 +0100)]
staging: r8188eu: make odm_CommonInfoSelfInit() static

Function odm_CommonInfoSelfInit() is only used in odm.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-18-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_DIG() static
Michael Straube [Wed, 29 Dec 2021 20:50:52 +0000 (21:50 +0100)]
staging: r8188eu: make odm_DIG() static

Function odm_DIG() is used only in odm.c. Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-17-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_DIGInit() static
Michael Straube [Wed, 29 Dec 2021 20:50:51 +0000 (21:50 +0100)]
staging: r8188eu: make odm_DIGInit() static

Function odm_DIGInit() is used only in odm.c. Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-16-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unused prototypes
Michael Straube [Wed, 29 Dec 2021 20:50:50 +0000 (21:50 +0100)]
staging: r8188eu: remove unused prototypes

Remove some unused function prototypes.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-15-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: make odm_ConfigRFReg_8188E() static
Michael Straube [Wed, 29 Dec 2021 20:50:49 +0000 (21:50 +0100)]
staging: r8188eu: make odm_ConfigRFReg_8188E() static

Function odm_ConfigRFReg_8188E() is only used in odm_RegConfig8188E.c.
Make it static.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-14-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove odm_interface
Michael Straube [Wed, 29 Dec 2021 20:50:48 +0000 (21:50 +0100)]
staging: r8188eu: remove odm_interface

After previous cleanups the file odm_interface.c is emtpy now
and the header odm_interface.h just contains an unused typedef.
Remove both files.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-13-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_CompareMemory()
Michael Straube [Wed, 29 Dec 2021 20:50:47 +0000 (21:50 +0100)]
staging: r8188eu: remove ODM_CompareMemory()

ODM_CompareMemory() is just a wrapper around memcmp().
Remove ODM_CompareMemory() and call memcmp() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-12-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_delay_ms()
Michael Straube [Wed, 29 Dec 2021 20:50:46 +0000 (21:50 +0100)]
staging: r8188eu: remove ODM_delay_ms()

ODM_delay_ms() is just a wrapper around mdelay().
Remove ODM_delay_ms() and call mdelay() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-11-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_delay_us()
Michael Straube [Wed, 29 Dec 2021 20:50:45 +0000 (21:50 +0100)]
staging: r8188eu: remove ODM_delay_us()

ODM_delay_us() is just a wrapper around udelay().
Remove ODM_delay_us() and call udelay() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-10-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_sleep_ms()
Michael Straube [Wed, 29 Dec 2021 20:50:44 +0000 (21:50 +0100)]
staging: r8188eu: remove ODM_sleep_ms()

ODM_sleep_ms() is just a wrapper around msleep().
Remove ODM_sleep_ms() and call msleep() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-9-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: clean up coding style issues
Michael Straube [Wed, 29 Dec 2021 20:50:43 +0000 (21:50 +0100)]
staging: r8188eu: clean up coding style issues

Clean up coding style issues in odm_ConfigRFReg_8188E() reported by
checkpatch.

WARNING: please, no spaces at the start of a line
WARNING: suspect code indent for conditional statements (4, 16)

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-8-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_SetBBReg()
Michael Straube [Wed, 29 Dec 2021 20:50:42 +0000 (21:50 +0100)]
staging: r8188eu: remove ODM_SetBBReg()

ODM_SetBBReg() is just a wrapper around rtl8188e_PHY_SetBBReg().
Remove ODM_SetBBReg() and call rtl8188e_PHY_SetBBReg() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-7-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_GetBBReg()
Michael Straube [Wed, 29 Dec 2021 20:50:41 +0000 (21:50 +0100)]
staging: r8188eu: remove ODM_GetBBReg()

ODM_GetBBReg() is just a wrapper around rtl8188e_PHY_QueryBBReg().
Remove ODM_GetBBReg() and call rtl8188e_PHY_QueryBBReg() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-6-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_SetRFReg()
Michael Straube [Wed, 29 Dec 2021 20:50:40 +0000 (21:50 +0100)]
staging: r8188eu: remove ODM_SetRFReg()

ODM_SetRFReg() is just a wrapper around rtl8188e_PHY_SetRFReg().
Remove ODM_SetRFReg() and call rtl8188e_PHY_SetRFReg() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-5-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_GetRFReg()
Michael Straube [Wed, 29 Dec 2021 20:50:39 +0000 (21:50 +0100)]
staging: r8188eu: remove ODM_GetRFReg()

ODM_GetRFReg() is just a wrapper around rtl8188e_PHY_QueryRFReg().
Remove ODM_GetRFReg() and call rtl8188e_PHY_QueryRFReg() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-4-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_GetMACReg()
Michael Straube [Wed, 29 Dec 2021 20:50:38 +0000 (21:50 +0100)]
staging: r8188eu: remove ODM_GetMACReg()

ODM_GetMACReg() is just a wrapper around rtl8188e_PHY_QueryBBReg().
Remove ODM_GetMACReg() and call rtl8188e_PHY_QueryBBReg() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-3-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_SetMACReg()
Michael Straube [Wed, 29 Dec 2021 20:50:37 +0000 (21:50 +0100)]
staging: r8188eu: remove ODM_SetMACReg()

ODM_SetMACReg() is just a wrapper around rtl8188e_PHY_SetBBReg().
Remove ODM_SetMACReg() and call rtl8188e_PHY_SetBBReg() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211229205108.26373-2-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: axis-fifo: Use platform_get_irq() to get the interrupt
Lad Prabhakar [Fri, 24 Dec 2021 16:13:34 +0000 (16:13 +0000)]
staging: axis-fifo: Use platform_get_irq() to get the interrupt

platform_get_resource(pdev, IORESOURCE_IRQ, ..) relies on static
allocation of IRQ resources in DT core code, this causes an issue
when using hierarchical interrupt domains using "interrupts" property
in the node as this bypasses the hierarchical setup and messes up the
irq chaining.

In preparation for removal of static setup of IRQ resource from DT core
code use platform_get_irq().

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com>
Link: https://lore.kernel.org/r/20211224161334.31123-4-prabhakar.mahadev-lad.rj@bp.renesas.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: greybus: auto_manager: use default_groups in kobj_type
Greg Kroah-Hartman [Tue, 28 Dec 2021 13:55:41 +0000 (14:55 +0100)]
staging: greybus: auto_manager: use default_groups in kobj_type

There are currently 2 ways to create a set of sysfs files for a
kobj_type, through the default_attrs field, and the default_groups
field.  Move the greybus audio code to use default_groups field which
has been the preferred way since aa30f47cf666 ("kobject: Add support for
default attribute groups to kobj_type") so that we can soon get rid of
the obsolete default_attrs field.

Cc: Vaibhav Agarwal <vaibhav.sr@gmail.com>
Cc: Johan Hovold <johan@kernel.org>
Reviewed-by: Alex Elder <elder@linaro.org>
Acked-by: Mark Greer <mgreer@animalcreek.com>
Link: https://lore.kernel.org/r/20211228135541.380275-1-gregkh@linuxfoundation.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: merge _ReadLEDSetting() into ReadAdapterInfo8188EU()
Michael Straube [Tue, 28 Dec 2021 10:11:20 +0000 (11:11 +0100)]
staging: r8188eu: merge _ReadLEDSetting() into ReadAdapterInfo8188EU()

Function _ReadLEDSetting() sets only a single variable and the only
user is ReadAdapterInfo8188EU(). Remove _ReadLEDSetting() and set the
variable in ReadAdapterInfo8188EU() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211228101120.9120-11-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: RSSI_test is always false
Michael Straube [Tue, 28 Dec 2021 10:11:19 +0000 (11:11 +0100)]
staging: r8188eu: RSSI_test is always false

The field RSSI_test of struct odm_dm_struct is never set. It stays
at the default value 0. Remove it and remove a related if test that
is always true.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211228101120.9120-10-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: TrainIdx is set but never used
Michael Straube [Tue, 28 Dec 2021 10:11:18 +0000 (11:11 +0100)]
staging: r8188eu: TrainIdx is set but never used

The field TrainIdx of struct fast_ant_train is set but never used.
Remove it.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211228101120.9120-9-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: FAT_State is set but never used
Michael Straube [Tue, 28 Dec 2021 10:11:17 +0000 (11:11 +0100)]
staging: r8188eu: FAT_State is set but never used

The field FAT_State of struct fast_ant_train is set but never used.
Remove it.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211228101120.9120-8-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: FAT_State is always FAT_NORMAL_STATE
Michael Straube [Tue, 28 Dec 2021 10:11:16 +0000 (11:11 +0100)]
staging: r8188eu: FAT_State is always FAT_NORMAL_STATE

In this driver pDM_FatTable->FAT_State is always FAT_NORMAL_STATE.
So the check 'if (pDM_FatTable->FAT_State == FAT_TRAINING_STATE)'
is always false. Remove dead code that is executed only if that
check is true.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211228101120.9120-7-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove write-only fields from struct rtl_ps
Michael Straube [Tue, 28 Dec 2021 10:11:15 +0000 (11:11 +0100)]
staging: r8188eu: remove write-only fields from struct rtl_ps

The fields pre_cca_state, cur_cca_state and rssi_val_min of struct
rtl_ps are set but never used. Remove them.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211228101120.9120-6-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove ODM_CMNINFO_ABILITY from ODM_CmnInfoInit()
Michael Straube [Tue, 28 Dec 2021 10:11:14 +0000 (11:11 +0100)]
staging: r8188eu: remove ODM_CMNINFO_ABILITY from ODM_CmnInfoInit()

ODM_CmnInfoInit() is never called with ODM_CMNINFO_ABILITY.
Remove that unused case from ODM_CmnInfoInit().

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211228101120.9120-5-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unused enum odm_h2c_cmd
Michael Straube [Tue, 28 Dec 2021 10:11:13 +0000 (11:11 +0100)]
staging: r8188eu: remove unused enum odm_h2c_cmd

The enum odm_h2c_cmd is not used in this driver. Remove it.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211228101120.9120-4-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove GET_CVID_ROM_VERSION
Michael Straube [Tue, 28 Dec 2021 10:11:12 +0000 (11:11 +0100)]
staging: r8188eu: remove GET_CVID_ROM_VERSION

The macro GET_CVID_ROM_VERSION is not used. Remove it.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211228101120.9120-3-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: DM_PriCCA is set but never used
Michael Straube [Tue, 28 Dec 2021 10:11:11 +0000 (11:11 +0100)]
staging: r8188eu: DM_PriCCA is set but never used

The field DM_PriCCA of struct odm_dm_struct is set but never used.
Remove it and remove related dead code.

Acked-by: Martin Kaiser <martin@kaiser.cx>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20211228101120.9120-2-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unused prototype
Martin Kaiser [Sun, 26 Dec 2021 21:25:35 +0000 (22:25 +0100)]
staging: r8188eu: remove unused prototype

Remove the prototype for wifirate2_ratetbl_inx, it is not needed.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226212535.197989-11-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove the private "test" ioctl
Martin Kaiser [Sun, 26 Dec 2021 21:25:34 +0000 (22:25 +0100)]
staging: r8188eu: remove the private "test" ioctl

Remove the private "test" ioctl. It copies data from user space,
this data is not used.

We can now remove a number of NULL entries at the end of the private
ioctl list.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226212535.197989-10-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove the private ioctl "tdls"
Martin Kaiser [Sun, 26 Dec 2021 21:25:33 +0000 (22:25 +0100)]
staging: r8188eu: remove the private ioctl "tdls"

Remove the private ioctl "tdls", it is mapped to an empty
function.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226212535.197989-9-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove the private ioctl "tdls_get"
Martin Kaiser [Sun, 26 Dec 2021 21:25:32 +0000 (22:25 +0100)]
staging: r8188eu: remove the private ioctl "tdls_get"

Remove the private ioctl "tdls_get", it is mapped to an empty
function.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226212535.197989-8-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove the private ioctl "wps_assoc_req_ie"
Martin Kaiser [Sun, 26 Dec 2021 21:25:31 +0000 (22:25 +0100)]
staging: r8188eu: remove the private ioctl "wps_assoc_req_ie"

Remove the private ioctl "wps_assoc_req_ie", it is mapped to
an empty function.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226212535.197989-7-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove private ioctls that return -1
Martin Kaiser [Sun, 26 Dec 2021 21:25:30 +0000 (22:25 +0100)]
staging: r8188eu: remove private ioctls that return -1

Remove the private ioctls that are mapped to rtw_wx_priv_null.
rtw_wx_priv_null itself can also be removed.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226212535.197989-6-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove the private ioctl "wps_prob_req_ie"
Martin Kaiser [Sun, 26 Dec 2021 21:25:29 +0000 (22:25 +0100)]
staging: r8188eu: remove the private ioctl "wps_prob_req_ie"

Remove the private ioctl "wps_prob_req_ie", it is mapped to
an empty function.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226212535.197989-5-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove the private drvext_hdl ioctl
Martin Kaiser [Sun, 26 Dec 2021 21:25:28 +0000 (22:25 +0100)]
staging: r8188eu: remove the private drvext_hdl ioctl

Remove the private drvext_hdl ioctl, it is mapped to an empty function.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226212535.197989-4-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove the private ioctl "get sensitivity"
Martin Kaiser [Sun, 26 Dec 2021 21:25:27 +0000 (22:25 +0100)]
staging: r8188eu: remove the private ioctl "get sensitivity"

Remove the private ioctl "get sensitivity", it is mapped to an empty
function.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226212535.197989-3-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: remove unused rtw_private_args entries
Martin Kaiser [Sun, 26 Dec 2021 21:25:26 +0000 (22:25 +0100)]
staging: r8188eu: remove unused rtw_private_args entries

Remove the entries of the rtw_private_args array that refer to
non-existing private ioctls.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226212535.197989-2-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2 years agostaging: r8188eu: rfoff_reason is never initialised
Martin Kaiser [Sun, 26 Dec 2021 19:55:56 +0000 (20:55 +0100)]
staging: r8188eu: rfoff_reason is never initialised

rfoff_reason in struct pwrctrl_priv is never set, its value remains 0.

Remove rfoff_reason, related defines and a check in rtw_led_control
that is always false.

Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Link: https://lore.kernel.org/r/20211226195556.159471-22-martin@kaiser.cx
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>