platform/kernel/linux-rpi.git
6 years agostaging: gasket: remove GASKET_SYSFS_REG()
Greg Kroah-Hartman [Fri, 13 Jul 2018 08:29:02 +0000 (10:29 +0200)]
staging: gasket: remove GASKET_SYSFS_REG()

In an attempt to start to clean up the monstrosity of the sysfs abuse in
the gasket driver, let's remove code that is not used at all.  The
GASKET_SYSFS_REG() macro is never used, so delete it.

Cc: Rob Springer <rspringer@google.com>
Cc: John Joseph <jnjoseph@google.com>
Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: remove gasket_page_table_num_extended_entries()
Greg Kroah-Hartman [Fri, 13 Jul 2018 10:05:55 +0000 (12:05 +0200)]
staging: gasket: remove gasket_page_table_num_extended_entries()

It is exported, yet no one calls it so just remove the dead code.

Cc: Rob Springer <rspringer@google.com>
Cc: John Joseph <jnjoseph@google.com>
Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: remove gasket_interrupt_get_msix_entries()
Greg Kroah-Hartman [Fri, 13 Jul 2018 10:05:54 +0000 (12:05 +0200)]
staging: gasket: remove gasket_interrupt_get_msix_entries()

No one calls it, it is claimed to be "legacy", whatever that means, so
just remove the dead code.

Cc: Rob Springer <rspringer@google.com>
Cc: John Joseph <jnjoseph@google.com>
Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: remove gasket_interrupt_trigger_eventfd()
Greg Kroah-Hartman [Fri, 13 Jul 2018 10:05:53 +0000 (12:05 +0200)]
staging: gasket: remove gasket_interrupt_trigger_eventfd()

No one calls it, so just remove the dead code.

Cc: Rob Springer <rspringer@google.com>
Cc: John Joseph <jnjoseph@google.com>
Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: remove gasket_interrupt_get_eventfd_ctxs()
Greg Kroah-Hartman [Fri, 13 Jul 2018 10:05:52 +0000 (12:05 +0200)]
staging: gasket: remove gasket_interrupt_get_eventfd_ctxs()

It is exported, yet no one calls it so just remove the dead code.

Cc: Rob Springer <rspringer@google.com>
Cc: John Joseph <jnjoseph@google.com>
Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: remove pointless gasket_interrupt_pause()
Greg Kroah-Hartman [Fri, 13 Jul 2018 10:05:51 +0000 (12:05 +0200)]
staging: gasket: remove pointless gasket_interrupt_pause()

gasket_interrupt_pause() does nothing, and no one calls it, so remove it
as it is dead-weight.

Cc: Rob Springer <rspringer@google.com>
Cc: John Joseph <jnjoseph@google.com>
Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Rename file macro to avoid camel case - Coding Style
John Whitmore [Fri, 13 Jul 2018 11:23:11 +0000 (12:23 +0100)]
staging:rtl8192u: Rename file macro to avoid camel case - Coding Style

Simple rename of the preprosessor switch, protecting against multiple
inclusion of the header file. Change to clear the checkpatch coding style
issue.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Rename CmdID_RF_WriteReg > CMD_ID_RF_WRITE_REG - Style
John Whitmore [Fri, 13 Jul 2018 11:23:10 +0000 (12:23 +0100)]
staging:rtl8192u: Rename CmdID_RF_WriteReg > CMD_ID_RF_WRITE_REG - Style

Rename enum label CmdID_RF_WriteReg to CMD_ID_RF_WRITE_REG. This change clears
the checkpatch issue with CamelCase. The change is style only and should not
impact code execution.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Rename CmdID_WritePortUchar > CMD_ID_WRITE_PORT_UCHAR
John Whitmore [Fri, 13 Jul 2018 11:23:09 +0000 (12:23 +0100)]
staging:rtl8192u: Rename CmdID_WritePortUchar > CMD_ID_WRITE_PORT_UCHAR

Rename the enum label CmdID_WritePortUchar to CMD_ID_WRITE_PORT_UCHAR, to
clear the checkpatch issue with CamelCase. The change is a coding style change
only and should not impact code execution.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Rename CmdID_WritePortUshort > CMD_ID_WRITE_PORT_USHORT
John Whitmore [Fri, 13 Jul 2018 11:23:08 +0000 (12:23 +0100)]
staging:rtl8192u: Rename CmdID_WritePortUshort > CMD_ID_WRITE_PORT_USHORT

Rename the enum label CmdID_WritePortUshort to CMD_ID_WRITE_PORT_USHORT to
clear the checkpatch warning on CamelCase naming. This is a coding style
change only and should not impact code execution.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Rename CmdID_WritePortUlong > CMD_ID_WRITE_PORT_ULONG
John Whitmore [Fri, 13 Jul 2018 11:23:07 +0000 (12:23 +0100)]
staging:rtl8192u: Rename CmdID_WritePortUlong > CMD_ID_WRITE_PORT_ULONG

