Commit Graph

4809 Commits

Author SHA1 Message Date
Mike McCormack 1dc4dbbf7b Staging: rtl8192e: Remove some redundant comments
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 21:21:25 -07:00
Mike McCormack 51ae5d558f Staging: rtl8192e: Remove extern and redundant declarations
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 21:21:24 -07:00
Mike McCormack 196bd68726 Staging: rtl8192e: Remove function with no effect
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 21:21:23 -07:00
Mike McCormack b6d5e884ab Staging: rtl8192e: Remove unused macros
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 21:21:22 -07:00
Mike McCormack f347140583 Staging: rtl8192e: Remove some commented out code
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 21:21:22 -07:00
Mike McCormack d5abdf72be Staging: rtl8192e: Remove function name comments at end of functions
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 21:21:21 -07:00
Mike McCormack 49e57f2fc0 Staging: rtl8192e: Remove some redundant code
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 21:21:20 -07:00
Stephen Hemminger f8942e07a3 staging: Beeceem USB Wimax driver
The Sprint 4G network uses a Wimax dongle with Beecem
chipset. The driver is typical of out of tree drivers, but
maybe useful for people, and the hardware is readily available.

Here is a staging ready version (i.e warts and all)

0. Started with Rel_5.2.7.3P1_USB from Sprint4GDeveloperPack-1.1
1. Consolidated files in staging
2. Remove Dos cr/lf
3. Remove unnecessary ioctl from usbbcm_fops

Applied patches that were in the developer pack, surprising
there were ones for 2.6.35 already.

This is compile tested only, see TODO for what still needs
to be done.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 21:15:06 -07:00
Greg Kroah-Hartman 2d2f03b022 Staging: keucr: fix up some coding style issues in the .h files
This resolves a few of the coding style issues in the .h files
for this driver.  It doesn't get all of them by far, but it's a
good start.

Cc: Al Cho <acho@novell.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 02:49:54 -07:00
Al Cho 126bb03b46 Staging: add USB ENE card reader driver
This driver is for the ENE card reader that can be found in many
different laptops.  It was written by ENE, but cleaned up to
work properly in the kernel tree by Novell.

Signed-off-by: Al Cho <acho@novell.com>
Cc: <yiyingc@ene.com.tw>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 02:49:39 -07:00
Javier Martinez Canillas 15b9e32769 staging: xgifb: Removes unnecesary log
This patch fixes a compile warning removing an unnecessary log message.
I redo the patch against today linux-next.

Thanks a lot

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 02:07:12 -07:00
Javier Martinez Canillas 328f55baae staging : xgifb: Removes compilation conditionals
This patch fixes a compilation warning in today linux-next
removing some compilation conditionals.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 02:07:12 -07:00
Vipin Mehta b6c78757f9 staging: ath6kl: Fixing a compilation error introduced by commit ec53d6123b.
Signed-off-by: Vipin Mehta <vmehta@atheros.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 02:02:26 -07:00
Andy Shevchenko c8e7978ee4 staging: ath6kl: use native methods from kernel library
There are already implemented methods such hex_to_bin() or isxdigit() in
the kernel. Let's use them.

Signed-off-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Acked-by: Vipin Mehta <Vipin.Mehta@Atheros.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 01:59:54 -07:00
Andy Shevchenko 91facdbe50 staging: rtl8712: throw away custom hex_to_bin()
Signed-off-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 01:59:53 -07:00
Greg Kroah-Hartman 51973d7fa0 Staging: xgifb: revert a warning fix and resolve it properly
Jiri pointed out that the previous compiler warning fix was incorrect as
the compiler was properly saying that the variable was not being set.
This was due to a #define commenting out all of the logic in the
function.

This patch reverts Javier's previous one, and properly fixes the issue
by making the function actually doing something.

Reported-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-08 01:49:45 -07:00
Prashant P. Shah 675d6409ae Staging: otus: removes global variable initialization to 0 in wwrap.c
This is a patch to the wwrap.c file that removes the initialization
of global variable 'smp_kevent_Lock' to 0

Signed-off-by: Prashant P. Shah <pshah.mumbai@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-07 19:39:15 -07:00
Thomas Gleixner 0f0800f17a staging: Bulk convert the semaphore mess
init_MUTEX(_LOCKED) and DECLARE_MUTEX are going away. Bulk convert
staging users.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-07 19:31:32 -07:00
Javier Martinez Canillas d6835e8417 staging: xgifb: Initialize uninitialized variables
Current patch solves compilation warnings in staging/xgifb for using
possibly uninitialized variables.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-06 23:18:18 -07:00
Prashant P. Shah b654f878ba Staging: xgifb: fixed many style issues in XGI_main_26.c
This is a patch to the XGI_main_26 file that fixes many style
issues found by the checkpatch.pl tool.
- extra spaces
- invalid code indent
- extra braces
- invalid comment style

Signed-off-by: Prashant P. Shah <pshah.mumbai@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-06 19:43:01 -07:00
Greg Kroah-Hartman 30cb3e5fb5 Staging: rt2860: Fix brace coding style issue
This fixes a single brace issue in the rt_linux.c file.

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 20:55:55 -07:00
Bernie Thompson 2685cffa9e staging: udlfb: fix checkpatch and style
Fix warnings detected by tools

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 19:46:14 -07:00
Bernie Thompson 5bea1fbf94 staging: udlfb: fix incorrect fb_defio implementation for multiple framebuffers
Fix fb_defio bug in udlfb for multiple framebuffers

Previously when using fb_defio with multiple DisplayLink attached displays
udlfb incorrectly used a shared datastructure where it needed to have
one per fb_info struct. This was completely broken and caused all kinds of
problems, including rendering to one framebuffer affecting others.

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 19:45:59 -07:00
Michael Prokop d5fa13361b Staging: cxt1e1: Kconfig: SBE_PMCC4_NCOMM can not be compiled as module, adjust help description
The Kconfig description for CONFIG_SBE_PMCC4_NCOMM says:

  If you have purchased this optional support you must say Y or M
  here to allow the driver to operate with the NCOMM product.

This is not correct as it can not be built as module,
this patch updates the description accordingly.

Signed-off-by: Michael Prokop <mika@grml.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:59:56 -07:00
Julia Lawall d6269644e1 Staging: comedi: Fix unsigned return type
In each case, the function has an unsigned return type, but returns a
negative constant to indicate an error condition.  For move_block_from_dma,
there is only one call and the return value is dropped, so it need not be
unsigned.  For labpc_eeprom_write, there is only one call and the result is
stored in a signed variable, so again the unsigned return type is not
necessary.

A sematic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@exists@
identifier f;
constant C;
@@

 unsigned f(...)
 { <+...
*  return -C;
 ...+> }
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:59:55 -07:00
Vasiliy Kulikov 7b1f6bfb03 staging: westbridge: improve error path
kmalloc() may fail, check for it.
Allocated memory is not freed.
Use IS_ERR() instead of strict checking.

Signed-off-by: Vasiliy Kulikov <segooon@gmail.com>
Cc: David Cross <david.cross@cypress.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:59:54 -07:00
Vasiliy Kulikov ec53d6123b staging: ath6kl: check return code of get_user and put_user
Function get_user may fail. Check for it.

Signed-off-by: Vasiliy Kulikov <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:59:53 -07:00
Vasiliy Kulikov 81604d43ad staging: comedi: check return code of put_user
Function put_user may fail. Check for it.

Signed-off-by: Vasiliy Kulikov <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:59:51 -07:00
Vasiliy Kulikov b04462a143 staging: tidspbridge: check return code of get_user
Function get_user may fail. Check for it.

Signed-off-by: Vasiliy Kulikov <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:59:50 -07:00
Vasiliy Kulikov 2fac6c290f staging: rtl8192u: improve error path
Functions alloc_ieee80211 and register_netdev may fail. Check for it.

Signed-off-by: Vasiliy Kulikov <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:59:50 -07:00
Vasiliy Kulikov e5a7dc54ee staging: tidspbridge: check return code of kzalloc
Function kzalloc may fail. Check for it.

Signed-off-by: Vasiliy Kulikov <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:59:49 -07:00
Bernie Thompson d5ed54322e staging: udlfb: add module options for console and fb_defio
Add module options for console and fb_defio

Convert fb_defio on/off switch to module option and add console option.

>From the command line, pass options to modprobe
modprobe udlfb defio=1 console=1

Or for permanent option, create file like /etc/modprobe.d/options with text
options udlfb defio=1 console=1

Accepted options:

fb_defio	Make use of the fb_defio (CONFIG_FB_DEFERRED_IO) kernel
		module to track changed areas of the framebuffer by page faults.
        	Standard fbdev applications that use mmap but that do not
		report damage, may be able to work with this enabled.
		Disabled by default because of overhead and other issues.

console		Allow fbcon to attach to udlfb provided framebuffers. This
		is disabled by default because fbcon will aggressively consume
		the first framebuffer it finds, which isn't usually what the
		user wants in the case of USB displays.

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:50:22 -07:00
Bernie Thompson 8ef8cc4fca staging: udlfb: support for writing backup EDID to sysfs file
Support writing default/backup edid via /sys/class/graphics/fb?/edid

Writing a backup edid blob to the 'edid' file will cause udlfb to
attempt to re-read the edid from hardware.
If we still don't have a good edid, it will use the backup edid instead.
The intent is to 1) enable user-supplied edid
2) enable udev rules to backup the last known good edid
for a device, and then provide that edid as a backup for all future starts

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:50:21 -07:00
Bernie Thompson 1572f91cff staging: udlfb: fix big endian rendering error
Fix big endian rendering bug (affects PowerPC)

Thanks to Christian Melki at Ericsson for finding and suggesting patch.

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:50:20 -07:00
Bernie Thompson 18dffdf891 staging: udlfb: enhance EDID and mode handling support
Enhance EDID and mode table handling

* Adds support for lower-end DL chips on higher-end monitors
* Adds support for using fbdev standard EDID parsing and handling
* Adds support for more dynamic reallocation of framebuffer, based on new EDID

Queries EDID from hardware with several retries then
queries DisplayLink chip for max pixel area via vendor descriptor.
Uses existing fbdev mode handling service funcations to build mode list
of common modes between adapter and monitor.
This enables lower-end chips (e.g. DL-125) to successfully pick a compatible
mode on higher end monitors (e.g. whose default mode is over 1280x1024).
Reallocate framebuffer if necessary in response to new max mode.

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:50:19 -07:00
Bernie Thompson 33077b8d30 staging: udlfb: revamp reference handling to insure successful shutdown
Revamp reference handling and synchronization for unload/shutdown

Udlfb is a "virtual" framebuffer device that really exists on
two separate stacks: at the bottom of the framebuffer interface,
and on top of USB.  During unload, there's no guarantee which
one will tear down first. So reference counting must be solid
to handle all possibilities and not access anything once its gone.

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:50:18 -07:00
Bernie Thompson f11f4bc027 staging: udlfb: remove metrics_misc sysfs attribute
Remove metrics_misc sysfs attribute

