Commit graph

871011 commits

Author SHA1 Message Date
Jérôme Pouiller
185c106f79 staging: wfx: add support for start-up indication
Once firmware is loaded, it send a first indication to host. This
indication signalize that host can start to communicate with firmware.
In add, it contains information about chip and firmware (MAC addresses,
firmware version, etc...).

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20190919142527.31797-10-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:46:09 +02:00
Jérôme Pouiller
1cc298c915 staging: wfx: add tracepoints for HIF
These tracepoints decode HIF headers and provide more human readable
results.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20190919142527.31797-9-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:46:09 +02:00
Jérôme Pouiller
b0998f0c04 staging: wfx: add IRQ handling
bh_work() is in charge to schedule all HIF message from/to chip.

On normal operation, when an IRQ is received, driver can get size of
next message in control register. In order to save control register
access, when chip send a message, it also appends a copy of control
register after the message (this register is not accounted in message
length declared in message header, but must accounted in bus request).
This copy of control register is called "piggyback".

It also handles a power saving mechanism specific to WFxxx series. This
mechanism is based on a GPIO called "wakeup" GPIO. Obviously, this gpio
is not part of SPI/SDIO standard buses and must be declared
independently (this is the main reason for why SDIO mode try to get
parameters from DT).

When wakeup is enabled, host can communicate with chip only if it is
awake. To wake up chip, there are two cases:
    - host receive an IRQ from chip (chip initiate communication): host
      just have to set wakeup GPIO before reading data
    - host want to send data to chip: host set wakeup GPIO, then wait
      for an IRQ (in fact, wait for an empty message) and finally send data

bh_work() is also in charge to track usage of chip buffers. Normally
each request expect a confirmation. However, you can notice that special
"multi tx" confirmation can acknowledge multiple requests at time.

Finally, note that wfx_bh_request_rx() is not atomic (because of
control_reg_read()). So, in SPI mode, hard-irq handler only postpone all
processing to wfx_spi_request_rx().

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20190919142527.31797-8-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:43:40 +02:00
Jérôme Pouiller
e4ee3cb3ef staging: wfx: import HIF API headers
These files are shared with firmware sources. Only a subset of these
definitions are used by driver but, for now, it is easier to import all.

API defines 3 kinds of messages:
   - Requests (req) are sent from host to chip
   - Confirmations (cnf) are sent by chip and are always in reply to a
     request
   - Indications (ind) are spontaneous message from chip to host

One request normally generate one confirmation. There are a few
exceptions to this rule:
   - "shutdown" request is not acknowledged
   - multiple tx request can be acknowledged a unique "multi-tx"
     confirmation

In add, API defines MIB. They are sub-structures for write_mib and
read_mib API.

Note that all numbers in API have to be little endian when sent/received
from/to chip (I didn't declared them with __le32 because driver also use
them internally).

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20190919142527.31797-7-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:43:40 +02:00
Jérôme Pouiller
652b4afb24 staging: wfx: load firmware
A firmware is necessary to run the chip. wfx_init_device() is in charge
of loading firmware on chip and doing low level initialization.

Firmwares for WF200 are available here:

  https://github.com/SiliconLabs/wfx-firmware/

Note that firmware are encrypted. Driver checks that key used to encrypt
firmware match with key burned into chip.

Currently, "C0" key is used for production chips.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20190919142527.31797-6-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:43:39 +02:00
Jérôme Pouiller
fee695e3e3 staging: wfx: add tracepoints for I/O access
Some tracepoints are useful for debugging.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20190919142527.31797-5-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:43:39 +02:00
Jérôme Pouiller
a794e8b6fa staging: wfx: add I/O API
hwio.c provides an abstraction to access different types of register of
the chip.

Note that only data register (aka FRAME_OUT) and control register are
used normal communication. Other registers are only used during chip
start up.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20190919142527.31797-4-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:43:39 +02:00
Jérôme Pouiller
0096214a59 staging: wfx: add support for I/O access
Introduce bus level communication layer. At this level, 7 registers can
be addressed.