Rename enum label CmdID_WritePortUlong to CMD_ID_WRITE_PORT_ULONG to clear the
checkpatch CamelCase issue. Simple syle change which should not impact code
execution.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Remove unused enum label CmdID_BBRegWrite10
John Whitmore [Fri, 13 Jul 2018 11:23:06 +0000 (12:23 +0100)]
staging:rtl8192u: Remove unused enum label CmdID_BBRegWrite10

The enum label CmdID_BBRegWrite10 is not used in the code, so removed from the
source code.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: rename CmdID_SetTxPowerLevel > CMD_ID_SET_TX_PWR_LEVEL
John Whitmore [Fri, 13 Jul 2018 11:23:05 +0000 (12:23 +0100)]
staging:rtl8192u: rename CmdID_SetTxPowerLevel > CMD_ID_SET_TX_PWR_LEVEL

Rename enumeration label CmdID_SetTxPowerLevel to
CMD_ID_SET_TX_PWR_LEVEL. This change clears a checkpatch warning on
CamelCase. The change should not impact runtime execution, style change only.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Rename enum label CmdID_End > CMD_ID_END - Style
John Whitmore [Fri, 13 Jul 2018 11:23:04 +0000 (12:23 +0100)]
staging:rtl8192u: Rename enum label CmdID_End > CMD_ID_END - Style

Rename enum label to clear a CamelCase warning from checkpatch. This is a
simple style change and should not impact execution.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Rename SwChnlCmdID > switch_chan_cmd_id - Coding Style
John Whitmore [Fri, 13 Jul 2018 11:23:03 +0000 (12:23 +0100)]
staging:rtl8192u: Rename SwChnlCmdID > switch_chan_cmd_id - Coding Style

Rename enumerated type to clear a CamelCase warning from checkpatch. The
change is style only. No impact on run time execution.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: remove typedef from structure SwChnlCmd - Style
John Whitmore [Fri, 13 Jul 2018 11:23:02 +0000 (12:23 +0100)]
staging:rtl8192u: remove typedef from structure SwChnlCmd - Style

Checkpatch warns against creation of new types in code. This patch simply
removes the "typedef" declaration of the structure SwChnlCmd to clear this
issue. Simple coding style issue which should not impact runtime execution.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Remove typdef from enumeration RF90_RADIO_PATH_E - Style
John Whitmore [Fri, 13 Jul 2018 11:23:01 +0000 (12:23 +0100)]
staging:rtl8192u: Remove typdef from enumeration RF90_RADIO_PATH_E - Style

Checkpatch warns about the creation of new types. This patch simply removes
the typedef from the enumeration RF90_RADIO_PATH_E to clear this checkpatch
warning. There should be no impact on run time code execution, as this is a
coding style issue only.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: remove typdef from enumeration HW90_BLOCK_E - Style
John Whitmore [Fri, 13 Jul 2018 11:23:00 +0000 (12:23 +0100)]
staging:rtl8192u: remove typdef from enumeration HW90_BLOCK_E - Style

Checkpatch warns about the creation of new types in code. This patch simply
removes the typedef from the enumeration HW90_BLOCK_E to clear this
warning. There should be no impact on run time code execution.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: remove typedef of enumeration SwChnlCmdID - Style
John Whitmore [Fri, 13 Jul 2018 11:22:59 +0000 (12:22 +0100)]
staging:rtl8192u: remove typedef of enumeration SwChnlCmdID - Style

To clear a checkpatch issue removed the typedef of the enumeration SwChnlCmdID
this should not impact runtime code as it's only a coding style change.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: fix comparsions to true
Michael Straube [Thu, 12 Jul 2018 10:36:10 +0000 (12:36 +0200)]
staging: rtl8723bs: fix comparsions to true

Use if(x) instead of if(x == true).

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: change return type to bool
Michael Straube [Thu, 12 Jul 2018 10:36:09 +0000 (12:36 +0200)]
staging: rtl8723bs: change return type to bool

Both rtw_is_cckrates_included() and rtw_is_cckratesonly_included()
return true or false. Change the return type from uint to bool.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: refactor rtw_is_cckratesonly_included
Michael Straube [Thu, 12 Jul 2018 10:36:08 +0000 (12:36 +0200)]
staging: rtl8723bs: refactor rtw_is_cckratesonly_included

Refactor rtw_is_cckratesonly_included() to improve readability and
slightly reduce object file size.

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>
6 years agostaging: rtl8723bs: refactor rtw_is_cckrates_included()
Michael Straube [Thu, 12 Jul 2018 10:36:07 +0000 (12:36 +0200)]
staging: rtl8723bs: refactor rtw_is_cckrates_included()

Refactor rtw_is_cckrates_included() to improve readability and
slightly reduce object file size.

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>
6 years agostaging: rtl8723bs: remove unused code
Michael Straube [Thu, 12 Jul 2018 10:36:06 +0000 (12:36 +0200)]
staging: rtl8723bs: remove unused code