Previously returned multiple values, which goes against sysfs guidelines.
Had been used for debugging to figure out which of the multiple
fbdev interfaces an app was using, but log file messages are sufficient.

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:50:17 -07:00
Bernie Thompson 9825f70f5c staging: udlfb: add DPMS support
Add ability to power off monitor with standard blanking interface

Used by X servers and others to manage power of dislpay

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:50:16 -07:00
Bernie Thompson d46ecb9f79 staging: udlfb: fbdev character read and write support
Restore fbdev character read and write support

Enables access to the framebuffer from simple reads and writes
to /dev/fb0 (or fb1, ...). Low performance, because of extra copy
and because udlfb must scan every pixel for changes. But very
useful for testing and simple image display, etc.

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:50:15 -07:00
Bernie Thompson df9be302a2 staging: udlfb: Add intro udlfb documentation
Add documentation for the udlfb framebuffer driver for DisplayLink devices.

Signed-off-by: Bernie Thompson <bernie@plugable.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 16:50:14 -07:00
Joe Perches e0ac7da044 staging: lirc: Remove unnecessary casts of private_data
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:35:37 -07:00
Javier Martinez Canillas 430eb1baae staging: xgifb: Removes unused variable
Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:35:37 -07:00
Sven Eckelmann 07fd7364b3 Staging: batman-adv: Update mtu of bat device by changing mtu of slave device
We must reduce our own mtu when we reduce the mtu of any device we use
to transfer our packets. Otherwise we may accept to large packets which
gets dropped by the actual device.

Reported-by: Vasiliy Kulikov <segooon@gmail.com>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:50 -07:00
Sven Eckelmann 81abee4f18 Staging: batman-adv: Don't inform about dropped packets in nodebug
Information about dropped packets are usually only interesting for
debugging purposes and otherwise open the possibility to flood the logs
of the target machine with useless information.

pr_debug will not output those information on a nodebug kernel.

Reported-by: Vasiliy Kulikov <segooon@gmail.com>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:50 -07:00
Sven Eckelmann 57b7117af8 Staging: batman-adv: Remove duplicate of attached device name
batman_if has the name of the net_dev as extra string in its own
structure, but also holds a reference to the actual net_device structure
which always has the current name of the device. This makes it
unneccessary and also more complex because we must update the name in
situations when we receive a NETDEV_CHANGENAME event.

Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:50 -07:00
Marek Lindner 8c70f13832 Staging: batman-adv: multiple mesh clouds
This patch removes all remaining global variables and includes the
necessary bits into the bat_priv structure. It is the last
remaining piece to allow multiple concurrent mesh clouds on the
same device.
A few global variables have been rendered obsolete during the process
and have been removed entirely.

Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
[sven.eckelmann@gmx.de: Rework on top of current version]
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:49 -07:00
Marek Lindner 6a0e9fa88d Staging: batman-adv: attach each hard-interface to a soft-interface
This patch replaces the static bat0 interface with a dynamic/abstracted
approach. It is now possible to create multiple batX interfaces by
assigning hard interfaces to them. Each batX interface acts as an
independent mesh network. A soft interface is removed once no hard
interface references it any longer.

Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
[sven.eckelmann@gmx.de: Rework on top of current version]
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:49 -07:00
Sven Eckelmann bf3264f6d1 Staging: batman-adv: Provide full headers and packets as linear skb
We must ensure that all interesting data is linear and not paged out to
access all information in a header or a full batman-adv related packet.
Otherwise we may drop packets which have non-linear headers but which
hold valid data.

This doesn't affect non-linear skbs which have all headers in a linear
head unless we must process the whole packet like in ogms or vis
packets.

Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:48 -07:00
Sven Eckelmann aedbffc777 Staging: batman-adv: Create copy of skb with pre-allocated headroom
We can use skb_cow instead of a handwritten function to test and create
a writable skb buffer. This also allows us to pre-allocate headroom to
be able to send the data without re-allocating the buffer again to add
the ethernet header.

Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:48 -07:00
Sven Eckelmann b411d498ee Staging: batman-adv: Prepare vis packets directly inside a skb
The vis information structure is used in a way that it can be transfered
directly as packet. It still had to be copied into a skb because of an
extra buffer used for the actual preparation of the data. This is
unnecessary and can be replaced by a simple clone instead of an full
copy before each send.

This makes also the send_raw_packet function obsolete.

Reported-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:47 -07:00
Sven Eckelmann b706007b89 Staging: batman-adv: Aggregate batman packets directly in skb
All originator messages are send through aggregation buffers. Those
buffers can directly be allocated as skb to reduce the cost of
allocation an extra buffer and copying them to a new allocated skb
directly before it gets send.

Now only the skb must be cloned in case of send_packet_to_if as it gets
called by send_packet for each interface. Non-primary ogms must not
cloned at all because they will only send once and the forward_packet
structure is freed by send_outstanding_bat_packet afterwards.

Reported-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:47 -07:00
Sven Eckelmann 43bfee7693 Staging: batman-adv: Only clone skb data for multiple broadcasts
batman-adv tries to resend broadcasts on all interfaces up to three
times. For each round and each interface it must provide a skb which
gets consumed by the sending function.

It is unnecessary to copy the data of each broadcast because the actual
data is either not shared or already copied by add_bcast_packet_to_list.
So it is enough to just copy the skb control data

Reported-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:46 -07:00
Sven Eckelmann 99eed2842c Staging: batman-adv: Keep header writable and unshared
my_skb_push provided an easy way to allocate enough headroom in
situation were we don't have enough space left and move the data pointer
to the new position, but we didn't checked wether we are allowed to
write to the new pushed header. This is for example a problem when the
skb was cloned and thus doesn't have a private data part.

my_skb_head_push now replaces my_skb_push by using skb_cow_head to
provide only a large enough, writable header without testing for the
rest of the (maybe shared) data. It will also move the data pointer
using skb_push when skb_cow_head doesn't fail.

This should give us enough flexibility in situation were skbs will be
queued by underlying layers and still doesn't unnecessarily copy the
data in situations when the skb was consumed right away during
dev_queue_xmit.

Reported-by: Marek Lindner <lindner_marek@yahoo.de>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:46 -07:00
Marek Lindner 15cf5523d2 Staging: batman-adv: register the batman-adv packet type per interface
Batman-adv globally registered the batman-adv packet type and installed
a hook to batman_skb_recv(). Each interface receiving a packet with that
type would end up in this function which then had to loop through all
batman-adv internal interface structures to find the its meta data. The
more interfaces a system had the longer the loops might take. Each and
every packet goes through this function making it a performance critical
loop.

This patch installs the hook for each activated interface. The called
batman_skb_recv() can distinguish these calls, therefore avoiding the
loop through the interface structures.

Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
[sven.eckelmann@gmx.de: Rework on top of current version]
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:45 -07:00
Sven Eckelmann d52e90aeaf Staging: batman-adv: Directly prepare icmp packets in socket buffer
It is unnecessary to generate an icmp packet in an extra memory region
and than copying it to a new allocated skb.

This also resolved the problem that we do inform the user that we
couldn't send the packet because we couldn't allocate the socket buffer.

Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:45 -07:00
Andreas Langer e63760e595 Staging: batman-adv: layer2 unicast packet fragmentation
This patch implements a simple layer2 fragmentation to allow traffic
exchange over network interfaces with a MTU smaller than 1500 bytes. The
fragmentation splits the big packets into two parts and marks the frames
accordingly. The receiving end buffers the packets to reassemble the
orignal packet before passing it to the higher layers. This feature
makes it necessary to modify the batman-adv encapsulation for unicast
packets by adding a sequence number, flags and the originator address.
This modifcation is part of a seperate packet type for fragemented
packets to keep the original overhead as low as possible. This patch
enables the feature by default to ensure the data traffic can travel
through the network. But it also prints a warning to notify the user
about the performance implications.

Note: Fragmentation should be avoided at all costs since it has a
dramatic impact on the performance, especially when it comes wifi
networks. Instead of a single packet, 2 packets have to be sent! Not
only valuable airtime is wasted but also packetloss decreases the
throughput. A link with 50% packetloss and fragmentation enabled is
pretty much unusable.

Signed-off-by: Andreas Langer <an.langer@gmx.de>
[sven.eckelmann@gmx.de: Rework on top of current version]
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:45 -07:00
Marek Lindner 24c76fc07b Staging: batman-adv: refactoring unicast payload code
Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
[sven.eckelmann@gmx.de: Rework on top of current version]
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:44 -07:00
Simon Wunderlich 7d02674f71 Staging: batman-adv: move queue counters into bat_priv
to support multiple mesh devices later, we need to move global variables
like the queues into corresponding private structs bat_priv of the soft
devices.

Note that this patch still has a lot of FIXMEs and depends on the global
soft_device variable. This should be resolved later, e.g. by referencing
the parent soft device in batman_if.

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
[sven.eckelmann@gmx.de: Rework on top of current version]
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:44 -07:00
Sven Eckelmann 8bb22a38d6 Staging: batman-adv: Calculate hamming weight using optimized kernel functions
The Kernighan algorithm is not able to calculate the number of set bits
in parallel and the compiler cannot replace it with optimized
instructions.

The kernel provides specialised functions for each cpu which can either
use a software implementation or hardware instruction depending on the
target cpu.

Reported-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:43 -07:00
Simon Wunderlich 556c83ece8 Staging: batman-adv: Count Ethernet header for incoming packets
The Ethernet header is counted when transmitting a packet, so it should also
be counted when receiving a packet. With this patch, the rx_bytes and tx_bytes
statistics behave like an ordinary Ethernet interface.

Signed-off-by: Simon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:43 -07:00
Sven Eckelmann b19ad29f55 Staging: batman-adv: Start new development cycle
Version 2010.1.0 of the extra kernel module was released and thus the
documentation should be updated and everything prepared for the the
upcoming patchset.

Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:42 -07:00
Sven Eckelmann cbbdd77152 Staging: batman-adv: Remove CHANGELOG
The changelog is only generated on standalone releases. Thus it has no
real value for the in-kernel version of batman-adv.

Reported-by: Abraham Arce <abraham.arce.moreno@gmail.com>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:42 -07:00
Sven Eckelmann de6d56723b Revert: "Staging: batman-adv: Adding netfilter-bridge hooks"
This reverts commit 96d592ed59.

The netfilter hook seems to be misused and may leak skbs in situations
when NF_HOOK returns NF_STOLEN. It may not filter everything as
expected. Also the ethernet bridge tables are not yet capable to
understand batman-adv packet correctly.

It was only added for testing purposes and can be removed again.

Reported-by: Vasiliy Kulikov <segooon@gmail.com>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-05 00:29:41 -07:00
Prashant P. Shah 602f2c9620 Staging: xgifb: fixed many style issues in vb_util.c
This is a patch to the vb_util.c file that fixes many style
issues found by the checkpatch.pl tool.
- extra spaces
- invalid code indent
- extra braces
- invalid comment style

Signed-off-by: Prashant P. Shah <pshah.mumbai@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:44:02 -07:00
Prashant P. Shah a24d60f45b Staging: xgifb: fixed many style issues in vb_init.c
This is a patch to the vb_init.c file that fixes many style
issues found by the checkpatch.pl tool.
- extra spaces
- invalid code indent
- extra braces
- invalid comment style

