aboutsummaryrefslogtreecommitdiff
path: root/drivers
AgeCommit message (Collapse)Author
2010-06-04Merge branch 'for-linus' of git://git.kernel.dk/linux-2.6-blockLinus Torvalds
* 'for-linus' of git://git.kernel.dk/linux-2.6-block: (27 commits) block: make blk_init_free_list and elevator_init idempotent block: avoid unconditionally freeing previously allocated request_queue pipe: change /proc/sys/fs/pipe-max-pages to byte sized interface pipe: change the privilege required for growing a pipe beyond system max pipe: adjust minimum pipe size to 1 page block: disable preemption before using sched_clock() cciss: call BUG() earlier Preparing 8.3.8rc2 drbd: Reduce verbosity drbd: use drbd specific ratelimit instead of global printk_ratelimit drbd: fix hang on local read errors while disconnected drbd: Removed the now empty w_io_error() function drbd: removed duplicated #includes drbd: improve usage of MSG_MORE drbd: need to set socket bufsize early to take effect drbd: improve network latency, TCP_QUICKACK drbd: Revert "drbd: Create new current UUID as late as possible" brd: support discard Revert "writeback: fix WB_SYNC_NONE writeback from umount" Revert "writeback: ensure that WB_SYNC_NONE writeback with sb pinned is sync" ...
2010-06-04Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6Linus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6: (27 commits) Staging: sep: return -EFAULT on copy_to_user errors Staging: rc2860: return -EFAULT on copy_to_user errors Staging: Eliminate a NULL pointer dereference staging: Use GFP_ATOMIC when a lock is held Staging: comedi - correct parameter gainlkup for DAQCard-6024E in driver ni_mio_cs.c Staging: comedi: fixing ni_labpc to mite dependancy Staging: wlags49_h2, wlags49_h25: fixed Kconfig dependencies Staging: phison: depends on ATA_BMDMA Staging: iio-utils: fix memory overflow for dynamically allocateded memory to hold filename Staging: adis16255: add proper section markings to hotplug funcs Staging: adis16255: fix typo in Kconfig Staging: batman-adv: Don't allocate icmp packet with GFP_KERNEL Staging: batman-adv: Don't call free_netdev twice Staging: batman-adv: Call unregister_netdev on failures to get rtnl lock Staging: batman-adv: fix rogue packets on shutdown Staging: add MSM framebuffer driver Staging: comedi: fixing ni_tio to mite PCI dependancy Staging: comedi: fix 8255 and DAS08 Kconfig dependancies. Staging: comedi: For COMEDI_BUFINFO, check access to command Staging: comedi: COMEDI_BUFINFO with no async - report no bytes read or written ...
2010-06-04Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty-2.6Linus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty-2.6: serial: add support for various Titan PCI cards vt_ioctl: return -EFAULT on copy_from_user errors serial: altera_uart: Proper section for altera_uart_remove tty: fix a little bug in scrup, vt.c altera_uart: Simplify altera_uart_console_putc altera_uart: Don't take spinlock in already protected functions TTY/n_gsm: potential double lock serial: bfin_5xx: fix typo in IER check serial: bfin_5xx: IRDA is not affected by anomaly 05000230 serial_cs: add and sort IDs for serial and modem cards msm_serial: fix serial on trout
2010-06-04Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6Linus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: USB: unbind all interfaces before rebinding them USB: serial: digi_acceleport: Eliminate a NULL pointer dereference usb: fix ehci_hcd build failure when both generic-OF and xilinx is selected USB: cdc-acm: fix resource reclaim in error path of acm_probe USB: ftdi_sio: fix DTR/RTS line modes USB: s3c-hsotg: Ensure FIFOs are fully flushed after layout USB: s3c-hsotg: SoftDisconnect minimum 3ms USB: s3c-hsotg: Ensure TX FIFO addresses setup when initialising FIFOs USB: s3c_hsotg: define USB_GADGET_DUALSPEED in Kconfig USB: s3c: Enable soft disconnect during initialization USB: xhci: Print NEC firmware version. USB: xhci: Wait for host to start running. USB: xhci: Wait for controller to be ready after reset. USB: isp1362: fix inw warning on Blackfin systems USB: mos7840: fix null-pointer dereference
2010-06-04omap: remove BUG_ON for disabled interruptsCory Maccarrone
Remove a BUG_ON for when interrupts are disabled during an MMC request. During boot, interrupts can be disabled when a request is made, causing this bug to be triggered. In reality, there's no reason this should halt the kernel, as the driver has proved reliable in spite of disabled interrupts, and additionally, there's nothing in this code that would require interrupts to be enabled. The only setup I've managed to make it trigger on is on the HTC Herald during bootup when the driver is built into the kernel (mostly because that's all I have). I believe it's related to the fact that on bootup I get many timeout errors on "CMD5" while initializing the card. Each CMD5 timeout triggers that bug (I changed it to a WARN_ON to get it to boot in) due to the fact that part of the timeout code involves sending the request again. With interrupts turned off, that BUG would be triggered. Signed-off-by: Cory Maccarrone <darkstar6262@gmail.com> Acked-by: Tony Lindgren <tony@atomide.com> Cc: <linux-mmc@vger.kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-06-04fbdev: fix frame buffer devices menuThadeu Lima de Souza Cascardo
Commit f601441916d1e19291d0b4f044b4a7551e2924d0 ("imxfb: add support for i.MX25:) has inserted the symbol HAVE_FB_IMX, which does not depend on FB after the menuconfig FB. This breaks the menu, presenting most of the drivers outside of it, when using menuconfig. Moving the symbol to the start of the file, just like HAVE_FB_ATMEL, fixes the problem without breaking it for iMX25 configurations (tested with ARCH=arm, no build). Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com> Cc: Sascha Hauer <s.hauer@pengutronix.de> Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Acked-by: Baruch Siach <baruch@tkos.co.il> Cc: "David S. Miller" <davem@davemloft.net> Cc: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-06-04fb_defio: redo fix for non-dirty ptesAlbert Herranz
As pointed by Nick Piggin, ->page_mkwrite provides a way to keep a page locked until the associated PTE is marked dirty. Re-implement the fix by using this mechanism. Signed-off-by: Albert Herranz <albert_herranz@yahoo.es> Acked-by: Jaya Kumar <jayakumar.lkml@gmail.com> Acked-by: Nick Piggin <npiggin@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-06-04Revert "fb_defio: fix for non-dirty ptes"Albert Herranz
This reverts commit 49bbd815fd8ba26d0354900b783b767c7f47c816 ("fb_defio: fix for non-dirty ptes"). Although the fix provided is correct, it's been suggested to avoid the underlying race in the same way as it is currently done in filesystems like NFS, for maintainability. A following patch "fb_defio: redo fix for non-dirty ptes" will provide such an alternate fix. Signed-off-by: Albert Herranz <albert_herranz@yahoo.es> Cc: Jaya Kumar <jayakumar.lkml@gmail.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>
2010-06-04vmware balloon: clamp number of collected non-balloonable pagesDmitry Torokhov
Limit number of accumulated non-balloonable pages during inflation cycle, otherwise there is a chance we will be spinning and growing the list forever. This happens during torture tests when balloon target changes while we are in the middle of inflation cycle and monitor starts refusing to lock pages (since they are not needed anymore). Signed-off-by: Dmitry Torokhov <dtor@vmware.com> Acked-by: Bhavesh Davda <bhavesh@vmware.com> Cc: <stable@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-06-04ramoops: add HAS_IOMEM dependencyHeiko Carstens
The driver fails to compile on s390: drivers/char/ramoops.c: In function 'ramoops_init': drivers/char/ramoops.c:122: error: implicit declaration of function 'ioremap' Since we won't make use of the driver anyway on s390 just let it depend on HAS_IOMEM. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: Marco Stornelli <marco.stornelli@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-06-04rtc: s3c: initialize s3c_rtc_cpu_type before using itMaurus Cuelenaere
Make sure s3c_rtc_cpu_type is initialised _before_ it's used in an if() check. Reported-by: Jiri Pinkava <jiri.pinkava@vscht.cz> Signed-off-by: Maurus Cuelenaere <mcuelenaere@gmail.com> Cc: Paul Gortmaker <p_gortmaker@yahoo.com> Cc: Alessandro Zummo <a.zummo@towertech.it> Cc: Maurus Cuelenaere <mcuelenaere@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-06-04rtc: s3c: initialize driver data before using itMaurus Cuelenaere
s3c_rtc_setfreq() uses the platform driver data to derive struct rtc_device, so make sure drvdata is set _before_ s3c_rtc_setfreq() is called. Signed-off-by: Maurus Cuelenaere <mcuelenaere@gmail.com> Cc: Paul Gortmaker <p_gortmaker@yahoo.com> Cc: Alessandro Zummo <a.zummo@towertech.it> Cc: Maurus Cuelenaere <mcuelenaere@gmail.com> Cc: <stable@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-06-04Staging: sep: return -EFAULT on copy_to_user errorsDan Carpenter
copy_to_user() returns the number of bytes remaining but we want to return a negative error code here. These functions are used in the ioctl handler and the error code gets returned to userspace. Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: rc2860: return -EFAULT on copy_to_user errorsDan Carpenter
copy_to_user() returns the number of bytes remaining but we want to return a negative error code. This is in the ioctl handler and the error code gets passed to userspace. Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: Eliminate a NULL pointer dereferenceJulia Lawall
Eliminate a NULL or near NULL pointer dereference. A simplified version of the semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @r exists@ expression E,E1; identifier f; statement S1,S2,S3; @@ if ((E == NULL && ...) || ...) { ... when != if (...) S1 else S2 when != E = E1 * E->f ... when any return ...; } else S3 // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04staging: Use GFP_ATOMIC when a lock is heldJulia Lawall
In each case, the containing function is only called from one place, where a spin lock is held. The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // <smpl> @gfp exists@ identifier fn; position p; @@ fn(...) { ... when != spin_unlock when any GFP_KERNEL@p ... when any } @locked@ identifier gfp.fn; @@ spin_lock(...) ... when != spin_unlock fn(...) @depends on locked@ position gfp.p; @@ - GFP_KERNEL@p + GFP_ATOMIC // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Cc: Jonathan Cameron <jic23@cam.ac.uk> Cc: Marek Lindner <lindner_marek@yahoo.de> Cc: Martyn Welch <martyn.welch@ge.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi - correct parameter gainlkup for DAQCard-6024E in driver ↵Martin Homuth-Rosemann
ni_mio_cs.c Correct at least one of the incorrect specs for a national instrument data acquisition card DAQCard-6024E. This card has only four different gain settings (+-10V, +-5V, +-0.5V, +-0.05V). Signed-off-by: Martin Homuth-Rosemann <homuth-rosemann@gmx.net> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi: fixing ni_labpc to mite dependancyAlexander Kurz
the dependancy of ni_labpc on mite was missing, Signed-off-by: Alexander Kurz <linux@kbdbabel.org> Acked-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> index 0aa2b0d..79f5f2e 100644
2010-06-04Staging: wlags49_h2, wlags49_h25: fixed Kconfig dependenciesHenk de Groot
Fixes Kconfig so the wlags49_h2 and wlags49_h25 drivers can be selected from menuconfig without having to select another WLAN driver first. Before it could only be selected when another driver already selected WIRELESS_EXT. Also adds WEXT_PRIV on which the driver also depends. Align help text in Kconfig. Signed-off-by: Henk de Groot <pe1dnn@amsat.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: phison: depends on ATA_BMDMARandy Dunlap
phison uses interfaces and data that are built only when ATA_BMDMA is enabled, so it should depend on that symbol. drivers/staging/phison/phison.c:43: error: implicit declaration of function 'ATA_BMDMA_SHT' drivers/staging/phison/phison.c:43: error: initializer element is not constant drivers/staging/phison/phison.c:43: error: (near initialization for 'phison_sht.module') drivers/staging/phison/phison.c:47: error: 'ata_bmdma_port_ops' undeclared here (not in a function) Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Cc: evan_ko@phison.com Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: iio-utils: fix memory overflow for dynamically allocateded memory ↵Barry Song
to hold filename Signed-off-by: Barry Song <21cnbao@gmail.com> Acked-by: Jonathan Cameron <jic23@cam.ac.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: adis16255: add proper section markings to hotplug funcsMike Frysinger
Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: adis16255: fix typo in KconfigMike Frysinger
Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: batman-adv: Don't allocate icmp packet with GFP_KERNELSven Eckelmann
A new buffer for a packet is created when a icmp packet is received. This happens in a context with disabled irq. Thus we are not allowed to sleep or call function which might sleep. kmalloc must be called with GFP_ATOMIC instead of GFP_KERNEL to ensure that it does not sleep. Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: batman-adv: Don't call free_netdev twiceSven Eckelmann
Free_netdev is registered as destructor in interface_setup for every soft_device. This destructor is automatically called from unregister_netdev and we must not call it again for the freed net_device. Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: batman-adv: Call unregister_netdev on failures to get rtnl lockSven Eckelmann
We must call unregister_netdev when we couldn't initialise the batman-adv module and the soft_device was registered. There are two version of the function which we can use: * unregister_netdevice - removes device * unregister_netdev - takes rtnl semaphore and remove device We don't hold the semaphore in an error situation. So we must use unregister_netdev. Signed-off-by: Sven Eckelmann <sven.eckelmann@gmx.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: batman-adv: fix rogue packets on shutdownMarek Lindner
On module shutdown batman-adv would purge the internal packet queue by sending all remaining packets which could confuse other nodes. Now, the packets are silently discarded. 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-06-04Staging: add MSM framebuffer driverStepan Moskovchenko
Qualcomm development of the MSM SOC framebuffer driver has diverged significantly from the driver used by Android. This is a snapshot of our current driver, in all it's agony. We are putting this in staging to help with the process of converging the two drivers. At this point, the driver has been tested only in dumb framebuffer mode. Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org> Signed-off-by: David Brown <davidb@codeaurora.org> Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org> [dwalker@codeaurora.org: added a small compile fix and TODO.] Signed-off-by: Daniel Walker <dwalker@codeaurora.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi: fixing ni_tio to mite PCI dependancyAlexander Kurz
On Wed, 19 May 2010, Randy Dunlap wrote: > linux-next of 2010-0519: > when CONFIG_PCI is not enabled: > > drivers/staging/comedi/drivers/mite.c: In function 'mite_init': > drivers/staging/comedi/drivers/mite.c:89: error: implicit declaration of function 'pci_dev_get' > drivers/staging/comedi/drivers/mite.c:89: warning: assignment makes pointer from integer without a cast > make[5]: *** [drivers/staging/comedi/drivers/mite.o] Error 1 This patch fixes the problem. Signed-off-by: Alexander Kurz <linux@kbdbabel.org> Acked-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi: fix 8255 and DAS08 Kconfig dependancies.Alexander Kurz
Both drivers support directly or indirectly multiple bus types, hence both are listed independent of bus types. Signed-off-by: Alexander Kurz <linux@kbdbabel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi: For COMEDI_BUFINFO, check access to commandIan Abbott
Don't allow COMEDI_BUFINFO ioctl if some other file object has locked the subdevice or has an active command. If there is no active command, just report back the last buffer position. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi: COMEDI_BUFINFO with no async - report no bytes read or writtenIan Abbott
When the COMEDI_BUFINFO ioctl is used on a subdevice without asynchronous streaming command support, set 'bytes_read = 0' and 'bytes_written = 0' in the buffer info returned back to the user. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi: don't write to buffer if command finishedIan Abbott
For write(), any data copied to the data buffer after the previously set up streaming acquisition command has finished won't be used, but a non-empty write() does not currently return 0 (or -EPIPE on error) after the command has finished until the data buffer has been filled up. Change this behavior to return 0 (or -EPIPE) any time after the command has finished, without bothering to fill up the buffer with more useless data. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi: amplc_dio200: Protect counter subdevice with spinlockIan Abbott
The internal state of an 82C54 counter timer chip will get messed up if several threads read, write, configure, or check the status of the chip simultaneously. Protect the register access sequences with a spin lock. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi: adv_pci_dio: Support Advantech PCI-1735UIan Abbott
Add support for the Advantech PCI-1735U card, including support for a counter subdevice (based on an 82C54 counter timer chip). The counter subdevice needs more testing, as the only person I know who tried it couldn't get it to work! Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi: addi-data: don't overwrite name for request_irq()Ian Abbott
The Addi-Data PCI drivers for Comedi use sprintf() in their comedi "attach" routine to construct a string to pass as the name in the call to request_irq(). All calls to "attach" routine share the same static buffer for this name, but the contents will differ on each call (including the comedi device number and the comedi board name). This changes the name displayed in /proc/interrupts for previous calls to request_irq() using the same buffer. Just use the board name instead; it has slightly less information (no comedi device number) but at least it doesn't change over the lifetime of the IRQ handler. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: comedi: Give the addi_apci_* drivers different driver namesIan Abbott
It is not currently possible for more than one of the addi_apci_* drivers to register themselves with comedi at once because they all use the same comedi driver name "addi_common". Give them different names. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04Staging: mid: Intel MID touch screen driverSreedhara DS
Touchscreen driver used by intel mid devices. Some clean up by Alan Cox. This driver is basically ready for upstreaming properly but is tied wrongly to the SPI layer and needs firmware/SFI changes to fix that. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04staging: Add framebuffer driver for XGI chipsetsapatard@mandriva.com
This driver handles XG20, XG21, XG40, XG42 chipsets from XGI. They're also known as Z7,Z9,Z11 chipsets. It's based on the SiS fb driver but has been heavily modified by XGI to support their newer chipsets. Signed-off-by: Arnaud Patard <apatard@mandriva.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04serial: add support for various Titan PCI cardsYegor Yefremov
serial: add support for various Titan PCI cards Models: 200I, 400I, 800I, 400EH, 800EH, 800EHB, 100E, 200E, 400E, 800E, 200EI, 200EISI Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04vt_ioctl: return -EFAULT on copy_from_user errorsDan Carpenter
copy_from_user() returns the number of bytes remaining 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-06-04serial: altera_uart: Proper section for altera_uart_removeTobias Klauser
altera_uart_remove should be in .devexit.text Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04tty: fix a little bug in scrup, vt.cFrank Pan
The code uses vc->vc_cols instead of vc->vc_size_row by mistake, it will cause half of the region which is going to clear remain uncleared. The issue happens in background consoles, so it's hard to observe. Frank Pan Signed-off-by: Frank Pan <frankpzh@gmail.com> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04altera_uart: Simplify altera_uart_console_putcTobias Klauser
The check for the TRDY flag after writing the character is not needed. Also do a cpu_relax() inside the loop. Pass a struct uart_port to altera_uart_console_putc, so we do not need to get it (and dereference pointers) for every character. Cc: Thomas Chou <thomas@wytron.com.tw> Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04altera_uart: Don't take spinlock in already protected functionsTobias Klauser
Don't take the port spinlock in uart functions where the serial core already takes care of locking/unlocking them. The code would actually lock up on architectures where spinlocks are implemented (not the case on nios2 where this driver is primarily used for now, thus this bug didn't trigger). Also protect calling altera_uart_rx_chars/altera_uart_tx_chars in the interrupt handler by the port spinlock. Thanks to Ian Abbott for pointing these issues out. Cc: Ian Abbott <abbotti@mev.co.uk> Cc: Thomas Chou <thomas@wytron.com.tw> Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04TTY/n_gsm: potential double lockDan Carpenter
In gsm_dlci_data_kick() we call gsm_dlci_data_sweep() with the "gsm->tx_lock" held so we can't lock it again inside gsm_dlci_data_sweep(). I removed that lock from and added one to gsmld_write_wakeup() instead. The sweep function is only called from those two places. Signed-off-by: Dan Carpenter <error27@gmail.com> Acked-by: Alan Cox <alan@linux.intel.com> Cc: stable <stable@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04serial: bfin_5xx: fix typo in IER checkSonic Zhang
This most likely won't cause problems on systems as people don't typically enable GPIO RTS/CTS if they don't actually use it. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04serial: bfin_5xx: IRDA is not affected by anomaly 05000230Graf Yang
Anomaly 05000230 (over sampling of the UART STOP bit) applies only when the peripheral is operating in UART mode. So drop the anomaly handling when the UART is in IRDA mode. Signed-off-by: Graf Yang <graf.yang@analog.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04serial_cs: add and sort IDs for serial and modem cardsAlexander Kurz
Signed-off-by: Alexander Kurz <linux@kbdbabel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2010-06-04msm_serial: fix serial on troutAbhijeet Dharmapurikar
Set the mnd counter based on uartclk. This fixes a problem on 7x30 where the uartclk is 19.2Mhz rather than the usual 4.8Mhz. Trout incorrectly reports uartclk to be running at 19.2Mhz It is actually running at 4.8Mhz. For trout force mnd counter values as if uartclk was fed by tcxo/4. Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org> [dwalker@codeaurora.org: inlined, moved into header, added comments.] Signed-off-by: Daniel Walker <dwalker@codeaurora.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>