aboutsummaryrefslogtreecommitdiff
path: root/include
AgeCommit message (Collapse)Author
2007-02-23USB: add driver for iowarrior devices.Greg Kroah-Hartman
The ioctl is commented out for now, until we verify some userspace application issues. Cc: Christian Lucht <lucht@codemercs.com> Cc: Robert Marquardt <marquardt@codemercs.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-02-21Merge branch 'master' of ↵Linus Torvalds
master.kernel.org:/pub/scm/linux/kernel/git/mchehab/v4l-dvb * 'master' of master.kernel.org:/pub/scm/linux/kernel/git/mchehab/v4l-dvb: (196 commits) V4L/DVB (5253): Qt1010: whitespace / 80 column cleanups V4L/DVB (5252): Qt1010: use ARRAY_SIZE macro when appropriate V4L/DVB (5251): Qt1010: fix compiler warning V4L/DVB (5249): Fix compiler warning in vivi.c V4L/DVB (5247): Stv0297: Enable BER/UNC counting V4L/DVB (5246): Budget-ci: IR handling fixups V4L/DVB (5245): Dvb-ttpci: use i2c gate ctrl from stv0297 frontend driver V4L/DVB (5244): Dvbdev: fix illegal re-usage of fileoperations struct V4L/DVB (5178): Avoid race when deregistering the IR control for dvb-usb V4L/DVB (5240): Qt1010: use i2c_gate_ctrl where appropriate V4L/DVB (5239): Whitespace / 80-column cleanups V4L/DVB (5238): Kconfig: qt1010 should be selected by gl861 and au6610 V4L/DVB (5237): Dvb: add new qt1010 tuner module V4L/DVB (5236): Initial support for Sigmatek DVB-110 DVB-T V4L/DVB (5235): Gl861: use parallel_ts V4L/DVB (5234): Gl861: remove unneeded declaration V4L/DVB (5233): Gl861: correct address of the bulk endpoint V4L/DVB (5232): Gl861: correct oops when loading module V4L/DVB (5231): Gl861: whitespace cleanups V4L/DVB (5230): Gl861: remove NULL entry from gl861_properties ...
2007-02-21V4L/DVB (5200): V4l_printk_ioctl_arg() is no longer used.Adrian Bunk
Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5204): Change videodev2.h licence to dual GPL/BSDMichael Schimek
videodev2.h contains just the V4L2 API structs and defines. By allowing this header file to be dual GPL/BSD will enable sharing userspace apps between Linux and *BSD systems. It will also allow developing newer BSD licensed drivers that can be shared on Linux and *BSD. It should be noticed that most of the current V4L drivers, and v4l core itself are GPL only. This won't be changed by this patch. Signed-off-by: Michael H. Schimek <mschimek@gmx.at> Signed-off-by: Gerd Hoffmann <kraxel@suse.de> Signed-off-by: Bill Dirks <bill@thedirks.org> Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Martin Rubli <mrubli@gmx.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5182): Remove #if 0 section from videodev2.hHans Verkuil
Remove a section containing basically ideas for future sliced VBI standards. This can be resurrected should any of this be actually implemented. For now it only pollutes this header file. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5181): Sliced VBI API no longer marked experimental.Hans Verkuil
The Sliced VBI API is no longer marked experimental. Introduced in 2.6.14 and with only a single modification in 2.6.19 I think we can consider this API to be solid. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5162): Change VIDIOC_DBG_[SG]_REGISTER ioctls' reg address to 64 bitsTrent Piepho
Maybe someday there will be a device with a register address space > 32-bits, or maybe an i2c device which uses a protocol > 4 bytes long to address its registers. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5147): Make vivi driver to use vmalloced pointersMauro Carvalho Chehab
Before this patch, vivi were simulating a scatter gather DMA transfer. While this is academic, showing how stuff really works on a real PCI device, this means a non-optimized code. There are only two memory models that vivi implements: 1) kernel alloced memory. This is also used by read() method. On this case, a vmalloc32 buffer is allocated at kernel; 2) userspace allocated memory. This is used by most userspace apps. video-buf will store this pointer. a simple copy_to_user is enough to transfer data. The third memory model scenario supported by video-buf is overlay mode. This model is not implemented on vivi and unlikely to be implemented on newer drivers, since now, most userspace apps do some post-processing (like de-interlacing). After this patch, some cleanups may be done at video-buf.c to avoid allocating pages, when the driver doesn't need a PCI buffer. This is the case of vivi and usb drivers. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5146): Make VIDIOC_INT_[SG]_REGISTER ioctls no longer internal onlyTrent Piepho
The direct register access ioctls were defined as kernel internal only, but they are very useful for debugging hardware from userspace and are used as such. Officially export them. VIDIOC_INT_[SG]_REGISTER is renamed to VIDIOC_DBG_[SG]_REGISTER Definition of ioctl and struct v4l2_register is moved from v4l2-common.h to videodev2.h. Types used in struct v4l2_register are changed to the userspace exportable versions (u32 -> __u32, etc). Use of VIDIOC_DBG_S_REGISTER requires CAP_SYS_ADMIN permission, so move the check into the video_ioctl2() dispatcher so it doesn't need to be duplicated in each driver's call-back function. CAP_SYS_ADMIN check is added to pvrusb2 (which doesn't use video_ioctl2). Signed-off-by: Trent Piepho <xyzzy@speakeasy.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5144): Restore VIDIOC_INT_[SG]_REGISTER callsTrent Piepho
Add support for these ioctls to the video_ioctl2 system and the cx88 driver. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5113): Adds video output routingMarco Schluessler
Nexus CA needs to use a different routing on saa7115 module. Signed-off-by: Marco Schluessler <marco@lordzodiac.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5070): Budget-ci: add support for the Technotrend 1500 bundled remoteVille-Pekka Vainio
The keymap is based on a previous patch by Jussi Kukkonen. This remote is identified by subsystem_device id 0x1010. Signed-off-by: Ville-Pekka Vainio <vpivaini@cs.helsinki.fi> Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5068): Fix authorship referencesMauro Carvalho Chehab
Bill Dirks asked me to update his entries at kernel files, since he change his e-mail. I've also updated a few web broken links or obsolete info to the curent sites where V4L drivers and API are being discussed currently. CC: Bill Dirks <bill@thedirks.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5017): DVB: fix compile errorAdrian Bunk
This patch fixes the following compile error: <-- snip --> ... LD drivers/media/video/built-in.o drivers/media/video/saa7134/built-in.o:(.data+0x85ec): multiple definition of `ir_rc5_remote_gap' drivers/media/video/bt8xx/built-in.o:(.data+0x734c): first defined here drivers/media/video/saa7134/built-in.o:(.data+0x85f0): multiple definition of `ir_rc5_key_timeout' drivers/media/video/bt8xx/built-in.o:(.data+0x7350): first defined here make[4]: *** [drivers/media/video/built-in.o] Error 1 <-- snip --> Since this variables were needlessly global, this patch implements the trivial fix of making them static. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (5015): Add support for more Encore TV cardsJuan Pablo Sormani
Signed-off-by: Juan Pablo Sormani <sorman@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (4986): Removed unimplemented cx2341x API commandsHans Verkuil
The commands CX2341X_DEC_SET_AUDIO_OUTPUT, CX2341X_DEC_SET_AV_DELAY and CX2341X_ENC_SET_3_2_PULLDOWN are not implemented in the Conexant firmware. So these commands are removed. This also means that the V4L2_CID_MPEG_VIDEO_PULLDOWN control in cx2341x.c and pvrusb2-hdw.c is removed. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21V4L/DVB (4961): Add support for the ASUS P7131 remote controlHermann Pitton
Besides adding the board specific code, this patch moves the RC5 decoding code from bt8xx to ir-functions.c to make it available for all drivers. Signed-off-by: Marc Fargas <telenieko.telenieko.com> Signed-off-by: Hermann Pitton <hermann-pitton@arcor.de> Signed-off-by: Hartmut Hackmann <hartmut.hackmann@t-online.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2007-02-21[S390] add atomic64_xchg to s390Mathieu Desnoyers
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2007-02-21[S390] local_t cleanup : use asm-generic/local.h.Mathieu Desnoyers
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2007-02-21[S390] nss: Free unused memory in kernel image.Heiko Carstens
With CONFIG_SHARED_KERNEL the kernel text segment that might be in a read only memory sections starts at 1MB. Memory between 0x12000 and 0x100000 is unused then. Free this, so we have appr. an extra MB of memory available. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2007-02-21[S390] New header file ipl.hMichael Holzheu
Setup.h has been misused for ipl related stuff in the past. We now move everything, which has to do with ipl and reipl to a new header file named "ipl.h". Signed-off-by: Michael Holzheu <holzheu@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2007-02-21[S390] New get_cpu_id() inline assemblyMichael Holzheu
Replace two stidp inline assemblies with one global implementation. Signed-off-by: Michael Holzheu <holzheu@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2007-02-20[PATCH] GPIO API: SA1100 wrapper cleanupPhilipp Zabel
Based on the discussion last december (http://lkml.org/lkml/2006/12/20/241), this patch - adds gpio_direction_input/output functions to generic.c instead of making them inline, - fixes comment and includes and uses inline functions instead of macros in gpio.h Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] GPIO API: S3C2410 wrapper cleanupPhilipp Zabel
this one adds an #include <asm/arch/regs-gpio.h>. Tested by Roman Moravcik on s3c2440. Based on the discussion last december (http://lkml.org/lkml/2006/12/20/243), this patch - fixes comment and includes in gpio.h - adds the gpio_to_irq definition for S3C2400 - includes asm/arch/regs-gpio.h for pin direction definitions Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] GPIO API: PXA wrapper cleanupPhilipp Zabel
Based on the discussion last december (http://lkml.org/lkml/2006/12/20/242), this patch: - moves the PXA_LAST_GPIO check into pxa_gpio_mode - fixes comment and includes in gpio.h - replaces the gpio_set/get_value macros with inline functions and adds a non-inline version to avoid code explosion when gpio is not a constant. Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Nicolas Pitre <nico@cam.org> Cc: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] autofs4: header file updateIan Kent
The current header file definitions for autofs version 5 have caused a couple of problems for application builds downstream. This fixes the problem by separating the definitions. Signed-off-by: Ian Kent <raven@themaw.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] cdrom: use unsigned bitfieldsRandy Dunlap
Fix 23 of these sparse warnings on x86_64 allmodconfig: include/linux/cdrom.h:942:19: error: dubious bitfield without explicit `signed' or `unsigned' Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Cc: Jens Axboe <axboe@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] mfd: SM501 core driverBen Dooks
This driver provides the core functionality of the SM501, which is a multi-function chip including two framebuffers, video acceleration, USB, and many other peripheral blocks. The driver exports a number of entries for the peripheral drivers to use. Signed-off-by: Ben Dooks <ben-linux@fluff.org> Signed-off-by: Vincent Sanders <vince@arm.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] cfag12864b: fix crash when built-in and no parport presentMiguel Ojeda
The problem comes when ks0108/cfag12864b are built-in and no parallel port is present. ks0108_init() is called first, as it should be, but fails to load (as there is no parallel port to use). After that, cfag12864b_init() gets called, without knowing anything about ks0108 failed, and calls ks0108_writecontrol(), which dereferences an uninitialized pointer. Init order is OK, I think. The problem is how to stop cfag12864b_init() being called if ks0108 failed to load. modprobe does it for us, but, how when built-in? Signed-off-by: Miguel Ojeda Sandonis <maxextreme@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] Convert highest_possible_processor_id to nr_cpu_idsChristoph Lameter
We frequently need the maximum number of possible processors in order to allocate arrays for all processors. So far this was done using highest_possible_processor_id(). However, we do need the number of processors not the highest id. Moreover the number was so far dynamically calculated on each invokation. The number of possible processors does not change when the system is running. We can therefore calculate that number once. Signed-off-by: Christoph Lameter <clameter@sgi.com> Cc: Frederik Deweerdt <frederik.deweerdt@gmail.com> Cc: Neil Brown <neilb@suse.de> Cc: Trond Myklebust <trond.myklebust@fys.uio.no> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] Replace highest_possible_node_id() with nr_node_idsChristoph Lameter
highest_possible_node_id() is currently used to calculate the last possible node idso that the network subsystem can figure out how to size per node arrays. I think having the ability to determine the maximum amount of nodes in a system at runtime is useful but then we should name this entry correspondingly, it should return the number of node_ids, and the the value needs to be setup only once on bootup. The node_possible_map does not change after bootup. This patch introduces nr_node_ids and replaces the use of highest_possible_node_id(). nr_node_ids is calculated on bootup when the page allocators pagesets are initialized. [deweerdt@free.fr: fix oops] Signed-off-by: Christoph Lameter <clameter@sgi.com> Cc: Neil Brown <neilb@suse.de> Cc: Trond Myklebust <trond.myklebust@fys.uio.no> Signed-off-by: Frederik Deweerdt <frederik.deweerdt@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] mincore warning fixAndrew Morton
allnoconfig: mm/mincore.c: In function 'do_mincore': mm/mincore.c:122: warning: unused variable 'entry' Yet another entry in the why-macros-are-wrong encyclopedia. Cc: Christoph Lameter <clameter@engr.sgi.com> Cc: Nick Piggin <nickpiggin@yahoo.com.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] rework reserved major handlingAndrew Morton
Several people have reported failures in dynamic major device number handling due to the recent changes in there to avoid handing out the local/experimental majors. Rolf reports that this is due to a gcc-4.1.0 bug. The patch refactors that code a lot in an attempt to provoke the compiler into behaving. Cc: Rolf Eike Beer <eike-kernel@sf-tec.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] minix v3: fix superblock definitionAndries Brouwer
Somehow we got the layout of the v3 superblock wrong, which causes crashes due to overindexing of the buffer_head array in statfs on large fielsystems. Cc: "Cedric Augonnet" <cedric.augonnet@gmail.com> Cc: "Daniel Aragones" <danarag@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] Fix build errors if bitop functions are do {} while macrosRalf Baechle
If one of clear_bit, change_bit or set_bit is defined as a do { } while (0) function usage of these functions in parenthesis like (foo_bit(23, &var)) while be expaned to something like (do { ... } while (0)}). resulting in a build error. This patch removes the useless parenthesis. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Cc: Trond Myklebust <trond.myklebust@fys.uio.no> Cc: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20Merge branch 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-armLinus Torvalds
* 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm: [ARM] 4165/1: S3C24XX: Select CONFIG_NO_IOPORT [ARM] Fix s3c2410 ALSA audio for typedef elimination [ARM] Fix ARM AACI ALSA driver [ARM] fix mach-at91 build breakage [ARM] Fix jornada720 build errors [ARM] Fix iop13xx build error [ARM] Fix build error caused by move of apm [ARM] 4223/1: ixdp2351 : Fix for a define error [ARM] 4187/1: iop: unify time implementation across iop32x, iop33x, and iop13xx [ARM] 4186/1: iop: remove cp6_enable/disable routines [ARM] 4185/2: entry: introduce get_irqnr_preamble and arch_ret_to_user
2007-02-20Merge ARM fixesRussell King
2007-02-20Merge branch 'upstream-linus' of ↵Linus Torvalds
master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6 * 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6: (21 commits) natsemi: Support Aculab E1/T1 PMXc cPCI carrier cards natsemi: Add support for using MII port with no PHY skge: race with workq and RTNL Replace local random function with random32() s2io: RTNL and flush_scheduled_work deadlock 8139too: RTNL and flush_scheduled_work deadlock sis190: RTNL and flush_scheduled_work deadlock r8169: RTNL and flush_scheduled_work deadlock [PATCH] ieee80211softmac: Fix setting of initial transmit rates [PATCH] bcm43xx: OFDM fix for rev 1 cards [PATCH] bcm43xx: Fix for 4311 and 02/07/07 specification changes [PATCH] prism54: correct assignment of DOT1XENABLE in WE-19 codepaths [PATCH] zd1211rw: Readd zd_addr_t cast [PATCH] bcm43xx: Fix for oops on resume [PATCH] bcm43xx: Ignore ampdu status reports [PATCH] wavelan: Use ARRAY_SIZE macro when appropriate [PATCH] hostap: Use ARRAY_SIZE macro when appropriate [PATCH] misc-wireless: Use ARRAY_SIZE macro when appropriate [PATCH] ipw2100: Use ARRAY_SIZE macro when appropriate [PATCH] bcm43xx: Janitorial change - remove two unused variables ...
2007-02-20Merge branch 'upstream-jgarzik' of ↵Jeff Garzik
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6 into upstream
2007-02-20[ARM] Fix s3c2410 ALSA audio for typedef eliminationRussell King
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2007-02-20[ARM] 4223/1: ixdp2351 : Fix for a define errorOzzy
Fix syntax error for a define in ixdp2351.h Signed-off-by: ozzy <linux-ozzy@gmx.de> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2007-02-20[ARM] Merge remaining IOP codeRussell King
Conflicts: include/asm-arm/arch-at91rm9200/entry-macro.S Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2007-02-20backlight: Separate backlight properties from backlight ops pointersRichard Purdie
Per device data such as brightness belongs to the indivdual device and should therefore be separate from the the backlight operation function pointers. This patch splits the two types of data and allows simplifcation of some code. Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
2007-02-20backlight: Rework backlight/fb interaction simplifying, lotsRichard Purdie
fb_info->bl_mutex is badly thought out and the backlight class doesn't need it if the framebuffer/backlight register/unregister order is consistent, particularly after the backlight locking fixes. Fix the drivers to use the order: backlight_device_register() register_framebuffer() unregister_framebuffer() backlight_device_unregister() and turn bl_mutex into a lock for the bl_curve data only. Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
2007-02-20backlight/fbcon: Add FB_EVENT_CONBLANKRichard Purdie
The backlight class wants notification whenever the console is blanked but doesn't get this when hardware blanking fails and software blanking is used. Changing FB_EVENT_BLANK to report both would be a behaviour change which could confuse the console layer so add a new event for software blanking and have the backlight class listen for both. Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
2007-02-20backlight: Convert semaphore -> mutexRichard Purdie
Convert internal semaphore to a mutex Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
2007-02-20backlight: Fix external uses of backlight internal semaphoreRichard Purdie
backlight_device->sem has a very specific use as documented in the header file. The external users of this are using it for a different reason, to serialise access to the update_status() method. backlight users were supposed to implement their own internal serialisation of update_status() if needed but everyone is doing things differently and incorrectly. Therefore add a global mutex to take care of serialisation for everyone, once and for all. Locking for get_brightness remains optional since most users don't need it. Also update the lcd class in a similar way. Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
2007-02-20backlight: Remove unneeded owner fieldRichard Purdie
Remove uneeded owner field from backlight_properties structure. Nothing uses it and it is unlikely that it will ever be used. The backlight class uses other means to ensure that nothing references unloaded code. Based on a patch from Dmitry Torokhov <dtor@insightbb.com> Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
2007-02-20[MIPS] Fixup copy_from_user_inatomicRalf Baechle
From the 01408c4939479ec46c15aa7ef6e2406be50eeeca log message: The problem is that when we write to a file, the copy from userspace to pagecache is first done with preemption disabled, so if the source address is not immediately available the copy fails *and* *zeros* *the* *destination*. This is a problem because a concurrent read (which admittedly is an odd thing to do) might see zeros rather that was there before the write, or what was there after, or some mixture of the two (any of these being a reasonable thing to see). If the copy did fail, it will immediately be retried with preemption re-enabled so any transient problem with accessing the source won't cause an error. The first copying does not need to zero any uncopied bytes, and doing so causes the problem. It uses copy_from_user_atomic rather than copy_from_user so the simple expedient is to change copy_from_user_atomic to *not* zero out bytes on failure. < --- end cite --- > This patch finally implements at least a not so pretty solution by duplicating the relevant part of __copy_user. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2007-02-20[MIPS] Fix struct sigcontext for N32 userlandAtsushi Nemoto
The kernel use 64-bit for sc_regs[0], and both N32/N64 userland expects it was 64-bit. But size of 'long' on N32 is actually 32-bit. So this definition make some confusion. Use __u32 and __u64 for N32/N64 sigcontext to get rid of this confusion. Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp> Signed-off-by: Ralf Baechle <ralf@linux-mips.org>