Signed-off-by: Prashant P. Shah <pshah.mumbai@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:43:01 -07:00
Prashant P. Shah 21df8fc82c Staging: xgifb: fixed many style issue in vb_setmode.c
This is a patch to the vb_setmode.c file that fixes many style
issues found by the checkpatch.pl tool.
- extra spaces
- invalid code indent
- extra braces
- invalid comment style

Signed-off-by: Prashant P. Shah <pshah.mumbai@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:37:47 -07:00
Prashant P. Shah 914a402dc5 Staging: xgifb: fixed many style issue in vb_ext.c
This is a patch to the vb_ext.c file that fixes many style
issues found by the checkpatch.pl tool.
- extra spaces
- invalid code indent
- extra braces
- invalid comment style

Signed-off-by: Prashant P. Shah <pshah.mumbai@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:36:31 -07:00
Andre Nogueira 3dc3494ba2 Staging: rtl8186se: Remove a duplicate include directive in ieee80211.h
This patch removes a duplicate include directive in
drivers/staging/rtl8187se/ieee80211/ieee80211.h.

Signed-off-by: Andre Nogueira <andre.neo.net@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:28:18 -07:00
Andrea Gelmini 10b476a2fc staging: spectra: Kconfig: add missing '.'
All help messages end with full stop.

Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:28:18 -07:00
Jiri Slaby 2a4724a76d Staging: ath6kl, remove unneeded ptr checking
In wmi_bssInfo_event_rx, there is unneeded check for bss, because it
is in the branch where the bss is checked to be non-null already.

Remove the superfluous check.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Cc: Vipin Mehta <vmehta@atheros.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:26:06 -07:00
Jiri Slaby ff7d368ed9 Staging: lirc, fix lock imbalance
[2nd version -- melded all three together]

1) There is a missing return or goto statement in one fail path in
sasem_probe, so that the code contiues its normal execution (and
unlocks a mutex twice). Fix that by jumping to the right place.

Anyway the code is very broken on its fail paths and there are many
leaks. But that's a different story.

2) There is an omitted unlock in one fail path in vfd_write, jump to
the right place to unlock the lock.

3) In the probe function, there is one more error where the lock is
not unlocked. Fix that by jumping to the proper place.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Cc: Jarod Wilson <jarod@redhat.com>
Cc: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:26:06 -07:00
Jiri Slaby cc92ac2049 Staging: lirc, fix NULL dereference
When 'context' allocation fails in imon_probe, we jump to unlock
context->ctx_lock. This is wrong as context is NULL and the lock is
not locked.

Fix the labels.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Cc: Jarod Wilson <jarod@redhat.com>
Cc: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:26:05 -07:00
Uwe Kleine-König 54669fdeb2 staging/trivial: fix typos concerning "through"
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:23:27 -07:00
Uwe Kleine-König 0e324fbdb7 staging/trivial: fix typos concerning "management"
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:23:26 -07:00
Uwe Kleine-König 9b0131cb24 staging/trivial: fix typos concerning "initiali[zs]e"
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:23:26 -07:00
Uwe Kleine-König 25a606c36a staging/trivial: fix typos concerning "address"
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:23:25 -07:00
Uwe Kleine-König 6cd5a9a35c staging/trivial: fix typos concerning "access"
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:23:25 -07:00
Uwe Kleine-König ded1e38d7f staging/comedi: fix syntax error
I don't know how gcc interprets this, but it wouldn't surprise me if it
choose something different than start-of-comment

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:23:24 -07:00
Jonathan Cameron 853098b6e5 staging: iio: documentation - partial update to make more of it true.
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:19:02 -07:00
Jonathan Cameron 04b708124a staging: iio: lis3l02dqbuffersimple.c bring example up to date.
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:19:02 -07:00
Jonathan Cameron 299475e0d9 staging: iio: remove odd structure definition.
I've no idea where this came from!
Also fixed form -> from in comment

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:19:01 -07:00
Jonathan Cameron 9dbfb6f14a staging: iio: Make use of the convenient IIO_TRIGGER_NAME_ATTR macro
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:19:01 -07:00
Jonathan Cameron 2d7770a942 staging: iio: Remove deprecated ATTR_TEMP in favour of ATTR_TEMP_RAW
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:19:00 -07:00
Jonathan Cameron 99e5dc45b8 staging: iio: Remove long dead function definitions from headers
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:19:00 -07:00
Jonathan Cameron c3e5d410bb staging: iio: unecessary header removal and kernel doc clean up
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:19:00 -07:00
Jonathan Cameron b6e5d69a9e staging: iio: simplify logic in iio_interrupt_handler
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:18:59 -07:00
Jonathan Cameron b156cf70e1 staging: iio: convert idr to ida as pointer never provided
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-04 21:18:59 -07:00
Vipin Mehta 30295c8936 staging: add ath6kl driver for AR6003 chip
AR6003 is a single stream, SDIO based 802.11 chipset from
Atheros optimized for mobile and embedded devices. ath6kl is a
cfg80211 driver for AR6003 and supports both the station and
AP mode of operation.

Station mode supports 802.11 a/b/g/n with HT20 on 2.4/5GHz and
HT40 only on 5GHz. Some of the other features include WPA/WPA2,
WPS, WMM, WMM-PS, and BT coexistence. AP mode can be operated
only in b/g mode with support for a subset of features mentioned
above.

The driver supports cfg80211 but comes with its own set of
wext ioctls which have historically supported some of our
customers with features like BT 3.0 and AP mode of operation.

For further details, please refer to:

http://wireless.kernel.org/en/users/Drivers/ath6kl

The driver requires firmware that runs on the chip's network
processor. The majority of it is stored in ROM. The binaries
that are downloaded and executed from RAM are as follows:

1) Patch against the code in ROM for bug fixes and feature
   enhancements.
2) Code to copy the data from the OTP region of the memory
   into RAM.
3) Calibration file carrying board specific data.

The above files need to be present in the directory
'/lib/firmware/ath6k/AR6003/hw2.0/' for the driver to initialize
the chip upon enumeration. The files can be downloaded from the
link specified at the following location:

http://wireless.kernel.org/en/users/Drivers/ath6kl#Download

This driver is only provided in the interim while we work on
the mac80211 replacement, ath6k. Once the mac80211 driver
achieves feature parity with the ath6kl driver, the ath6kl will
be deprecated and removed from staging.

Signed-off-by: Vipin Mehta <vmehta@atheros.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-09-02 11:43:26 -07:00
Nitin Gupta 9b9913d80b Staging: zram: Update zram documentation
Update zram documentation to reflect transition form
ioctl to sysfs interface.

Signed-off-by: Nitin Gupta <ngupta@vflare.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:36:36 -07:00
Nitin Gupta 484875adbc Staging: zram: Remove need for explicit device initialization
Currently, the user has to explicitly write a positive value to
initstate sysfs node before the device can be used. This event
triggers allocation of per-device metadata like memory pool,
table array and so on.

We do not pre-initialize all zram devices since the 'table' array,
mapping disk blocks to compressed chunks, takes considerable amount
of memory (8 bytes per page). So, pre-initializing all devices will
be quite wasteful if only few or none of the devices are actually
used.

This explicit device initialization from user is an odd requirement and
can be easily avoided. We now initialize the device when first write is
done to the device.

Signed-off-by: Nitin Gupta <ngupta@vflare.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:36:36 -07:00
Nitin Gupta 33863c21e6 Staging: zram: Replace ioctls with sysfs interface
Creates per-device sysfs nodes in /sys/block/zram<id>/
Currently following stats are exported:
 - disksize
 - num_reads
 - num_writes
 - invalid_io
 - zero_pages
 - orig_data_size
 - compr_data_size
 - mem_used_total

By default, disksize is set to 0. So, to start using
a zram device, fist write a disksize value and then
initialize device by writing any positive value to
initstate. For example:

        # initialize /dev/zram0 with 50MB disksize
        echo 50*1024*1024 | bc > /sys/block/zram0/disksize
        echo 1 > /sys/block/zram0/initstate

When done using a disk, issue reset to free its memory
by writing any positive value to reset node:

        echo 1 > /sys/block/zram0/reset

This change also obviates the need for 'rzscontrol' utility.

Signed-off-by: Nitin Gupta <ngupta@vflare.org>
Acked-by: Pekka Enberg <penberg@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:33:54 -07:00
Markus Grabner e1a164d7a3 Staging: line6: another upstream sync
Everything should be in sync now.

Signed-off-by: Markus Grabner <grabner@icg.tugraz.at>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:28:16 -07:00
Markus Grabner 1027f476f5 staging: line6: sync with upstream
Big upstream sync.

Signed-off-by: Markus Grabner <grabner@icg.tugraz.at>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:28:15 -07:00
Julia Lawall 4498dbcd2d staging: rtl8193*: Remove double test
The 1 element of the array is tested twice.  Change the code so that the
remaining 3 element of the array is tested instead of testing the 1 element
a second time.

The sematic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@expression@
expression E;
@@

(
* E
  || ... || E
|
* E
  && ... && E
)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:22:37 -07:00
Prashant P. Shah 15300c1df7 Staging: solo6x10: fixed assignments in if conditions in solo6010-core.c
This is a patch to the solo6010-core.c file that fixes the assignments
in if condition style issues found by the checkpatch.pl tool.

Signed-off-by: Prashant P. Shah <pshah.mumbai@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:22:37 -07:00
Larry Finger ebf993ba2b staging: r8712u: Update copy-to list for patches
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:20:06 -07:00
Alek Du 9453ed9cc7 Staging: mrst-touchscreen: Fix wrong Makefile config
The config name is wrong in drivers/staging/Makefile...
The object name is wrong in drivers/staging/mrst-touchscreen/Makefile...

Signed-off-by: Alek Du <alek.du@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:14:15 -07:00
Arjan van de Ven e1eeeae2bf Staging: mrst-touchscreen: fix channel allocation in the touch screen driver
the touch screen driver tries to find a range of free channels (which
are an array of bytes), by scanning for the "end of used channel" marker.
however it tries to be WAAAAY too smart and does 32 bit logic on 8 bit
quantities, and in the process completely gets it wrong
(repeatedly read the same register instead of incrementing in the loop,
assuming that if any of the 4 bytes in the 32 byte quantity is free,
all four are free, returning the channel number divided by 4 rather than
the actual first free channel number)

On the setting side, the same mistakes are made by and large; changed
this to just use the byte SCU write functions....

with these fixes we go from a completely non detected touchscreen to
something that appears to completely get detected.
(after also fixing the ordering issue that Jacobs patch should solve)

Signed-off-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:14:03 -07:00
Pavan Savoy dbd3a87095 Staging: ti-st: remove st_get_plat_device
In order to support multiple ST platform devices, a new symbol
'st_get_plat_device' earlier needed to be exported by the arch/XX/brd-XX.c
file which intends to add the ST platform device.

On removing this dependency, now inside ST driver maintain the array of
ST platform devices that would be registered.
As of now let id=0, as and when we end up having such platforms
where mutliple ST devices can exist, id would come from
protocol drivers (BT, FM and GPS) as to on which platform device
they want to register to.