Notice that SPI driver is able to manage chip reset. SDIO mode relies
on an external driver (`mmc-pwrseq`) to reset chip.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20190919142527.31797-3-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:28:16 +02:00
Jérôme Pouiller
a7a91ca5a2 staging: wfx: add infrastructure for new driver
Instantiate build infrastructure WFx driver. This driver provides support
for Wifi chipset Silicon Labs WF200 and further:

   https://www.silabs.com/documents/public/data-sheets/wf200-datasheet.pdf

This chip support SPI and SDIO bus.

SDIO interface has two particularities:
    1. Some parameters may be useful for end user (I will talk about
       gpio_wakeup later).
    2. The SDIO VID and PID of WF200 are 0000:0001 which are too much
       generic to rely on.

So, current code checks VID/PID and looks for a node in DT (since WF200
targets embedded platforms, I don't think it is a problem to rely on
DT). DT can also be used to define to parameters for driver. Currently,
if no node is found, a warning is emitted, but it could be changed in
error.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20190919142527.31797-2-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:26:51 +02:00
Valdis Klētnieks
d98bb9c2fe staging: exfat: explain the fs_sync() issue in TODO
We've seen several incorrect patches for fs_sync() calls in the exfat driver.
Add code to the TODO that explains this isn't just a delete code and refactor,
but that actual analysis of when the filesystem should be flushed to disk
needs to be done.

Signed-off-by: Valdis Kletnieks <valdis.kletnieks@vt.edu>

Link: https://lore.kernel.org/r/9837.1570042895@turing-police
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:17:57 +02:00
Valdis Klētnieks
8789f13ddc staging: exfat: fix fs_sync() calls.
The majority of them were totally backwards.  Change the logic
so that if DELAYED_SYNC *isn't* in the config, we actually flush to disk
before flagging the file system as clean.

That leaves two calls in the DELAYED_SYNC case.  More detailed
analysis is needed to make sure that's what's really needed, or if other
call sites also need a fs_sync() call.  This patch is at least "less wrong"
than the code was, but further changes should be another patch.

Signed-off-by: Valdis Kletnieks <valdis.kletnieks@vt.edu>

Link: https://lore.kernel.org/r/11092.1570043784@turing-police
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:17:51 +02:00
Michael Straube
7e6af677d8 staging: rtl8188eu: cleanup comments in update_hw_ht_param
Cleanup comments in update_hw_ht_param to follow kernel coding style
and avoid line length over 80 characters.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20191003122514.1760-5-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:17:21 +02:00
Michael Straube
5f6bca795f staging: rtl8188eu: cleanup whitespace in update_hw_ht_param
Replace tabs with spaces in declarations and reomve two blank lines in
update_hw_ht_param to cleanup whitespace and improve readability.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20191003122514.1760-4-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:17:21 +02:00
Michael Straube
7e3303fc8c staging: rtl8188eu: rename variables to avoid mixed case
Rename the local varibles max_AMPDU_len and min_MPDU_spacing to avoid
mixed case.

max_AMPDU_len -> max_ampdu_len
min_MPDU_spacing -> min_mpdu_spacing

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20191003122514.1760-3-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:17:20 +02:00
Michael Straube
b74e124e10 staging: rtl8188eu: convert variables from unsigned char to u8
Convert the local variables max_AMPDU_len and min_MPDU_spacing from
unsigned char to u8 and remove unnecessary castings to u8 pointer.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20191003122514.1760-2-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:17:20 +02:00
Rohit Sarkar
b664312285 staging: rtl8712: fix boundary condition for n
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-10-04 10:16:49 +02:00
Nachammai Karuppiah
f8fcbb6ba8 staging: vc04_services: Avoid typedef
Avoid typedefs to maintain kernel coding style. Issue found by
checkpatch.pl

Replace the enum typedef VCHIQ_REASON_T with vchiq_reason.

Signed-off-by: Nachammai Karuppiah <nachukannan@gmail.com>
Link: https://lore.kernel.org/r/1570125797-24410-1-git-send-email-nachukannan@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-04 10:16:48 +02:00
Sven Van Asbroeck
9cc05ed4df staging: fieldbus: move "offline mode" definition to fieldbus core
anybus-s cards use the "offline mode" property to determine if
process memory should be clear, set, or frozen when the card
is offline.

