summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2023-01-17staging: r8188eu: terminate_xmitthread_sema is not usedMartin Kaiser
Remove terminate_xmitthread_sema from struct xmit_priv. This semaphore is initialised but not used. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-16-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: bm_pending is not usedMartin Kaiser
The bm_pending queue in struct xmit_priv is initialised but not used. It can be removed. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-15-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: remove unused dma_transfer_addrMartin Kaiser
The dma_transfer_addr component in struct xmit_buf is initialised but not used. Remove it. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-14-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: remove unused bpending arrayMartin Kaiser
The bpending array in struct xmit_buf is unused. Remove it. (struct xmit_buf is not part of the interface between the kernel driver and the device's firmware. It's safe to remove components from this struct.) Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-13-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: clean up qos_option settingMartin Kaiser
The qos_option variable in function rtw_make_wlanhdr should be a boolean as it's set to true or false. We can directly set it to pqospriv->qos_option instead of using a default value and if statements. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-12-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: simplify rtw_make_wlanhdr's error handlingMartin Kaiser
Simplify the error handling in rtw_make_wlanhdr. Exit immediately instead of jumping to the end of the function. We don't have to do any clean-up. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-11-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: simplify frame type checkMartin Kaiser
Reorder the code in rtw_make_wlanhdr to make the function simpler. There's a large if statement to check that we process only data frames. Revert the condition and exit for non-data frames. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-10-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: remove duplicate psta checkMartin Kaiser
We do not need the psta check in the while loop of rtw_xmitframe_coalesce. psta is already checked near the start of the function and is not modified afterwards. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-9-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: remove rtl8188eu_init_xmit_privMartin Kaiser
rtl8188eu_init_xmit_priv's only jobs is to initialise the xmit tasklet. Remove rtl8188eu_init_xmit_priv and initialise the xmit tasklet in _rtw_init_xmit_priv. Yet again, this makes the code a tiny bit smaller. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-8-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: simplify rtl8188eu_xmit_taskletMartin Kaiser
Simplify the rtl8188eu_xmit_tasklet function. Remove an unnecessary temporary variable and reformat the code. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-7-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: remove unused parameterMartin Kaiser
All callers of rtl8188eu_xmitframe_complete set the pxmitbuf parameter to NULL, in which case rtl8188eu_xmitframe_complete allocates another xmit_buf internally. Remove the pxmitbuf parameter and resulting dead code. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-6-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: return immediately if we're not meant to encryptMartin Kaiser
In function xmitframe_swencrypt, we can return immediately if our packet needs no encryption. This is simpler than wrapping all the code into a large if statement. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-5-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: cmd_seq is write-onlyMartin Kaiser
The cmd_seq component of struct cmd_priv is set and incremented but never read. It can be removed. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-4-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: remove some unused CAM definesMartin Kaiser
Remove some CAM-related defines which are not used in the r8188eu driver. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-3-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: make xmitframe_swencrypt a void functionMartin Kaiser
xmitframe_swencrypt always returns _SUCCESS and the caller does not check the return value. We can remove the return value and make xmitframe_swencrypt a void function. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230180646.91008-2-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: remove intermediate token variableMartin Kaiser
Remove the token variable in on_action_public and use frame_body[2] as function parameter. This saves another few lines of code. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230175326.90617-5-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: remove intermediate pframe pointerMartin Kaiser
The pframe pointer in on_action_public is used only in the definition of frame_body, which points to the payload of an incoming action frame. We can use mgmt to locate the action payload and remove the pframe pointer. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230175326.90617-4-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: merge on_action_public_default into its only callerMartin Kaiser
Merge on_action_public_default into on_action_public, which is the only caller. Yet again, this makes the code a tiny bit smaller. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230175326.90617-3-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: merge on_action_public_vendor into its callerMartin Kaiser
Apart from declaring variables, on_action_public_vendor is only an if statement. Merge this function into its only caller. This makes the code a tiny bit smaller. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Link: https://lore.kernel.org/r/20221230175326.90617-2-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: use strscpy() to instead of strncpy()Xu Panda
The implementation of strscpy() is more robust and safer. That's now the recommended way to copy NUL-terminated strings. Signed-off-by: Xu Panda <xu.panda@zte.com.cn> Signed-off-by: Yang Yang <yang.yang29@zte.com> Reviewed-by: Dan Carpenter <error27@gmail.com> Link: https://lore.kernel.org/r/202212261905476729002@zte.com.cn Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: r8188eu: Prefer kcalloc over kzallocKang Minchul
Fixed following checkpatch.pl warning: * WARNING: Prefer kcalloc over kzalloc with multiply Instead of specifying (number of bytes) * (size) as arugment in kzalloc, prefer kcalloc. Signed-off-by: Kang Minchul <tegongkang@gmail.com> Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150 Reviewed-by: Martin Kaiser <martin@kaiser.cx> Link: https://lore.kernel.org/r/20221216223942.334221-1-tegongkang@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename EEPROMTxPower.., AutoloadF.. and SilentReset..Philipp Hortmann
Rename variable SilentResetRxSlotIndex to silent_reset_rx_slot_index, IC_Cut to ic_cut and Rf_Mode to rf_mode to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/60c1fb2861143c8736f061cf85e737b78c210a09.1673812850.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename EEPROMTxPower.., AutoloadF.. and SilentReset..Philipp Hortmann
Rename variable EEPROMTxPowerLevelCCK to eeprom_tx_pwr_level_cck, AutoloadFailFlag to autoload_fail_flag and SilentResetRxStuckEvent to silent_reset_rx_stuck_event to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/328bdd5fd16ba000d2083473e16e89ce2e2521ee.1673812850.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename EEPROMTherma.., EEPROMAntPw.. and EEPROMTxPow..Philipp Hortmann
Rename variable EEPROMThermalMeter to eeprom_thermal_meter, EEPROMAntPwDiff to eeprom_ant_pwr_diff and EEPROMTxPowerLevelOFDM24G to eeprom_tx_pwr_level_ofdm24g to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/f708533cc24af1e08f34b681b9e8e8c01dc7b8f5.1673812850.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename CrystalCap, EEPROMLegacyHTT.. and EEPROMCrys..Philipp Hortmann
Rename variable CrystalCap to crystal_cap, EEPROMLegacyHTTxPowerDiff to eeprom_legacy_ht_tx_pwr_diff and EEPROMCrystalCap to eeprom_crystal_cap to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/16337153218e9d1e25f90ca17774d1246086f1a7.1673812849.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename SetBWModeIn.., SwChnlInPro.. and ThermalMet..Philipp Hortmann
Rename variable SetBWModeInProgress to set_bw_mode_in_progress, SwChnlInProgress to sw_chnl_in_progress and ThermalMeter to thermal_meter to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/fc8bffbef60dba7aeb3bdfeab031c4e02e551c82.1673812849.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename bResetInPro.., framesyncMo.. and nCur40MhzPri..Philipp Hortmann
Rename variable bResetInProgress to reset_in_progress, framesyncMonitor to frame_sync_monitor and nCur40MhzPrimeSC to n_cur_40mhz_prime_sc to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/dc9a6353e2342f524d8cbf0de6a6340990dc913b.1673812849.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename rateCountDi.., ContinueDif.. and TxCounterPhilipp Hortmann
Rename variable rateCountDiffRecord to rate_count_diff_rec, ContinueDiffCount to continue_diff_count and TxCounter to tx_counter to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/c1e168e60a987ae64b64490c04ad79fd0f2f7583.1673812849.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename Record_CCK_2.., Record_CCK_4.. and DefaultIn..Philipp Hortmann
Rename variable Record_CCK_20Mindex to rec_cck_20m_idx, Record_CCK_40Mindex to rec_cck_40m_idx and DefaultInitialGain to def_initial_gain to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/2963e704afae2382bb7fded0453adbc4a8d48db3.1673812849.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename bLastDTPFlag_Low, OFDM_index and CCK_indexPhilipp Hortmann
Rename variable bLastDTPFlag_Low to last_dtp_flag_low, OFDM_index to ofdm_index and CCK_index to cck_index to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/1058b8be954b634f5c2cd9d4a46c33dbbe9459c5.1673812849.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename bDynamicTxHig.., bDynamicTxL.. and bLastDTPF..Philipp Hortmann
Rename variable bDynamicTxHighPower to dynamic_tx_high_pwr, bDynamicTxLowPower to dynamic_tx_low_pwr and bLastDTPFlag_High to last_dtp_flag_high to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/585a76cf4d2c805eada805c18c18ef207b9a4ea4.1673812849.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename SetRFPowerSta.., RfReg0Value and bTXPowerDa..Philipp Hortmann
Rename variable SetRFPowerStateInProgress to set_rf_pwr_state_in_progress, RfReg0Value to rf_reg_0value and bTXPowerDataReadFromEEPORM to tx_pwr_data_read_from_eeprom to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/01ff54a2c135ba6e3d06255102679d496fd2aef1.1673290428.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename MCSTxPowerL.., LegacyHTTxPowe.. and AntennaTx..Philipp Hortmann
Rename variable MCSTxPowerLevelOriginalOffset to mcs_tx_pwr_level_org_offset, LegacyHTTxPowerDiff to legacy_ht_tx_pwr_diff and AntennaTxPwDiff to antenna_tx_pwr_diff to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/271b3a9e1c23593e9ead925eb8415a584058fb56.1673290428.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename TxPowerLevelOFDM24G...Philipp Hortmann
Rename variable TxPowerLevelOFDM24G to tx_pwr_level_ofdm_24g, TxPowerLevelOFDM24G_A to tx_pwr_level_ofdm_24g_a and TxPowerLevelOFDM24G_C to tx_pwr_level_ofdm_24g_c to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/6bb354bd6f6387a26378de3b154d975b826a1a88.1673290428.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename TxPowerLevelCCK...Philipp Hortmann
Rename variable TxPowerLevelCCK to tx_pwr_level_cck, TxPowerLevelCCK_A to tx_pwr_level_cck_a and TxPowerLevelCCK_C to tx_pwr_level_cck_c to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/c18af327debcf85f3498be9c7a1492d501748669.1673290428.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename CCKPresentAtt...Philipp Hortmann
Rename variable CCKPresentAttentuation_20Mdefault to cck_present_attn_20m_def, CCKPresentAttentuation_40Mdefault to cck_present_attn_40m_def and CCKPresentAttentuation_difference to cck_present_attn_diff to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/1254f23aefd25075ef3e16719eed79b461f41e4c.1673290428.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename TSSI_13dBm, Pwr_Track and NumTotalRFPathPhilipp Hortmann
Rename variable TSSI_13dBm to tssi_13dBm, Pwr_Track to pwr_track and NumTotalRFPath to num_total_rf_path to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/d3bb45535b7babd1cb8df437ca238eb0ce93c9fe.1673290428.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8192e: Rename ChannelPlan, eeprom_ChannelPlan and CckPwEnlPhilipp Hortmann
Rename variable ChannelPlan to chnl_plan, eeprom_ChannelPlan to eeprom_chnl_plan and CckPwEnl to cck_pwr_enl to avoid CamelCase which is not accepted by checkpatch. Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> Link: https://lore.kernel.org/r/aee78a6adf41a2096898e0c0c5ef45e9f7e1659b.1673290428.git.philipp.g.hortmann@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: rtl8723bs: hal: Fix codespell-reported spelling mistakesAnup Sharma
They are appear to be spelling mistakes, Initially identified in a codespell report and never been addressed so far. drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c:656: regsiters ==> registers drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c:1696: beacause ==> because drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c:2092: Checl ==> Check drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c:2513: checksume ==> checksum drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c:2726: sequense ==> sequence drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c:2780: vlaue ==> value drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c:3409: equall ==> equal, equally Signed-off-by: Anup Sharma <anupnewsmail@gmail.com> Link: https://lore.kernel.org/r/Y61y+flJp9/jEicc@local Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17Staging: rtl8192u: ieee80211: Fix indentation errors by removing extra spacesAnup Sharma
Remove extra spaces before statements to fix following indentation warnings reported by checkpatch.pl. WARNING: Statements should start on a tabstop + struct delayed_work start_ibss_wq; Signed-off-by: Anup Sharma <anupnewsmail@gmail.com> Link: https://lore.kernel.org/r/Y6215u/jtmcgO6TY@local Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: ks7010: use strscpy() to instead of strncpy()Xu Panda
The implementation of strscpy() is more robust and safer. That's now the recommended way to copy NUL-terminated strings. Signed-off-by: Xu Panda <xu.panda@zte.com.cn> Signed-off-by: Yang Yang <yang.yang29@zte.com> Reviewed-by: Dan Carpenter <error27@gmail.com> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/202212261903245548969@zte.com.cn Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: vchiq_arm: fix enum vchiq_status return typesArnd Bergmann
gcc-13 notices a type mismatch between function declaration and definition for a few functions that have been converted from returning vchiq specific status values to regular error codes: drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c:662:5: error: conflicting types for 'vchiq_initialise' due to enum/integer mismatch; have 'int(struct vchiq_instance **)' [-Werror=enum-int-mismatch] drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c:1411:1: error: conflicting types for 'vchiq_use_internal' due to enum/integer mismatch; have 'int(struct vchiq_state *, struct vchiq_service *, enum USE_TYPE_E)' [-Werror=enum-int-mismatch] drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c:1468:1: error: conflicting types for 'vchiq_release_internal' due to enum/integer mismatch; have 'int(struct vchiq_state *, struct vchiq_service *)' [-Werror=enum-int-mismatch] Change the declarations to match the actual function definition. Fixes: a9fbd828be7f ("staging: vchiq_arm: drop enum vchiq_status from vchiq_*_internal") Cc: stable <stable@kernel.org> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Link: https://lore.kernel.org/r/20230117163957.1109872-1-arnd@kernel.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: vc04_services: vchiq: Drop custom return values from TODOUmang Jain
The custom return values (enum vchiq_status) has been dropped. Remove the TODO entry for the same. Signed-off-by: Umang Jain <umang.jain@ideasonboard.com> Tested-by: Stefan Wahren <stefan.wahren@i2se.com> Link: https://lore.kernel.org/r/20221223122404.170585-8-umang.jain@ideasonboard.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: vc04_services: Drop enum vchiq_status remnantsUmang Jain
Drop all references to enum vchiq_status as they are no longer in use. Signed-off-by: Umang Jain <umang.jain@ideasonboard.com> Tested-by: Stefan Wahren <stefan.wahren@i2se.com> Link: https://lore.kernel.org/r/20221223122404.170585-7-umang.jain@ideasonboard.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: vc04_services: vchiq_arm: Drop VCHIQ_RETRY usage on disconnectUmang Jain
Drop the usage of VCHIQ_RETRY when the vchiq has connection status VCHIQ_CONNSTATE_DISCONNECTED. Disconnected status will not be valid to carry on a retry, hence replace the VCHIQ_RETRY with -ENOTCONN. This patch removes the usage of vCHIQ_RETRY completely and act as intermediatory to address the TODO item: * Get rid of custom function return values for vc04_services/interface. Signed-off-by: Umang Jain <umang.jain@ideasonboard.com> Tested-by: Stefan Wahren <stefan.wahren@i2se.com> Link: https://lore.kernel.org/r/20221223122404.170585-6-umang.jain@ideasonboard.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: vc04_services: Drop VCHIQ_RETRY usageUmang Jain
Drop the usage of VCHIQ_RETRY vchiq_status enum type in most of the places and replace it with -EAGAIN. The exception to this replacement is vchiq_send_remote_use() and vchiq_send_remote_use_active() which will be addressed in the subsequent commit. This patch acts as intermediatory to address the TODO item: * Get rid of custom function return values for vc04_services/interface. Signed-off-by: Umang Jain <umang.jain@ideasonboard.com> Tested-by: Stefan Wahren <stefan.wahren@i2se.com> Link: https://lore.kernel.org/r/20221223122404.170585-5-umang.jain@ideasonboard.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: vc04_services: Drop VCHIQ_ERROR usageUmang Jain
Drop the usage of VCHIQ_ERROR vchiq_status enum type. Replace it with -EINVAL to report the error in most cases, -ENOMEM for out-of-memory errors and -EHOSTDOWN for service shutdown. This patch acts as intermediatory to address the TODO item: * Get rid of custom function return values for vc04_services/interface. Signed-off-by: Umang Jain <umang.jain@ideasonboard.com> Tested-by: Stefan Wahren <stefan.wahren@i2se.com> Link: https://lore.kernel.org/r/20221223122404.170585-4-umang.jain@ideasonboard.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: vc04_services: Drop VCHIQ_SUCCESS usageUmang Jain
Drop the usage of VCHIQ_SUCCESS vchiq_status enum type. Replace it with 0 to report the success status. This patch acts as intermediatory to address the TODO item: * Get rid of custom function return values for vc04_services/interface. Signed-off-by: Umang Jain <umang.jain@ideasonboard.com> Tested-by: Stefan Wahren <stefan.wahren@i2se.com> Link: https://lore.kernel.org/r/20221223122404.170585-3-umang.jain@ideasonboard.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: vc04_services: Replace vchiq_status return type to intUmang Jain
Modify the functions' signature using enum vchiq_status to return int. Currently, this patch only touches the function signatures and in subsequent patches each vchiq_status enumerated value will be replaced by a integer value. This patch acts as an initial point to address the TODO item: * Get rid of custom function return values for vc04_services/interface. Signed-off-by: Umang Jain <umang.jain@ideasonboard.com> Tested-by: Stefan Wahren <stefan.wahren@i2se.com> Link: https://lore.kernel.org/r/20221223122404.170585-2-umang.jain@ideasonboard.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-17staging: vchiq_core: Add comments to remote event partsPhil Elwell
struct remote_event and the related functions remote_event_*() provides a higher function between ARM core and VPU. It's very helpful for a reviewer to have explaining comments about these parts. Signed-off-by: Phil Elwell <phil@raspberrypi.com> Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com> Link: https://lore.kernel.org/r/20221222141553.138563-1-stefan.wahren@i2se.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>