Signed-off-by: Pavan Savoy <pavan_savoy@ti.com>
Acked-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:11:20 -07:00
Sunny Aujla 8cbf7a9e39 Staging: comedi: fix brace coding style issue in dt2817.c
This is a patch to the dt2817.c file that fixes up all coding style
issues found by the checkpatch.pl tool

Signed-off-by: Sunny Aujla <sunnyfedora99@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:05:13 -07:00
Neil Munro b0ea846105 Staging: RT2860: Fixed all warnings and errors in the iface directory
I have cleaned both files inside the iface directory (fileo rtmp_pci.h
and rtmp_usb.h). I am not sure about some of the changes I have made
however my adjustments have solved all errors.  There were also a few
issues on my machine with ap.h on my machine, however I have since
cleaned that too.

Signed-off-by: Neil Munro <neilmunro@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:05:13 -07:00
Stefan Weil 39831861ff Staging: rtl81*: Fix spelling fuction -> function in comments
Obviously the wrong spelling was copied a lot of times.

A similar patch for the non-staging part of linux
is committed by Jiri Kosina.

Cc: devel@driverdev.osuosl.org
Signed-off-by: Stefan Weil <weil@mail.berlios.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:05:13 -07:00
Ramkumar Ramachandra 60ef9eb61c Staging: rtl8192e: Cleanup style and whitespace
Replace C99-style comments with C89-style comments, fix some typos,
and fix whitespace to use only tabs.

Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:05:12 -07:00
Julia Lawall 4d9db977f9 staging: Use available error codes
An error code is stored in a variable, but 0 is returned instead.  Use the
variable instead of 0.

The semantic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@r@
local idexpression x;
constant C;
@@

if (...) { ...
  x = -C
  ... when != x
(
  return <+...x...+>;
|
  return NULL;
|
  return;
|
* return ...;
)
}
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:05:12 -07:00
Gorskin Ilya bb59a4c539 Staging: cx25821: clenup warnings found by checkpatch.pl tool in cx25821-audio-upstream.c and cx25821-audio.h.
This is a patch to the cx25821-audio-upstream.c and cx25821-audio.h
that fixes up a warnings found by checkpatch.pl tool.