Remove commented rtw_is_cckrates_included() and
rtw_is_cckratesonly_included() from os_dep/ioctl_linux.c.
Both are defined in core/rtw_ieee80211.c.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Change struct r8192_priv member Rf_Mode from u8 > enum
John Whitmore [Wed, 11 Jul 2018 19:21:49 +0000 (20:21 +0100)]
staging:rtl8192u: Change struct r8192_priv member Rf_Mode from u8 > enum

The file r8192U.h defines the structure for holding private data for the
driver (typedef struct r8192_priv). This structure includes a member Rf_Mode
which is defined to be of type "u8".

Whilst the variable Rf_Mode is defined to be of type "u8" it is being assigned
enumerated values defined by the enumerated type "enum rf_op_type". Because of
the mismatch in types being used any advantage of using an enumerated type, to
have the compiler check assignments, is nullified.

This patch changes the type of the Rf_Mode member from a u8 to the enumerated
type "enum rf_op_type", so that the compiler can now check assignments.

This change of type would cause a problem if the structure was mapped from a
hardware device and the size and location of members was significant. I
believe that the structure to hold private data for the driver is allocated
from memory and populated with data in the function rtl8192_usb_probe() in the
file r8192U_core.c. As such the physical size of the member variable Rf_Mode
is not significant, so the change should have no impact on code execution, bar
the move from a u8 type to an int, (or whatever size compiler uses for enum).

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: remove typedef from struct rx_drvinfo_819x_usb
John Whitmore [Wed, 11 Jul 2018 19:21:48 +0000 (20:21 +0100)]
staging:rtl8192u: remove typedef from struct rx_drvinfo_819x_usb

Removed the typedef from the struct rx_drvinfo_819x_usb  to leave it as a
simple structure.

This clears the issue flagged by checkpatch, defining new types.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Remove struct rx_desc_819x_usb_aggr_subframe
John Whitmore [Wed, 11 Jul 2018 19:21:47 +0000 (20:21 +0100)]
staging:rtl8192u: Remove struct rx_desc_819x_usb_aggr_subframe

Removal of structure rx_desc_819x_usb_aggr_subframe from local header file,
which is not used outside the header file.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: typedef struct rx_desc_819x_usb remove typedef
John Whitmore [Wed, 11 Jul 2018 19:21:46 +0000 (20:21 +0100)]
staging:rtl8192u: typedef struct rx_desc_819x_usb remove typedef

Change structure rx_desc_819x_usb from being typedef to being a simple
structure, without the typedef.

Clears a checkpatch issue, definging new types in the code.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: typedef struct tx_fwinfo_819x_usb remove typedef
John Whitmore [Wed, 11 Jul 2018 19:21:45 +0000 (20:21 +0100)]
staging:rtl8192u: typedef struct tx_fwinfo_819x_usb remove typedef

Change structure tx_fwinfo_819x_usb from being typedef to being a simple
structure, without the typedef.

Clears the coding style issue flagged by checkpatch, (new type definitions)

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: typedef struct tx_desc_cmd_819x_usb remove typedef
John Whitmore [Wed, 11 Jul 2018 19:21:44 +0000 (20:21 +0100)]
staging:rtl8192u: typedef struct tx_desc_cmd_819x_usb remove typedef

Change structure tx_desc_cmd_819x_usb from being typedef to being a simple
structure, without the typedef.

checkpatch warns about defining new types in the code.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: remove unused structure tx_desc_819x_usb_aggr_subframe
John Whitmore [Wed, 11 Jul 2018 19:21:42 +0000 (20:21 +0100)]
staging:rtl8192u: remove unused structure tx_desc_819x_usb_aggr_subframe

Structure tx_desc_819x_usb_aggr_subframe is defined in a local header file but
is not used outside of the header file. Removed from the code as a result.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: trim multiple blank lines - Coding Style
John Whitmore [Wed, 11 Jul 2018 19:21:41 +0000 (20:21 +0100)]
staging:rtl8192u: trim multiple blank lines - Coding Style

Trim the extra blank lines from the code, to clear checkpatch messages.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: typedef struct tx_desc_819x_usb > struct tx_desc_819x_usb
John Whitmore [Wed, 11 Jul 2018 19:21:40 +0000 (20:21 +0100)]
staging:rtl8192u: typedef struct tx_desc_819x_usb > struct tx_desc_819x_usb

Change structure tx_desc_819x_usb from being typedef to being a simple
structure, without the typedef.

checkpatch warns about defining new types in code.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: bcm2835-audio: Don't leak workqueue if open fails
Tuomas Tynkkynen [Thu, 12 Jul 2018 21:54:17 +0000 (00:54 +0300)]
staging: bcm2835-audio: Don't leak workqueue if open fails

Currently, if bcm2835_audio_open() fails partway, the allocated
workqueue is leaked. Avoid that.

While at it, propagate the return value of
bcm2835_audio_open_connection() on failure instead of returning -1.

