Ralph Loader [Fri, 21 Jan 2011 06:27:53 +0000 (19:27 +1300)]
staging: Fix some incorrect use of positive error codes.
Use -E... instead of just E... in a few places where negative error
codes are expected by a functions callers. These were found by grepping
with coccinelle & then inspecting by hand to determine which were bugs.
The staging/cxt1e1 driver appears to intentionally use positive E...
error codes in some places, and negative -E... error codes in others,
making it hard to know which is intended where - very likely I missed
some problems in that driver.
Signed-off-by: Ralph Loader <suckfish@ihug.co.nz> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Ian Abbott [Tue, 18 Jan 2011 17:44:33 +0000 (17:44 +0000)]
staging: comedi: Make INSN_BITS behavior consistent across drivers
Most comedi hardware drivers that support the INSN_BITS instruction
ignore the base channel (specified by insn->chanspec) and assume it is
0. The base channel is supposed to affect how the mask (in data[0]) and
bits (in data[1]) are treated. Bit 0 applies to the base channel, bit 1
applies to base channel plus 1, etc.
For subdevices with no more than 32 channels, this patch modifies the
chanspec and data before presenting it to the hardware driver, and
modifies the data bits read back by the hardware driver (into data[1]).
This makes it appear to the hardware driver that the base channel was
set to 0.
For subdevices with more than 32 channels, the instruction is left
unmodified, as it is assumed that the hardware driver takes note of the
base channel in this case in order to provide access beyond channel 31.
Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This patch fixes the sparse warnings in me4000.c:
me4000.c:122:1: warning: obsolete struct initializer, use C99 syntax
me4000.c:123:1: warning: obsolete struct initializer, use C99 syntax
me4000.c:124:1: warning: obsolete struct initializer, use C99 syntax
me4000.c:125:1: warning: obsolete struct initializer, use C99 syntax
by converting the struct to use C99 syntax
Signed-off-by: Peter Huewe <peterhuewe@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Tomas Winkler [Tue, 18 Jan 2011 12:03:23 +0000 (14:03 +0200)]
Staging: easycap: fix sparse warnings for module parameters
easycap_main.c:34:5: warning: symbol 'easycap_debug' was not declared. Should it be static?
easycap_main.c:36:5: warning: symbol 'easycap_gain' was not declared. Should it be static?
These two variables actually were declared in several places.
The variables are used in several files.
I've fixed "easycap_debug" so it gets declared in one place only and included properly.
For "easycap_gain" made it static and I created added a
->gain member to the easycap struct. This seems cleaner than using a
global variable and later on we may make this controlable via sysfs.
Cc:Mike Thomas <rmthomas@sciolus.org> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Acked-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Larry Finger [Fri, 14 Jan 2011 21:02:18 +0000 (15:02 -0600)]
staging: r8712u: Firmware changes for driver
* select FW_LOADER in Kconfig - From: Stefan Lippers-Hollmann <s.l-h@gmx.de>
* declare MODULE_FIRMWARE for r8712u and change to correct directory
* delete 10K line farray.h containing internal firmware
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Mike Thomas [Mon, 10 Jan 2011 18:34:41 +0000 (18:34 +0000)]
Staging: easycap: Make easycap_debug non-static
The parameter easycap_debug appears in macros JOT and JOM and therefore
needs to be visible from all source files. The easycap_ prefix should
be sufficient to avoid namespace clashes outside the module.
Signed-off-by: Mike Thomas <rmthomas@sciolus.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Brice Dubost [Fri, 7 Jan 2011 17:49:18 +0000 (18:49 +0100)]
staging: comedi : Analog input trigerring modes for cb_pcidas
This patch allows the possibility to choose between edgre triggering
and level trigerring, for the analog input, on the Measurement
Computing PCI-DAS* boards
staging: keucr: Delete use kernel strcmp() & strcpy() from TODO file
staging: keucr: Delete use kernel strcmp() & strcpy() from TODO file
Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com> Acked-by: Dan Carpenter <error27@gmail.com> Reviewed-by: Marcin Slusarz <marcin.slusarz@gmail.com> Cc: Al Cho <acho@novell.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
staging: keucr: Delete StringCmp() and StringCopy custom functions
staging: keucr: Delete StringCmp() and StringCopy custom functions
Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com> Acked-by: Dan Carpenter <error27@gmail.com> Reviewed-by: Marcin Slusarz <marcin.slusarz@gmail.com> Cc: Al Cho <acho@novell.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
staging: keucr: Use memcpy() instead custom StringCopy() and some style cleanups
staging: keucr: Use memcpy() instead custom StringCopy() and some style cleanups
Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com> Acked-by: Dan Carpenter <error27@gmail.com> Reviewed-by: Marcin Slusarz <marcin.slusarz@gmail.com> Cc: Al Cho <acho@novell.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
staging: keucr: Use memcmp() instead custom StringCmp() and some style cleanups
staging: keucr: Use memcmp() instead custom StringCmp() and some style cleanups
Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com> Acked-by: Dan Carpenter <error27@gmail.com> Reviewed-by: Marcin Slusarz <marcin.slusarz@gmail.com> Cc: Al Cho <acho@novell.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Bitwise and logical or are the equivalent here, so this doesn't affect
runtime, but logical or was intended. The original code causes a
warning in Sparse: "warning: dubious: !x | !y"
Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Arend van Spriel [Fri, 21 Jan 2011 09:54:52 +0000 (10:54 +0100)]
staging: brcm80211: use KBUILD_MODNAME as driver name in registration
The driver name was hardcoded and not same as the kernel module file
being build. Although there may be no strong requirement to this it
may provide increased consistency.
Reviewed-by: Brett Rudley <brudley@broadcom.com> Reviewed-by: Henry Ptasinski <henryp@broadcom.com> Reviewed-by: Roland Vossen <rvossen@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Arend van Spriel [Fri, 21 Jan 2011 09:54:50 +0000 (10:54 +0100)]
staging: brcm80211: removed sys directory layer from brcmsmac driver
Based on review comments moved sources from brcm80211/brcmsmac/sys
to its parent directory. The phy directory is kept for maintainance
logistics around phy source code.
Reviewed-by: Brett Rudley <brudley@broadcom.com> Reviewed-by: Henry Ptasinski <henryp@broadcom.com> Reviewed-by: Roland Vossen <rvossen@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Arend van Spriel [Fri, 21 Jan 2011 09:54:49 +0000 (10:54 +0100)]
staging: brcm80211: cleanup on the brcm80211 include directory
moved several files to specific source directory as these do not
need to be shared between drivers. Also removed some unused include
files from the include directory.
Reviewed-by: Brett Rudley <brudley@broadcom.com> Reviewed-by: Henry Ptasinski <henryp@broadcom.com> Reviewed-by: Roland Vossen <rvossen@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Not exactly sure if this is a typo or not, due to my search
results comming up with not that many hits. Either its dereferenceable
or dereferencable from the two I choose the later. if it's wrong let me know
and I'll resend.
Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Pavan Savoy [Thu, 23 Dec 2010 07:23:56 +0000 (01:23 -0600)]
drivers:staging: ti-st: add the v7 btwilink driver
Add the btwilink driver which has undergone 7 revisions
of review. Based on bluetooth maintainer comments, since
there might be some re-work needed on underlying ST driver,
park the driver here.
staging: speakup: more fixes for init-failure handling.
We still leaked many resources when Speakup failed to initialize.
Examples of leaked resources include:
/dev/synth, keyboard or VT notifiers, and heap-allocated st_spk_t
structs.
This is fixed.
* We now use PTR_ERR to detect kthread_create failure
(thank you Dan Carpenter).
* The loop which frees members of the speakup_console array now iterates
over the whole array, not stopping at the first NULL value. Fixes
a possible memory leak. Safe because kfree(NULL) is a no-op.
* The order of some initializations was changed. The safe ones, which
will never fail, are performed first.
Signed-off-by: Christopher Brannon <chris@the-brannons.com> Acked-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
The patch below removes WAKE_LOCK since it is no longer in the kernel.
Please let me know, if this is the proper way of doing this and/or more needs
to be done..
Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
The patch below removes CONFIG_HAS_WAKELOCK since it is no longer in the kernel.
Please let me know, if this is the proper way of doing this and/or more needs
to be done..
Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Note:not sure if there is already something like this submitted or not.
The first two patches removes CONFIG_HAS_WAKELOCK since it is no longer in the kernel.
Please let me know, if this is the proper way of doing this and/or more needs
to be done..
Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Arend van Spriel [Wed, 22 Dec 2010 08:30:14 +0000 (09:30 +0100)]
staging: brcm80211: remove usage of packet section macros
Removed include construction used to solve compiler differences
related to packed structure types. Now GNUC variant of packed
structure is used explicitly.
Reviewed-by: Brett Rudley <brudley@broadcom.com> Reviewed-by: Henry Ptasinski <henryp@broadcom.com> Reviewed-by: Roland Vossen <rvossen@broadcom.com> Reviewed-by: Dowan Kim <dowan@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Arend van Spriel [Wed, 22 Dec 2010 08:30:13 +0000 (09:30 +0100)]
staging: brcm80211: removed usage of proto/wpa.h file
Definitions used either had linux equivalent or were only used in
one source file. Changes were made accordingly and proto/wpa.h
has been removed from the driver sources.
Reviewed-by: Brett Rudley <brudley@broadcom.com> Reviewed-by: Henry Ptasinski <henryp@broadcom.com> Reviewed-by: Roland Vossen <rvossen@broadcom.com> Reviewed-by: Dowan Kim <dowan@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Arend van Spriel [Wed, 22 Dec 2010 08:30:09 +0000 (09:30 +0100)]
staging: brcm80211: remove usage of ETHER_MAX_LEN definition
The linux include file if_ether.h already provides a definition
ETH_FRAME_LEN although this is excluding checksum. So code uses
ETH_FRAME_LEN+ETH_FCS_LEN now.
Reviewed-by: Brett Rudley <brudley@broadcom.com> Reviewed-by: Henry Ptasinski <henryp@broadcom.com> Reviewed-by: Roland Vossen <rvossen@broadcom.com> Reviewed-by: Dowan Kim <dowan@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Ky Srinivasan [Fri, 17 Dec 2010 01:56:54 +0000 (18:56 -0700)]
Staging: hv: Add a user-space daemon to support key/value pair (KVP)
All guest specific data gathering is implemented in a user-mode daemon.
The kernel component of KVP passes the "key" to this daemon and
the daemon is responsible for passing back the corresponding
value. This daemon communicates with the kernel
component via a netlink channel.
Cc: Haiyang Zhang <haiyangz@microsoft.com> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Ky Srinivasan [Fri, 17 Dec 2010 01:54:16 +0000 (18:54 -0700)]
Staging: hv: Implement key/value pair (KVP)
This is an implementation of the key value/pair (KVP) functionality
for Linux guests hosted on HyperV. This component communicates
with the host to support the KVP functionality.
Cc: Haiyang Zhang <haiyangz@microsoft.com> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>