Signed-off-by: Ilya Gorskin <Revent82@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 15:05:12 -07:00
Mike McCormack c6eae67748 Staging: rtl8192e: Remove redundant brackets around return values
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:55:09 -07:00
Mike McCormack 1e0f9ac07c Staging: rtl8192e: Remove pointless return statements
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:55:08 -07:00
Mike McCormack 0186f21229 Staging: rtl8192e: Remove unnecessary externs
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:55:08 -07:00
Mike McCormack 26ef8190cd Staging: rtl8192e: Remove unused function
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:55:08 -07:00
Mike McCormack f500e256dd Staging: rtl8192e: Don't compare bHwRadioOff with true
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:55:08 -07:00
Mike McCormack 5b3b1a7bf1 Staging: rtl8192e: Make functions static
Make functions static and move their declarations to
 the top of the file.

Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:55:07 -07:00
Mike McCormack 207b58fb12 Staging: rtl8192e: Remove backslashes at end of lines
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:55:07 -07:00
Mike McCormack 285f660cbd Staging: rtl8192e: Simplify some return codes
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:55:07 -07:00
Mike McCormack 4e1cfec95e Staging: rtl8192e: Delete unused function dm_shadow_init()
Signed-off-by: Mike McCormack <mikem@ring3k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:51:53 -07:00
Randy Dunlap 8922967ea3 Staging: xgifb: fix lots of sparse warnings
Fix many sparse warnings about data or functions being static.
Fix many sparse warnings about data or functions not being used
  (put them inside #if 0/#endif blocks).
Fix sparse warnings about 0 being used for NULL.
Fixed a small bit of source formatting when those lines were being
  modified anyway, but there is still lots of this yet to be done.

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Cc: devel@driverdev.osuosl.org
Cc: Arnaud Patard <apatard@mandriva.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:51:53 -07:00
Dan Carpenter 6a4ca03992 Staging: solo6x10: return -EFAULT on copy_to_user errors
copy_to_user() returns the number of bytes remaining to be copied, but
we want to return a negative error code here.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:51:53 -07:00
Kulikov Vasiliy c7e62defd3 staging: adis16255: fix sysfs leak
Original code does not call sysfs_remove_group() on error. This can lead
to NULL dereference.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:51:53 -07:00
Kulikov Vasiliy cd6541c03d staging: tm6000: fix memory leak
Original code doesn't call kfree(chip) on error.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:51:52 -07:00
Kulikov Vasiliy c2c6a66a51 staging: usbip: fix memory leak
If stub_probe() failed then do not increase interf_count. In original
code sdev was leaked as its interf_count never reaches 0.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:51:52 -07:00
Jarod Wilson 211673991e Staging: lirc: fix compiler warning
On Fri, Aug 13, 2010 at 03:38:40PM +0200, Dan Carpenter wrote:
> Speak of left over stuff, it's weird that I didn't notice this before
> but gcc complains about an unitialized variable in
> imon_incoming_packet().
>
> drivers/staging/lirc/lirc_imon.c: In function ‘imon_incoming_packet’:
> drivers/staging/lirc/lirc_imon.c:661: warning: ‘chunk_num’ may be used
> 	uninitialized in this function
>
> I don't know how to fix that, but it looks important.

Ew. Yeah, that doesn't look so hot like it is right now. The old lirc_imon
driver had chunk_num = buf[7], and made much more extensive use of
chunk_num. Simply removing chunk_num and using buf[7] should be fine.

Signed-off-by: Jarod Wilson <jarod@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:49:22 -07:00
Kulikov Vasiliy c37c6d2196 staging: cx25821: call disable_pci_device() if pci_probe() failed
Driver should call disable_pci_device() if it returns from pci_probe()
with error. Also it must not be called if pci_request_region() fails as
it means that somebody uses device resources and rules the device.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:48:10 -07:00
Kulikov Vasiliy 918e3592b9 staging: sm7xx: call disable_pci_device() if pci_probe() failed
Driver should call disable_pci_device() if it returns from pci_probe()
with error.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:48:09 -07:00
Kulikov Vasiliy 3a8f2d3c71 staging: rtl8187e: call disable_pci_device() if pci_probe() failed
Driver should call disable_pci_device() if it returns from pci_probe()
with error.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:48:09 -07:00
Dan Carpenter f090386309 Staging: quickstart: acpi_status is unsigned
acpi_bus_register_driver() returns an int, not acpi_status.  It returns
zero on success and negative error codes on failure, but acpi_status is
unsigned.  We can just use "ret" here.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:48:09 -07:00
Dan Carpenter 0b6e7220ed Staging: ti-st: writing past end of array
In the original source it would write past the end of the array before
returning the error code.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:48:09 -07:00
Dan Carpenter 2a8a4b7530 Staging: rtl8192e: add curly braces to if statement
In the original code there was some extra semicolons after the if
statement:
	if (!channel_map[ieee->current_network.channel]);
						       ^^^
>From the indenting it looked like that should be curly braces instead.

Also I made some white space changes to stop checkpatch.pl from
complaining.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:48:08 -07:00
Dan Carpenter f22f99e101 Staging: lirc: remove unneeded variable
We never use control_req so I removed it.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Jarod Wilson <jarod@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:48:08 -07:00
Kulikov Vasiliy 4fd09f900a staging: spectra: call disable_pci_device() if pci_probe() failed
Driver should call disable_pci_device() if it returns from pci_probe()
with error.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:48:08 -07:00
Kulikov Vasiliy beef969724 staging: rtl8187se: call disable_pci_device() if pci_probe() failed
Driver should call disable_pci_device() if it returns from pci_probe()
with error.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:48:07 -07:00
Kulikov Vasiliy 036b00e091 staging: crystalhd: call disable_pci_device() if pci_probe() failed
Driver should call disable_pci_device() if it returns from pci_probe()
with error.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Acked-by: Jarod Wilson <jarod@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:48:07 -07:00
Javier Martinez Canillas b6cdc4056f staging: xgifb: use DEFINE_PCI_DEVICE_TABLE() macro
Use DEFINE_PCI_DEVICE_TABLE() to make xgifb_pci_table const and marked as __devinitconst

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:30 -07:00
Javier Martinez Canillas 16f08494f4 staging: comedi (cb_pcidas): use PCI_DEVICE() macro
This is the first of a patch series that uses PCI_DEVICE() macro for pci table entries on comedi drivers and thus improving readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:30 -07:00
Javier Martinez Canillas 07c2412a5e staging: comedi (cb_pcidda): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:30 -07:00
Javier Martinez Canillas 0924f2f06b staging: comedi (cb_pcidio): user PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:29 -07:00
Javier Martinez Canillas e43d94e52a staging: comedi (rtd520): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:29 -07:00
Javier Martinez Canillas 51a6c8d058 staging: comedi (me4000): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:29 -07:00
Javier Martinez Canillas 37907697db staging: comedi (cb_pcimdas): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:29 -07:00
Javier Martinez Canillas 81b621dafc staging: comedi (adv_pci_dio): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:29 -07:00
Javier Martinez Canillas e27b81d5bb staging: comedi (adl_pci6208): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:28 -07:00
Javier Martinez Canillas 20b6a7f3d5 staging: comedi (adl_pci9118): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:28 -07:00
Javier Martinez Canillas 7af6fb13ca staging: comedi (skel): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:28 -07:00
Javier Martinez Canillas d991058efb staging: comedi (adv_pci1710): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:28 -07:00
Javier Martinez Canillas 494a3dd3b9 staging: comedi (adv_pci1723): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:27 -07:00
Javier Martinez Canillas 7feb75ac05 staging: comedi (cb_pcidas64): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:27 -07:00
Javier Martinez Canillas a9ef0a8fab staging: comedi (dt3000): use PCI_DEVICE() macro
Use PCI_DEVICE() macro for pci table entries on comedi driver and thus improves readability.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 14:32:27 -07:00
Neil Munro 4819a3667e Staging: RT2860: Fixed the spacing error in oid.h
Fixed the single spacing error in oid.h.

Signed-off-by: Neil Munro <neilmunro@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:54:30 -07:00
Neil Munro a2b4e5f447 Staging: RT2860: Fixed both coding style errors in eeprom.h
Fixed two coding style errors in the form of pointer style issues in eeprom.h.

Signed-off-by: Neil Munro <neilmunro@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:53:20 -07:00
Roberto Rodriguez Alkala bed49c6945 staging: otus: fix compile warning and some style issues
In today linux-next I got a compile warning in staging/otus driver.
This patch solves the issue and also improves the coding style.

Signed-off-by: Roberto Rodriguez Alcala <rralcala@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:52:30 -07:00
Denis Kirjanov 1033f1f7ef Staging: slicoss: Remove explicit arch dependencies
Remove explicit arch dependencies

Signed-off-by: Denis Kirjanov <dkirjanov@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:52:28 -07:00
Manuel Stahl 11f05c7715 staging: iio: hmc5843 change ABI to comply with documentation
this one completes my last patch set to compile fine for all drivers.

Signed-off-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Datta, Shubhrajyoti <shubhrajyoti@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:42:48 -07:00
Manuel Stahl 4f64b80144 staging: iio sync scale units
g     -> ms/s^2
deg   -> rad
deg/s -> rad/s
some temperatures still broken

Signed-off-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:42:03 -07:00
Manuel Stahl 51a0a5b021 staging: iio sync drivers with current ABI
Signed-off-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:42:02 -07:00
Manuel Stahl 5770b8ffaf staging: iio partial documentation update
Signed-off-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:42:02 -07:00
Manuel Stahl bf32963cbe staging: iio move scan_elements into ring buffer
tested with sca3000, adis16400

Signed-off-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:42:02 -07:00
Manuel Stahl 07e6229e42 staging: iio: lis3l02dq adjust lis3l02dq_configure_ring
Now fits other driver's structure for easier modification.

Signed-off-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:42:01 -07:00
Manuel Stahl ffcab07a74 staging: iio rename ring attributes
bps -> bytes_per_datum
ring_enable -> enable

Signed-off-by: Manuel Stahl <manuel.stahl@iis.fraunhofer.de>
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:42:01 -07:00
Dan Carpenter 213fd22704 Staging: iio: signedness bug
i2c_smbus_read_byte_data() returns an s32 type.  We need to change
"rate" to signed for the error handling to work.

Also I changed it to propogate the error code instead of just returning
-EINVAL.  Other error codes could be -EAGAIN for example.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:40:35 -07:00
Julia Lawall d1ae4da731 drivers/staging/iio: call mutex_unlock in error handling code
Adjust the error handling code so that it benefits from the call to
mutex_unlock at the end of the function.

The semantic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@rcu exists@
position p1;
expression E;
@@

mutex_lock@p1(E);
...
mutex_unlock(E);

@exists@
position rcu.p1;
expression E;
@@

*mutex_lock@p1(E);
... when != mutex_unlock(E);
?*return ...;
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Acked-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:40:35 -07:00
Dan Carpenter e3a92cdedf Staging: vt6656: problems in error handling
The first kfree(pDevice) is pointless because pDevice is NULL.  The
second kfree(pDevice) is a double free because pDevice is the driver's
private data and that is already freed by free_netdev(netdev).  Also the
free_netdev() error path doesn't call usb_put_dev().

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:35:06 -07:00
Luis Bosch fe149785a4 staging: vt6656: resolved checkpatch finding
Added spaces in for loop arguments.

Signed-off-by: Luis Bosch <luis.bosch@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:35:06 -07:00
Victor Rosales 62e7e96148 staging: vt6656: removed extra spaces
Removed spaces between functions name and parenthesis.

Signed-off-by: Victor Rosales <victorhrosales@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:35:05 -07:00
Alejandro Emanuel Paredes 4846cbc13a staging: vt6656: changed comments convention and removed spaces before tab
resolved checkpatch finding

Signed-off-by: Alejandro Emanuel Paredes <aleparedes@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:34:53 -07:00
Andres More 731047f904 staging: vt6656: removed macro to test bits
Removed custom macro used to test bits.

Signed-off-by: Andres More <more.andres@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:31:26 -07:00
Andres More 27264fb8c7 staging: vt6656: removed NDIS_STATUS int redefinition
Removed int redefinition for function results.

Signed-off-by: Andres More <more.andres@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:31:26 -07:00
Andres More 203e4615ee staging: vt6656: removed custom definitions of Ethernet packet types
Removed some unused definitions of Ethernet packet types, also replaced
two of them with in-kernel counterparts from include/linux/if_ether.h

Signed-off-by: Andres More <more.andres@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:31:25 -07:00
Ivan Gomez Castellanos bd5dc30e3e staging: tidspbridge: Remove services.c and services.h
The services_init() and services_exit() functions don't do anything,
so they are removed, and as these are the only two functions defined
in services.c and services.h, then these files are also removed.

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:17 -07:00
Ivan Gomez Castellanos 220344f254 staging: tidspbridge: Remove cfg.c and cfg.h files
So far, the cfg.c file is empty, and the function prototypes in cfg.h
are not used in any place. So they can be removed.

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:16 -07:00
Ivan Gomez Castellanos b87561f748 staging: tidspbridge: Remove cfg_set_object()
As the services directory is going to be removed, the cfg_set_object
function has also to be removed.

Since the driver object handle is retrieved from the drv_data structure,
then the word "Registry" is replaced by "driver data" in the comments.

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:16 -07:00
Ivan Gomez Castellanos a47d4deebf staging: tidspbridge: Remove cfg_set_dev_object()
As the services directory is going to be removed, the cfg_set_dev_object
function has also to be removed.

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:16 -07:00
Ivan Gomez Castellanos 73b87a9166 staging: tidspbridge: Remove cfg_get_object()
As the services directory is going to be removed, the cfg_get_object
function has also to be removed.

Since the driver object handle is retrieved from the drv_data structure,
then the word "Registry" is replaced by "driver data" in the comments.

Also, the hdrv_obj is not used in function omap34_xx_bridge_remove(), so
it is removed.

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:15 -07:00
Ivan Gomez Castellanos 315a1a20aa staging: tidspbridge: Remove cfg_get_exec_file()
As the services directory is going to be removed, the cfg_get_exec_file
function has also to be removed.

This patch also avoids a possible NULL pointer dereference in function
cfg_get_exec_file(), when drv_datap is checked for NULL and then pass
drv_datap->base_img as argument to strlen().

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:15 -07:00
Ivan Gomez Castellanos e8184e6c2d staging: tidspbridge: Remove cfg_get_dev_object() and do a trivial cleanup
The cfg_get_dev_object function is only used in one place and because of
its simplicity, it can be removed.

The parameter *value can be left uninitialized if the strcmp() returns a
nonzero value, so in the function dev_remove_device(), the hdev_obj could
be used uninitialized and could be dereferenced in dev_destroy_device().
This patch fixes this issue, and also removes the dev_obj pointer which
is not used.

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:15 -07:00
Ivan Gomez Castellanos 345c8bec42 staging: tidspbridge: Remove cfg_init() and cfg_exit()
The functions cfg_init() and cfg_exit() do nothing, so they are removed.

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:15 -07:00
Ivan Gomez Castellanos 4a6595625c staging: tidspbridge: Remove cfg_get_auto_start()
As the services directory is going to be removed, this patch is needed.

The function cfg_get_auto_start() only assigns a value to the flag
tmp, and it is only called by the function api_init_complete2(). So
the function cfg_get_auto_start() is not required.

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:14 -07:00
Ivan Gomez Castellanos 27e7f23f64 staging: tidspbridge: Remove ntfy.c
As the services directory is going to be removed, this patch is needed.

ntfy.c only contained the function dsp_notifier_event(), and since this
function calls sync_set_event(), then the dsp_notifier_event() is moved
to the sync.c file.

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:14 -07:00
Ivan Gomez Castellanos 3aa1e0e6c7 staging: tidspbridge: Move sync.c from services to core
As the services directory is going to be removed, the file sync.c is moved
from services to core.

Signed-off-by: Ivan Gomez Castellanos <ivan.gomez@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:23:14 -07:00
Andrea Gelmini 42cd0f56b7 drivers: staging: tidspbridge: gen: gb.c: Removed duplicated #include
Signed-off-by: Andrea Gelmini <andrea.gelmini@gelma.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:22:18 -07:00
Andres More 465711b39d staging: vt6656: removed not useful comments
Removed comments about who changed/added lines, they do not seem useful.

Signed-off-by: Andres More <more.andres@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:14:39 -07:00
Kulikov Vasiliy 13b631a599 staging: vt6655: do not use PCI resources before pci_enable_device()
IRQ and resource[] may not have correct values until
after PCI hotplug setup occurs at pci_enable_device() time.

The semantic match that finds this problem is as follows:

// <smpl>
@@
identifier x;
identifier request ~= "pci_request.*|pci_resource.*";
@@

(
* x->irq
|
* x->resource
|
* request(x, ...)
)
 ...
*pci_enable_device(x)
// </smpl>

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:13:57 -07:00
Andres More bd2bc4c763 staging: vt6656: added spaces around '||'
Cleared checkpatch ERROR: spaces required around that '||'

Signed-off-by: Andres More <more.andres@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:13:56 -07:00
Julia Lawall a3d7fc5ce9 staging: Drop unnecessary null test
list_for_each_entry binds its first argument to a non-null value, and thus
any null test on the value of that argument is superfluous.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
iterator I;
expression x;
statement S;
@@

I(x,...) { <...
- if (x != NULL || ...)
  S
  ...> }
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:13:15 -07:00
Jacob Smith ace9115712 staging: rt2860: rtmp: Fixed coding style issue in rtmp.h
This patch fixes a whitespace issue detected by checkpatch.pl

Signed-off-by: Jacob Smith <tarinaky@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 11:13:15 -07:00
Larry Finger 74b4ad79ed staging: r8712u: Add TODO to driver files
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 10:59:53 -07:00
Larry Finger 5a3acb043a staging: r8712u: Update driver version to v7_0.20100831
Signed-off-by: Albert Wang <albert_wang@realtek.com.tw>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 10:59:53 -07:00
Larry Finger 2e04fc838a staging: r8712u: Fix potential crash issue
When the driver received the Addba request frame from AP, a crash could
occur.

Signed-off-by: Albert Wang <albert_wang@realtek.com.tw>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 10:59:53 -07:00
Larry Finger d19b86473e staging: r8712u: Add module parameter to disable turbo mode
Signed-off-by: Albert Wang <albert_wang@realtek.com.tw>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 10:59:52 -07:00
Larry Finger 1c9bb32a38 staging: r8712u: Use 802.11bg mode to make a WEP connection
There are some IOT issues when 802.11bgn mode is used to make a WEP
connection.

Signed-off-by: Albert Wang <albert_wang@realtek.com.tw>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 10:59:52 -07:00
Larry Finger 16e53729b7 staging: r8712u: Fix sparse warnings
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-31 10:59:52 -07:00
Krzysztof Halasa 921a86e0e3 Staging: Add SBE 2T3E3 WAN driver
This is a driver for SBE Inc.'s dual port T3/E3 WAN cards. Based on
their original GPLed driver.

The original driver tarball is now accessible at
http://userweb.kernel.org/~chris/SBE_2T3_Linux_2.0c.tgz

It needs at least a new generic HDLC setup code (not yet written) before
moving to drivers/net/wan.

Signed-off-by: Krzysztof Hałasa <khc@pm.waw.pl>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-30 17:36:50 -07:00
Greg Kroah-Hartman b0b5763308 Staging: westbridge: mark BROKEN as it doesn't currently build properly
Future patches should fix this up.

Cc: David Cross <david.cross@cypress.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-30 17:29:22 -07:00
David Cross 81eb669b95 Staging: add West Bridge Astoria Driver
This is a driver for the Cypress West Bridge companion chip. Its
function is analogous to the North/South Bridges of PC environments
applied to embedded devices, in that it expands I/O and storage
capabilities of an embedded processor. The Astoria version, which this
driver applies to, functions as a USB, embedded memory and SDIO
controller. The kernel that this patch was applied to is linux-2.6.35,
although it was tested using the android kernel 2.6.29 running on the
Zoom 2 platform. In this system, it was used primarily as a sideloading
accelerator enabling direct data transfers between a USB host PC and
embedded memory without system overheads.  Minor modifications were also
made to the kernel for this patch. These include changes such as
EXPORTing of fat_get_block in the kernel code. Another function,
mpage_cleardirty was also added to the memory management code. This
function is used to clear the dirty pages from a specific inode. This
allows for direct, file based DMA. None of these changes are believed to
have any negative impact on the kernel and may provide additional
benefit for other developers and drivers.

The driver, as submitted, was placed into the drivers/staging/westbridge
folder as the directory structure it will eventually reside in is not yet
defined. The driver, as placed in staging is divided into four parts:
1) gadget - this implements a gadget peripheral controller and includes IOCTLs
for MTP transfers
2) block -this implements a generic block device driver to enable access to
embedded memory
3) api -this is the Cypress SDK, and includes USB and Storage specific
functions. In addition, it includes common code for low level routines such as
message passing and common data transfer routines
4) hal - this should likely be included in the arch directory as it needs to
be modified for a given platform. The directory structure in the staging area
is meant to reflect the eventual location of where this code likely should be.
It is platform specific. In this case, the HAL included is for the Android
Zoom 2 platform. Here, West Bridge is connected to the GPMC (general purpose
memory controller) of the OMAP3. Specific timing needs to be enabled to ensure
reliable communication.
Many thanks to Greg KH for conducting initial reviews and providing pointers.
Please contact david.cross@cypress.com for questions, concerns or feedback.