Move this property to the fieldbus core, so that it can become
part of the future fieldbus config interface.

Signed-off-by: Sven Van Asbroeck <TheSven73@gmail.com>
Link: https://lore.kernel.org/r/20190918183552.28959-3-TheSven73@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:03 +02:00
Sven Van Asbroeck
7c1a38e1fe staging: fieldbus core: remove unused strings
Remove two unused static const strings - a leftover from
a previous stage. Interestingly, neither gcc nor sparse
warned about their presence.

Signed-off-by: Sven Van Asbroeck <TheSven73@gmail.com>
Link: https://lore.kernel.org/r/20190918183552.28959-2-TheSven73@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:03 +02:00
Adham Abozaeid
854d66df74 staging: wilc1000: look for rtc_clk clock in spi mode
If rtc_clk is provided from DT, use it and enable it.
This is optional.
The signal may be hardcoded and no need to be requested,
but if DT provides it, use it.

Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
Link: https://lore.kernel.org/r/20190916193701.20755-1-adham.abozaeid@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:03 +02:00
Ajay Singh
8399918f30 staging: wilc1000: use RCU list to maintain vif interfaces list
Make use of RCU list to maintain virtual interfaces instead of an array.
The update operation on 'vif' list is less compare to the read
operations. Mostly the 'vif' list elements are accessed for the read
operation, so RCU list is more suited for this requirement.
The shifting of interface index id's during the delete interface is not
required. As the firmware only supports 2 interfaces so make use of
available free slot index id during add interface.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Link: https://lore.kernel.org/r/20190926151436.27819-3-ajay.kathat@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:03 +02:00
Ajay Singh
fb2d74342f staging: wilc1000: move wlan_deinit_locks() in wilc_netdev_cleanup()
Move deinitialization of lock during the module remove and the
initialization of lock wilc_cfg80211_init(). This to ensure locks are
available during module load and gets free during unload.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Link: https://lore.kernel.org/r/20190926151436.27819-2-ajay.kathat@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:02 +02:00
Ajay Singh
82e465642f staging: wilc1000: remove unnecessary netdev validation check in del_key()
Removed unnecessary check to compare vif interface with zeroth index
element in vif array. Already the caller takes care of passing the
appropriate netdev handler during the del key operation.

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Link: https://lore.kernel.org/r/20190926151436.27819-1-ajay.kathat@microchip.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:02 +02:00
Connor Kuehl
228241944a staging: rtl8188eu: fix possible null dereference
Inside a nested 'else' block at the beginning of this function is a
call that assigns 'psta' to the return value of 'rtw_get_stainfo()'.
If 'rtw_get_stainfo()' returns NULL and the flow of control reaches
the 'else if' where 'psta' is dereferenced, then we will dereference
a NULL pointer.

Fix this by checking if 'psta' is not NULL before reading its
'psta->qos_option' data member.

Addresses-Coverity: ("Dereference null return value")

Signed-off-by: Connor Kuehl <connor.kuehl@canonical.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Link: https://lore.kernel.org/r/20190926150317.5894-1-connor.kuehl@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:02 +02:00
Michael Straube
c47be36db3 staging: rtl8723bs: remove unused function write_cam_from_cache
Function write_cam_from_cache in rtw_wlan_util.c is never used,
so remove it.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20190926175933.44967-1-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:01 +02:00
Colin Ian King
17e325285d staging: vt6656: clean up an indentation issue
There is a block of code that is indented incorrectly, add in the
missing tabs.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Reviewed-by: Quentin Deslandes <quentin.deslandes@itdev.co.uk>
Link: https://lore.kernel.org/r/20190927092400.20213-1-colin.king@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:01 +02:00
Colin Ian King
5dec9a2877 staging: rtl8192e: clean up indentation issue
The RT_TRACE is indented incorrectly, add in the missing tabs.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20190926125057.16158-1-colin.king@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:01 +02:00
Connor Kuehl
43821e36e5 staging: rtl8188eu: remove dead code/vestigial do..while loop
The local variable 'bcmd_down' is always set to true almost immediately
before the do-while's condition is checked. As a result, !bcmd_down
evaluates to false which short circuits the logical AND operator meaning
that the second operand is never reached and is therefore dead code.

