summaryrefslogtreecommitdiffstats
path: root/drivers/staging/rtl8712
AgeCommit message (Collapse)Author
2020-07-29Staging: rtl8712: Fixed a coding sytle issueAnkit Baluni
Removed braces for a 'if' condition as it contain only single line & there is no need for braces for such case according to coding style rules. Signed-off-by: Ankit Baluni <b18007@students.iitmandi.ac.in> Link: https://lore.kernel.org/r/20200729074541.1972-1-b18007@students.iitmandi.ac.in Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-28staging: rtl8712: Use fallthrough pseudo-keywordGustavo A. R. Silva
Replace the existing /* fall through */ comments and its variants with the new pseudo-keyword macro fallthrough[1]. [1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org> Link: https://lore.kernel.org/r/20200727185838.GA29595@embeddedor Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-17staging: rtl*/security: Use static const in array declarationsJoe Perches
Use static const in declarations where appropriate. Signed-off-by: Joe Perches <joe@perches.com> Link: https://lore.kernel.org/r/818bbd25924f0c733a4a39d426fd30392d4eae80.camel@perches.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-17staging: rtl8712: handle firmware load failureRustam Kovhaev
when firmware fails to load we should not call unregister_netdev() this patch fixes a race condition between rtl871x_load_fw_cb() and r871xu_dev_remove() and fixes the bug reported by syzbot Reported-by: syzbot+80899a8a8efe8968cde7@syzkaller.appspotmail.com Link: https://syzkaller.appspot.com/bug?extid=80899a8a8efe8968cde7 Signed-off-by: Rustam Kovhaev <rkovhaev@gmail.com> Cc: stable <stable@vger.kernel.org> Link: https://lore.kernel.org/r/20200716151324.1036204-1-rkovhaev@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-10staging: rtl8712/: Using comparison to true is error proneJohn Oldman
clear below issues reported by checkpatch.pl: CHECK: Using comparison to true is error prone CHECK: Comparison to NULL should be written "!oldest" Signed-off-by: John Oldman <john.oldman@polehill.co.uk> Link: https://lore.kernel.org/r/20200710113113.1648-1-john.oldman@polehill.co.uk Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-10staging: rtl8712: Use proper format in call to dev_err()Mauro Dreissig
In the call to dev_err(), remove the cast of size_t to int and change the format string accordingly. As reported by the kernel test robot, the correct format string for a size_t argument should be %zu. Reported-by: kernel test robot <lkp@intel.com> Signed-off-by: Mauro Dreissig <mukadr@gmail.com> Link: https://lore.kernel.org/r/20200705143552.9368-6-mukadr@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-10staging: rtl8712: Remove variable 'raw' from rtl871x_open_fw()Mauro Dreissig
Remove useless variable 'raw' from function rtl871x_open_fw() making the code a bit easier to understand. Signed-off-by: Mauro Dreissig <mukadr@gmail.com> Link: https://lore.kernel.org/r/20200705143552.9368-5-mukadr@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-10staging: rtl8712: Use ETH_ALEN instead of hardcoded valueMauro Dreissig
Use macro ETH_ALEN which defines the number of octets in an ethernet address. Signed-off-by: Mauro Dreissig <mukadr@gmail.com> Link: https://lore.kernel.org/r/20200705143552.9368-4-mukadr@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-10staging: rtl8712: Simplify expressions with boolean logicMauro Dreissig
Simplify some expressions by using boolean operations. Signed-off-by: Mauro Dreissig <mukadr@gmail.com> Link: https://lore.kernel.org/r/20200705143552.9368-3-mukadr@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-10staging: rtl8712: Replace constant 49152 with expression 48 * 1024Mauro Dreissig
This way we don't need the comment stating that 49152 equals 48k. Signed-off-by: Mauro Dreissig <mukadr@gmail.com> Link: https://lore.kernel.org/r/20200705143552.9368-2-mukadr@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-10staging: rtl8712: Annotate r8712_sitesurvey_cmd()Mauro Dreissig
Add __must_hold() sparse annotation to r8712_sitesurvey_cmd(), replacing the comments on top of the function. Signed-off-by: Mauro Dreissig <mukadr@gmail.com> Link: https://lore.kernel.org/r/20200705180944.20958-1-mukadr@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-03staging: rtl8712: base_types: Remove unused macrosMauro Dreissig
Those #define's are not used anywhere, get rid of them. Signed-off-by: Mauro Dreissig <mukadr@gmail.com> Link: https://lore.kernel.org/r/20200701214420.5566-3-mukadr@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-03staging: rtl8712: Replace FIELD_OFFSET() with offsetof()Mauro Dreissig
Use the existing offsetof() macro instead of duplicating code. Signed-off-by: Mauro Dreissig <mukadr@gmail.com> Link: https://lore.kernel.org/r/20200701214420.5566-2-mukadr@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-03staging: rtl8712: use common ieee80211 constantsMichael Straube
Many defined constants in wifi.h are unused and/or available from <linux/ieee80211.h>, some with slightly different names. Use the common ones, rename where necessary and remove unused. Signed-off-by: Michael Straube <straube.linux@gmail.com> Link: https://lore.kernel.org/r/20200701164213.4205-1-straube.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-01staging: rtl8712: remove some ieee80211 constants from wifi.hMichael Straube
The constants IEEE80211_BAR_CTRL_ACK_POLICY_NORMAL and IEEE80211_BAR_CTRL_CBMTID_COMPRESSED_BA are not used in the driver code and, if ever needed, available from 'include/linux/ieee80211.h'. Remove them from wifi.h. Signed-off-by: Michael Straube <straube.linux@gmail.com> Link: https://lore.kernel.org/r/20200629171405.7711-3-straube.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-06-18staging:rtl8712: avoid skb_clone after skb allocation failIvan Safonov
The skb allocated when out of memory is likely to be discarded during subsequent processing. Signed-off-by: Ivan Safonov <insafonov@gmail.com> Link: https://lore.kernel.org/r/20200531110548.9318-1-insafonov@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-06-16staging: rtl8712: Remove unnecesary else after return statement.Sebastian Arriola
This patch fixes the checkpatch.pl warning: WARNING: else is not generally useful after a break or return 490: FILE: drivers/staging/rtl8712/rtl8712_recv.c:490: return false; else Signed-off-by: Sebastian Arriola <sebdeveloper6952@gmail.com> Link: https://lore.kernel.org/r/20200615155131.GA4563@sevic69 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-06-16staging: rtl8712: switch to common ieee80211 headersPascal Terjan
This patch switches to <linux/ieee80211.h> and <net/cfg80211.h> and deletes a lot of duplicate definitions plus many unused ones. Non obvious changes: - struct ieee80211_ht_cap is different enough that I preferred to keep (and rename) it for now. - mcs_rate in translate_scan was not read after being set, so I deleted that part rather than using the renamed struct - WLAN_CAPABILITY_BSS is replaced with WLAN_CAPABILITY_ESS which is the corresponding one with same value Signed-off-by: Pascal Terjan <pterjan@google.com> Link: https://lore.kernel.org/r/20200609194848.166130-1-pterjan@google.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-05-27staging: rtl8712: Fix IEEE80211_ADDBA_PARAM_BUF_SIZE_MASKPascal Terjan
The value in shared headers was fixed 9 years ago in commit 8d661f1e462d ("ieee80211: correct IEEE80211_ADDBA_PARAM_BUF_SIZE_MASK macro") and while looking at using shared headers for other duplicated constants I noticed this driver uses the old value. The macros are also defined twice in this file so I am deleting the second definition. Signed-off-by: Pascal Terjan <pterjan@google.com> Cc: stable <stable@vger.kernel.org> Link: https://lore.kernel.org/r/20200523211247.23262-1-pterjan@google.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-16staging: rtl8712: correct spelling mistake in commentMichael Straube
Correct a spelling mistake discovered by checkpatch. attatch -> attach Signed-off-by: Michael Straube <straube.linux@gmail.com> Link: https://lore.kernel.org/r/20200413215109.15749-1-straube.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-13staging: rtl8712: fix multiline derefernce warningsAiman Najjar
This patch fixes remaining checkpatch warnings in rtl871x_xmit.c: WARNING: Avoid multiple line dereference - prefer 'psecuritypriv->PrivacyKeyIndex' 636: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:636: + (u8)psecuritypriv-> + PrivacyKeyIndex); WARNING: Avoid multiple line dereference - prefer 'psecuritypriv->XGrpKeyid' 643: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:643: + (u8)psecuritypriv-> + XGrpKeyid); WARNING: Avoid multiple line dereference - prefer 'psecuritypriv->XGrpKeyid' 652: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:652: + (u8)psecuritypriv-> + XGrpKeyid); Signed-off-by: Aiman Najjar <aiman.najjar@hurranet.com> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/98805a72b92e9bbf933e05b827d27944663b7bc1.1585508171.git.aiman.najjar@hurranet.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-13staging: rtl8712: code improvements to make_wlanhdrAiman Najjar
1. Refactor make_wlanhdr to improve code style. 2. Use ether_addr_copy instead of memcpy to copy addresses. Suggested-by: Joe Perches <joe@perches.com> Signed-off-by: Aiman Najjar <aiman.najjar@hurranet.com> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/275773a0379e4a03839cd832d2ed952fd7bfee48.1585508171.git.aiman.najjar@hurranet.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-13staging: rtl8712: fix checkpatch warningsAiman Najjar
This patch fixes multiline dereference warnings in rtl871x_xmit.c: WARNING: Avoid multiple line dereference - prefer 'psecuritypriv->XGrptxmickey' 379: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:379: + psecuritypriv-> + XGrptxmickey[psecuritypriv-> WARNING: Avoid multiple line dereference - prefer 'psecuritypriv->XGrpKeyid' 380: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:380: + XGrptxmickey[psecuritypriv-> + XGrpKeyid].skey); Signed-off-by: Aiman Najjar <aiman.najjar@hurranet.com> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/ddd296c34c5b0206dfe5cf2e6cbe40e0a118c257.1585508171.git.aiman.najjar@hurranet.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-13staging: rtl8712: fix long-line checkpatch warningAiman Najjar
This patch fixes the following warning in rtl871x_xmit.c: WARNING: line over 80 characters 130: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:130: + pxmitbuf->pallocated_buf = kmalloc(MAX_XMITBUF_SZ + XMITBUF_ALIGN_SZ, Signed-off-by: Aiman Najjar <aiman.najjar@hurranet.com> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/de477e0d8f352c1d6cd75d64d84ac6f9017db254.1585508171.git.aiman.najjar@hurranet.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-13staging: rtl8712: fix checkpatch long-line warningAiman Najjar
This patch fixes these two long-line checkpatch warnings in rtl871x_xmit.c: WARNING: line over 80 characters \#74: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:74: + * Please allocate memory with the sz = (struct xmit_frame) * NR_XMITFRAME, WARNING: line over 80 characters \#79: FILE: drivers/staging//rtl8712/rtl871x_xmit.c:79: + kmalloc(NR_XMITFRAME * sizeof(struct xmit_frame) + 4, GFP_ATOMIC); Signed-off-by: Aiman Najjar <aiman.najjar@hurranet.com> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/acd523d0d24cc81fae9eb933a066d87815587cee.1585508171.git.aiman.najjar@hurranet.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-03-20staging: rtl8712: Remove unnecessary bracesGokce Kuler
Remove unnecessary braces for single statement block Signed-off-by: Gokce Kuler <gokcekuler@gmail.com> Link: https://lore.kernel.org/r/20200320000326.GA9349@siyah2 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-03-19staging: rtl8712: Fix for long lines in Kconfig helpR Veera Kumar
Fixes two long line in Kconfig help. Found using checkpatch.pl Signed-off-by: R Veera Kumar <vkor@vkten.in> Link: https://lore.kernel.org/r/20200319095513.GA3078@tulip.local Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-03-19staging: rtl8712: Correct a typo in a commentR Veera Kumar
Correct a single typo in a comment. Misspelling found using checkpatch.pl. Signed-off-by: R Veera Kumar <vkor@vkten.in> Link: https://lore.kernel.org/r/20200319094358.GA2751@tulip.local Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-03-12staging: rtl8712: Fixes for simple typos in C commentsR Veera Kumar
Fixes for simple typos in C comments. Found using checkpatch.pl. Signed-off-by: R Veera Kumar <vkor@vkten.in> Link: https://lore.kernel.org/r/20200312091042.GA4246@tulip.local Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-02-23staging: Replace zero-length array with flexible-array memberGustavo A. R. Silva
The current codebase makes use of the zero-length array language extension to the C90 standard, but the preferred mechanism to declare variable-length types such as these ones is a flexible array member[1][2], introduced in C99: struct foo { int stuff; struct boo array[]; }; By making use of the mechanism above, we will get a compiler warning in case the flexible array does not occur last in the structure, which will help us prevent some kind of undefined behavior bugs from being inadvertently introduced[3] to the codebase from now on. Also, notice that, dynamic memory allocations won't be affected by this change: "Flexible array members have incomplete type, and so the sizeof operator may not be applied. As a quirk of the original implementation of zero-length arrays, sizeof evaluates to zero."[1] This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com> Link: https://lore.kernel.org/r/20200220132908.GA30501@embeddedor Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-01-22staging: rtl8712: simplify evm_db2percentage()Michael Straube
Use clamp() to simplify function evm_db2percentage() and reduce object file size. Signed-off-by: Michael Straube <straube.linux@gmail.com> Link: https://lore.kernel.org/r/20200118195305.16685-3-straube.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-12-10staging: rtl8712: fix interface sanity checkJohan Hovold
Make sure to use the current alternate setting when verifying the interface descriptors to avoid binding to an invalid interface. Failing to do so could cause the driver to misbehave or trigger a WARN() in usb_submit_urb() that kernels with panic_on_warn set would choke on. Fixes: 2865d42c78a9 ("staging: r8712u: Add the new driver to the mainline kernel") Cc: stable <stable@vger.kernel.org> # 2.6.37 Signed-off-by: Johan Hovold <johan@kernel.org> Link: https://lore.kernel.org/r/20191210114751.5119-3-johan@kernel.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-11-16staging: rtl*: Remove tasklet callback castsKees Cook
In order to make the entire kernel usable under Clang's Control Flow Integrity protections, function prototype casts need to be avoided because this will trip CFI checks at runtime (i.e. a mismatch between the caller's expected function prototype and the destination function's prototype). Many of these cases can be found with -Wcast-function-type, which found that the rtl wifi drivers had a bunch of needless function casts. Remove function casts for tasklet callbacks in the various drivers. Signed-off-by: Kees Cook <keescook@chromium.org> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/201911150926.2894A4F973@keescook Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-28staging: rtl8712: Fix Alignment of open parenthesisCristiane Naves
Fix alignment should match open parenthesis. Issue found by checkpatch. Signed-off-by: Cristiane Naves <cristianenavescardoso09@gmail.com> Link: https://lore.kernel.org/r/2a6e8fbef7b9e72d95b7c4a7cbcce08a9e231d07.1572276208.git.cristianenavescardoso09@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-27staging: rtl8712: Remove lines before a close braceCristiane Naves
Fix Blank lines aren't necessary before a close brace '}'. Issue found by checkpatch. Signed-off-by: Cristiane Naves <cristianenavescardoso09@gmail.com> Link: https://lore.kernel.org/r/8c74dcd9afaa528a80804081f582792045bb7a7a.1572121059.git.cristianenavescardoso09@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-14staging: rtl8712: clean up function headersWambui Karuga
Remove unnecessary line-breaks in function headers to improve readability of function headers. Signed-off-by: Wambui Karuga <wambui.karugax@gmail.com> Link: https://lore.kernel.org/r/c14b9e60b1e9bab635bc9527cbd2a2a07436ba44.1570918228.git.wambui.karugax@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-14staging: rtl8712: remove unnecessary return variablesWambui Karuga
Remove variables that are only used to hold and return constants and have the functions directly return the constants. Issue found by coccinelle: @@ local idexpression ret; expression e; @@ -ret = +return e; -return ret; Signed-off-by: Wambui Karuga <wambui.karugax@gmail.com> Link: https://lore.kernel.org/r/f61a0f036af24228c682c6b12c3a8e6cf6736185.1570918228.git.wambui.karugax@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-10staging: rtl8712: Align function arguments with opening paranthesisWambui Karuga
Fixes checkpatch.pl "CHECK Alignment should match open parenthesis" on drivers/staging/rtl8712/rtl8712_recv.c:122 Signed-off-by: Wambui Karuga <wambui.karugax@gmail.com> Link: https://lore.kernel.org/r/20191008195350.20544-1-wambui.karugax@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-07staging: rtl8712: align arguments with open parenthesis in file rtl8712_led.cGabriela Bittencourt
Cleans up checks of "Alignment should match open parenthesis" Signed-off-by: Gabriela Bittencourt <gabrielabittencourt00@gmail.com> Link: https://lore.kernel.org/r/20191007003902.21911-1-gabrielabittencourt00@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04staging: rtl8712: fix boundary condition for nRohit Sarkar
Now that snprintf is replaced by scnprintf n >= MAX_WPA_IE_LEN doesn't make sense as the maximum value n can take is MAX_WPA_IE_LEN. Signed-off-by: Rohit Sarkar <rohitsarkar5398@gmail.com> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/20191002170518.GA1688@SARKAR Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30staging: rtl8712: Replace snprintf with scnprintfRohit Sarkar
When the number of bytes to be printed exceeds the limit snprintf returns the number of bytes that would have been printed (if there was no truncation). This might cause issues, hence use scnprintf which returns the actual number of bytes printed to buffer always. Signed-off-by: Rohit Sarkar <rohitsarkar5398@gmail.com> Link: https://lore.kernel.org/r/20190910184931.GA8228@SARKAR Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-27staging: rtl8712: wifi: checkpatch style fixTaihsiang Ho (tai271828)
Remove multiple blank lines. Signed-off-by: Taihsiang Ho (tai271828) <tai271828@gmail.com> Link: https://lore.kernel.org/r/20190826052018.18649-1-tai271828@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-21staging: rtl8712: Improve naming of include hearder guardsChristophe JAILLET
Choose a better name for the include hearder guard used in rtl871x_io.h. '_IO_H_' is to generic and does not match the comment after the #endif. Use '_RTL871X_IO_H_' instead. Also make the comments in the #endif /* XXX */ match the name used in #ifndef. Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Link: https://lore.kernel.org/r/20190818150609.3376-1-christophe.jaillet@wanadoo.fr Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-14Staging: rtl8712: rtl8712_recv: fixed 80 character length warningMerwin Trever Ferrao
When the checkpatch.pl script was run, it showed lines with length more than 80 characters in rtl8712_recv.c file. Fixed by breaking it up into two lines within 80 characters. Signed-off-by: Merwin Trever Ferrao <merwintf@gmail.com> Link: https://lore.kernel.org/r/20190813065806.GA23606@IoT-COE Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-14staging: rtl8712: r8712_dump_aggr_xframe(): Change type to voidNishka Dasgupta
Change return type of r8712_dump_aggr_xframe from u8 to void as it always returns _SUCCESS and its return value is never used. Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com> Link: https://lore.kernel.org/r/20190813044638.16348-4-nishkadg.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-14staging: rtl8712: r8712_xmitframe_aggr_1st(): Change return type to voidNishka Dasgupta
Change return type of r8712_xmitframe_aggr_1st from u8 to void as it always returns _SUCCESS and its return value is never used. Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com> Link: https://lore.kernel.org/r/20190813044638.16348-3-nishkadg.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-14staging: rtl8712: r8712_append_mpdu_unit(): Change return typeNishka Dasgupta
Change return type of r8712_append_mpdu_unit from u8 to void and remove its return statement as it always returns only _SUCCESS. Modify call sites to simply call this function instead of checking its return value, and execute all the statements in the if-block for when the function returns _SUCCESS. Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com> Link: https://lore.kernel.org/r/20190813044638.16348-2-nishkadg.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-14staging: rtl8712: xmitframe_addmic(): Change return values and typeNishka Dasgupta
Change return values of xmitframe_addmic from _SUCCESS and _FAIL to 0 and -ENOMEM respectively. Modify call sites to check for non-zero values instead of _FAIL. Also change return type from sint to int. Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com> Link: https://lore.kernel.org/r/20190813044638.16348-1-nishkadg.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-12staging: rtl8712: r8712_construct_txaggr_cmd_hdr(): Change return typeNishka Dasgupta
Change return type of r8712_construct_txaggr_cmd_hdr from u8 to void as it always returns _SUCCESS and its return value is never used. Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com> Link: https://lore.kernel.org/r/20190809052353.5308-8-nishkadg.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-12staging: rtl8712: r8712_construct_txaggr_cmd_desc(): Change return typeNishka Dasgupta
Change return type of r8712_construct_txaggr_cmd_desc from u8 to void (and remove its return statement) as it always returns _SUCCESS and its return value is never stored, checked or otherwise used. Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com> Link: https://lore.kernel.org/r/20190809052353.5308-7-nishkadg.linux@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>