Signed-off-by: Tuomas Tynkkynen <tuomas@tuxera.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: bcm2835-audio: Check if workqueue allocation failed
Tuomas Tynkkynen [Thu, 12 Jul 2018 21:54:16 +0000 (00:54 +0300)]
staging: bcm2835-audio: Check if workqueue allocation failed

Currently, if allocating a workqueue fails, the driver will probe
successfully but it will silently do nothing, which is rather silly.
So instead bail out with -ENOMEM in bcm2835_audio_open() if
alloc_workqueue() fails, and remove the now pointless checks for a NULL
workqueue.

While at it, get rid of the rather pointless one-line function
my_workqueue_init().

Signed-off-by: Tuomas Tynkkynen <tuomas@tuxera.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: fsl-dpaa2/eth: Remove unnecessary cast
Ioana Radulescu [Thu, 12 Jul 2018 17:12:29 +0000 (12:12 -0500)]
staging: fsl-dpaa2/eth: Remove unnecessary cast

There's no need to explicitly cast DPAA2_ETH_MFL to u16,
so remove it.

Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Suggested-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8188eu: use strlcpy instead of strncpy
Michael Straube [Thu, 12 Jul 2018 16:16:13 +0000 (18:16 +0200)]
staging: rtl8188eu: use strlcpy instead of strncpy

Use strlcpy instead of strncpy to avoid gcc 8 warning:
warning: '__builtin_strncpy' specified bound 16 equals destination size [-Wstringop-truncation]

The maximum length of the source string including terminating null is 5.
Hence it always fits in the destination buffer of length 16.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtlwifi: Remove empty halmac_pcie_reg.h
Bjorn Helgaas [Thu, 12 Jul 2018 15:33:30 +0000 (10:33 -0500)]
staging: rtlwifi: Remove empty halmac_pcie_reg.h

halmac_pcie_reg.h is empty, so remove it and the only include of it.

Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8188eu: break line longer than 80 cols
Kacper Kołodziej [Thu, 12 Jul 2018 08:11:39 +0000 (10:11 +0200)]
staging: rtl8188eu: break line longer than 80 cols

Break too long line to follow kernel coding style.

Signed-off-by: Kacper Kołodziej <kacper@kolodziej.it>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: Use __func__ instead of hardcoded string - Style
Felix Siegel [Thu, 12 Jul 2018 22:58:49 +0000 (00:58 +0200)]
staging: gasket: Use __func__ instead of hardcoded string - Style

Changed logging statements to use %s and __func__ instead of hard coding
the function name in a string.

Signed-off-by: Felix Siegel <felix.siegel@posteo.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: remove "function entered" log messages
Felix Siegel [Thu, 12 Jul 2018 22:58:48 +0000 (00:58 +0200)]
staging: gasket: remove "function entered" log messages

Remove log messages that solely print the function's name
everytime it is called.

Signed-off-by: Felix Siegel <felix.siegel@posteo.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: fix multi line comments style
Felix Siegel [Thu, 12 Jul 2018 19:27:14 +0000 (21:27 +0200)]
staging: gasket: fix multi line comments style

This patch fixes checkpatch.pl warnings:

WARNING: Block comments should align the * on each line

Signed-off-by: Felix Siegel <felix.siegel@posteo.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: Move open-curly brace to match kernel code style
Felix Siegel [Thu, 12 Jul 2018 19:27:13 +0000 (21:27 +0200)]
staging: gasket: Move open-curly brace to match kernel code style

Move open open-curly brace to the next line following function
definition to match the kernel's coding style

Signed-off-by: Felix Siegel <felix.siegel@posteo.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: goldfish: add a blank line into struct goldfish_audio
Roman Kiryanov [Wed, 11 Jul 2018 23:37:48 +0000 (16:37 -0700)]
staging: goldfish: add a blank line into struct goldfish_audio

To separate data members and the comment for better readability.

Signed-off-by: Roman Kiryanov <rkir@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: goldfish: fix whitespace in goldfish_audio
Roman Kiryanov [Wed, 11 Jul 2018 23:36:28 +0000 (16:36 -0700)]
staging: goldfish: fix whitespace in goldfish_audio

Linux kernel coding style: spaces are never used for
indentation.

Signed-off-by: Roman Kiryanov <rkir@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: goldfish: Remove references to the retired driver from README
Roman Kiryanov [Wed, 11 Jul 2018 20:23:57 +0000 (13:23 -0700)]
staging: goldfish: Remove references to the retired driver from README

The goldfish nand driver was retired (not used).

Signed-off-by: Roman Kiryanov <rkir@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: fix error return code in pi433_probe()
Wei Yongjun [Wed, 11 Jul 2018 13:15:54 +0000 (13:15 +0000)]
staging: pi433: fix error return code in pi433_probe()

Fix to return a negative error code from the kthread_run() error
handling case instead of 0, as done elsewhere in this function.

Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: remove TODO item about SPDX usage
Greg Kroah-Hartman [Wed, 11 Jul 2018 11:39:12 +0000 (13:39 +0200)]
staging: gasket: remove TODO item about SPDX usage