Furthermore, the do..while loop may be removed since it will always only
execute once because 'bcmd_down' is always set to true, so the
!bcmd_down evaluates to false and the loop exits immediately after the
first pass.

Fix this by removing the loop and its condition variables 'bcmd_down'
and 'retry_cnts'

While we're in there, also fix some checkpatch.pl suggestions regarding
spaces around arithmetic operators like '+'

Addresses-Coverity: ("Logically dead code")

Signed-off-by: Connor Kuehl <connor.kuehl@canonical.com>
Link: https://lore.kernel.org/r/20190924142819.5243-1-connor.kuehl@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:01 +02:00
Jerry Lin
01b16aed57 staging: olpc_dcon: fix wrong dependencies in Kconfig file
To allow simultaneous support for XO-1 and XO-1.5.
This module require GPIO_CS5535 (for 1.0) and ACPI (for 1.5) now.

Reported-by: kbuild test robot <lkp@intel.com>
Signed-off-by: Jerry Lin <wahahab11@gmail.com>
Link: https://lore.kernel.org/r/20190925074243.GA24947@compute1
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:00 +02:00
Kefeng Wang
af42abb680 staging: Use pr_warn instead of pr_warning
As said in commit f2c2cbcc35 ("powerpc: Use pr_warn instead of
pr_warning"), removing pr_warning so all logging messages use a
consistent <prefix>_warn style. Let's do it.

Cc: Karsten Keil <isdn@linux-pingi.de>
Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
Link: https://lore.kernel.org/r/20190920062544.180997-22-wangkefeng.wang@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:00 +02:00
Navid Emamdoost
ca312438cf staging: rtl8192u: fix multiple memory leaks on error path
In rtl8192_tx on error handling path allocated urbs and also skb should
be released.

Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com>
Link: https://lore.kernel.org/r/20190920025137.29407-1-navid.emamdoost@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:00 +02:00
Navid Emamdoost
0911224b6b staging: rtl8192u: release memory on error path
In rtl819xU_tx_cmd if usb_submit_urb fails the allocated memories should
be released.

Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com>
Link: https://lore.kernel.org/r/20190920014303.31410-1-navid.emamdoost@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:58:00 +02:00
Aliasgar Surti
0605bed9ba staging: qlge: Removed unnecessary variable
coccicheck reported warning for unnecessary variable used.
This patch fixes the same by removing the variable and
returning value directly.

Signed-off-by: Aliasgar Surti <aliasgar.surti500@gmail.com>
Link: https://lore.kernel.org/r/1568812596-25926-1-git-send-email-aliasgar.surti500@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:59 +02:00
Rohit Sarkar
d9dc93128d staging: rtl8712: Replace snprintf with scnprintf
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-09-30 21:57:59 +02:00
Jerry Lin
e40219d5e4 staging: olpc_dcon: allow simultaneous XO-1 and XO-1.5 support
This patch remove model related configuration.
Since the module can decide which platform data to use itself base on
current running olpc board.

Also change module dependency from (GPIO_CS5535 || GPIO_CS5535=n)
to (GPIO_CS5535 || ACPI) because original one does not make any sense
and module only doing real work when GPIO_CS5535 or ACPI is setted.

Remove kernel configurations:
- FB_OLPC_DCON_1
- FB_OLPC_DCON_1_5

Signed-off-by: Jerry Lin <wahahab11@gmail.com>
Link: https://lore.kernel.org/r/20190906010613.GA562@compute1
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:58 +02:00
Sumera Priyadarsini
c2e323290f staging: rtl8192u: Remove unnecessary line-breaks in function signatures
This patch fixes the function signatures for rtl8192_handle_assoc_response,
rtl8192_record_rxdesc_forlateruse, rtl819xusb_process_received_packet
and other relevant code blocks to avoid the checkpatch.pl warning:

	CHECK: Lines should not end with a '('

Signed-off-by: Sumera Priyadarsini <sylphrenadin@gmail.com>
Link: https://lore.kernel.org/r/ed06fc34eecd883f02bb9a037522b65c63a5eec4.1568814125.git.sylphrenadin@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:58 +02:00
Sumera Priyadarsini
3278ef5961 staging: rtl8192u: Fix alignment to match open parenthesis
This patch fixes the file r8192U_core.c to avoid the checkpatch.pl
warning:
	CHECK: Alignment should match open parenthesis

Signed-off-by: Sumera Priyadarsini <sylphrenadin@gmail.com>
Link: https://lore.kernel.org/r/07a4311b70ed22833a01a9067418639905041cb7.1568814125.git.sylphrenadin@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:58 +02:00
Sumera Priyadarsini
78f7aac11e staging: rtl8192u: Remove unnecessary blank lines
This patch fixes the file r8192U_core.c to avoid the chechpatch.pl
warnings:

	CHECK: Please don't use multiple blank lines
	CHECK: Blank lines aren't necessary before a close brace '}'

