Ran Algawi [Sun, 12 Feb 2017 21:45:32 +0000 (23:45 +0200)]
Staging: media: bcm2048: Fixed coding style issue.
Fixed a coding style issue, where an octal value was needed insted of decimal.
Signed-off-by: Ran Algawi <ran.algawi@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sun, 12 Feb 2017 07:26:23 +0000 (12:56 +0530)]
staging: rtl8192u: Fixing no new typedef warning
This patch fixes following checkpatch.pl
warnings: WARNING:do not add new typedefs.
All the related files have been modified.
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Arushi Singhal [Sun, 12 Feb 2017 10:45:58 +0000 (16:15 +0530)]
staging: rtl8192e: Aligning the * on each line in block comments
This patch fixes the issue by aligning the * on each line in block
comments.
Signed-off-by: Arushi Singhal <arushisinghal19971997@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sun, 12 Feb 2017 09:44:12 +0000 (15:14 +0530)]
staging: rtl8192u: Removing unnecessary parentheses
Removing unnecessary parentheses from an expression of the form &(x).
Issue found by checkpatch.
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 21:10:26 +0000 (02:40 +0530)]
staging: rtl8192u: Fix warnings relating to printk()
This fixes the following checkpatch.pl warnings:
WARNING: printk() should include KERN_ facility level
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:56:58 +0000 (02:26 +0530)]
staging: rtl8192u: Fix RETURN_VOID warnings
Fix 'void function return statements are not generally useful'
checkpatch.pl warnings.
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:55:07 +0000 (02:25 +0530)]
staging: rtl8192u: Fix brace placement
Fix brace placement errors caught by checkpatch.pl ERROR: that open
brace { should be on the previous line
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:53:15 +0000 (02:23 +0530)]
staging: rtl8192u: Removing true and false comparison
Remove comparison to true and false in if statement.
Problem found usingcheckpatch.pl.
CHECK: Using comparison to true is error prone
CHECK: Using comparison to false is error prone
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:51:21 +0000 (02:21 +0530)]
staging: rtl8192u: Remove unnecessary space after a cast
This patch fixes the checkpatch issue:
CHECK: No space is necessary after a cast
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:49:21 +0000 (02:19 +0530)]
staging: rtl8192u: Replace explicit NULL comparisons with !
This patch replace explicit NULL comparison with ! or unmark operator to
simplify code.
Reported by checkpatch.pl for comparison to NULL could be
written "!XXX" or "XXX".
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:46:51 +0000 (02:16 +0530)]
staging: rtl8192u: Remove useless function
This patch remove useless function ieee80211_ccmp_null.
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:43:40 +0000 (02:13 +0530)]
staging: rtl8192u: Fix braces {} style
This fixes all checkpatch form of this from the Lustre tree: CHECK:
braces {} should be used on all arms of this statement
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:40:09 +0000 (02:10 +0530)]
staging: rtl8192u: Clean up comparison to NULL
Checkpatch recommended changes.
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:37:38 +0000 (02:07 +0530)]
staging: rtl8192u: Fixing multiple assignments
This patch modifies the assignments into single assignments.
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:32:21 +0000 (02:02 +0530)]
staging: rtl8192u: Removing unnecessary space after a cast
This patch fixes the checkpatch warning by removing unnecessary space
after a cast.
CHECK: No space is necessary after a cast
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Sat, 11 Feb 2017 20:26:09 +0000 (01:56 +0530)]
staging: rtl8192u: Removing multiple blank lines
This patch fixes the checkpatch warning by removing multiple blank
lines.
CHECK: Please don't use multiple blank lines
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sat, 11 Feb 2017 09:59:01 +0000 (22:59 +1300)]
Staging: rtl8192u: ieee80211: ieee80211_crypt.c - style fix
Fixed style of block comments
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sat, 11 Feb 2017 09:58:46 +0000 (22:58 +1300)]
Staging: rtl8192u: ieee80211: ieee80211_crypt.h - style fix
Fixed style of block comments
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sat, 11 Feb 2017 09:55:48 +0000 (22:55 +1300)]
Staging: rtl8192u: ieee80211: ieee80211_crypt_wep.c - style fix
Fixed style of block comments
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sat, 11 Feb 2017 09:55:31 +0000 (22:55 +1300)]
Staging: rtl8192u: r8180_93cx6.c - style fix
Fixed style of block comments
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sat, 11 Feb 2017 09:55:16 +0000 (22:55 +1300)]
Staging: rtl8192u: r8190_rtl8256.c - style fix
Fixed style of block comments
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sat, 11 Feb 2017 09:55:00 +0000 (22:55 +1300)]
Staging: rtl8192u: r8190_rtl8256.h - style fix
Fixed style of block comments
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sat, 11 Feb 2017 09:53:51 +0000 (22:53 +1300)]
Staging: rtl8192u: r8192U_hw.h - style fix
Fixed style of block comments
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sat, 11 Feb 2017 09:53:15 +0000 (22:53 +1300)]
Staging: rtl8192u: r819xU_cmdpkt.h - style fix
Fixed style of block comments.
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sat, 11 Feb 2017 09:52:58 +0000 (22:52 +1300)]
Staging: rtl8192u: r819xU_firmware.c - style fix
Fixed style of block comments
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sat, 11 Feb 2017 09:52:40 +0000 (22:52 +1300)]
Staging: rtl8192u: r819xU_phy.c - style fix
Fixed style of block comments
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Larry Finger [Sat, 11 Feb 2017 03:30:30 +0000 (21:30 -0600)]
staging: r8712u: Fix Sparse warnings in rtl871x_mlme.c
Sparse reports the following:
CHECK drivers/staging/rtl8712/rtl871x_mlme.c
drivers/staging/rtl8712/rtl871x_mlme.c:1653:46: warning: incorrect type in assignment (different base types)
drivers/staging/rtl8712/rtl871x_mlme.c:1653:46: expected unsigned int [unsigned] [usertype] DSConfig
drivers/staging/rtl8712/rtl871x_mlme.c:1653:46: got restricted __le32 [usertype] <noident>
drivers/staging/rtl8712/rtl871x_mlme.c:1656:56: warning: incorrect type in assignment (different base types)
drivers/staging/rtl8712/rtl871x_mlme.c:1656:56: expected unsigned int [unsigned] [usertype] ATIMWindow
drivers/staging/rtl8712/rtl871x_mlme.c:1656:56: got restricted __le32 [usertype] <noident>
drivers/staging/rtl8712/rtl871x_mlme.c:1712:35: warning: incorrect type in assignment (different base types)
drivers/staging/rtl8712/rtl871x_mlme.c:1712:35: expected restricted __le16 [addressable] [usertype] cap_info
drivers/staging/rtl8712/rtl871x_mlme.c:1712:35: got int
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Larry Finger [Sat, 11 Feb 2017 03:30:29 +0000 (21:30 -0600)]
staging: r8712u: Fix Sparse warnings in rtl871x_ioctl_linux.c
Sparse reports the following:
CHECK drivers/staging/rtl8712/rtl871x_ioctl_linux.c
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1422:46: warning: restricted __le16 degrades to integer
drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1424:46: warning: restricted __le16 degrades to integer
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Larry Finger [Sat, 11 Feb 2017 03:30:28 +0000 (21:30 -0600)]
staging: r8712u: Fix Sparse endian warning in rtl871x_recv.c
Sparse reports the following:
CHECK drivers/staging/rtl8712/rtl871x_recv.c
drivers/staging/rtl8712/rtl871x_recv.c:657:21: warning: incorrect type in assignment (different base types)
drivers/staging/rtl8712/rtl871x_recv.c:657:21: expected unsigned short [unsigned] [assigned] [usertype] len
drivers/staging/rtl8712/rtl871x_recv.c:657:21: got restricted __be16 [usertype] <noident>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Larry Finger [Sat, 11 Feb 2017 03:30:27 +0000 (21:30 -0600)]
staging: r8712u: Fix Sparse warning in rtl871x_xmit.c
Sparse reports the following:
CHECK drivers/staging/rtl8712/rtl871x_xmit.c
drivers/staging/rtl8712/rtl871x_xmit.c:350:44: warning: restricted __le32 degrades to integer
drivers/staging/rtl8712/rtl871x_xmit.c:491:23: warning: incorrect type in initializer (different base types)
drivers/staging/rtl8712/rtl871x_xmit.c:491:23: expected unsigned short [usertype] *fctrl
drivers/staging/rtl8712/rtl871x_xmit.c:491:23: got restricted __le16 *<noident>
drivers/staging/rtl8712/rtl871x_xmit.c:580:36: warning: incorrect type in assignment (different base types)
drivers/staging/rtl8712/rtl871x_xmit.c:580:36: expected unsigned short [unsigned] [short] [usertype] <noident>
drivers/staging/rtl8712/rtl871x_xmit.c:580:36: got restricted __be16 [usertype] <noident>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Larry Finger [Sat, 11 Feb 2017 03:30:26 +0000 (21:30 -0600)]
staging: r8712u: Fix macros used to read/write the TX/RX descriptors
Although the driver works on big-endian hardware, Sparse generates a lot
of warnings. Many of these are the result of incorrect coding of these
macros.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Larry Finger [Sat, 11 Feb 2017 03:30:25 +0000 (21:30 -0600)]
staging: rtl8712u: Fix endian settings for structs describing network packets
The headers describing a number of network packets do not have the
correct endian settings for several types of data.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Larry Finger [Sat, 11 Feb 2017 03:30:24 +0000 (21:30 -0600)]
staging: rtl8712: Fix some Sparse endian messages
Sparse reports the following:
CHECK drivers/staging/rtl8712/rtl8712_xmit.c
drivers/staging/rtl8712/rtl8712_xmit.c:564:42: warning: cast from restricted __le32
drivers/staging/rtl8712/rtl8712_xmit.c:569:42: warning: cast from restricted __le32
drivers/staging/rtl8712/rtl8712_xmit.c:571:42: warning: cast from restricted __le32
Each of these cases is transferring a quantity that is little-endian. There
is no need for conversion.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Jess Frazelle [Sat, 11 Feb 2017 01:37:57 +0000 (17:37 -0800)]
staging: set msi_domain_ops as __ro_after_init
Marked msi_domain_ops structs as __ro_after_init when called only during init.
This protects the data structure from accidental corruption.
Suggested-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Jess Frazelle <me@jessfraz.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Shiva Kerdel [Fri, 10 Feb 2017 16:08:14 +0000 (17:08 +0100)]
Staging: ks7010: ks_*: Removed blank lines before and after braces.
Removing unnecessary blank lines around braces to solve CHECKS.
Signed-off-by: Shiva Kerdel <shiva@exdev.nl>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Youngdo, Lee [Fri, 10 Feb 2017 15:29:15 +0000 (00:29 +0900)]
staging: android: ion: fix coding style issue
Replaced sizeof(struct foo) into sizeof(*ptr), found by checkpatch.pl.
Signed-off-by: Youngdo, Lee <oss.ydlee@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Gioh Kim [Thu, 9 Feb 2017 16:30:12 +0000 (17:30 +0100)]
staging: greybus: fix symbolic permission coding style issues
Fix "Octal permissions are preffered than symbolic ones" issues.
Signed-off-by: Gioh Kim <gi-oh.kim@profitbricks.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Gioh Kim [Thu, 9 Feb 2017 16:30:11 +0000 (17:30 +0100)]
staging: greybus: fix "line over 80 characters" coding style issues
This patch fixes only obvious lines.
There are still more issues.
Signed-off-by: Gioh Kim <gi-oh.kim@profitbricks.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Nathan Howard [Sat, 11 Feb 2017 04:16:37 +0000 (23:16 -0500)]
staging: greybus: arpc.h: remove duplicate line.
Fix checkpatch.pl issue of the form:
"CHECK: Please don't use multiple blank lines".
Signed-off-by: Nathan Howard <adanhawthorn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Nathan Howard [Sat, 11 Feb 2017 05:06:44 +0000 (00:06 -0500)]
staging: dgnc: dgnc_tty.c: fix argument list alignment issue.
Fix checkpatch.pl issue of the form:
"CHECK: Alignment should match open parenthesis".
Signed-off-by: Nathan Howard <adanhawthorn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Sun, 12 Feb 2017 07:13:42 +0000 (20:13 +1300)]
Staging: sm750fb: sm750.c - style fix
Change permissions to octal style.
Found using checkpatch
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Alexander Alemayhu [Sat, 11 Feb 2017 10:13:47 +0000 (11:13 +0100)]
staging: wlan-ng: reduce type warnings
Fixes the following sparse output:
drivers/staging/wlan-ng/p80211conv.c:132:25: warning: cast to restricted __be16
drivers/staging/wlan-ng/p80211conv.c:132:25: warning: cast to restricted __be16
drivers/staging/wlan-ng/p80211conv.c:132:25: warning: cast to restricted __be16
drivers/staging/wlan-ng/p80211conv.c:132:25: warning: cast to restricted __be16
drivers/staging/wlan-ng/p80211conv.c:154:38: warning: incorrect type in assignment (different base types)
drivers/staging/wlan-ng/p80211conv.c:154:38: expected unsigned short [unsigned] [usertype] type
drivers/staging/wlan-ng/p80211conv.c:154:38: got restricted __be16 [usertype] <noident>
drivers/staging/wlan-ng/p80211conv.c:390:42: warning: cast to restricted __le16
drivers/staging/wlan-ng/p80211conv.c:413:29: warning: incorrect type in assignment (different base types)
drivers/staging/wlan-ng/p80211conv.c:413:29: expected unsigned short [unsigned] [usertype] type
drivers/staging/wlan-ng/p80211conv.c:413:29: got restricted __be16 [usertype] <noident>
drivers/staging/wlan-ng/p80211conv.c:481:29: warning: incorrect type in assignment (different base types)
drivers/staging/wlan-ng/p80211conv.c:481:29: expected unsigned short [unsigned] [usertype] type
drivers/staging/wlan-ng/p80211conv.c:481:29: got restricted __be16 [usertype] <noident>
Signed-off-by: Alexander Alemayhu <alexander@alemayhu.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Jacob Zachariah [Sun, 12 Feb 2017 01:27:50 +0000 (17:27 -0800)]
staging:wilc1000: Fix line over 80 characters
Fix a checkpatch.pl WARNING: line over 80 characters
Signed-off-by: Jacob Zachariah <jacob_z@yahoo.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Saber Rezvani [Thu, 9 Feb 2017 12:59:56 +0000 (16:29 +0330)]
staging: comedi: dmm32at: usleep_range is preferred over udelay
Fix the checkpatch.pl issue:
CHECK: usleep_range is preferred over udelay
Signed-off-by: Saber Rezvani <irsaber@gmail.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Saber Rezvani [Thu, 9 Feb 2017 14:26:02 +0000 (17:56 +0330)]
staging: comedi: dt2801: usleep_range is preferred over udelay
Fix the checkpatch.pl issue:
CHECK: usleep_range is preferred over udelay
Signed-off-by: Saber Rezvani <irsaber@gmail.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Saber Rezvani [Thu, 9 Feb 2017 14:44:10 +0000 (18:14 +0330)]
staging: comedi: dt2814: usleep_range is preferred over udelay
Fix the checkpatch.pl issue:
CHECK: usleep_range is preferred over udelay
Signed-off-by: Saber Rezvani <irsaber@gmail.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Saber Rezvani [Thu, 9 Feb 2017 15:04:26 +0000 (18:34 +0330)]
staging: comedi: dt2815: usleep_range is preferred over udelay
Fix the checkpatch.pl issue:
CHECK: usleep_range is preferred over udelay
Signed-off-by: Saber Rezvani <irsaber@gmail.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Saber Rezvani [Thu, 9 Feb 2017 21:33:27 +0000 (01:03 +0330)]
staging: comedi: ni_at_a2150: usleep_range is preferred over udelay
Fix the checkpatch.pl issue:
CHECK: usleep_range is preferred over udelay
Signed-off-by: Saber Rezvani <irsaber@gmail.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
AbdAllah-MEZITI [Fri, 10 Feb 2017 18:52:51 +0000 (19:52 +0100)]
staging: bcm2835-audio: fix trailing statements
Trailing statements should be on next line.
Signed-off-by: AbdAllah-MEZITI <abdallah.meziti.pro@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
William Blough [Sun, 12 Feb 2017 10:05:31 +0000 (05:05 -0500)]
staging: lustre: lnet: fix type warning in lib-socket.c
The local socket address is defined as a __be32 value. However, if the
local ip address is not given, then the constant INADDR_ANY is used.
This patch converts INADDR_ANY to __be32 for type consistency.
Fixes the following sparse warnings:
drivers/staging/lustre/lnet/lnet/lib-socket.c:396:41: warning:
incorrect type in assignment (different base types)
drivers/staging/lustre/lnet/lnet/lib-socket.c:397:56: warning:
restricted __be32 degrades to integer
Signed-off-by: William Blough <devel@blough.us>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Niu Yawei [Sat, 11 Feb 2017 17:12:39 +0000 (12:12 -0500)]
staging: lustre: llite: check reply status in ll_migrate()
ll_migrate() should check reply status before trying to read
reply buffer, checking if request is NULL doesn't make sense.
Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-8807
Reviewed-on: https://review.whamcloud.com/23666
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
wang di [Sat, 11 Feb 2017 17:12:38 +0000 (12:12 -0500)]
staging: lustre: llite: root inode checking for migration
Do not migrate root inode.
Signed-off-by: wang di <di.wang@intel.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7577
Reviewed-on: http://review.whamcloud.com/17669
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
wang di [Sat, 11 Feb 2017 17:12:37 +0000 (12:12 -0500)]
staging: lustre: llite: check request != NULL in ll_migrate
Check if the request is NULL, before retrieve reply body
from the request.
Signed-off-by: wang di <di.wang@intel.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7396
Reviewed-on: http://review.whamcloud.com/17079
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Signed-off-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Greg Kroah-Hartman [Sat, 11 Feb 2017 15:46:03 +0000 (16:46 +0100)]
Merge tag 'iio-fixes-for-4.11a' of git://git./linux/kernel/git/jic23/iio into staging-next
Jonathan writes:
First set of IIO fixes for the 4.11 cycle. Regression fixes from 4.10.
These are fixes that came in just to late for the 4.10 cycle.
Two drivers made an accidental assumption of structure arrangement for
struct iio_dev that are no longer true. It was a typo in the first place
that happened to work until some elements were added to the structure.
* mpl3115
- don't rely on structure field ordering
* mpl115
- don't rely on structure field ordering.
Peter Rosin [Wed, 1 Feb 2017 20:40:57 +0000 (21:40 +0100)]
iio: pressure: mpl115: do not rely on structure field ordering
Fixes a regression triggered by a change in the layout of
struct iio_chan_spec, but the real bug is in the driver which assumed
a specific structure layout in the first place. Hint: the three bits were
not OR:ed together as implied by the indentation prior to this patch,
there was a comma between the first two, which accidentally moved the
..._SCALE and ..._OFFSET bits to the next structure field. That field
was .info_mask_shared_by_type before the _available attributes was added
by commit
51239600074b ("iio:core: add a callback to allow drivers to
provide _available attributes") and .info_mask_separate_available
afterwards, and the regression happened.
info_mask_shared_by_type is actually a better choice than the originally
intended info_mask_separate for the ..._SCALE and ..._OFFSET bits since
a constant is returned from mpl115_read_raw for the scale/offset. Using
info_mask_shared_by_type also preserves the behavior from before the
regression and is therefore less likely to cause other interesting side
effects.
The above mentioned regression causes unintended sysfs attibutes to
show up that are not backed by code, in turn causing a NULL pointer
defererence to happen on access.
Fixes:
3017d90e8931 ("iio: Add Freescale MPL115A2 pressure / temperature sensor driver")
Fixes:
51239600074b ("iio:core: add a callback to allow drivers to provide _available attributes")
Signed-off-by: Peter Rosin <peda@axentia.se>
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Peter Rosin [Wed, 1 Feb 2017 20:40:56 +0000 (21:40 +0100)]
iio: pressure: mpl3115: do not rely on structure field ordering
Fixes a regression triggered by a change in the layout of
struct iio_chan_spec, but the real bug is in the driver which assumed
a specific structure layout in the first place. Hint: the two bits were
not OR:ed together as implied by the indentation prior to this patch,
there was a comma between them, which accidentally moved the ..._SCALE
bit to the next structure field. That field was .info_mask_shared_by_type
before the _available attributes was added by commit
51239600074b
("iio:core: add a callback to allow drivers to provide _available
attributes") and .info_mask_separate_available afterwards, and the
regression happened.
info_mask_shared_by_type is actually a better choice than the originally
intended info_mask_separate for the ..._SCALE bit since a constant is
returned from mpl3115_read_raw for the scale. Using
info_mask_shared_by_type also preserves the behavior from before the
regression and is therefore less likely to cause other interesting side
effects.
The above mentioned regression causes an unintended sysfs attibute to
show up that is not backed by code, in turn causing the following NULL
pointer defererence to happen on access.
Segmentation fault
Unable to handle kernel NULL pointer dereference at virtual address
00000000
pgd =
ecc3c000
[
00000000] *pgd=
87f91831
Internal error: Oops:
80000007 [#1] SMP ARM
Modules linked in:
CPU: 1 PID: 1051 Comm: cat Not tainted
4.10.0-rc5-00009-gffd8858-dirty #3
Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree)
task:
ed54ec00 task.stack:
ee2bc000
PC is at 0x0
LR is at iio_read_channel_info_avail+0x40/0x280
pc : [<
00000000>] lr : [<
c06fbc1c>] psr:
a0070013
sp :
ee2bdda8 ip :
00000000 fp :
ee2bddf4
r10:
c0a53c74 r9 :
ed79f000 r8 :
ee8d1018
r7 :
00001000 r6 :
00000fff r5 :
ee8b9a00 r4 :
ed79f000
r3 :
ee2bddc4 r2 :
ee2bddbc r1 :
c0a86dcc r0 :
ee8d1000
Flags: NzCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment none
Control:
10c5387d Table:
3cc3c04a DAC:
00000051
Process cat (pid: 1051, stack limit = 0xee2bc210)
Stack: (0xee2bdda8 to 0xee2be000)
dda0:
ee2bddc0 00000002 c016d720 c016d394 ed54ec00 00000000
ddc0:
60070013 ed413780 00000001 edffd480 ee8b9a00 00000fff 00001000 ee8d1018
dde0:
ed79f000 c0a53c74 ee2bde0c ee2bddf8 c0513c58 c06fbbe8 edffd480 edffd540
de00:
ee2bde3c ee2bde10 c0293474 c0513c40 c02933e4 ee2bde60 00000001 ed413780
de20:
00000001 ed413780 00000000 edffd480 ee2bde4c ee2bde40 c0291d00 c02933f0
de40:
ee2bde9c ee2bde50 c024679c c0291ce0 edffd4b0 b6e37000 00020000 ee2bdf78
de60:
00000000 00000000 ed54ec00 ed013200 00000817 c0a111fc edffd540 ed413780
de80:
b6e37000 00020000 00020000 ee2bdf78 ee2bded4 ee2bdea0 c0292890 c0246604
dea0:
c0117940 c016ba50 00000025 c0a111fc b6e37000 ed413780 ee2bdf78 00020000
dec0:
ee2bc000 b6e37000 ee2bdf44 ee2bded8 c021d158 c0292770 c0117764 b6e36004
dee0:
c0f0d7c4 ee2bdfb0 b6f89228 00021008 ee2bdfac ee2bdf00 c0101374 c0117770
df00:
00000000 00000000 ee2bc000 00000000 ee2bdf34 ee2bdf20 c016ba04 c0171080
df20:
00000000 00020000 ed413780 b6e37000 00000000 ee2bdf78 ee2bdf74 ee2bdf48
df40:
c021e7a0 c021d130 c023e300 c023e280 ee2bdf74 00000000 00000000 ed413780
df60:
ed413780 00020000 ee2bdfa4 ee2bdf78 c021e870 c021e71c 00000000 00000000
df80:
00020000 00020000 b6e37000 00000003 c0108084 00000000 00000000 ee2bdfa8
dfa0:
c0107ee0 c021e838 00020000 00020000 00000003 b6e37000 00020000 0001a2b4
dfc0:
00020000 00020000 b6e37000 00000003 7fffe000 00000000 00000000 00020000
dfe0:
00000000 be98eb4c 0000c740 b6f1985c 60070010 00000003 00000000 00000000
Backtrace:
[<
c06fbbdc>] (iio_read_channel_info_avail) from [<
c0513c58>] (dev_attr_show+0x24/0x50)
r10:
c0a53c74 r9:
ed79f000 r8:
ee8d1018 r7:
00001000 r6:
00000fff r5:
ee8b9a00
r4:
edffd480
[<
c0513c34>] (dev_attr_show) from [<
c0293474>] (sysfs_kf_seq_show+0x90/0x110)
r5:
edffd540 r4:
edffd480
[<
c02933e4>] (sysfs_kf_seq_show) from [<
c0291d00>] (kernfs_seq_show+0x2c/0x30)
r10:
edffd480 r9:
00000000 r8:
ed413780 r7:
00000001 r6:
ed413780 r5:
00000001
r4:
ee2bde60 r3:
c02933e4
[<
c0291cd4>] (kernfs_seq_show) from [<
c024679c>] (seq_read+0x1a4/0x4e0)
[<
c02465f8>] (seq_read) from [<
c0292890>] (kernfs_fop_read+0x12c/0x1cc)
r10:
ee2bdf78 r9:
00020000 r8:
00020000 r7:
b6e37000 r6:
ed413780 r5:
edffd540
r4:
c0a111fc
[<
c0292764>] (kernfs_fop_read) from [<
c021d158>] (__vfs_read+0x34/0x118)
r10:
b6e37000 r9:
ee2bc000 r8:
00020000 r7:
ee2bdf78 r6:
ed413780 r5:
b6e37000
r4:
c0a111fc
[<
c021d124>] (__vfs_read) from [<
c021e7a0>] (vfs_read+0x90/0x11c)
r8:
ee2bdf78 r7:
00000000 r6:
b6e37000 r5:
ed413780 r4:
00020000
[<
c021e710>] (vfs_read) from [<
c021e870>] (SyS_read+0x44/0x90)
r8:
00020000 r7:
ed413780 r6:
ed413780 r5:
00000000 r4:
00000000
[<
c021e82c>] (SyS_read) from [<
c0107ee0>] (ret_fast_syscall+0x0/0x1c)
r10:
00000000 r8:
c0108084 r7:
00000003 r6:
b6e37000 r5:
00020000 r4:
00020000
Code: bad PC value
---[ end trace
9c4938ccd0389004 ]---
Fixes:
cc26ad455f57 ("iio: Add Freescale MPL3115A2 pressure / temperature sensor driver")
Fixes:
51239600074b ("iio:core: add a callback to allow drivers to provide _available attributes")
Reported-by: Ken Lin <ken.lin@advantech.com>
Tested-by: Ken Lin <ken.lin@advantech.com>
Signed-off-by: Peter Rosin <peda@axentia.se>
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Simon Sandström [Fri, 10 Feb 2017 12:33:53 +0000 (13:33 +0100)]
staging: bcm2835-audio: Make internal symbols static
Fixes sparse warnings:
warning: symbol 'xxx' was not declared. Should it be static?
Signed-off-by: Simon Sandström <simon@nikanor.nu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Abhijit Naik [Fri, 10 Feb 2017 11:39:05 +0000 (17:09 +0530)]
staging: bcm2835-audio: Fixed initialization of global to "false"
bcm2835-vchiq.c:
fixing ERROR: do not initialise globals to false
Instead of explicitly initializing global variable force_bulk to "false",
declared force_bulk as static variable.
Signed-off-by: Abhijit Naik <abhijitnaik27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Frans Klaver [Thu, 9 Feb 2017 21:58:21 +0000 (22:58 +0100)]
staging: wlan_ng: fix logical continuation alignment
It appears that our coding style prefers that logical continuations
have the operator at the end of the line. Fix that.
While at it, stick the 'if' after 'else' where it belongs.
Signed-off-by: Frans Klaver <fransklaver@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Arushi Singhal [Thu, 9 Feb 2017 13:22:53 +0000 (18:52 +0530)]
staging:vt6656:baseband.h: fix function definition argument without identifier name issue
Function definitions arguments should also have an identifier name as
reported by checkpatch.pl.
Signed-off-by: Arushi Singhal <arushisinghal19971997@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
simran singhal [Thu, 9 Feb 2017 12:15:14 +0000 (17:45 +0530)]
staging: rtl8192u: Adding a blank line after declarations
This patch fixes the checkpatch warning by adding a blank line after
declarations.
WARNING: Missing a blank line after declarations
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Colin Ian King [Thu, 9 Feb 2017 11:37:54 +0000 (11:37 +0000)]
Staging: rtl8192e: remove redundant null check on array alg
u.crypt.alg is an array of u8 integers and hence the null check on
this array is redundant and can be removed.
Detected with CoverityScan, CID#146583 ("Array compared against 0")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Stuart Yoder [Thu, 9 Feb 2017 14:32:31 +0000 (08:32 -0600)]
staging: fsl-mc: update MAINTAINERS
Add Laurentiu Tudor as a second maintainer and update Stuart Yoder's
email address.
Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Laurentiu Tudor [Tue, 7 Feb 2017 15:43:53 +0000 (09:43 -0600)]
staging: fsl-mc: dprc: drop unused APIs
Leave only APIs that area actually used in the bus driver.
The patch is mostly mechanical, with a couple exceptions:
- getters/setters were not removed even if only one of
them is being used
- versioning API was also left in place
They will be added back on an as-needed basis.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Acked-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Laurentiu Tudor [Tue, 7 Feb 2017 15:43:52 +0000 (09:43 -0600)]
staging: fsl-mc: dpbp: add a few missing EXPORT_SYMBOL()s
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Acked-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Laurentiu Tudor [Tue, 7 Feb 2017 15:43:51 +0000 (09:43 -0600)]
staging: fsl-mc: dpbp: drop unused APIs
Leave only APIs that will be used in upcomming drivers.
The patch is mostly mechanical, with a couple exceptions:
- getters/setters were not removed even if only one of
them is being used
- versioning API was also left in place
They will be added back on an as-needed basis.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Acked-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Laurentiu Tudor [Tue, 7 Feb 2017 15:43:50 +0000 (09:43 -0600)]
staging: fsl-mc: dpmng: drop unused prototype
The implementation was removed in commit:
decd3d0cf (staging: fsl-mc: uprev binary interface to match MC v10.x)
but the prototype was left behind.
Also fix a message that was wrongly mentioning it.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Acked-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Laurentiu Tudor [Tue, 7 Feb 2017 15:43:49 +0000 (09:43 -0600)]
staging: fsl-mc: dpmcp: drop unused APIs
These APIs are not used yet, so drop the dead code.
The patch is mostly mechanical, with a couple exceptions:
- getters/setters were not removed even if only one of
them is being used
- versioning API was also left in place
Also in this patch, add missing prototype for
version query function.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Acked-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Laurentiu Tudor [Tue, 7 Feb 2017 15:43:48 +0000 (09:43 -0600)]
staging: fsl-mc: remove slab cache for mc devices
Let's drop the slab cache for objects
until we actually have proof that it improves
performance. This makes the code cleaner.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Acked-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Laurentiu Tudor [Tue, 7 Feb 2017 15:43:47 +0000 (09:43 -0600)]
staging: fsl-mc: don't use devres api for refcounted objects
Mixing two memory management systems, in this case
managed device resource api and refcounted objects
is a bad idea. Lifetime of an object is controlled
by its refcount so allocating it with other apis
that have their own lifetime control is not ok.
Drop devm_*() apis in favor of plain allocations.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Acked-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Laurentiu Tudor [Tue, 7 Feb 2017 15:43:46 +0000 (09:43 -0600)]
staging: fsl-mc: add device release callback
When hot unplugging a mc-bus device the kernel displays
this pertinent message, followed by a stack dump:
"Device 'foo.N' does not have a release() function,
it is broken and must be fixed."
Add the required callback to fix and drop the now
uneeded explicit freeing.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Acked-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Laurentiu Tudor [Tue, 7 Feb 2017 15:43:45 +0000 (09:43 -0600)]
staging: fsl-mc: fix device ref counting
Drop unneeded get_device() call at device creation
and, as per documentation, drop reference count
after using device_find_child() return.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Acked-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Laurentiu Tudor [Tue, 7 Feb 2017 15:43:44 +0000 (09:43 -0600)]
staging: fsl-mc: drop root dprc counting
It was used just to sanity check some obscure
cases that are unlikely to ever happen.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Acked-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Matthieu Simon [Wed, 8 Feb 2017 06:48:43 +0000 (22:48 -0800)]
staging: sm750fb: Replace POKE32 and PEEK32 by inline functions
POKE32 and PEEK32 have been replaced by inlined functions poke32 and
peek32.
Having inline functions instead of macros help to get the correct
type-checking and avoid the possible precedence issues reported by
checkpatch.
Signed-off-by: Matthieu Simon <gmatthsim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Colin Ian King [Thu, 9 Feb 2017 11:06:43 +0000 (11:06 +0000)]
staging: rtl8192u: remove redundant null check on array alg
u.crypt.alg is an array of u8 integers and hence the null check on
this array is redundant and can be removed.
Detected with CoverityScan, CID#143214 ("Array compared against 0")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Fu Yong Quah [Tue, 7 Feb 2017 03:24:12 +0000 (22:24 -0500)]
staging: rtl8192u: Fix indentation
Fix number of indentaions for block scopes as suggested by
Documentation/CodingStyle.
Signed-off-by: Fu Yong Quah <quah.fy95@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Ivan Safonov [Mon, 6 Feb 2017 17:23:28 +0000 (20:23 +0300)]
staging:r8188eu: replace recv_frame->rx_(data|len|tail) with pkt->(data|len|tail) and remove unused recvframe_(put|pull|pull_tail)()
recv_frame->rx_(data|len|tail) duplicate pkt (skb) data|len|tail members
and require special functions recvframe_(put|pull|pull_tail)()
instead of skb_(put|pull|trim).
Replace rx_(data|len|tail) with pkt->(data|len|tail),
remove rx_(data|len|tail) and remove recvframe_(put|pull|pull_tail)().
Signed-off-by: Ivan Safonov <insafonov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Ivan Safonov [Mon, 6 Feb 2017 17:23:27 +0000 (20:23 +0300)]
staging:r8188eu: update pkt->(data|tail|len) synchronously with rx_(data|tail|len) in recv_frame structure
Original driver code uses rx_* members to store skb (pkt) fields
(instead of pkt->* members), pkt->* updated only after data
completely formed, not in process.
Update pkt->* after data buffer changed (with rx_*).
Signed-off-by: Ivan Safonov <insafonov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Ivan Safonov [Mon, 6 Feb 2017 17:23:26 +0000 (20:23 +0300)]
staging:r8188eu: remove unused rtw_ieee80211_bar structure definition
rtw_ieee80211_bar structure definition does not used. Remove it.
Signed-off-by: Ivan Safonov <insafonov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Ivan Safonov [Mon, 6 Feb 2017 17:23:25 +0000 (20:23 +0300)]
staging:r8188eu: replace rx_end member of recv_frame with pkt->end
rx_end is duplication of pkt->end pointer.
pkt->end is preferred, because it is native skb field
supported by skb_*() functions.
Signed-off-by: Ivan Safonov <insafonov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Carlos Palminha [Thu, 9 Feb 2017 10:18:42 +0000 (10:18 +0000)]
staging: rtl8712: rtl8712: fixed missing conversion to le32
Fixed missing conversion to le32, detected by sparse
(invalid assignment from int to __le32)
Signed-off-by: Carlos Palminha <palminha@synopsys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Dan Carpenter [Tue, 7 Feb 2017 13:17:57 +0000 (16:17 +0300)]
Staging: bcm2835-audio: remove unneeded NULL check
We just dereferenced "instance" on the line before so checking it here
is pointless. Anyway, it can't be NULL here so let's remove the check.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Dan Carpenter [Tue, 7 Feb 2017 13:17:34 +0000 (16:17 +0300)]
Staging: bcm2835-audio: fix an uninitialized return value
"ret" isn't necessarily initialized on the success path.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Dan Carpenter [Tue, 7 Feb 2017 13:17:07 +0000 (16:17 +0300)]
staging: bcm2835-audio: off by one in snd_bcm2835_playback_open_generic()
The > should be >= otherwise we write beyond the end of the array when
we do:
chip->alsa_stream[idx] = alsa_stream;
Fixes:
23b028c871e1 ("staging: bcm2835-audio: initial staging submission")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Victor Vaschenko [Mon, 6 Feb 2017 12:48:01 +0000 (15:48 +0300)]
Staging: bcm2835-audio: Fixed that open brace should be on previous line error in bcm2835-ctl.c
Fixed ERROR: that open brace { should be on the previous line.
One coding style correction for better readable code.
Signed-off-by: Victor Vaschenko <vicmos89@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Simon Sandström [Tue, 7 Feb 2017 11:03:04 +0000 (12:03 +0100)]
staging: bcm2835-audio: Remove unnecessary space after cast
Fixes checkpatch check "No space is necessary after a cast".
Signed-off-by: Simon Sandström <simon@nikanor.nu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Simon Sandström [Tue, 7 Feb 2017 11:02:43 +0000 (12:02 +0100)]
staging: bcm2835-audio: Rewrite comparison to NULL
Fixes checkpatch check "Comparison to NULL could be written '!chip'".
Signed-off-by: Simon Sandström <simon@nikanor.nu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Simon Sandström [Tue, 7 Feb 2017 11:02:26 +0000 (12:02 +0100)]
staging: bcm2835-audio: Fix argument indentation
Fixes checkpatch CHECK: "Alignment should match open parenthesis".
Signed-off-by: Simon Sandström <simon@nikanor.nu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Simon Sandström [Tue, 7 Feb 2017 11:02:06 +0000 (12:02 +0100)]
staging: bcm2835-audio: Simplify bcm2835_alsa_device_init()
Fixes checkpatch warning "Missing a blank line after declarations".
Signed-off-by: Simon Sandström <simon@nikanor.nu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Simon Sandström [Tue, 7 Feb 2017 11:01:46 +0000 (12:01 +0100)]
staging: bcm2835-audio: Move open brace to correct line
Fixes checkpatch error "open brace { should be on the previous line".
Signed-off-by: Simon Sandström <simon@nikanor.nu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Simon Sandström [Tue, 7 Feb 2017 11:01:27 +0000 (12:01 +0100)]
staging: bcm2835-audio: Remove whitespace before quoted newline
Fixes checkpatch warning "unnecessary whitespace before a quoted
newline".
Signed-off-by: Simon Sandström <simon@nikanor.nu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Simon Sandström [Tue, 7 Feb 2017 11:01:10 +0000 (12:01 +0100)]
staging: bcm2835-audio: Remove incorrect whitespace
According to the coding style, "bcm2835_ship ** rchip" should be
"bcm2835 **rchip".
Signed-off-by: Simon Sandström <simon@nikanor.nu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Simon Sandström [Tue, 7 Feb 2017 11:00:56 +0000 (12:00 +0100)]
staging: bcm2835-audio: Remove static initialisation
Static pointers are explicility initialised to NULL.
Signed-off-by: Simon Sandström <simon@nikanor.nu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Javier Rodriguez [Mon, 6 Feb 2017 17:19:32 +0000 (18:19 +0100)]
staging: gdm724x: fix incorrect type in assignment
Fix sparse warning issue.
drivers/staging/gdm724x/gdm_lte.c:201:33: warning: incorrect type in assignment (different base types)
drivers/staging/gdm724x/gdm_lte.c:201:33: expected unsigned int [unsigned] [addressable] [usertype] ph_len
drivers/staging/gdm724x/gdm_lte.c:201:33: got restricted __be16 [usertype] payload_len
Signed-off-by: Javier Rodriguez <jrodbar@yahoo.es>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Dan Carpenter [Wed, 8 Feb 2017 07:18:08 +0000 (10:18 +0300)]
staging: gdm724x: fix a couple array overflows
The find_dev_index() function is frustrating. If you give it an invalid
index then it returns 0. That was the intent except there is an
off-by-one so it can return MAX_NIC_TYPE which is one higher than we
want.
There is one caller which had a sanity check to catch invalid returns,
but the other two callers assumed that index was valid.
My feeling is that when we are given invalid indexes, that should be
treated like an error and we abandon what we were doing.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
stephen knipe [Wed, 8 Feb 2017 19:27:46 +0000 (20:27 +0100)]
staging: most: dim2_hdm octal permissions fix
This patch is to make the permissions sent to module_param be
explicitly octal in accordance with the linux style conventions. Issues
found by checkpatch.pl.
Signed-off-by: stephen knipe <steve.knipe@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Derek Robson [Mon, 6 Feb 2017 02:28:13 +0000 (15:28 +1300)]
Staging: speakup: speakup.h - remove unused define
As part of cleaning up symbolic permissions found define that is not used.
Signed-off-by: Derek Robson <robsonde@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Johan Hovold [Mon, 23 Jan 2017 12:04:14 +0000 (13:04 +0100)]
staging: greybus: operation: add generic timeout support
Add a struct timer_list to struct gb_operation and use that to implement
generic operation timeouts.
This simplifies the synchronous operation handling somewhat while also
providing a generic timeout mechanism that drivers can use for
asynchronous operations.
Signed-off-by: Johan Hovold <johan@kernel.org>
Acked-by: Bryan O'Donoghue <pure.logic@nexus-software.ie>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Greg Kroah-Hartman [Mon, 6 Feb 2017 08:36:10 +0000 (09:36 +0100)]
Merge 4.10-rc7 into staging-next
This resolves the merge errors that were reported in linux-next and it
picks up the staging and IIO fixes that we need/want in here as well.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Linus Torvalds [Sun, 5 Feb 2017 23:10:58 +0000 (15:10 -0800)]
Linux 4.10-rc7