Commit Graph

753709 Commits

Author SHA1 Message Date
Greg Kroah-Hartman
f7a258a8a4 staging: lustre: fix build error in mdc_request.c
Turns out we need some more .h files to build properly on all arches.
Specifically prefetch.h for this file.

Reported-by: kbuild test robot <lkp@intel.com>
Fixes: 73d65c8d1a ("staging: lustre: remove libcfs_all.h from lustre/include/*.h")
Cc: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-26 08:57:25 +02:00
Sergio Paracuellos
0badacd779 staging: mt7621-gpio: update TODO file
update TODO file accordly to last changes.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Sergio Paracuellos
8cf7c2f9df staging: mt7621-gpio: use MTK_BANK_WIDTH instead of magic number
There are some places where magic number '32' is being used to get
the gpio bank. There already exist a definition MTK_BANK_WIDTH
with this value, so just use it instead.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Sergio Paracuellos
b36dd3af48 staging: mt7621-gpio: use ternary operator in return in mediatek_gpio_get_direction
This commits replaces if statement and two returns in favour
of a only one return using a ternary operator.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Sergio Paracuellos
e9301a5a8b staging: mt7621-gpio: avoid devm_kzalloc() hidden inside declarations and refactor function a bit
Driver probe function includes an allocation using devm_kzalloc
which is "hidden" a bit inside the declarations. Extract this
to a better place to increase readability. Also because we are
allocating zeroed memory 'memset' statement is not needed at all.
Condition for checking for a valid gpio id is wrong and it should
be greater or equal instead of only greater so update to be the
good one.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Sergio Paracuellos
10ca84f272 staging: mt7621-gpio: dt-bindings: add interrupt nodes to bindings doc
Interrupt related stuff for gpio controller in mt7621 was missing
in device tree documentation. Add it to complete documentation for
this driver.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Sergio Paracuellos
c7092ed794 staging: mt7621-dts: add interrupt device tree nodes for the gpio controller
The GPIO controller of mt7621 can receive interrupts on any
of the GPIOs, either edge or level. It then interrupts the CPU using
GIC INT12. Update device tree accordly.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Sergio Paracuellos
0aaf256cf1 staging: mt7621-gpio: avoid use of globals and use platform_data instead
Gpio driver have a some globals which can be avoided just
using platform_data in a proper form. This commit adds a new
struct mtk_data which includes all of those globals setting them
using platform_set_drvdata and devm_gpiochip_add_data functions.
With this properly set we are able to retrieve driver data along
the code using kernel api's so globals are not needed anymore.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Sergio Paracuellos
568f24236b staging: mt7621-gpio: replace 'mtk' to use correct one 'mediatek'
Gpio driver is using mtk and there is already 'mediatek' binding
defined for this maker. Update driver to use it instead the custom
one 'mtk'.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Sergio Paracuellos
81ca7c496f staging: mt7621-dts: update gpios related entries to use 'mediatek'
Gpio driver for mt7621 is using 'mtk' as binding but in the kernel
is already defined one for this maker which is 'mediatek'. Update
device tree to use the correct one.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Sergio Paracuellos
af315a5b04 staging: mt7621-gpio: dt-bindings: add documentation for mt7621-gpio
This commit add missing dt bindings documentation for mt7621-gpio
driver. There is some missing stuff here about interrupts with is
not also being used in the mt7621.dtsi file. So just include in
staging a incomplete version before moving this to kernel's dt-bindings
place.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Reviewed-by: NeilBrown <neil@brown.name>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:49:32 +02:00
Quytelda Kahja
55dee96311 staging: rtl8723bs: Fix grammar error in comment.
Fix a grammatical error in the comment describing 'struct
rt_firmware_hdr'.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:47:22 +02:00
Quytelda Kahja
699ad73456 staging: rtl8723bs: Fix camel-case in 'struct rt_firmware_hdr'.
Replace camel-case member names with snake-case names per the linux
kernel coding style guidelines.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:47:22 +02:00
Quytelda Kahja
7a45210e95 staging: rtl8723bs: Fix spelling/grammar errors in comment.
Fix the spelling/grammar errors in the comment block describing
the 'Function' member of 'struct rt_firmware_hdr'.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:47:22 +02:00
Quytelda Kahja
93998817a1 staging: rtl8723bs: Fix camel-case in 'struct rt_firmware'.
Change the members of 'struct rt_firmware' to be snake case instead
of camel-case, per the kernel coding style guide.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:47:22 +02:00
Quytelda Kahja
341aa5ad1a staging: rtl8723bs: Fix camel-case in IS_FW_HEADER_EXIST_8723B().
Change the parameter of the macro to the snake case 'fw_hdr' instead
of '_pFwHdr'.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:47:22 +02:00
Quytelda Kahja
44500a42c5 staging: rtl8723bs: Clean up whitespace in 'rtl8723_hal.h'.
Make alignment and whitespace more consistent within the file
'rtl8723_hal.h' and with the kernel coding style guidelines.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:47:22 +02:00
Quytelda Kahja
92096dc077 staging: rtl8723bs: Rename 'Hal8723BPhyCfg.h' using snake case.
Camel-case is discouraged in the linux kernel coding style.  Rename
this header file using snake case instead.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:47:22 +02:00
Quytelda Kahja
8875d38b14 staging: rtl8723bs: Rename 'Hal8723bPhyReg.h' using snake case.
Camel-case is discouraged in the linux kernel coding style.  Rename
this header using snake case instead.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:47:22 +02:00
Quytelda Kahja
22962b380c staging: rtl8723bs: Rename 'Hal8723BPwrSeq.{c, h}' to 'hal_pwr_seq.*'.
Camel-case naming is discouraged int the linux kernel coding style.
Rename these files using snake case, and update the makefile to use
the new names.