Signed-off-by: Sumera Priyadarsini <sylphrenadin@gmail.com>
Link: https://lore.kernel.org/r/95ce1564a34ff65e51fd63a241713e23e12dac91.1568814125.git.sylphrenadin@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:58 +02:00
Rohit Sarkar
88b3673ec0 staging: rtl8192u: ieee80211: Replace snprintf with scnprintf
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/20190910182415.GA5768@SARKAR
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:57 +02:00
Aurabindo Jayamohanan
1c0c5e9b23 staging: board: use appropriate macro to initialize struct
Make code more readable by using macros defined for initializing
struct resource

Signed-off-by: Aurabindo Jayamohanan <mail@aurabindo.in>
Link: https://lore.kernel.org/r/20190919113945.13700-1-mail@aurabindo.in
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:57 +02:00
Connor Kuehl
fe11afc326 staging: rtl8188eu: remove unnecessary self-assignment
This is a self-assignment which is redundant. Fix this by removing the
self-assignment.

Addresses-Coverity: ("Self assignment")

Signed-off-by: Connor Kuehl <connor.kuehl@canonical.com>
Link: https://lore.kernel.org/r/20190920094807.9217-1-connor.kuehl@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:57 +02:00
Michael Straube
97a0ea7795 staging: rtl8188eu: cleanup long line in rtw_mlme_ext.c
Remove comparsion to NULL and unnecessary parentheses to avoid line
length over 80 characters and follow kernel coding style.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20190912114257.17529-1-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:57 +02:00
Ido Tamir
8635b4c480 staging: sm750fb: CHECK: Avoid CamelCase
This patch fixes the checkpatch.pl warning: CHECK: Avoid CamelCase for
the following files:

drivers/staging/sm750fb/ddk750_chip.c
drivers/staging/sm750fb/ddk750_chip.h
drivers/staging/sm750fb/ddk750_mode.c

Signed-off-by: Ido Tamir <ido.tamir@gmail.com>
Link: https://lore.kernel.org/r/20190906112241.GA2144@ubuntu-kernel
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:56 +02:00
Michael Straube
87a966d8ca staging: rtl8723bs: remove return statements from void functions
Remove unnecessary return statements from void functions reported by
checkpatch.

WARNING: void function return statements are not generally useful

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20190914115634.67874-1-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:56 +02:00
Saiyam Doshi
9cdb192868 staging: rtl8723bs: remove unneeded conversion to bool
Relational and logical operators evaluate to bool,
explicit conversion is overly verbose and unneeded.

