summaryrefslogtreecommitdiff
path: root/drivers/staging/rtl8188eu
AgeCommit message (Collapse)Author
2018-01-25staging: rtl8188eu: remove redundant initialization of 'pwrcfgcmd'Colin Ian King
Structure pwrcfgcmd is being zero'd at initialization however this value is never read as few statements later in a loop it is being assigned a new value, hence the initialization is redundant and can be removed. Cleans up clang warning: drivers/staging/rtl8188eu/hal/pwrseqcmd.c:25:20: warning: Value stored to 'pwrcfgcmd' during its initialization is never read Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-12-13rtl8188eu: Fix a possible sleep-in-atomic bug in set_tx_beacon_cmdJia-Ju Bai
The driver may sleep under a spinlock. The function call path is: update_beacon (acquire the spinlock) update_BCNTIM set_tx_beacon_cmd kzalloc(GFP_KERNEL) --> may sleep kmemdup(GFP_KERNEL) --> may sleep To fix it, GFP_KERNEL is replaced with GFP_ATOMIC. This bug is found by my static analysis tool(DSAC) and checked by my code review. Signed-off-by: Jia-Ju Bai <baijiaju1990@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-11-28staging: rtl8188eu: Fix incorrect response to SIOCGIWESSIDLarry Finger
When not associated with an AP, wifi device drivers should respond to the SIOCGIWESSID ioctl with a zero-length string for the SSID, which is the behavior expected by dhcpcd. Currently, this driver returns an error code (-1) from the ioctl call, which causes dhcpcd to assume that the device is not a wireless interface and therefore it fails to work correctly with it thereafter. This problem was reported and tested at https://github.com/lwfinger/rtl8188eu/issues/234. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-11-13Merge tag 'staging-4.15-rc1' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging Pull staging and IIO updates from Greg KH: "Here is the "big" staging and IIO driver update for 4.15-rc1. Lots and lots of little changes, almost all minor code cleanups as the Outreachy application process happened during this development cycle. Also happened was a lot of IIO driver activity, and the typec USB code moving out of staging to drivers/usb (same commits are in the USB tree on a persistent branch to not cause merge issues.) Overall, it's a wash, I think we added a few hundred more lines than removed, but really only a few thousand were modified at all. All of these have been in linux-next for a while. There might be a merge issue with Al's vfs tree in the pi433 driver (take his changes, they are always better), and the media tree with some of the odd atomisp cleanups (take the media tree's version)" * tag 'staging-4.15-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (507 commits) staging: lustre: add SPDX identifiers to all lustre files staging: greybus: Remove redundant license text staging: greybus: add SPDX identifiers to all greybus driver files staging: ccree: simplify ioread/iowrite staging: ccree: simplify registers access staging: ccree: simplify error handling logic staging: ccree: remove dead code staging: ccree: handle limiting of DMA masks staging: ccree: copy IV to DMAable memory staging: fbtft: remove redundant initialization of buf staging: sm750fb: Fix parameter mistake in poke32 staging: wilc1000: Fix bssid buffer offset in Txq staging: fbtft: fb_ssd1331: fix mirrored display staging: android: Fix checkpatch.pl error staging: greybus: loopback: convert loopback to use generic async operations staging: greybus: operation: add private data with get/set accessors staging: greybus: loopback: Fix iteration count on async path staging: greybus: loopback: Hold per-connection mutex across operations staging: greybus/loopback: use ktime_get() for time intervals staging: fsl-dpaa2/eth: Extra headroom in RX buffers ...
2017-11-03staging: rtl8188eu: avoid a null dereference on pmlmeprivColin Ian King
There is a check on pmlmepriv before dereferencing it when vfree'ing pmlmepriv->free_bss_buf however the previous call to rtw_free_mlme_priv_ie_data deferences pmlmepriv causing a null pointer deference if it is null. Avoid this by also calling rtw_free_mlme_priv_ie_data if the pointer is non-null. Detected by CoverityScan, CID#1230262 ("Dereference before null check") Fixes: 7b464c9fa5cc ("staging: r8188eu: Add files for new driver - part 4") Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-11-02staging: rtl8188eu: Revert 4 commits breaking ARPHans de Goede
Commit 2ba8444c97b1 ("staging:r8188eu: move IV/ICV trimming into decrypt() and also place it after rtl88eu_mon_recv_hook()") breaks ARP. After this commit ssh-ing to a laptop with r8188eu wifi no longer works if the machine connecting has never communicated with the laptop before. This is 100% reproducable using "arp -d <ipv4> && ssh <ipv4>" to ssh to a laptop with r8188eu wifi. This commit reverts 4 commits in total: 1. Commit 79650ffde38e ("staging:r8188eu: trim IV/ICV fields in validate_recv_data_frame()") This commit depends on 2 of the other commits being reverted. 2. Commit 02b19b4c4920 ("staging:r8188eu: inline unprotect_frame() in mon_recv_decrypted_recv()") The inline code is wrong the un-inlined version contains: if (skb->len < hdr_len + iv_len + icv_len) return; ... Where as the inline-ed code introduced by this commit does: if (skb->len < hdr_len + iv_len + icv_len) { ... Note the same check, but now to actually continue doing ... instead of to not do it, so this commit is no good. 3. Commit d86e16da6a5d ("staging:r8188eu: use different mon_recv_decrypted() inside rtl88eu_mon_recv_hook() and rtl88eu_mon_xmit_hook().") This commit introduced a 1:1 copy of a function so that one of the 2 copies can be modified in the 2 commits we're already reverting. 4. Commit 2ba8444c97b1 ("staging:r8188eu: move IV/ICV trimming into decrypt() and also place it after rtl88eu_mon_recv_hook()") This is the commit actually breaking ARP. Note this commit is a straight-forward squash of the revert of these 4 commits, without any changes. Cc: stable@vger.kernel.org Cc: Ivan Safonov <insafonov@gmail.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-11-02staging: rtl8188eu: Fix bug introduced by convert timers to use timer_setup()Hans de Goede
Commit b7749656e946 ("staging: rtl8188eu: Convert timers to use timer_setup()") introduces a copy and paste error which causes the rtl8188eu driver to no longer function. This commit fixes this. Fixes: b7749656e946 ("staging: rtl8188eu: Convert timers to use timer_setup()") Cc: Kees Cook <keescook@chromium.org> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-11-02staging: rtl8188eu: Revert part of "staging: rtl8188eu: fix comments with ↵Hans de Goede
lines over 80 characters" Commit 74e1e498e84e ("staging: rtl8188eu: fix comments with lines over 80 characters") not only changed comments but also changed an if check: -if (pmlmepriv->cur_network.join_res != true) { +if (!(pmlmepriv->cur_network.join_res)) { This is not equivalent as join_res is an int and can have values such as -2 and -3. Note for the next time, please only make one type of changes in a single clean-up commit. Fixes: 74e1e498e84e ("staging: rtl8188eu: fix comments with lines over 80 ...") Cc: Juliana Rodrigues <juliana.orod@gmail.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-11-02License cleanup: add SPDX GPL-2.0 license identifier to files with no licenseGreg Kroah-Hartman
Many source files in the tree are missing licensing information, which makes it harder for compliance tools to determine the correct license. By default all files without license information are under the default license of the kernel, which is GPL version 2. Update the files which contain no license information with the 'GPL-2.0' SPDX license identifier. The SPDX identifier is a legally binding shorthand, which can be used instead of the full boiler plate text. This patch is based on work done by Thomas Gleixner and Kate Stewart and Philippe Ombredanne. How this work was done: Patches were generated and checked against linux-4.14-rc6 for a subset of the use cases: - file had no licensing information it it. - file was a */uapi/* one with no licensing information in it, - file was a */uapi/* one with existing licensing information, Further patches will be generated in subsequent months to fix up cases where non-standard license headers were used, and references to license had to be inferred by heuristics based on keywords. The analysis to determine which SPDX License Identifier to be applied to a file was done in a spreadsheet of side by side results from of the output of two independent scanners (ScanCode & Windriver) producing SPDX tag:value files created by Philippe Ombredanne. Philippe prepared the base worksheet, and did an initial spot review of a few 1000 files. The 4.13 kernel was the starting point of the analysis with 60,537 files assessed. Kate Stewart did a file by file comparison of the scanner results in the spreadsheet to determine which SPDX license identifier(s) to be applied to the file. She confirmed any determination that was not immediately clear with lawyers working with the Linux Foundation. Criteria used to select files for SPDX license identifier tagging was: - Files considered eligible had to be source code files. - Make and config files were included as candidates if they contained >5 lines of source - File already had some variant of a license header in it (even if <5 lines). All documentation files were explicitly excluded. The following heuristics were used to determine which SPDX license identifiers to apply. - when both scanners couldn't find any license traces, file was considered to have no license information in it, and the top level COPYING file license applied. For non */uapi/* files that summary was: SPDX license identifier # files ---------------------------------------------------|------- GPL-2.0 11139 and resulted in the first patch in this series. If that file was a */uapi/* path one, it was "GPL-2.0 WITH Linux-syscall-note" otherwise it was "GPL-2.0". Results of that was: SPDX license identifier # files ---------------------------------------------------|------- GPL-2.0 WITH Linux-syscall-note 930 and resulted in the second patch in this series. - if a file had some form of licensing information in it, and was one of the */uapi/* ones, it was denoted with the Linux-syscall-note if any GPL family license was found in the file or had no licensing in it (per prior point). Results summary: SPDX license identifier # files ---------------------------------------------------|------ GPL-2.0 WITH Linux-syscall-note 270 GPL-2.0+ WITH Linux-syscall-note 169 ((GPL-2.0 WITH Linux-syscall-note) OR BSD-2-Clause) 21 ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) 17 LGPL-2.1+ WITH Linux-syscall-note 15 GPL-1.0+ WITH Linux-syscall-note 14 ((GPL-2.0+ WITH Linux-syscall-note) OR BSD-3-Clause) 5 LGPL-2.0+ WITH Linux-syscall-note 4 LGPL-2.1 WITH Linux-syscall-note 3 ((GPL-2.0 WITH Linux-syscall-note) OR MIT) 3 ((GPL-2.0 WITH Linux-syscall-note) AND MIT) 1 and that resulted in the third patch in this series. - when the two scanners agreed on the detected license(s), that became the concluded license(s). - when there was disagreement between the two scanners (one detected a license but the other didn't, or they both detected different licenses) a manual inspection of the file occurred. - In most cases a manual inspection of the information in the file resulted in a clear resolution of the license that should apply (and which scanner probably needed to revisit its heuristics). - When it was not immediately clear, the license identifier was confirmed with lawyers working with the Linux Foundation. - If there was any question as to the appropriate license identifier, the file was flagged for further research and to be revisited later in time. In total, over 70 hours of logged manual review was done on the spreadsheet to determine the SPDX license identifiers to apply to the source files by Kate, Philippe, Thomas and, in some cases, confirmation by lawyers working with the Linux Foundation. Kate also obtained a third independent scan of the 4.13 code base from FOSSology, and compared selected files where the other two scanners disagreed against that SPDX file, to see if there was new insights. The Windriver scanner is based on an older version of FOSSology in part, so they are related. Thomas did random spot checks in about 500 files from the spreadsheets for the uapi headers and agreed with SPDX license identifier in the files he inspected. For the non-uapi files Thomas did random spot checks in about 15000 files. In initial set of patches against 4.14-rc6, 3 files were found to have copy/paste license identifier errors, and have been fixed to reflect the correct identifier. Additionally Philippe spent 10 hours this week doing a detailed manual inspection and review of the 12,461 patched files from the initial patch version early this week with: - a full scancode scan run, collecting the matched texts, detected license ids and scores - reviewing anything where there was a license detected (about 500+ files) to ensure that the applied SPDX license was correct - reviewing anything where there was no detection but the patch license was not GPL-2.0 WITH Linux-syscall-note to ensure that the applied SPDX license was correct This produced a worksheet with 20 files needing minor correction. This worksheet was then exported into 3 different .csv files for the different types of files to be modified. These .csv files were then reviewed by Greg. Thomas wrote a script to parse the csv files and add the proper SPDX tag to the file, in the format that the file expected. This script was further refined by Greg based on the output to detect more types of files automatically and to distinguish between header and source .c files (which need different comment types.) Finally Greg ran the script using the .csv files to generate the patches. Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org> Reviewed-by: Philippe Ombredanne <pombredanne@nexb.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-20staging: rtl8188eu: use pr_cont()Aastha Gupta
Using 'printk("\n")' is not preferred anymore as printks without KERN_CONT are emitted on a new line and KERN_CONT is required to continue lines so use pr_cont. Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-20staging: rtl8188eu: add spaces around '|'Aastha Gupta
Fixes 'use spaces around '|' ' as reported by checkpatch.pl Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-20staging: rtl8188eu: prefer using BIT macroAastha Gupta
Fixes checkpatch.pl: Use BIT(x) instead of using (1<<x) Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18staging: rtl8188eu: usb_ops_linux: mark expected switch fall-throughGustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 1077613 Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18staging: rtl8188eu: usb_halinit: mark expected switch fall-throughGustavo A. R. Silva
In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Addresses-Coverity-ID: 1373894 Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18rtl8188eu: Fix a possible sleep-in-atomic bug in _rtw_pwr_wakeupJia-Ju Bai
The driver may sleep under a spinlock, and the function call path is: rtw_set_802_11_disassociate(acquire the spinlock) _rtw_pwr_wakeup usleep_range --> may sleep To fix it, usleep_range is replaced with udelay. This bug is found by my static analysis tool and my code review. Signed-off-by: Jia-Ju Bai <baijiaju1990@163.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18rtl8188eu: Fix a possible sleep-in-atomic bug in rtw_createbss_cmdJia-Ju Bai
The driver may sleep under a spinlock, and the function call path is: rtw_surveydone_event_callback(acquire the spinlock) rtw_createbss_cmd kzalloc(GFP_KERNEL) --> may sleep To fix it, GFP_KERNEL is replaced with GFP_ATOMIC. This bug is found by my static analysis tool and my code review. Signed-off-by: Jia-Ju Bai <baijiaju1990@163.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18rtl8188eu: Fix a possible sleep-in-atomic bug in rtw_disassoc_cmdJia-Ju Bai
The driver may sleep under a spinlock, and the function call path is: rtw_set_802_11_bssid(acquire the spinlock) rtw_disassoc_cmd kzalloc(GFP_KERNEL) --> may sleep To fix it, GFP_KERNEL is replaced with GFP_ATOMIC. This bug is found by my static analysis tool and my code review. Signed-off-by: Jia-Ju Bai <baijiaju1990@163.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18staging: rtl8188eu: add spaces around algebric and boolean operatorsAastha Gupta
This patch fixes checkpatch.pl warnings about preferring spaces around algebric and boolean operators. Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18staging: rtl8188eu: fix spaces before tabsAastha Gupta
This patch fixes checkpatch.pl warning: WARNING: please, no space before tabs Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18staging: rtl8188eu: fix space between function name and '('Aastha Gupta
This patch fixes checkpatch.pl warning: WARNING: space prohibited between function name and open parenthesis '(' Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18staging: rtl8188eu: fix block comment styling in rtl8188eu filesAastha Gupta
This patch fixes checkpatch.pl warnings for block comment styling. 1. Block comment use a trailing */ on a separate line. 2. Block comment use * on subsequent lines. 3. Block comment should align * on each line. Signed-off-by: Aastha Gupta <aastha.gupta4104@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-18staging: rtl8188eu: Convert timers to use timer_setup()Kees Cook
In preparation for unconditionally passing the struct timer_list pointer to all timer callbacks, switch to using the new timer_setup() and from_timer() to pass the timer pointer explicitly. Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Juliana Rodrigues <juliana.orod@gmail.com> Cc: Ivan Safonov <insafonov@gmail.com> Cc: Gargi Sharma <gs051095@gmail.com> Cc: sayli karnik <karniksayli1995@gmail.com> Cc: Yamanappagouda Patil <goudapatilk@gmail.com> Cc: Luca Ceresoli <luca@lucaceresoli.net> Cc: Victor Carvajal <carva005@gmail.com> Cc: Sebastian Haas <sehaas@deebas.com> Cc: devel@driverdev.osuosl.org Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-03Staging: rtl8188eu: core: Use list_entry instead of container_ofSrishti Sharma
For variables that have type struct list_head* use list_entry to access current list element instead of using container_of. Done using the following semantic patch by coccinelle. @r@ identifier e; struct list_head* l; @@ <... when != l == NULL l; ...> ( e= -container_of +list_entry ( ...) ) Signed-off-by: Srishti Sharma <srishtishar@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-03staging: rtl8188eu: Place the constant on the right side in comparisonsMihaela Muraru
Move constant to the right side of comparison operator. Issue found by checkpatch.pl Signed-off-by: Mihaela Muraru <mihaela.muraru21@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-10-03staging: rtl8188eu: Remove braces from single statement blocksMihaela Muraru
This patch fix a coding style issue, by removing braces {} from single statement blocks. Issue found by checkpatch.pl. Signed-off-by: Mihaela Muraru <mihaela.muraru21@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-29Staging: rtl8188eu: core: Fix line over 80 charactersGeorgiana Chelu
Fix warning reported by checkpatch.pl script: WARNING: line over 80 characters Signed-off-by: Georgiana Chelu <georgiana.chelu93@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-29Staging: rtl8188eu: core: Add spaces around '+'Georgiana Chelu
Improve the coding style by adding spaces around arithmetic operation. Issue reported by checkpatch.pl script. Signed-off-by: Georgiana Chelu <georgiana.chelu93@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-29Staging: rtl8188eu: core: Use __func__ instead of function nameGeorgiana Chelu
Replace the function name from format string with the constant __func__ to avoid multiple changes in case the name of the function will be modified. Issue reported by checkpatch.pl script. Signed-off-by: Georgiana Chelu <georgiana.chelu93@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-29staging: rtl8188eu: wrap lines in 80 charactersAishwarya Pant
Perform cleanup for all function declarations in core/rtw_mlme_ext wherever checkpatch complains about lines being over 80 characters long. Signed-off-by: Aishwarya Pant <aishpant@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-29staging: rtl8188eu: remove implicit bool->int conversionsAishwarya Pant
Implicit type conversions are bad; they hinder readability of code and have potential to cause bugs. Here the variable wait_ack is always supplied a bool value while in function declarations it is defined as an int type. Fix it by defining wait_ack a bool type in all usages. Signed-off-by: Aishwarya Pant <aishpant@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-29staging: rtl8188eu: remove unneeded conversions to boolAishwarya Pant
Patch suppresses the following warning issued by coccicheck: WARNING: conversion to bool not needed here Signed-off-by: Aishwarya Pant <aishpant@gmail.com> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-22staging:rtl8188eu:hal Fix wrong comparison to FalseJanani Sankara Babu
This patch solves the warning "Using comparison to false is error prone" Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-22staging:rtl8188eu Fix remove semicolon in do {}while(0)Janani Sankara Babu
This patch removes the semicolon at the end of while statement in the do while macro , inorder to avoid it behaving like compound statement. Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-18staging: rtl8188eu: Fix spellingValentine Sinitsyn
rtl8188eu contains some spelling errors in comment lines as well as in constants. Harmless as they are, they still make the code feel a bit unclean, which is not something we want in the kernel. Improve this by fixing typos so they won't catch eyes of future driver developers anymore. Signed-off-by: Wolfgang Hartmann <wolfgang.hartmann@siemens.com> Signed-off-by: Manish Shrestha <manishshrestha2006@gmail.com> Signed-off-by: Valentine Sinitsyn <valentine.sinitsyn@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-18staging: rtl8188eu: remove parenthesis from right hand side of assignmentAishwarya Pant
Parenthesis are not needed around the right hand side of an assignment. This patch was made on the core files of rtl8188eu using the following coccinelle script. @@ binary operator op = {==,!=,&&,||,>=,<=,&,|}; expression l, r, t; @@ ( l = (r op t) | l = -( r -) ) Signed-off-by: Aishwarya Pant <aishpant@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-17staging:rtl8188eu:core Fix code IndentJanani Sankara Babu
This patch is created to solve the code indentation issue Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-17staging:rtl8188eu Remove unneccessary parenthesisJanani Sankara Babu
This patch is creates in order to correct the coding style issues. It removes the unwanted parenthesis from the code. Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-17staging:rtl8188eu Fix coding style issuesJanani Sankara Babu
This patch aims to solve coding style issues by placing constants on the right side of the test Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-17staging:rtl8188eu Fix use __func__ for function nameJanani Sankara Babu
This patch fixes the WARNING: Prefer using '"%s...", __func__' to using this function's name, in a string Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-01staging:rtl8188eu:core Fix remove unneccessary else blockJanani Sankara Babu
This patch removes the unwanted braces and else statement inside the function 'SecIsInPMKIDList' Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-31staging:rtl8188eu Fix comparison to NULLJanani Sankara Babu
This patch replaces the comparison of variable say x to NULL with '!x' signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-31staging:rtl8188eu:core Fix Code IndentJanani Sankara Babu
This patch solves the code indentation issue inside the if block Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-31staging:rtl8188eu Use __func__ instead of function nameJanani Sankara Babu
This patch makes use of predefined identifier __func__ inorder to clear the warning: Prefer using '"%s...", __func__' to using 'update_bmc_sta', this function's name, in a string Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-29staging: rtl8188eu: remove unnecessary call to memsetHimanshu Jha
call to memset to assign 0 value immediately after allocating memory with kzalloc is unnecesaary as kzalloc allocates the memory filled with 0 value. Signed-off-by: Himanshu Jha <himanshujha199640@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-28Merge 4.13-rc7 into staging-nextGreg Kroah-Hartman
We want the staging and iio fixes in here to handle the merge issues. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-28staging:rtl8188eu:core Fix add spaces around &Janani Sankara Babu
This patch is created to solve the following coding style issue reported by the checkpatch script. CHECK: spaces preffered around that '&' (ctx:VxV) Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-28staging:rtl8188eu:core Fix coding style IssuesJanani Sankara Babu
This patch solves the following warning shown by the checkpatch script WARNING: Comparisons should place the constants on the right side of the test Signed-off-by: Janani Sankara Babu <jananis37@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-20staging:rtl8188eu: fix coding style issueJamie Huang
checkpatch.pl gave ERROR: open brace '{' following function definitions go on the next line. Signed-off-by: Jamie Huang <jamienstar@163.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-18staging: rtl8188eu: add RNX-N150NUB supportCharles Milette
Add support for USB Device Rosewill RNX-N150NUB. VendorID: 0x0bda, ProductID: 0xffef Signed-off-by: Charles Milette <charles.milette@gmail.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-18staging: rtl8188eu: constify usb_device_idArvind Yadav
usb_device_id are not supposed to change at runtime. All functions working with usb_device_id provided by <linux/usb.h> work with const usb_device_id. So mark the non-const structs as const. Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>