Signed-off-by: Quytelda Kahja <quytelda@tamalin.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:47:22 +02:00
Arnd Bergmann
916c0c4b83 staging: fsl-dpaa2/rtc: fix PTP dependency
We can't select PTP_1588_CLOCK when posix timers are completely
disabled:

WARNING: unmet direct dependencies detected for PTP_1588_CLOCK
  Depends on [n]: NET [=y] && POSIX_TIMERS [=n]
  Selected by [y]:
  - FSL_DPAA2_PTP_CLOCK [=y] && STAGING [=y] && FSL_DPAA2_ETH [=y]

This adds the necessary dependency.

Fixes: 9bdf43b3d4 ("staging: fsl-dpaa2/rtc: add rtc driver")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:45:47 +02:00
Adham Abozaeid
979eb0c96b staging: wilc1000: Avoid overriding rates_no while parsing ies element.
Commit d4b4aaba51 ("staging: wilc1000: fix line over 80 characters in
host_int_parse_join_bss_param()") introduced a bug by not keeping the
rates_no value while parsing ies elements.
It also increments auth_total_cnt as a pointer instead of its reference.

This commit fixes the bug by passing reference to rates_no to
host_int_parse_join_bss_param() and by incrementing reference of
auth_total_cnt

Fixes: d4b4aaba51 (staging: wilc1000: fix line over 80 characters in host_int_parse_join_bss_param())
Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:45:47 +02:00
Tim Collier
173ffd0993 staging: wlan-ng: convert P80211SKB_RXMETA to inline function in p80211conv
To avoid possible issues with repeated reference to the macro argument
as reported by checkpatch, macro P80211SKB_RXMETA is replaced with an
equivalent inline function. The function is named p80211skb_rxmeta to
follow the coding style guidelines; references to the macro are
updated to reference the new function.

This change depends on the similar change for P80211SKB_FRMMETA having
been applied.

Signed-off-by: Tim Collier <osdevtc@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:44:14 +02:00
Tim Collier
df6835d1f6 staging: wlan-ng: convert P80211SKB_FRMMETA to inline function in p80211conv
To avoid possible issues with repeated reference to the macro argument
as reported by checkpatch, macro P80211SKB_FRMMETA is replaced with an
equivalent inline function. The function is named p80211skb_frmmeta to
follow the coding style guidelines; references to the macro are
updated to reference the new function.

Signed-off-by: Tim Collier <osdevtc@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:44:14 +02:00
Davide Spataro
67d412e44d staging: rtl8192e: rtllib_tx: fix spelling issue.
Fix a spelling problem. Issue found by checkpatch.pl.

Signed-off-by: Davide Spataro <davide90.spataro@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:44:14 +02:00
Colin Ian King
e709e7fe49 staging: mt7621-mmc: fix spelling mistake: "Illgal" -> "Illegal"
Trivial fix to another spelling mistake in N_MSG message text

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:44:13 +02:00
Colin Ian King
ac5d6d869c staging: greybus: fix spelling mistake: "Inavlid" -> "Invalid"
Trivial fix to spelling mistake in dev_err error message

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: Vaibhav Agarwal <vaibhav.sr@gmail.com>
Acked-by: Mark Greer <mgreer@animalcreek.com>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:44:13 +02:00
Colin Ian King
70ac74619c staging: rtlwifi: fix spelling mistake: "Platfoem" -> "Platform"
Trivial fix to spelling mistake in ODM_RT_TRACE message text

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:44:13 +02:00
Colin Ian King
a9a45c19af staging: wilc1000: fix spelling mistake: "Preamle" -> "Preamble"
Trivial fix to spelling mistake in netdev_err error message

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Reviewed-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:44:13 +02:00
Ivan Bornyakov
1e71247364 staging: lustre: libcfs: add parens around macros args
One may call 'CFS_FAIL_TIMEOUT(id, secs + 5);' and get unexpected result
after macro substitution, viz., 'secs + 5' will turn into
'secs + 5 * 1000'

Signed-off-by: Ivan Bornyakov <brnkv.i1@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:41:19 +02:00
Sabin Mihai Rapan
777690e68c staging: lustre: Fix block comments style
This patch fixes the checkpatch.pl warning:

WARNING:BLOCK_COMMENT_STYLE: Block comments use a trailing */ on a separate line

Signed-off-by: Sabin Mihai Rapan <sabin.rapan@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:40:56 +02:00
Sabin Mihai Rapan
0fb1de16f3 staging: lustre: Fix "unsigned"->"unsigned int"
This patch fixes the checkpatch.pl warning:

WARNING:UNSPECIFIED_INT: Prefer 'unsigned int' to bare use of 'unsigned'

Signed-off-by: Sabin Mihai Rapan <sabin.rapan@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:40:56 +02:00
Sabin Mihai Rapan
b743387eb4 staging: lustre: Fix "Possible intergrate"->"Possibly integrate"
Trivial fix to spelling mistake in TODO file.

Signed-off-by: Sabin Mihai Rapan <sabin.rapan@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:40:56 +02:00
Sabin Mihai Rapan
1c0f625871 staging: lustre: Fix "from from"->"from"
Trivial fix to spelling mistake in README.txt

Signed-off-by: Sabin Mihai Rapan <sabin.rapan@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:40:56 +02:00
NeilBrown
8e5566ac73 staging: lustre: remove libcfs_all.h
In the remaining files that include libcfs_all.h,
replace it with other include files as necessary,
then remove libcfs_all.h

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:36:43 +02:00
NeilBrown
7059b37ffe staging: lustre: move all libcfs_all includes except in lustre/lnet/libcfs/
Again, most of these are not needed.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:36:43 +02:00
NeilBrown
8fbb71cb35 staging: lustre: remove remaining libcfs_all.h includes from lustre/lustre
Most of these aren't needed, a few can be simplified.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:36:42 +02:00
NeilBrown
f076bfb791 staging: lustre: remove libcfs_all.h from fid, fld, obdclass
None of these files seem to nee libcfs_all.h

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:36:42 +02:00
NeilBrown
0922c0084b staging: lustre: remove libcfs_all from ptlrpc
Some files didn't need it at all, others just needed
one or two includes.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:36:18 +02:00
NeilBrown
8f0ca7fca3 staging: lustre: remove libcfs_all.h from remaining .h files.
Now no *.h files include libcfs_all.h - only *.c files.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:36:18 +02:00
NeilBrown
73d65c8d1a staging: lustre: remove libcfs_all.h from lustre/include/*.h
Instead of the catch-all libcfs_all.h, just include the
files actually needed in different places.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:36:18 +02:00
NeilBrown
fd998c02dc staging: lustre: remove libcfs_all.h from includes lustre/lnet
Some of these include files didn't need to
include libcfs_all.h.  A couple did so replace with just the
base include files needed.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:36:18 +02:00
NeilBrown
7a83b3a19a staging: lustre: remove libcfs_all.h includes from lnet/klnd
Other smaller include files are sufficient.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:36:18 +02:00
NeilBrown
1f28db699f staging: lustre: don't include libcfs.h in lnet/lib-lnet.h
We want to be more focused in what is included where.
So we remove libcfs.h from where it isn't needed.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:36:18 +02:00
NeilBrown
e6eafdb9f9 staging: lustre: start moving includes out of libcfs.h
Lots of places include libcfs.h, and it includes lots of other include
files.  Many of these aren't needed in many places.  It is tidier and
better documentation to just include what is needed.

So remove all the includes from libcfs.h and create libcfs_all.h which
contains them.  Then change every reference to libcfs.h to instead
include libcfs_all.h

Next several patches will remove that from various files
in small batches

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:34:03 +02:00
NeilBrown
7673fd6b6a staging: lustre: discard libcfs_prim.h
This file no longer contains enough content
to justify a separate file.  So merge with
libcfs.h.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:29:11 +02:00
NeilBrown
fa39909362 staging: lustre: replace memory_presure funcitons by standard interfaces.
Use memalloc_noreclaim_save() and memalloc_noreclaim_restore(),
and for testing, just directly test the flag in current->flags

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:29:10 +02:00
NeilBrown
525609ed58 staging: lustre: move RESV_PORT definitions to lnet/lib-lnet.h
These are network related on only used in lnet, so move
to lib-lnet.h

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:29:10 +02:00
NeilBrown
17bcf37aac staging: lustre: move lnet_debug_log_upcall declaration to tracefile.h
Both files that use this variable include tracefile.h, and it
seems a more suitable home for the declaration.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:29:10 +02:00
NeilBrown
c4f9077197 staging: lustre: make lnet_debugfs_symlink_def local to libcfs/modules.c
This type is only used in libcfs/module.c, so make it local to there.
If any other module ever wanted to add its own symlinks,
it would probably be easiest to export lnet_debugfs_root
and just call debugfs_create_symlink as required.

Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-25 18:29:10 +02:00