This issue found using - Coccinelle (http://coccinelle.lip6.fr)

Signed-off-by: Saiyam Doshi <saiyamdoshi.in@gmail.com>
Link: https://lore.kernel.org/r/20190912145346.GA9013@SD.eic.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:56 +02:00
Colin Ian King
53e3a7e1d7 staging: rtl8723bs: core: make array op_class static const, makes object smaller
Don't populate the array op_class on the stack but instead make it
static const. Makes the object code smaller by 64 bytes.

Before:
   text	   data	    bss	    dec	    hex	filename
  93553	   7944	   5056	 106553	  1a039	rtl8723bs/core/rtw_mlme_ext.o

After:
   text	   data	    bss	    dec	    hex	filename
  93425	   8008	   5056	 106489	  19ff9	rtl8723bs/core/rtw_mlme_ext.o

(gcc version 9.2.1, amd64)

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20190906175021.25103-1-colin.king@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:55 +02:00
Colin Ian King
6f406c7303 staging: rtl8723bs: os_dep: fix spelling mistake "offet" -> "offset"
There is a spelling mistake in a DBG_871X error message. Fix it.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20190916092211.32646-1-colin.king@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:55 +02:00
Aliasgar Surti
55ecd411c3 staging: rtl8723bs: Removed unneeded variables
coccicheck reported warning for unneeded variable used.

This patch removes the unneeded variables.

Signed-off-by: Aliasgar Surti <aliasgar.surti500@gmail.com>
Link: https://lore.kernel.org/r/1568798749-9855-1-git-send-email-aliasgar.surti500@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-30 21:57:55 +02:00
Linus Torvalds
54ecb8f702 Linux 5.4-rc1 2019-09-30 10:35:40 -07:00
Linus Torvalds
bb48a59135 for-5.4-rc1-tag
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEE8rQSAMVO+zA4DBdWxWXV+ddtWDsFAl2SDbMACgkQxWXV+ddt
 WDsUhw/9HcRsT6SlrwA2R5leHxCR5UMwT2Zmbxpfft37ANF0SC1UINHBfnmquM97
 xX6fdRSR9RUjF9DrdLPfLBnJDQ/MnHl1ruIVBFhJm6cJ9TJwf9E0TiJBQt+08JWg
 vy5hZBWvsPWWRBJ94XPMe4LtakK/isW4Cz5W9AdrC2Siqw69j6eZzms2AnIjyBjA
 BoKg4se2Ay2rMxLZWXIOj9374PU+N1cnRnqgh77ZxLku5WdCzrDfB5safE7UmoTG
 /MWJuuIgzOk0iQpQORRtEZDS1dNe5KT9m4xXkUbrZbQROwqnXrT1SVIsuqNAvlPk
 uaymR1W8nshepzpMlSxVydLv/mKWZNUGnDxOJ23ooow8Yd7ndppXEtFuGwCYqIFc
 xQqxuTLREvJ9+jpSv11bmDpk/ULRqpV+2PjUqGaWlGwFArJ+qFRLVGYx31eXmDPj
 t2mrPOcXGzY0pKtIpbkuUGleY/jeI+BNsvD4+QPs+jnp0nmfvH0/Rmp7grGqx2FI
 rQM8Gn4a5i3nuEDWLp8nN2wcKC3ePwy96Vp2tqfsl6TVTPx4EFzGLkWogHR2yiqI
 0LAj8YWFmWuChSv71wYOjX79CppjcbNwOakSwtDjV30jkwoh2f/0D3OwOpua2xe8
 75KQMaSB0kesGZz7ZkL1kMqA5m5w7MGZom6XZoBJ+bq2HPLB2jo=
 =2UM7
 -----END PGP SIGNATURE-----

Merge tag 'for-5.4-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux

Pull btrfs fixes from David Sterba:
 "A bunch of fixes that accumulated in recent weeks, mostly material for
  stable.

  Summary:

   - fix for regression from 5.3 that prevents to use balance convert
     with single profile

   - qgroup fixes: rescan race, accounting leak with multiple writers,
     potential leak after io failure recovery

   - fix for use after free in relocation (reported by KASAN)

   - other error handling fixups"

* tag 'for-5.4-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux:
  btrfs: qgroup: Fix reserved data space leak if we have multiple reserve calls
  btrfs: qgroup: Fix the wrong target io_tree when freeing reserved data space
  btrfs: Fix a regression which we can't convert to SINGLE profile
  btrfs: relocation: fix use-after-free on dead relocation roots
  Btrfs: fix race setting up and completing qgroup rescan workers
  Btrfs: fix missing error return if writeback for extent buffer never started
  btrfs: adjust dirty_metadata_bytes after writeback failure of extent buffer
  Btrfs: fix selftests failure due to uninitialized i_mode in test inodes
2019-09-30 10:25:24 -07:00