Now that the files are all properly tagged with SPDX lines, and the
boilerplate license text is gone, remove the TODO item.

Cc: Rob Springer <rspringer@google.com>
Cc: John Joseph <jnjoseph@google.com>
Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: remove redundant license information
Greg Kroah-Hartman [Wed, 11 Jul 2018 11:39:11 +0000 (13:39 +0200)]
staging: gasket: remove redundant license information

Now that the SPDX tag is in all gasket files, that identifies the
license in a specific and legally-defined manner.  So the extra GPL text
wording can be removed as it is no longer needed at all.

This is done on a quest to remove the 700+ different ways that files in
the kernel describe the GPL license text.  And there's unneeded stuff
like the address (sometimes incorrect) for the FSF which is never
needed.

Cc: Rob Springer <rspringer@google.com>
Cc: John Joseph <jnjoseph@google.com>
Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: add SPDX identifiers to all files.
Greg Kroah-Hartman [Wed, 11 Jul 2018 11:39:10 +0000 (13:39 +0200)]
staging: gasket: add SPDX identifiers to all files.

It's good to have SPDX identifiers in all files to make it easier to
audit the kernel tree for correct licenses.

Fix up the all of the staging gasket files to have a proper SPDX
identifier, based on the license text in the file itself.  The SPDX
identifier is a legally binding shorthand, which can be used instead of
the full boiler plate text.

Cc: Rob Springer <rspringer@google.com>
Cc: John Joseph <jnjoseph@google.com>
Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: vt6655: remove some redundant variables
Colin Ian King [Wed, 11 Jul 2018 11:47:28 +0000 (12:47 +0100)]
staging: vt6655: remove some redundant variables

Variables rx_sts, sq, frame and is_pspoll are being assigned but are
never used hence they are redundant and can be removed.

Cleans up clang warnings:
warning: variable 'sq' set but not used [-Wunused-but-set-variable]
warning: variable 'rx_sts' set but not used [-Wunused-but-set-variable]
warning: variable 'frame' set but not used [-Wunused-but-set-variable]
warning: variable 'is_pspoll' set but not used [-Wunused-but-set-variable]

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8188eu: remove blank lines
Michael Straube [Wed, 11 Jul 2018 12:27:15 +0000 (14:27 +0200)]
staging: rtl8188eu: remove blank lines

Remove unrequired blank lines as reported by checkpatch.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8188eu: fix lines over 80 characters
Michael Straube [Wed, 11 Jul 2018 12:27:14 +0000 (14:27 +0200)]
staging: rtl8188eu: fix lines over 80 characters

Fix lines over 80 characters by adding appropriate line breaks.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8188eu: add spaces around '|'
Michael Straube [Wed, 11 Jul 2018 12:27:13 +0000 (14:27 +0200)]
staging: rtl8188eu: add spaces around '|'

Add spaces around '|' to follow kernel coding style.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: simplify ratetbl_val_2wifirate()
Michael Straube [Wed, 11 Jul 2018 11:23:30 +0000 (13:23 +0200)]
staging: rtl8723bs: simplify ratetbl_val_2wifirate()

Simplify ratetbl_val_2wifirate() by not using extra variable
for the return value.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: fix comparsions to NULL
Michael Straube [Wed, 11 Jul 2018 11:23:29 +0000 (13:23 +0200)]
staging: rtl8723bs: fix comparsions to NULL

Fix comparsions to NULL to follow kernel coding style.
x == NULL -> !x
x != NULL -> x

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: remove blank lines
Michael Straube [Wed, 11 Jul 2018 11:23:28 +0000 (13:23 +0200)]
staging: rtl8723bs: remove blank lines

Remove unrequired blank lines as reported by checkpatch.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: fix lines over 80 characters
Michael Straube [Wed, 11 Jul 2018 11:23:27 +0000 (13:23 +0200)]
staging: rtl8723bs: fix lines over 80 characters

Fix lines over 80 characters by adding appropriate line breaks.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: add spaces around '|'
Michael Straube [Wed, 11 Jul 2018 11:23:26 +0000 (13:23 +0200)]
staging: rtl8723bs: add spaces around '|'

Add spaces around '|' to follow kernel coding style.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: speakup: remove redundant variable l
Colin Ian King [Wed, 11 Jul 2018 11:26:07 +0000 (12:26 +0100)]
staging: speakup: remove redundant variable l

Variable l is being assigned but is never used hence it is redundant
and can be removed.

