summaryrefslogtreecommitdiffstats
path: root/drivers/staging/rtl8188eu
AgeCommit message (Collapse)AuthorFilesLines
2019-02-28staging: rtl8188eu: remove unused P2P_PRIVATE_IOCTL_SET_LENMichael Straube1-2/+0
Defined P2P_PRIVATE_IOCTL_SET_LEN is not used in the driver code, so remove it from wifi.h. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-02-28staging: rtl8188eu: remove unused enum P2P_PROTO_WK_IDMichael Straube1-10/+0
Enumeration P2P_PROTO_WK_ID is not used in the driver code, so remove it from wifi.h. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-02-26staging: rtl8188eu: cleanup comparsions to NULL in rtl8188eu_xmit.cMichael Straube1-2/+2
Use !x instead of x == NULL. Reported by checkpatch. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-02-26staging: rtl8188eu: add spaces around '*' in rtl8188e_cmd.cMichael Straube1-4/+4
Add spaces around '*' to follow kernel coding style. Reported by checkpatch. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-02-26staging: rtl8188eu: remove unused function declarationsMichael Straube2-10/+0
There are no definitions of odm_DIGbyRSSI_LPS(), ODM_PhyStatusQuery() and ODM_MacStatusQuery() in the driver code. So remove the unused declarations from the headers odm.h and odm_hwconfig.h. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-02-26staging: rtl8188eu: remove blank line between declarationsMichael Straube1-1/+0
Remove unnecessary blank line between declarations. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-02-26staging: rtl8188eu: cleanup declarations in rtl8188e_cmd.cMichael Straube1-14/+14
Replace tabs with spaces in declarations to cleanup whitespace. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-02-26staging: rtl8188eu: remove unnecessary parentheses in rtl8188e_cmd.cMichael Straube1-21/+21
Remove unnecessary parentheses reported by checkpatch. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-02-19staging: rtl8188eu: fix bad indentation for conditional statementStephen Martin1-1/+1
Fixed else block indentation Signed-off-by: Stephen Martin <lockwood@opperline.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-02-04staging: rtl8188eu: cleanup ODM_CmnInfoPtrArrayHook()Michael Straube1-10/+1
Convert single case switch to if statement to cleanup and simplify code in ODM_CmnInfoPtrArrayHook(). Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-30staging: rtl8188eu: refactor rtw_reset_securitypriv()Michael Straube1-14/+15
Move the declaration of 'psec_priv' out of the else path and use it in the if path as well to improve readability. Also clears line over 80 characters checkpatch warnings. Suggested-by: Joe Perches <joe@perches.com> Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-30staging: rtl8188eu: &array[0] -> arrayMichael Straube1-2/+2
Change '&array[0]' to just 'array' in rtw_reset_securitypriv(). Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-30staging: rtl8188eu: remove unncessary asignment to cleanup long lineMichael Straube1-2/+1
Instead of first asign 'wrqu.data.length = p - buff' use 'p - buff' directly in min_t() in the subsequent asignment. Clears a line over 80 characters checkpatch warning. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-30staging: rtl8188eu: cleanup declarations in mlme_linux.cMichael Straube1-4/+4
Replace tabs with spaces in declarations to cleanup whitespace. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-30staging: rtl8188eu: remove unnecessary initializationsMichael Straube1-3/+3
The local variables backup_index, backup_counter and backup_time in rtw_reset_securitypriv() are all asigned before their uses, so initialization to zero is not necessary. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-30staging: rtl8188eu: cleanup comments in mlme_linux.cMichael Straube1-6/+11
Cleanup comments to avoid lines over 80 characters and follow kernel style for block comments. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-28Merge 5.0-rc4 into staging-nextGreg Kroah-Hartman1-0/+1
We need the staging fixes in here as well. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-25staging: rtw_ieee80211: fix constant comparison warningStephen Martin1-2/+2
Fixed comparison on right side of test warnings. Signed-off-by: Stephen Martin <lockwood@opperline.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-18staging: rtl8188eu: cleanup indenting issue in mlme_linux.cMichael Straube1-3/+2
Cleanup indenting issue reported by checkpatch. CHECK: Alignment should match open parenthesis Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-18staging: rtl8188eu: add spaces around operators in mlme_linux.cMichael Straube1-2/+2
Add spaces around '+' and '-' to follow kernel coding style. Reported by checkpatch. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-18staging: rtl8188eu: add spaces around operators in os_intfs.cMichael Straube1-3/+3
Add spaces around '+', '<<' and '*' to follow kernel coding style. Reported by checkpatch. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-18staging: rtl8188eu: cleanup declarations in os_intfs.cMichael Straube1-6/+6
Replace tabs with spaces and/or remove extra spaces in declarations. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-15staging: rtl8188eu: Refactoring struct ndis_802_11_ssid from CamelCase to ↵Florian Büstgens13-96/+96
correct code style. rtl8188eu uses CamelCase for many struct members. Refactors the ndis_802_11_ssid members Ssid and SsidLength to keep correct code style. Issue found by checkpatch. Signed-off-by: Florian Büstgens <flbue@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-15staging: rtl8188eu: Add device code for D-Link DWA-121 rev B1Michael Straube1-0/+1
This device was added to the stand-alone driver on github. Add it to the staging driver as well. Link: https://github.com/lwfinger/rtl8188eu/commit/a0619a07cd1e Signed-off-by: Michael Straube <straube.linux@gmail.com> Acked-by: Larry Finger <Larry.Finger@lwfinger.net> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-15staging: rtl8188eu: remove unnecessary parentheses in os_intfs.cMichael Straube1-2/+2
Remove unnecessary parentheses reported by checkpatch. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-15staging: rtl8188eu: Replace kzalloc with kcallocGustavo A. R. Silva1-1/+3
Replace kzalloc() function with its 2-factor argument form, kcalloc(). This patch replaces cases of: kzalloc(a * b, gfp) with: kcalloc(a, b, gfp) This code was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-07staging: rtl8188eu: Fix module loading from tasklet for WEP encryptionLarry Finger1-2/+2
Commit 2b2ea09e74a5 ("staging:r8188eu: Use lib80211 to decrypt WEP-frames") causes scheduling while atomic bugs followed by a hard freeze whenever the driver tries to connect to a WEP-encrypted network. Experimentation showed that the freezes were eliminated when module lib80211 was preloaded, which can be forced by calling lib80211_get_crypto_ops() directly rather than indirectly through try_then_request_module(). With this change, no BUG messages are logged. Fixes: 2b2ea09e74a5 ("staging:r8188eu: Use lib80211 to decrypt WEP-frames") Cc: Stable <stable@vger.kernel.org> # v4.17+ Cc: Michael Straube <straube.linux@gmail.com> Cc: Ivan Safonov <insafonov@gmail.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-07staging: rtl8188eu: Fix module loading from tasklet for CCMP encryptionLarry Finger1-1/+1
Commit 6bd082af7e36 ("staging:r8188eu: use lib80211 CCMP decrypt") causes scheduling while atomic bugs followed by a hard freeze whenever the driver tries to connect to a CCMP-encrypted network. Experimentation showed that the freezes were eliminated when module lib80211 was preloaded, which can be forced by calling lib80211_get_crypto_ops() directly rather than indirectly through try_then_request_module(). With this change, no BUG messages are logged. Fixes: 6bd082af7e36 ("staging:r8188eu: use lib80211 CCMP decrypt") Cc: Stable <stable@vger.kernel.org> # v4.17+ Reported-and-tested-by: Michael Straube <straube.linux@gmail.com> Cc: Ivan Safonov <insafonov@gmail.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: cleanup brace coding style issuesMichael Straube5-12/+9
Cleanup brace coding style issues reported by checkpatch. ERROR: space required before the open brace '{' WARNING: braces {} are not necessary for single statement blocks CHECK: Unbalanced braces around else statement Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: add spaces around '&' in rtw_mlme_ext.cMichael Straube1-45/+45
Add spaces around '&' to follow kernel coding style. Reported by checkpatch. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: change return type of is_basicrate() to boolMichael Straube1-1/+1
The function is_basicrate() returns true or false, so change the return type from int to bool. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: simplify null array initializationsMichael Straube2-6/+4
Simplfy initialization of null arrays to improve readability and save some lines. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: change order of declarations to improve readabilityMichael Straube1-1/+1
Change the order of array declarations in rtw_mlme_ext.c to improve readability. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: make some arrays static in rtw_mlme_ext.cMichael Straube2-8/+3
Make some arrays that are only used in rtw_mlme_ext.c static and remove the corresponding extern declarations from rtw_mlme_ext.h. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: constify some arraysMichael Straube4-27/+27
The values of these arrays in rtw_mlme_ext.c and rtw_wlan_util.c are never changed, so make them const. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: convert unsigned char arrays to u8Michael Straube4-27/+27
Change the type of some arrays from unsigned char to u8. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: remove redundant declaration in rtw_mlme_ext.cMichael Straube1-2/+0
The array REALTEK_96B_IE is already declared in rtw_mlme.h, so remove the declaration in rtw_mlme_ext.c. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: remove unused arrays WFD_OUI and WMM_INFO_OUIMichael Straube2-4/+0
The arrays WFD_OUI and WMM_INFO_OUI are not used anywhere, so remove them. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: remove unnecessary parentheses in rtw_mlme_ext.cMichael Straube1-161/+161
Remove unnecessary parentheses, most of them reported by checkpatch. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: remove unnecessary comments in rtw_mlme_ext.cMichael Straube1-4/+4
Remove comments from 'endif's where the corresponding 'if' is just a few lines above to improve readability. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: add blank line after declarationsMichael Straube1-0/+1
Add a missing blank line after declarations in rtw_mlme_ext.c. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: remove blank lines between declarationsMichael Straube1-2/+0
Remove blank lines between declarations in rtw_mlme_ext.c. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: remove commented declarations in rtw_mlme_ext.cMichael Straube1-3/+0
Remove unused/commented declarations. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: replace tabs with spaces in rtw_mlme_ext.cMichael Straube1-6/+6
Replace tabs with spaces where appropriate. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-19staging: rtl8188eu: cleanup declarations in rtw_mlme_ext.cMichael Straube1-241/+241
Replace tabs with spaces and/or remove spaces in declarations. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-12staging: rtl8188eu: reuse Hal_GetChnlGroup88E()Michael Straube3-15/+6
Use Hal_GetChnlGroup88E() instead of duplicating it's code in get_rx_power_val_by_reg(). Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-12staging: rtl8188eu: simplify loop in rtl88eu_phy_iq_calibrate()Michael Straube1-9/+4
Zeroing the array result[m][n] and setting only the values at even 'n's simplifies the code and slightly reduces object file size. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-06staging: rtl8188eu: remove unused code in rtw_cmd.cMichael Straube1-12/+0
Remove unused/commented code in rtw_cmd.c. Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-06staging: rtl8188eu: rename struct field Wifi_Error_StatusMichael Straube3-5/+5
Rename struct field Wifi_Error_Status to avoid CamelCase. Wifi_Error_Status -> wifi_error_status Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-12-06staging: rtl8188eu: replace if else with ternary operatorMichael Straube1-4/+3
Replace if else with a single call and ternary operator to slightly reduce object file size. Also clears a checkpatch warning: WARNING: Statements should start on a tabstop Suggested-by: Joe Perches <joe@perches.com> Signed-off-by: Michael Straube <straube.linux@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>