Signed-off-by: David Cross <david.cross@cypress.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-30 17:20:53 -07:00
Greg Kroah-Hartman 760ffce8ab Staging: delete rtl8192su driver
Now that we have a much better driver for this device (rtl8712), delete
this driver as it is no longer needed.

Cc: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-30 16:29:56 -07:00
Larry Finger 1407a9e105 staging: r8712u: Fix rate setting when HT is not enabled
When operating in normal bg mode, the maximum rate was fixed at 48 Mb/s.

Signed-off-by: Albert Wang <albert_wang@realtek.com.tw>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
2010-08-30 07:51:09 -05:00
Larry Finger 0a2f38193d Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6 2010-08-26 15:11:25 -05:00
Greg Kroah-Hartman d49824c067 Staging: sep: remove driver
It's currently stalled and the original submitter recommended that it
just be dropped at this point in time due.

Cc: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:38 -07:00
Sven Eckelmann f86b998425 Staging: batman-adv: Don't write in not allocated packet_buff
Each net_device in a system will automatically managed as a possible
batman_if and holds different informations like a buffer with a prepared
originator messages. To reduce the memory usage, the packet_buff will
only be allocated when the interface is really added/enabled for
batman-adv.

The function to update the hw address information inside the packet_buff
just assumes that the packet_buff is always initialised and thus the
kernel will just oops when we try to change the hw address of a not
already fully enabled interface.

We must always check if the packet_buff is allocated before we try to
change information inside of it.

Reported-by: Tim Glaremin <Tim.Glaremin@web.de>
Reported-by: Kazuki Shimada <zukky@bb.banban.jp>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:38 -07:00
Sven Eckelmann 51a00eaf6e Staging: batman-adv: Don't use net_dev after dev_put
dev_put allows a device to be freed when all its references are dropped.
After that we are not allowed to access that information anymore. Access
to the data structure of a net_device must be surrounded a dev_hold
and ended using dev_put.

batman-adv adds a device to its own management structure in
hardif_add_interface and will release it in hardif_remove_interface.
Thus it must hold a reference all the time between those functions to
prevent any access to the already released net_device structure.

Reported-by: Tim Glaremin <Tim.Glaremin@web.de>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:37 -07:00
Sven Eckelmann 1189f130f8 Staging: batman-adv: Create batman_if only on register event
We try to get all events for all net_devices to be able to add special
sysfs folders for the batman-adv configuration. This also includes such
events like NETDEV_POST_INIT which has no valid kobject according to
v2.6.32-rc3-13-g7ffbe3f. This would create an oops in that situation.

It is enough to create the batman_if only on NETDEV_REGISTER events
because we will also receive those events for devices which already
existed when we registered the notifier call.

Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:37 -07:00
Marek Lindner 51e21ae3d7 Staging: batman-adv: fix own mac address detection
Earlier batman-adv versions would only create a batman_if struct after
a corresponding interface had been activated by a user. Now each
existing system interface has a batman_if struct and has to be checked
by verifying the IF_ACTIVE flag.

Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:37 -07:00
Marek Lindner b7a23bce7b Staging: batman-adv: always reply batman icmp packets with primary mac
When receiving an batman icmp echo request or in case of a time-to-live
exceeded batman would reply with the mac address of the outgoing
interface which might be a secondary interface. Because secondary
interfaces are not globally known this might lead to confusion.
Now, replies are sent with the mac address of the primary interface.

Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:36 -07:00
Marek Lindner 13334d4875 Staging: batman-adv: fix batman icmp originating from secondary interface
If a batman icmp packet had to be routed over a secondary interface
at the first hop, the mac address of that secondary interface would
be written in the 'orig' field of the icmp packet. A node which is
more than one hop away is not aware of the mac address because
secondary interfaces are not flooded through the whole mesh and
therefore can't send a reply.
This patch always sends the mac address of the primary interface
in the 'orig' field of the icmp packet.

Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:36 -07:00
Marek Lindner 9abc10238e Staging: batman-adv: unify orig_hash_lock spinlock handling to avoid deadlocks
The orig_hash_lock spinlock always has to be locked with IRQs being
disabled to avoid deadlocks between code that is being executed in
IRQ context and code that is being executed in non-IRQ context.

Reported-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Marek Lindner <lindner_marek@yahoo.de>
Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:36 -07:00
Sven Eckelmann 466122df80 Staging: batman-adv: Fix merge of linus tree
Greg Kroah-Hartman merged Linus 2.6.36 tree in
e9563355ac with his staging tree.
Different parts of the merge conflicts were resolved incorrectly and may
result in an abnormal behavior.

Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:35 -07:00
Javier Martinez Canillas 49b4854772 Staging: spectra: removes unused functions
Fix compilation warning removing unused functions.


Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:35 -07:00
Javier Martinez Canillas fd484b86a2 Staging: spectra: initializa lblk variable
Fix a compile warning by initializaing lblk. Since FTL_Get_Block_Index()
returns BAD_BLOCK if it doesn't find the logical block number, lblk
number is initizalized to BAD_BLOCK.


Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:35 -07:00
Javier Martinez Canillas 676cecaadd Staging: spectra: removes unused variable
Fix a compile warning by removing an unused variable int i.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:34 -07:00
Javier Martinez Canillas c321da6dc5 Staging: spectra: remove duplicate GLOB_VERSION definition
This is the first patch of a patchset that removes all compilations
warnings in staging/spectra.

These patches are a delta from a previous patchset and it assumes that
these three patches all already applied:

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:34 -07:00
Javier Martinez Canillas 6e19d2db49 Staging: spectra: don't use locked_ioctl, fix build
Last patch has a style problem. Sending the correct one. Sorry for the noise

Since BKL was removed from block ioctl handling code, locked_ioctl doesn't
exist anymore.

Using ioctl instead and doing the locking manually.

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:34 -07:00
Javier Martinez Canillas 7b633f6624 Staging: use new REQ_FLUSH flag, fix build breakage
REQ_TYPE_LINUX_BLOCK and REQ_LB_OP_FLUSH doesn't exist anymore. Using
the new REQ_FLUSH flag instead

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:33 -07:00
Javier Martinez Canillas 09e74c794f Staging: spectra: removes q->prepare_flush_fn, fix build breakage
This patch is the first one of a patchset that allows 
stagin/spectra driver to compile in linux-next. 

blk_queue_ordered doesn't receive a prepare flush function anymore

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-23 18:15:33 -07:00
Larry Finger 2865d42c78 staging: r8712u: Add the new driver to the mainline kernel
This code is for a completely new version of the Realtek 8192 USB devices
such as the D-Link DWA-130. The Realtek code, which was originally for
Linux, Windows XP and Windows CE, has been stripped of all code not needed
for Linux. In addition, only one additional configuration variable, which
enables AP mode, remains.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Florian Schilhabel <florian.c.schilhabel@googlemail.com>
Tested-by: Frederic Leroy <fredo@starox.org>
2010-08-20 10:15:30 -05:00
Nick Piggin 2a4419b5b2 fs: fs_struct rwlock to spinlock
fs: fs_struct rwlock to spinlock

struct fs_struct.lock is an rwlock with the read-side used to protect root and
pwd members while taking references to them. Taking a reference to a path
typically requires just 2 atomic ops, so the critical section is very small.
Parallel read-side operations would have cacheline contention on the lock, the
dentry, and the vfsmount cachelines, so the rwlock is unlikely to ever give a
real parallelism increase.

Replace it with a spinlock to avoid one or two atomic operations in typical
path lookup fastpath.

Signed-off-by: Nick Piggin <npiggin@kernel.dk>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2010-08-18 08:35:46 -04:00
Rusty Russell dca4130639 param: remove unnecessary writable charp
sysfs-writable charp arguments need to be locked against modification
(since the old ones may be kfreed underneath us).  String arguments
are much simpler, so use them for small strings (eg. IFNAMSIZ).

lkdtm only uses the parameters at module initialization time, so there's
not much point making them writable.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Reviewed-by: Takashi Iwai <tiwai@suse.de>
Tested-by: Phil Carmody <ext-phil.2.carmody@nokia.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: M. Mohan Kumar <mohan@in.ibm.com>
Cc: Greg Kroah-Hartman <gregkh@suse.de>
Cc: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Cc: Jeff Mahoney <jeffm@suse.com>
Cc: Julia Lawall <julia@diku.dk>
Cc: devel@driverdev.osuosl.org
2010-08-11 23:04:27 +09:30
Linus Torvalds 2f9e825d3e Merge branch 'for-2.6.36' of git://git.kernel.dk/linux-2.6-block
* 'for-2.6.36' of git://git.kernel.dk/linux-2.6-block: (149 commits)
  block: make sure that REQ_* types are seen even with CONFIG_BLOCK=n
  xen-blkfront: fix missing out label
  blkdev: fix blkdev_issue_zeroout return value
  block: update request stacking methods to support discards
  block: fix missing export of blk_types.h
  writeback: fix bad _bh spinlock nesting
  drbd: revert "delay probes", feature is being re-implemented differently
  drbd: Initialize all members of sync_conf to their defaults [Bugz 315]
  drbd: Disable delay probes for the upcomming release
  writeback: cleanup bdi_register
  writeback: add new tracepoints
  writeback: remove unnecessary init_timer call
  writeback: optimize periodic bdi thread wakeups
  writeback: prevent unnecessary bdi threads wakeups
  writeback: move bdi threads exiting logic to the forker thread
  writeback: restructure bdi forker loop a little
  writeback: move last_active to bdi
  writeback: do not remove bdi from bdi_list
  writeback: simplify bdi code a little
  writeback: do not lose wake-ups in bdi threads
  ...

