summaryrefslogtreecommitdiffstats
path: root/drivers/char/rio
Commit message (Collapse)AuthorAgeFilesLines
* rio: typo in bitwise AND expression.Willy Tarreau2007-02-171-1/+1
| | | | | | | | | | | | | | | The line : hp->Mode &= !RIO_PCI_INT_ENABLE; is obviously wrong as RIO_PCI_INT_ENABLE=0x04 and is used as a bitmask 2 lines before. Getting no IRQ would not disable RIO_PCI_INT_ENABLE but rather RIO_PCI_BOOT_FROM_RAM which equals 0x01. Obvious fix is to change ! for ~. Signed-off-by: Willy Tarreau <w@1wt.eu> Signed-off-by: Adrian Bunk <bunk@stusta.de>
* [PATCH] Char: timers cleanupJiri Slaby2007-02-121-8/+4
| | | | | | | | | | | | | | | | | | | | | - Use timer macros to set function and data members and to modify expiration time. - Use DEFINE_TIMER for global timers and do not init them at run-time in these cases. - del_timer_sync is common in most cases -- we want to wait for timer function if it's still running. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Cc: Dave Airlie <airlied@linux.ie> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Dominik Brodowski <linux@dominikbrodowski.net> Cc: Alessandro Zummo <a.zummo@towertech.it> Cc: Paul Fulghum <paulkf@microgate.com> Cc: Kylene Jo Hall <kjhall@us.ibm.com> Cc: Wim Van Sebroeck <wim@iguana.be> Acked-by: Dmitry Torokhov <dtor@mail.ru> (Input bits) Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* [PATCH] Char: tty_wakeup cleanupJiri Slaby2007-02-111-7/+2
| | | | | | | | | | | | | | tty_wakeup cleanup - remove wake_up_interruptible(&tty->write_wait) surrounding tty_wakup(tty); - substitute tty->ldisc.write_wakeup(tty) + wake_up() by tty_wakeup(tty); Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Acked-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* [PATCH] getting rid of all casts of k[cmz]alloc() callsRobert P. J. Day2006-12-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Run this: #!/bin/sh for f in $(grep -Erl "\([^\)]*\) *k[cmz]alloc" *) ; do echo "De-casting $f..." perl -pi -e "s/ ?= ?\([^\)]*\) *(k[cmz]alloc) *\(/ = \1\(/" $f done And then go through and reinstate those cases where code is casting pointers to non-pointers. And then drop a few hunks which conflicted with outstanding work. Cc: Russell King <rmk@arm.linux.org.uk>, Ian Molton <spyro@f2s.com> Cc: Mikael Starvik <starvik@axis.com> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Cc: Roman Zippel <zippel@linux-m68k.org> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Kyle McMartin <kyle@mcmartin.ca> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: "David S. Miller" <davem@davemloft.net> Cc: Jeff Dike <jdike@addtoit.com> Cc: Greg KH <greg@kroah.com> Cc: Jens Axboe <jens.axboe@oracle.com> Cc: Paul Fulghum <paulkf@microgate.com> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Cc: Karsten Keil <kkeil@suse.de> Cc: Mauro Carvalho Chehab <mchehab@infradead.org> Cc: Jeff Garzik <jeff@garzik.org> Cc: James Bottomley <James.Bottomley@steeleye.com> Cc: Ian Kent <raven@themaw.net> Cc: Steven French <sfrench@us.ibm.com> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Neil Brown <neilb@cse.unsw.edu.au> Cc: Jaroslav Kysela <perex@suse.cz> Cc: Takashi Iwai <tiwai@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] ioremap balanced with iounmap for drivers/char/rio/rio_linux.cAmol Lad2006-12-071-1/+7
| | | | | | | Signed-off-by: Amol Lad <amol@verismonetworks.com> Acked-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* Fix misc .c/.h comment typosMatt LaPlante2006-11-303-5/+5
| | | | | | | Fix various .c/.h typos in comments (no code changes). Signed-off-by: Matt LaPlante <kernel1@cyberdogtech.com> Signed-off-by: Adrian Bunk <bunk@stusta.de>
* [PATCH] Char: correct pci_get_device changesJiri Slaby2006-10-212-0/+10
| | | | | | | | | | | | | | | | | | | | | | Commits 881a8c120acf7ec09c90289e2996b7c70f51e996 and efe1ec27837d6639eae82e1f5876910ba6433c3f corrects pci device matching in only one way; it no longer oopses/crashes, despite hotplug is not solved in these changes. Whenever pci_find_device -> pci_get_device change is performed, also pci_dev_get and pci_dev_put should be in most cases called to properly handle hotplug. This patch does exactly this thing -- increase refcount to let kernel know, that we are using this piece of HW just now. It affects moxa and rio char drivers. Cc: <R.E.Wolff@BitWizard.nl> Acked-by: Amit Gud <gud@eth.net> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Acked-by: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] rio: fix array checkingAlan Cox2006-10-161-2/+2
| | | | | | | Found by an analysis tool and reported to the list. Fix is simple enough Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* Various drivers' irq handlers: kill dead code, needless castsJeff Garzik2006-10-063-4/+4
| | | | | | | | | | | | | | | | - Eliminate casts to/from void* - Eliminate checks for conditions that never occur. These typically fall into two classes: 1) Checking for 'dev_id == NULL', then it is never called with NULL as an argument. 2) Checking for invalid irq number, when the only caller (the system) guarantees the irq handler is called with the proper 'irq' number argument. Signed-off-by: Jeff Garzik <jeff@garzik.org>
* IRQ: Maintain regs pointer globally rather than passing to IRQ handlersDavid Howells2006-10-051-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Maintain a per-CPU global "struct pt_regs *" variable which can be used instead of passing regs around manually through all ~1800 interrupt handlers in the Linux kernel. The regs pointer is used in few places, but it potentially costs both stack space and code to pass it around. On the FRV arch, removing the regs parameter from all the genirq function results in a 20% speed up of the IRQ exit path (ie: from leaving timer_interrupt() to leaving do_IRQ()). Where appropriate, an arch may override the generic storage facility and do something different with the variable. On FRV, for instance, the address is maintained in GR28 at all times inside the kernel as part of general exception handling. Having looked over the code, it appears that the parameter may be handed down through up to twenty or so layers of functions. Consider a USB character device attached to a USB hub, attached to a USB controller that posts its interrupts through a cascaded auxiliary interrupt controller. A character device driver may want to pass regs to the sysrq handler through the input layer which adds another few layers of parameter passing. I've build this code with allyesconfig for x86_64 and i386. I've runtested the main part of the code on FRV and i386, though I can't test most of the drivers. I've also done partial conversion for powerpc and MIPS - these at least compile with minimal configurations. This will affect all archs. Mostly the changes should be relatively easy. Take do_IRQ(), store the regs pointer at the beginning, saving the old one: struct pt_regs *old_regs = set_irq_regs(regs); And put the old one back at the end: set_irq_regs(old_regs); Don't pass regs through to generic_handle_irq() or __do_IRQ(). In timer_interrupt(), this sort of change will be necessary: - update_process_times(user_mode(regs)); - profile_tick(CPU_PROFILING, regs); + update_process_times(user_mode(get_irq_regs())); + profile_tick(CPU_PROFILING); I'd like to move update_process_times()'s use of get_irq_regs() into itself, except that i386, alone of the archs, uses something other than user_mode(). Some notes on the interrupt handling in the drivers: (*) input_dev() is now gone entirely. The regs pointer is no longer stored in the input_dev struct. (*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking. It does something different depending on whether it's been supplied with a regs pointer or not. (*) Various IRQ handler function pointers have been moved to type irq_handler_t. Signed-Off-By: David Howells <dhowells@redhat.com> (cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)
* [PATCH] const struct tty_operationsJeff Dike2006-10-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | As part of an SMP cleanliness pass over UML, I consted a bunch of structures in order to not have to document their locking. One of these structures was a struct tty_operations. In order to const it in UML without introducing compiler complaints, the declaration of tty_set_operations needs to be changed, and then all of its callers need to be fixed. This patch declares all struct tty_operations in the tree as const. In all cases, they are static and used only as input to tty_set_operations. As an extra check, I ran an i386 allyesconfig build which produced no extra warnings. 53 drivers are affected. I checked the history of a bunch of them, and in most cases, there have been only a handful of maintenance changes in the last six months. serial_core.c was the busiest one that I looked at. Signed-off-by: Jeff Dike <jdike@addtoit.com> Acked-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] make more file_operation structs staticArjan van de Ven2006-07-031-1/+1
| | | | | | | | | | | | Mark the static struct file_operations in drivers/char as const. Making them const prevents accidental bugs, and moves them to the .rodata section so that they no longer do any false sharing; in addition with the proper debug option they are then protected against corruption.. [akpm@osdl.org: build fix] Signed-off-by: Arjan van de Ven <arjan@linux.intel.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] irq-flags: rio: Use the new IRQF_ constantsThomas Gleixner2006-07-021-1/+1
| | | | | | | | | Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@elte.hu> Cc: "David S. Miller" <davem@davemloft.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* Remove obsolete #include <linux/config.h>Jörn Engel2006-06-303-3/+0
| | | | | Signed-off-by: Jörn Engel <joern@wohnheim.fh-wedel.de> Signed-off-by: Adrian Bunk <bunk@stusta.de>
* spelling fixesAndreas Mohr2006-06-261-1/+1
| | | | | | | | | | | | acquired (aquired) contiguous (contigious) successful (succesful, succesfull) surprise (suprise) whether (weather) some other misspellings Signed-off-by: Andreas Mohr <andi@lisas.de> Signed-off-by: Adrian Bunk <bunk@stusta.de>
* [PATCH] missing readb/readw in rioAl Viro2006-05-273-24/+24
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* [PATCH] copy_to_user() from iomem is a bad thingAl Viro2006-05-271-4/+16
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* [PATCH] forgotten swap of copyout() argumentsAl Viro2006-05-271-1/+1
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* [PATCH] handling rio MEMDUMPAl Viro2006-05-271-1/+1
| | | | | | | it copies data _from_ iomem, so it should be rio_memcpy_fromio(), not ->Copy(). Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* [PATCH] fix rio_copy_to_card() for OLDPCI caseAl Viro2006-05-272-2/+14
| | | | | | | | It replaced old rio_pcicopy(). That puppy did _not_ do readb() (unlike rio_memcpy_toio()) and current implementation is simply broken - readb(NULL) is never a valid thing to do. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* [PATCH] uses of ->Copy() in rioroute are bogusAl Viro2006-05-271-5/+5
| | | | | | | ... there we are building a command in normal memory; it will be copied to iomem (by ->Copy()) later. Use memcpy()... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* [PATCH] bogus order of copy_from_user() argumentsAl Viro2006-05-271-1/+1
| | | | | | ... aka "somebody forgot to swap arguments when converting from copyin()" Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* [PATCH] rio ->Copy() expects the sourse as first argumentAl Viro2006-05-272-2/+2
| | | | | | | ... so conversion from rio_pcicopy() to rio_copy_to_card() had broken the damn thing. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* [PATCH] trivial annotations in rioAl Viro2006-05-2717-230/+228
| | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* [PATCH] Final rio polishAlan Cox2006-05-154-75/+34
| | | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Yet more rio cleaning (2 of 2)Alan Cox2006-03-2418-912/+265
| | | | | | | | | | | | | | - Remove more unused headers - Remove various typedefs - Correct type of PaddrP (physical addresses should be ulong) - Kill use of bcopy - More printk cleanups - Kill true/false - Clean up direct access to pci BARs Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Yet more rio cleaning (1 of 2)Alan Cox2006-03-2415-524/+36
| | | | | | | | | | | | | | - Remove more unused headers - Remove various typedefs - Correct type of PaddrP (physical addresses should be ulong) - Kill use of bcopy - More printk cleanups - Kill true/false - Clean up direct access to pci BARs Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] rio driver rework continued #5Alan Cox2006-03-242-9/+1
| | | | | | | | | Final polish. There is no more save_flags/cli type locking left. We also no longer use the pcicopy function and file so they can go. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] rio driver rework continued #4Alan Cox2006-03-241-272/+118
| | | | | | | | | | | | Third large chunk of code cleanup. The split between this and #3 and #4 is fairly arbitary and due to the message length limit on the list. These patches continue the process of ripping out macros and typedefs while cleaning up lots of 32bit assumptions. Several inlines for compatibility also get removed and that causes a lot of noise. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] rio driver rework continued #3Alan Cox2006-03-247-535/+232
| | | | | | | | | | | | Second large chunk of code cleanup. The split between this and #3 and #4 is fairly arbitary and due to the message length limit on the list. These patches continue the process of ripping out macros and typedefs while cleaning up lots of 32bit assumptions. Several inlines for compatibility also get removed and that causes a lot of noise. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] rio driver rework continued #2Alan Cox2006-03-244-154/+115
| | | | | | | | | | | | First large chunk of code cleanup. The split between this and #3 and #4 is fairly arbitary and due to the message length limit on the list. These patches continue the process of ripping out macros and typedefs while cleaning up lots of 32bit assumptions. Several inlines for compatibility also get removed and that causes a lot of noise. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] rio driver rework continued #1Alan Cox2006-03-2410-167/+118
| | | | | | | | | | | | | More header cleanups, strip out typedefs and remove cruft. There are a lot of magic macros that can go and also a great deal of abuse of volatile that is not needed any more as this patch set cleans up the misuse of pointer access to ISA and PCI space. It now builds cleanly on 64bit, although there is more work left to do Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] rioboot: post-LindentAlan Cox2006-03-241-252/+177
| | | | | | | | | After the indent we can now clean up unused code, and fix all myriad cases that don't use readb/writeb properly. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] rioboot: lindentAlan Cox2006-03-241-811/+704
| | | | | | | | This is the result of indent -kr -i8 -bri0 -l255 Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] rio: more header cleanupAlan Cox2006-03-2410-400/+243
| | | | | | | | | Strip some of the typedef mess out Remove a small subset of unused defines and the like. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] rio cleanupsAlan Cox2006-02-0311-567/+0
| | | | | | | | | | | | INKERNEL is always defined HOST is never defined therefore RTA is also never defined Strip the relevant garbage out of the headers on this basis. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove unused code from rioctrl.c (Last for this batch of work)Alan Cox2006-01-161-110/+1
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove rio_table.c unused codeAlan Cox2006-01-161-8/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove unused code from rio_linux.cAlan Cox2006-01-161-60/+0
| | | | Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove unused CHECK code from riocmd.cAlan Cox2006-01-161-30/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove unused code from rioroute.hAlan Cox2006-01-161-24/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove unused code from rioboot.hAlan Cox2006-01-161-61/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove unused code from riobootAlan Cox2006-01-161-1152/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove #if 0 and other long dead code from rio_ttyAlan Cox2006-01-161-583/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove long dead #if 0 code from rio_paramAlan Cox2006-01-161-43/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove old firmware headers from rio driversAlan Cox2006-01-164-235/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove rtahw.h from rio driver (unused file)Alan Cox2006-01-161-75/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove file riscos.h from rio driver (unused file)Alan Cox2006-01-161-63/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove file riowinif.h from rio driver (unused file)Alan Cox2006-01-161-1329/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] Remove riotime.h from rio driver (unused file)Alan Cox2006-01-161-63/+0
| | | | | Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
OpenPOWER on IntegriCloud