Cleans up clang warning:
warning: variable 'l' set but not used [-Wunused-but-set-variable

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: sm750fb: remove redundant pointer 'output'
Colin Ian King [Wed, 11 Jul 2018 11:35:23 +0000 (12:35 +0100)]
staging: sm750fb: remove redundant pointer 'output'

Pointer 'output' is being assigned but is never used hence it is redundant
and can be removed.

Cleans up clang warning:
warning: variable 'output' set but not used [-Wunused-but-set-variable]

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: fix plain integer as NULL pointer warning
Ivan Bornyakov [Wed, 11 Jul 2018 11:13:34 +0000 (14:13 +0300)]
staging: gasket: fix plain integer as NULL pointer warning

Trivial fix to remove sparse warnings:

  drivers/staging/gasket/gasket_page_table.c:884:40: warning: Using plain integer as NULL pointer
  drivers/staging/gasket/gasket_page_table.c:1743:57: warning: Using plain integer as NULL pointer
  drivers/staging/gasket/gasket_page_table.c:1768:57: warning: Using plain integer as NULL pointer

Signed-off-by: Ivan Bornyakov <brnkv.i1@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Correction of indentation issues - Coding Style
John Whitmore [Tue, 10 Jul 2018 15:05:23 +0000 (16:05 +0100)]
staging:rtl8192u: Correction of indentation issues - Coding Style

Simple changes to correct indentation issues.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Correct indentation of ieee80211_softmac_new_net()
John Whitmore [Tue, 10 Jul 2018 15:05:22 +0000 (16:05 +0100)]
staging:rtl8192u: Correct indentation of ieee80211_softmac_new_net()

Coding style change to correct the indentation of the function
ieee80211_softmac_new_net(). A large proportion of the function's if statements
were incorrectly indented.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Remove unnecessary parentheses - Coding Style
John Whitmore [Tue, 10 Jul 2018 15:05:21 +0000 (16:05 +0100)]
staging:rtl8192u: Remove unnecessary parentheses - Coding Style

checkpatch.pl flags unnecessary parentheses, so removed from code.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Move trailing conditional statement to the following line
John Whitmore [Tue, 10 Jul 2018 15:05:20 +0000 (16:05 +0100)]
staging:rtl8192u: Move trailing conditional statement to the following line

Coding standard requires that the conditional statement is not on the same
line as the 'if' or 'else' but on the following line. Statements moved
accordingly.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Remove prohibited spaces - Coding Style
John Whitmore [Tue, 10 Jul 2018 15:05:19 +0000 (16:05 +0100)]
staging:rtl8192u: Remove prohibited spaces - Coding Style

Simple removal of spaces prohibited by the coding standard.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Correct spacing before and after parenthesis - Style
John Whitmore [Tue, 10 Jul 2018 15:05:18 +0000 (16:05 +0100)]
staging:rtl8192u: Correct spacing before and after parenthesis - Style

Corrected coding style issues aroung opening and closed parenthesis.
Spaces, or blank line, removed from after '(' or before ')'

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Correct indentation and spacing for braces of code blocks
John Whitmore [Tue, 10 Jul 2018 15:05:17 +0000 (16:05 +0100)]
staging:rtl8192u: Correct indentation and spacing for braces of code blocks

Simple style change to fix the indentaiton and spacing of the braces around
multiline code blocks.

Braces removed from code block with a single line.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Remove blank lines before '}' and after '{' characters
John Whitmore [Tue, 10 Jul 2018 15:05:16 +0000 (16:05 +0100)]
staging:rtl8192u: Remove blank lines before '}' and after '{' characters

Coding style change to simply remove the unrequired blanks lines before a
closing brace or after an opening brace.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: ks7010: remove redundant variable eth_proto
Colin Ian King [Wed, 11 Jul 2018 10:59:11 +0000 (11:59 +0100)]
staging: ks7010: remove redundant variable eth_proto

Variable eth_proto is being assigned but is never used hence it is
redundant and can be removed.

Cleans up clang warning:
warning: variable 'eth_proto' set but not used [-Wunused-but-set-variable]

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gdm724x: redundant variables idProduct and idVendor
Colin Ian King [Wed, 11 Jul 2018 10:49:21 +0000 (11:49 +0100)]
staging: gdm724x: redundant variables idProduct and idVendor

Variable idProduct and idVendor are being assigned but are never used
hence they are redundant and can be removed.

Cleans up clang warnings:
warning: variable 'idProduct' set but not used [-Wunused-but-set-variable]
warning: variable 'idVendor' set but not used [-Wunused-but-set-variable]

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: gasket: remove redundant pointer bar_data
Colin Ian King [Wed, 11 Jul 2018 10:40:05 +0000 (11:40 +0100)]
staging: gasket: remove redundant pointer bar_data

Pointer bar_data is being assigned but is never used hence it is redundant
and can be removed.

Cleans up clang warning:
warning: variable 'bar_data' set but not used [-Wunused-but-set-variable]

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: comedi: remove redundant variable segpos
Colin Ian King [Wed, 11 Jul 2018 10:32:29 +0000 (11:32 +0100)]
staging: comedi: remove redundant variable segpos

Variable segpos is being assigned but is never used hence it is redundant
and can be removed.

Cleans up clang warning:
warning: variable 'segpos' set but not used [-Wunused-but-set-variable]

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: Make only one statement per line
Sophie Matter [Wed, 11 Jul 2018 09:45:53 +0000 (11:45 +0200)]
staging: pi433: Make only one statement per line

Lines containing multiple statements were broken into multiple
lines, increasing readability and complying with the coding standard.
This also fixes several checkpatch.pl errors complaining about
the lines being too long.

Signed-off-by: Sophie Matter <sophie.matter@web.de>
Signed-off-by: Rico Schrage <rico.schrage@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: Use preferred commenting style
Sophie Matter [Wed, 11 Jul 2018 09:45:52 +0000 (11:45 +0200)]
staging: pi433: Use preferred commenting style

For multi-line comments, the preferred commenting style from the
coding style Documentation was applied to the comments, meaning
almost blank lines at the beginning and end of the comment.
One changed comment includes a line over 80 characters, causing
checkpatch.pl to complain, however breaking this line would not
make much sense, so it is kept like it is.

Signed-off-by: Sophie Matter <sophie.matter@web.de>
Signed-off-by: Rico Schrage <rico.schrage@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: pi433: Comply with 80 character column limit
Sophie Matter [Wed, 11 Jul 2018 09:45:51 +0000 (11:45 +0200)]
staging: pi433: Comply with 80 character column limit

Lines have been split where it makes sense to shorten them in order
to comply with the coding standards and fix checkpatch.pl warnings.
There are still lines left that are too long, however breaking
those would impair readability.

Changes in v2:
 - now working on staging-next branch of the staging tree
 - the changes to the defines previously made are deleted
   due to readability

Signed-off-by: Sophie Matter <sophie.matter@web.de>
Signed-off-by: Rico Schrage <rico.schrage@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: mt7621-pci: factor out mt7621_pci_get_cfgaddr function
Sergio Paracuellos [Mon, 9 Jul 2018 20:21:04 +0000 (22:21 +0200)]
staging: mt7621-pci: factor out mt7621_pci_get_cfgaddr function

To get config address the same pattern is repeated in some functions
along the code. Factor out a new mt7621_pci_get_cfgaddr for calculate
it and use it in convenient places. Adjust types to match to u32 where
is neccesary.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: mt7621-pci: remove unused macro MV_READ_DATA
Sergio Paracuellos [Mon, 9 Jul 2018 20:21:03 +0000 (22:21 +0200)]
staging: mt7621-pci: remove unused macro MV_READ_DATA

This macro is not being used at all along the code.
Just remove it.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: mt7621-gpio: remove driver from staging
Sergio Paracuellos [Mon, 9 Jul 2018 16:05:48 +0000 (18:05 +0200)]
staging: mt7621-gpio: remove driver from staging

Remove driver from staging. It has been accepted in
the linux-gpio tree.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: use mac_pton()
Michael Straube [Mon, 9 Jul 2018 13:50:39 +0000 (15:50 +0200)]
staging: rtl8723bs: use mac_pton()

Use mac_pton() instead of custom approach.
Remove the now unused hex2num_i() and hwaddr_aton_i().

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agoRevert "staging: mt7621-pinctrl: replace core_initcall_sync with builtin_platform_driver"
Sergio Paracuellos [Mon, 9 Jul 2018 11:28:30 +0000 (13:28 +0200)]
Revert "staging: mt7621-pinctrl: replace core_initcall_sync with builtin_platform_driver"

That patch causes the network interface on the device to stop working.
device_initcall() is called much later than core_initcall_sync() and
that seem to be a problem. Revert it to get a correct behaviour.

Reported-by: NeilBrown <neil@brown.name>
Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: mt7621-pinctrl: init *map to NULL for correct memory assignation
Sergio Paracuellos [Mon, 9 Jul 2018 04:52:45 +0000 (06:52 +0200)]
staging: mt7621-pinctrl: init *map to NULL for correct memory assignation

pinctrl_utils_reserve_map() calls krealloc() on *map. Because of this
*map need to be initialized to NULL before calling it.

Fixes: 62b6215c11ea ("staging: mt7621-pinctrl: make use of pinctrl_utils_reserve_map")
Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: fsl-dpaa2/eth: Remove Rx frame size check
Ioana Radulescu [Mon, 9 Jul 2018 15:01:11 +0000 (10:01 -0500)]
staging: fsl-dpaa2/eth: Remove Rx frame size check

Most Ethernet drivers don't enforce the MTU value as upper limit
for ingress frames. We too support receiving frames larger than
MTU, so allow that.

Remove our ndo_change_mtu implementation, letting the default
stack implementation handle things. Also, set the max frame length
allowed by hardware only once at probe time, with the largest
possible value.

Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: fsl-dpaa2/eth: MTU cleanup
Ioana Radulescu [Mon, 9 Jul 2018 15:01:10 +0000 (10:01 -0500)]
staging: fsl-dpaa2/eth: MTU cleanup

Don't set the lower MTU limit explicitly, since we use
the default value anyway.

Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: fsl-dpaa2/eth: Remove pointless instruction
Ioana Radulescu [Mon, 9 Jul 2018 15:01:09 +0000 (10:01 -0500)]
staging: fsl-dpaa2/eth: Remove pointless instruction

We don't need to call dev_set_drvdata(dev, NULL) on driver
remove since core kernel code also performs this step.

Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: fsl-dpaa2/eth: Remove obsolete reference
Ioana Radulescu [Mon, 9 Jul 2018 15:01:08 +0000 (10:01 -0500)]
staging: fsl-dpaa2/eth: Remove obsolete reference

Commit 2b7c86eb7bf3 ("staging: fsl-dpaa2/eth: Don't enable FAS on Tx")
removed the status field from the TX confirm frame annotation,
but a reference to it remained in the description of free_tx_fd().
Remove it.

Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: fsl-dpaa2/eth: Fix DMA mapping direction
Ioana Radulescu [Mon, 9 Jul 2018 15:01:07 +0000 (10:01 -0500)]
staging: fsl-dpaa2/eth: Fix DMA mapping direction

We are using DMA_FROM_DEVICE when mapping RX frame buffers,
but DMA_BIDIRECTIONAL for unmap. Fix the direction for DMA
unmapping operation.

Fixes: 87eb55e418b7 ("staging: fsl-dpaa2/eth: Fix potential endless loop")

Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8188eu: replace tabs with spaces
Michael Straube [Sun, 8 Jul 2018 11:58:12 +0000 (13:58 +0200)]
staging: rtl8188eu: replace tabs with spaces

Replace tabs with spaces in some function definitions and variable
declarations.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8188eu: refactor rtw_macaddr_cfg()
Michael Straube [Sun, 8 Jul 2018 11:58:11 +0000 (13:58 +0200)]
staging: rtl8188eu: refactor rtw_macaddr_cfg()

Use ether_addr_copy() instead of memcpy() to copy the mac address.

Using is_broadcast_ether_addr() and is_zero_ether_addr() instead of
testing each byte of the mac[] array for 0xff and 0x00 shortens the
code and improves readability.

Instead of a fixed default mac address use a random one to reduce the
likelihood of mac address collision.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: remove braces from single if statement
Michael Straube [Sun, 8 Jul 2018 10:38:55 +0000 (12:38 +0200)]
staging: rtl8723bs: remove braces from single if statement

Remove braces from single if statement to follow kernel coding style.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: add missing blank lines
Michael Straube [Sun, 8 Jul 2018 10:38:54 +0000 (12:38 +0200)]
staging: rtl8723bs: add missing blank lines

Add missing blank lines after declarations as reported by checkpatch.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: remove blank lines
Michael Straube [Sun, 8 Jul 2018 10:38:53 +0000 (12:38 +0200)]
staging: rtl8723bs: remove blank lines

Remove unrequired blank lines as reported by checkpatch.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: fix indentation
Michael Straube [Sun, 8 Jul 2018 10:38:52 +0000 (12:38 +0200)]
staging: rtl8723bs: fix indentation

Remove unrequired extra indentations.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: replace tab with space
Michael Straube [Sun, 8 Jul 2018 10:38:51 +0000 (12:38 +0200)]
staging: rtl8723bs: replace tab with space

Replace tabs with spaces in some function definitions.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging: rtl8723bs: replace while with shorter for loop
Michael Straube [Sun, 8 Jul 2018 10:38:50 +0000 (12:38 +0200)]
staging: rtl8723bs: replace while with shorter for loop

Simplify rtw_get_rateset_len() by replacing the while loop
with a shorter for loop.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: rename HT_EXTCHNL_OFFSET -> enum ht_extension_chan_width
John Whitmore [Sat, 7 Jul 2018 14:55:07 +0000 (15:55 +0100)]
staging:rtl8192u: rename HT_EXTCHNL_OFFSET -> enum ht_extension_chan_width

remove the typedef of enumerated type HT_EXTCHNL_OFFSET and replace it with
'enum ht_extension_chan_offset'

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Add spaces required around operators - Coding Style
John Whitmore [Sat, 7 Jul 2018 14:55:05 +0000 (15:55 +0100)]
staging:rtl8192u: Add spaces required around operators - Coding Style

Added the spaces, required by coding style, around the various operators.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: Add space required before '(' - Style
John Whitmore [Sat, 7 Jul 2018 14:55:03 +0000 (15:55 +0100)]
staging:rtl8192u: Add space required before '(' - Style

Simple addition of the coding style required space before '('.

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6 years agostaging:rtl8192u: rename HT_CHANNEL_WIDTH -> enum ht_channel_width
John Whitmore [Sat, 7 Jul 2018 14:55:02 +0000 (15:55 +0100)]
staging:rtl8192u: rename HT_CHANNEL_WIDTH -> enum ht_channel_width

remove the typedef HT_CHANNEL_WIDTH and replace with 'enum ht_channel_width'

Signed-off-by: John Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>