Fixed up pretty trivial conflicts in drivers/block/virtio_blk.c and
drivers/scsi/scsi_error.c as per Jens.
2010-08-10 15:22:42 -07:00
Linus Torvalds 7ae0dea900 Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6
* 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (94 commits)
  V4L/DVB: tvp7002: fix write to H-PLL Feedback Divider LSB register
  V4L/DVB: dvb: siano: free spinlock before schedule()
  V4L/DVB: media: video: pvrusb2: remove custom hex_to_bin()
  V4L/DVB: drivers: usbvideo: remove custom implementation of hex_to_bin()
  V4L/DVB: Report supported QAM modes on bt8xx
  V4L/DVB: media: ir-keytable: null dereference in debug code
  V4L/DVB: ivtv: convert to the new control framework
  V4L/DVB: ivtv: convert gpio subdev to new control framework
  V4L/DVB: wm8739: convert to the new control framework
  V4L/DVB: cs53l32a: convert to new control framework
  V4L/DVB: wm8775: convert to the new control framework
  V4L/DVB: cx2341x: convert to the control framework
  V4L/DVB: cx25840: convert to the new control framework
  V4L/DVB: cx25840/ivtv: replace ugly priv control with s_config
  V4L/DVB: saa717x: convert to the new control framework
  V4L/DVB: msp3400: convert to the new control framework
  V4L/DVB: saa7115: convert to the new control framework
  V4L/DVB: v4l2: hook up the new control framework into the core framework
  V4L/DVB: Documentation: add v4l2-controls.txt documenting the new controls API
  V4L/DVB: v4l2-ctrls: Whitespace cleanups
  ...
2010-08-10 15:09:54 -07:00
Linus Torvalds 9895850b23 Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (148 commits)
  USB: serial: fix stalled writes
  USB: remove fake "address-of" expressions
  USB: fix thread-unsafe anchor utiliy routines
  USB: usbtest: support test device with only one iso-in or iso-out endpoint
  USB: usbtest: avoid to free coherent buffer in atomic context
  USB: xhci: Set DMA mask for host.
  USB: xhci: Don't flush doorbell writes.
  USB: xhci: Reduce reads and writes of interrupter registers.
  USB: xhci: Make xhci_set_hc_event_deq() static.
  USB: xhci: Minimize HW event ring dequeue pointer writes.
  USB: xhci: Make xhci_handle_event() static.
  USB: xhci: Remove unnecessary reads of IRQ_PENDING register.
  USB: xhci: Performance - move xhci_work() into xhci_irq()
  USB: xhci: Performance - move interrupt handlers into xhci-ring.c
  USB: xhci: Performance - move functions that find ep ring.
  USB:: fix linux/usb.h kernel-doc warnings
  USB: add USB serial ssu100 driver
  USB: usb-storage: implement autosuspend
  USB: ehci: fix remove of ehci debugfs dir
  USB: Add USB 2.0 to ssb ohci driver
  ...
2010-08-10 15:05:02 -07:00
Alan Stern 541c7d432f USB: convert usb_hcd bitfields into atomic flags
This patch (as1393) converts several of the single-bit fields in
struct usb_hcd to atomic flags.  This is for safety's sake; not all
CPUs can update bitfield values atomically, and these flags are used
in multiple contexts.

The flag fields that are set only during registration or removal can
remain as they are, since non-atomic accesses at those times will not
cause any problems.

(Strictly speaking, the authorized_default flag should become atomic
as well.  I didn't bother with it because it gets changed only via
sysfs.  It can be done later, if anyone wants.)

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-10 14:35:37 -07:00
Linus Torvalds 7233e39276 Merge branch 'bkl/ioctl' of git://git.kernel.org/pub/scm/linux/kernel/git/frederic/random-tracing
* 'bkl/ioctl' of git://git.kernel.org/pub/scm/linux/kernel/git/frederic/random-tracing:
  staging: Pushdown bkl to easycap ioctl handlers
  autofs/autofs4: Move compat_ioctl handling into fs
  v4l: Convert v4l2-dev to unlocked_ioctl
  ia64/perfmon: Convert to unlocked_ioctl
  sunrpc: Remove duplicated #include
  ncpfs: Remove duplicated #include
2010-08-10 13:58:28 -07:00
Linus Torvalds 5f248c9c25 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6: (96 commits)
  no need for list_for_each_entry_safe()/resetting with superblock list
  Fix sget() race with failing mount
  vfs: don't hold s_umount over close_bdev_exclusive() call
  sysv: do not mark superblock dirty on remount
  sysv: do not mark superblock dirty on mount
  btrfs: remove junk sb_dirt change
  BFS: clean up the superblock usage
  AFFS: wait for sb synchronization when needed
  AFFS: clean up dirty flag usage
  cifs: truncate fallout
  mbcache: fix shrinker function return value
  mbcache: Remove unused features
  add f_flags to struct statfs(64)
  pass a struct path to vfs_statfs
  update VFS documentation for method changes.
  All filesystems that need invalidate_inode_buffers() are doing that explicitly
  convert remaining ->clear_inode() to ->evict_inode()
  Make ->drop_inode() just return whether inode needs to be dropped
  fs/inode.c:clear_inode() is gone
  fs/inode.c:evict() doesn't care about delete vs. non-delete paths now
  ...

Fix up trivial conflicts in fs/nilfs2/super.c
2010-08-10 11:26:52 -07:00
Al Viro 45321ac543 Make ->drop_inode() just return whether inode needs to be dropped
... and let iput_final() do the actual eviction or retention

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2010-08-09 16:48:35 -04:00
Christoph Hellwig 1025774ce4 remove inode_setattr
Replace inode_setattr with opencoded variants of it in all callers.  This
moves the remaining call to vmtruncate into the filesystem methods where it
can be replaced with the proper truncate sequence.

In a few cases it was obvious that we would never end up calling vmtruncate
so it was left out in the opencoded variant:

 spufs: explicitly checks for ATTR_SIZE earlier
 btrfs,hugetlbfs,logfs,dlmfs: explicitly clears ATTR_SIZE earlier
 ufs: contains an opencoded simple_seattr + truncate that sets the filesize just above

In addition to that ncpfs called inode_setattr with handcrafted iattrs,
which allowed to trim down the opencoded variant.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2010-08-09 16:47:37 -04:00
Maxim Levitsky 9ea53b74df V4L/DVB: STAGING: remove lirc_ene0100 driver
Add latest unported version of this driver to media/IR.
Next patch will port it to ir core.

Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-08-08 23:43:00 -03:00
Jarod Wilson 2c1101d5ae V4L/DVB: IR: put newly ported streamzap driver in proper home
Moves drivers/staging/lirc/lirc_streamzap.c to
drivers/media/IR/streamzap.c, along with making the requisite Kconfig
and Makefile changes.

Signed-off-by: Jarod Wilson <jarod@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-08-08 23:42:58 -03:00
Jarod Wilson 8e9e606400 V4L/DVB: staging/lirc: port lirc_streamzap to ir-core
This ports lirc_streamzap.c over to ir-core in-place, to be followed by
a patch moving the driver over to drivers/media/IR/streamzap.c and
enabling the proper Kconfig bits.

Presently, the in-kernel keymap doesn't work, as the stock Streamzap
remote uses an RC-5-like, but not-quite-RC-5 protocol, which the
in-kernel RC-5 decoder doesn't cope with. The remote can be used right
now with the lirc bridge driver though, and other remotes (at least an
RC-6(A) MCE remote) work perfectly with the driver.

I'll take a look at making the existing RC-5 decoder cope with this odd
duck, possibly implement another standalone decoder engine, or just
throw up my hands and say "meh, use lirc"... But the driver itself
should be perfectly sound.

Remaining items on the streamzap TODO list:
- add LIRC_SET_REC_TIMEOUT-alike support
- add LIRC_GET_M{AX,IN}_TIMEOUT-alike support
- add LIRC_GET_REC_RESOLUTION-alike support

All of the above should be trivial to add. There are patches pending to
add this support to ir-core from Maxim Levitsky, and I'll take care of
these once his patches get integrated. None of them are currently
essential though.

Signed-off-by: Jarod Wilson <jarod@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-08-08 23:42:58 -03:00
Jarod Wilson 82ce67bf26 V4L/DVB: staging/lirc: fix non-CONFIG_MODULES build horkage
Fix when CONFIG_MODULES is not enabled:

drivers/staging/lirc/lirc_parallel.c:243: error: implicit declaration of function 'module_refcount'
drivers/staging/lirc/lirc_it87.c:150: error: implicit declaration of function 'module_refcount'
drivers/built-in.o: In function `it87_probe':
lirc_it87.c:(.text+0x4079b0): undefined reference to `init_chrdev'
lirc_it87.c:(.text+0x4079cc): undefined reference to `drop_chrdev'
drivers/built-in.o: In function `lirc_it87_exit':
lirc_it87.c:(.exit.text+0x38a5): undefined reference to `drop_chrdev'

Its a quick hack and untested beyond building, since I don't have the
hardware, but it should do the trick.

Acked-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Jarod Wilson <jarod@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-08-08 23:42:57 -03:00
Janne Grunau efce8ca3c5 V4L/DVB: staging/lirc: fix Kconfig dependencies
Signed-off-by: Janne Grunau <j@jannau.net>
Signed-off-by: Jarod Wilson <jarod@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-08-08 23:42:57 -03:00
Frederic Weisbecker 5ef06839f5 staging: Pushdown bkl to easycap ioctl handlers
These were amongst the last users of struct file_operations:ioctl

Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
2010-08-09 03:28:40 +02:00
Arnd Bergmann 6e9624b8ca block: push down BKL into .open and .release
The open and release block_device_operations are currently
called with the BKL held. In order to change that, we must
first make sure that all drivers that currently rely
on this have no regressions.

This blindly pushes the BKL into all .open and .release
operations for all block drivers to prepare for the
next step. The drivers can subsequently replace the BKL
with their own locks or remove it completely when it can
be shown that it is not needed.

The functions blkdev_get and blkdev_put are the only
remaining users of the big kernel lock in the block
layer, besides a few uses in the ioctl code, none
of which need to serialize with blkdev_{get,put}.

Most of these two functions is also under the protection
of bdev->bd_mutex, including the actual calls to
->open and ->release, and the common code does not
access any global data structures that need the BKL.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Christoph Hellwig <hch@infradead.org>
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
2010-08-07 18:25:34 +02:00
Christoph Hellwig 33659ebbae block: remove wrappers for request type/flags
Remove all the trivial wrappers for the cmd_type and cmd_flags fields in
struct requests.  This allows much easier grepping for different request
types instead of unwinding through macros.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
2010-08-07 18:17:56 +02:00
Linus Torvalds 1685e633b3 Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6:
  pcmcia: avoid buffer overflow in pcmcia_setup_isa_irq
  pcmcia: do not request windows if you don't need to
  pcmcia: insert PCMCIA device resources into resource tree
  pcmcia: export resource information to sysfs
  pcmcia: use struct resource for PCMCIA devices, part 2
  pcmcia: remove memreq_t
  pcmcia: move local definitions out of include/pcmcia/cs.h
  pcmcia: do not use io_req_t when calling pcmcia_request_io()
  pcmcia: do not use io_req_t after call to pcmcia_request_io()
  pcmcia: use struct resource for PCMCIA devices
  pcmcia: clean up cs.h
  pcmcia: use pcmica_{read,write}_config_byte
  pcmcia: remove cs_types.h
  pcmcia: remove unused flag, simplify headers
  pcmcia: remove obsolete CS_EVENT_ definitions
  pcmcia: split up central event handler
  pcmcia: simplify event callback
  pcmcia: remove obsolete ioctl

Conflicts in:
 - drivers/staging/comedi/drivers/*
 - drivers/staging/wlags49_h2/wl_cs.c
due to dev_info_t and whitespace changes
2010-08-06 12:25:06 -07:00
Christoph Fritz 9015e49962 Staging: wlan-ng: Update prism2_set_tx_power() to use mBm
Commit fa61cf70a6 updates nl80211's function
.set_tx_power to use mBm units instead of dBm for greater accuracy and
smaller power levels.

This patchs updates prism2_set_tx_power() accordingly.

Signed-off-by: Christoph Fritz <chf.fritz@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-05 14:18:29 -07:00
Greg Kroah-Hartman e9563355ac Staging: Merge staging-next into Linus's tree
Conflicts:
	drivers/staging/Kconfig
	drivers/staging/batman-adv/bat_sysfs.c
	drivers/staging/batman-adv/device.c
	drivers/staging/batman-adv/hard-interface.c
	drivers/staging/cx25821/cx25821-audups11.c

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-05 14:18:03 -07:00
Linus Torvalds 3cfc2c42c1 Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial
* 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (48 commits)
  Documentation: update broken web addresses.
  fix comment typo "choosed" -> "chosen"
  hostap:hostap_hw.c Fix typo in comment
  Fix spelling contorller -> controller in comments
  Kconfig.debug: FAIL_IO_TIMEOUT: typo Faul -> Fault
  fs/Kconfig: Fix typo Userpace -> Userspace
  Removing dead MACH_U300_BS26
  drivers/infiniband: Remove unnecessary casts of private_data
  fs/ocfs2: Remove unnecessary casts of private_data
  libfc: use ARRAY_SIZE
  scsi: bfa: use ARRAY_SIZE
  drm: i915: use ARRAY_SIZE
  drm: drm_edid: use ARRAY_SIZE
  synclink: use ARRAY_SIZE
  block: cciss: use ARRAY_SIZE
  comment typo fixes: charater => character
  fix comment typos concerning "challenge"
  arm: plat-spear: fix typo in kerneldoc
  reiserfs: typo comment fix
  update email address
  ...
2010-08-04 15:31:02 -07:00
Linus Torvalds 6ba74014c1 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1443 commits)
  phy/marvell: add 88ec048 support
  igb: Program MDICNFG register prior to PHY init
  e1000e: correct MAC-PHY interconnect register offset for 82579
  hso: Add new product ID
  can: Add driver for esd CAN-USB/2 device
  l2tp: fix export of header file for userspace
  can-raw: Fix skb_orphan_try handling
  Revert "net: remove zap_completion_queue"
  net: cleanup inclusion
  phy/marvell: add 88e1121 interface mode support
  u32: negative offset fix
  net: Fix a typo from "dev" to "ndev"
  igb: Use irq_synchronize per vector when using MSI-X
  ixgbevf: fix null pointer dereference due to filter being set for VLAN 0
  e1000e: Fix irq_synchronize in MSI-X case
  e1000e: register pm_qos request on hardware activation
  ip_fragment: fix subtracting PPPOE_SES_HLEN from mtu twice
  net: Add getsockopt support for TCP thin-streams
  cxgb4: update driver version
  cxgb4: add new PCI IDs
  ...

Manually fix up conflicts in:
 - drivers/net/e1000e/netdev.c: due to pm_qos registration
   infrastructure changes
 - drivers/net/phy/marvell.c: conflict between adding 88ec048 support
   and cleaning up the IDs
 - drivers/net/wireless/ipw2x00/ipw2100.c: trivial ipw2100_pm_qos_req
   conflict (registration change vs marking it static)
2010-08-04 11:47:58 -07:00
Linus Torvalds c145307a11 Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mjg59/platform-drivers-x86
* 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mjg59/platform-drivers-x86: (88 commits)
  ips driver: make it less chatty
  intel_scu_ipc: fix size field for intel_scu_ipc_command
  intel_scu_ipc: return -EIO for error condition in busy_loop
  intel_scu_ipc: fix data packing of PMIC command on Moorestown
  Clean up command packing on MRST.
  zero the stack buffer before giving random garbage to the SCU
  Fix stack buffer size for IPC writev messages
  intel_scu_ipc: Use the new cpu identification function
  intel_scu_ipc: tidy up unused bits
  Remove indirect read write api support.
  intel_scu_ipc: Support Medfield processors
  intel_scu_ipc: detect CPU type automatically
  x86 plat: limit x86 platform driver menu to X86
  acpi ec_sys: Be more cautious about ec write access
  acpi ec: Fix possible double io port registration
  hp-wmi: acpi_drivers.h is already included through acpi.h two lines below
  hp-wmi: Fix mixing up of and/or directive
  dell-laptop: make dell_laptop_i8042_filter() static
  asus-laptop: fix asus_input_init error path
  msi-wmi: make needlessly global symbols static
  ...
2010-08-04 10:44:06 -07:00
Jiri Kosina d790d4d583 Merge branch 'master' into for-next 2010-08-04 15:14:38 +02:00
Alan Cox c715a38bb7 rar: Move the RAR driver into the right place as its now clean
We exit staging rar! rar! rar!...

Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Matthew Garrett <mjg@redhat.com>
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-03 09:48:50 -04:00
Dominik Brodowski 0f52e86ded pcmcia: do not request windows if you don't need to
Several drivers contained dummy code to request for memory windows,
even though they never made use of it. Remove all such code
snippets.

CC: netdev@vger.kernel.org
CC: linux-wireless@vger.kernel.org
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
2010-08-03 09:04:21 +02:00
Dominik Brodowski b5cb259e7f pcmcia: remove memreq_t
Page already had to be set to 0; Offset can easily be passed as
parameter to pcmcia_map_mem_page.

CC: netdev@vger.kernel.org
CC: linux-wireless@vger.kernel.org
CC: linux-ide@vger.kernel.org
CC: linux-usb@vger.kernel.org
CC: laforge@gnumonks.org
CC: linux-mtd@lists.infradead.org
CC: linux-bluetooth@vger.kernel.org
CC: alsa-devel@alsa-project.org
CC: linux-serial@vger.kernel.org
CC: Michael Buesch <mb@bu3sch.de>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
2010-08-03 09:04:14 +02:00
Dominik Brodowski 90abdc3b97 pcmcia: do not use io_req_t when calling pcmcia_request_io()
Instead of io_req_t, drivers are now requested to fill out
struct pcmcia_device *p_dev->resource[0,1] for up to two ioport
ranges. After a call to pcmcia_request_io(), the ports found there
are reserved, after calling pcmcia_request_configuration(), they may
be used.

CC: netdev@vger.kernel.org
CC: linux-wireless@vger.kernel.org
CC: linux-ide@vger.kernel.org
CC: linux-usb@vger.kernel.org
CC: laforge@gnumonks.org
CC: linux-mtd@lists.infradead.org
CC: alsa-devel@alsa-project.org
CC: linux-serial@vger.kernel.org
CC: Michael Buesch <mb@bu3sch.de>
Acked-by: Marcel Holtmann <marcel@holtmann.org> (for drivers/bluetooth/)
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
2010-08-03 09:04:11 +02:00
Dominik Brodowski 9a017a9103 pcmcia: do not use io_req_t after call to pcmcia_request_io()
After pcmcia_request_io(), do not make use of the values stored in
io_req_t, but instead use those found in struct pcmcia_device->resource[].

CC: netdev@vger.kernel.org
CC: linux-wireless@vger.kernel.org
CC: linux-ide@vger.kernel.org
CC: linux-usb@vger.kernel.org
CC: laforge@gnumonks.org
CC: linux-mtd@lists.infradead.org
CC: alsa-devel@alsa-project.org
CC: linux-serial@vger.kernel.org
Acked-by: Marcel Holtmann <marcel@holtmann.org> (for drivers/bluetooth/)
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
2010-08-03 09:03:59 +02:00
Pavan Savoy b12d1995f6 Staging: ti-st: update TODO
Removed TODO item 2 :
Current UIM/KIM communicate via the rfkill device and identified by the unique idx
assisgned by the rfkill sub-system to each of these rfkill entries.

Removed TODO item 1 :
Since there is no way we can test existance of multiple connectivity
devices on  platform.
However the basic infrastructure as in providing a context to ST driver
exist.
If multiple devices have to exist on a given platform, multiple ST
platform devices need to be registered and each of the protocol drivers
have to mention which platform device they want to bind to/make use of.

Removed TODO item 3:
Locking have been reviewed and commit
36b5aee46b documents locking.

Signed-off-by: Pavan Savoy <pavan_savoy@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-02 18:28:40 -07:00
Javier Martinez Canillas 100ca12287 Staging: wlags49_h2: use common PCI_VENDOR/DEVICE_ID name format
There is a common name format for PCI_VENDOR/DEVICE_ID constants.
wlags49_h2 names doesn't fit in the standard.
This patch change the names and also fix some style issues.

Thanks a lot,

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-02 18:28:39 -07:00
Daniele Boncompagni d9811b79d4 Staging: comedi : fix brace coding style issue in wwrap.c
This is a patch to the wwrap.c file that fixes up a brace warnings and
other errors found by the checkpatch.pl tool.

Signed-off-by: Daniele Boncompagni <daniele.boncompagni@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-02 18:27:42 -07:00
Javier Martinez Canillas 3457912e0e Staging: quatech_usb2: remove unused qt2_box_flush function
In today linux-next I got a compilation warning:

drivers/staging/quatech_usb2/quatech_usb2.c:1852: warning:
‘qt2_box_flush’ defined but not used

Signed-off-by: Javier Martinez Canillas <martinez.javier@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-02 18:25:27 -07:00
Denis Kirjanov 9092de6df3 Staging: slicoss: Remove net_device_stats from the driver's private
Remove net_device_stats from the driver's private.

Signed-off-by: Denis Kirjanov <dkirjanov@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-02 18:25:26 -07:00
Kulikov Vasiliy 0ebdd466f4 staging: rtl8192su: check whether requests succeeded
rtl8192_usb_probe() does not check alloc_ieee80211() and
register_netdev() return values for errors.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-02 18:23:45 -07:00
Kulikov Vasiliy 10f3f5b7f6 staging: panel: fix error path
panel_attach() poorly handles errors. On error unregister everything we
have registered.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-02 18:23:45 -07:00
Kulikov Vasiliy d49d0e39a0 staging: otus: check kmalloc() return value
kmalloc() may fail, if so return error from zfwUsbSubmitControl().

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-02 18:23:44 -07:00
Kulikov Vasiliy 94f5659cfa staging: octeon: check request_irq() return value
request_irq() may fail, if so propagate error code.

Signed-off-by: Kulikov Vasiliy <segooon@gmail.com>
Acked-by: David Daney <ddaney@caviumnetworks.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-08-02 18:23:44 -07:00