aboutsummaryrefslogtreecommitdiff
path: root/drivers/isdn/gigaset
AgeCommit message (Collapse)Author
2008-10-13tty: fix up gigaset a bitAlan Cox
Stephen's fixes reminded me that gigaset is still rather broken so fix it up a bit Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-10-13tty: Fallout from tty-move-canon-specialsStephen Rothwell
Today's linux-next build (x86_64 allmodconfig) failed like this: /drivers/char/tty_ioctl.c: In function 'change_termios': drivers/isdn/capi/capi.c:1234: error: implicit declaration of function 'n_tty_ioctl' drivers/isdn/gigaset/ser-gigaset.c: In function 'gigaset_tty_ioctl': drivers/isdn/gigaset/ser-gigaset.c:648: error: implicit declaration of function 'n_tty_ioctl' Introduced by commit 686b5e4aea05a80e370dc931b7f4a8d03c80da54 ("tty-move-canon-specials"). I added the following patch (which may not be correct). Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-30isdn: use the common ascii hex helpersHarvey Harrison
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2008-07-24gigaset: gigaset_isowbuf_getbytes() may return signed unnoticedTilman Schmidt
ifd->offset is unsigned. gigaset_isowbuf_getbytes() may return signed unnoticed. Revised version of patch originally submitted by Roel Kluin <12o3l@tiscali.nl>. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24gigaset: use dev_ macros for messagesTilman Schmidt
The info() / warn() / err() macros from usb.h for generating kernel messages are considered inferior to dev_info() / dev_warn() / dev_err() from device.h. Replace them where possible. Also correct the severity level and improve the text of one message. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-20tty: Ldisc revampAlan Cox
Move the line disciplines towards a conventional ->ops arrangement. For the moment the actual 'tty_ldisc' struct in the tty is kept as part of the tty struct but this can then be changed if it turns out that when it all settles down we want to refcount ldiscs separately to the tty. Pull the ldisc code out of /proc and put it with our ldisc code. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-04-30tty: The big operations reworkAlan Cox
- Operations are now a shared const function block as with most other Linux objects - Introduce wrappers for some optional functions to get consistent behaviour - Wrap put_char which used to be patched by the tty layer - Document which functions are needed/optional - Make put_char report success/fail - Cache the driver->ops pointer in the tty as tty->ops - Remove various surplus lock calls we no longer need - Remove proc_write method as noted by Alexey Dobriyan - Introduce some missing sanity checks where certain driver/ldisc combinations would oops as they didn't check needed methods were present [akpm@linux-foundation.org: fix fs/compat_ioctl.c build] [akpm@linux-foundation.org: fix isicom] [akpm@linux-foundation.org: fix arch/ia64/hp/sim/simserial.c build] [akpm@linux-foundation.org: fix kgdb] Signed-off-by: Alan Cox <alan@redhat.com> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Cc: Jason Wessel <jason.wessel@windriver.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-03-07gigaset: fix Oops on module unload regressionTilman Schmidt
The card state mutex was only initialized when a device was connected, but used during unload unconditionally, leading to an Oops if a driver was loaded and unloaded again without ever connecting a device. Fix this by initializing the mutex as soon as the structure is allocated. Also add a missing mutex unlock revealed in the same execution path. This fixes a possible Oops in 2.6.25-rc that was introduced by commit e468c04894f36045cf93d1384183a461014b6840 ("Gigaset: permit module unload"). Thanks to Roland Kletzing for reporting this problem. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Tested-by: Roland Kletzing <devzero@web.de> Cc: Hansjoerg Lipp <hjlipp@web.de> Cc: Karsten Keil <kkeil@suse.de> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-06ser_gigaset: convert mutex to completionTilman Schmidt
The ser_gigaset ISDN driver was using a mutex in its close() method for waiting for other running ldisc methods to finish. That's what completions are for. Incidentally, this also avoids a spurious "BUG: lock held at task exit time" message when the driver's userspace daemon daemonizes itself. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-06Gigaset: permit module unloadTilman Schmidt
Fix the initialization and reference counting of the Gigaset driver modules so that they can be unloaded when they are not actually in use. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Cc: Hansjoerg Lipp <hjlipp@web.de> Cc: Greg KH <gregkh@suse.de> Cc: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-06gigaset: atomic cleanupTilman Schmidt
Convert atomic_t variables that don't actually use atomic_t functionality to int. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-06usb_gigaset: suspend supportTilman Schmidt
Add basic suspend/resume support to the usb_gigaset driver for the Siemens Gigaset M105 USB DECT adapter. Only the USB aspects are handled so far; the ISDN subsystem is not notified in any way, for lack of information about how to do that. The driver does not check for active connections before suspending. They will be dropped when the device loses USB power. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Cc: Greg KH <gregkh@suse.de> Cc: Hansjoerg Lipp <hjlipp@web.de> Cc: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-06bas_gigaset: suspend supportTilman Schmidt
Add basic suspend/resume support to the bas_gigaset ISDN driver for the Siemens Gigaset SX255 series of ISDN DECT bases. Only the USB aspects are handled so far; the ISDN subsystem is not notified in any way, for lack of information about how to do that. The driver will refuse to suspend if a connection is active. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Cc: Greg KH <gregkh@suse.de> Cc: Hansjoerg Lipp <hjlipp@web.de> Cc: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-06gigaset: code cleanupsTilman Schmidt
Some cleanups to the bas-gigaset and usb-gigaset USB ISDN drivers: - simplified error handling - improved debug messages - readability improvements - removal of obsolete defines and comments Signed-off-by: Tilman Schmidt <tilman@imap.cc> Cc: Greg KH <gregkh@suse.de> Cc: Hansjoerg Lipp <hjlipp@web.de> Cc: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-06gigaset: clean up urb->status usageTilman Schmidt
Make there only be one reference to urb->status per URB callback, and none outside, in preparation for removal of that field. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Cc: Greg KH <gregkh@suse.de> Cc: Hansjoerg Lipp <hjlipp@web.de> Cc: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-01-24driver core: Make the dev_*() family of macros in device.h completeEmil Medve
Removed duplicates defined elsewhere Signed-off-by: Emil Medve <Emilian.Medve@Freescale.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-10-18Add missing newlines to some uses of dev_<level> messagesJoe Perches
Found these while looking at printk uses. Add missing newlines to dev_<level> uses Add missing KERN_<level> prefixes to multiline dev_<level>s Fixed a wierd->weird spelling typo Added a newline to a printk Signed-off-by: Joe Perches <joe@perches.com> Cc: "Luck, Tony" <tony.luck@intel.com> Cc: Jens Axboe <jens.axboe@oracle.com> Cc: Mark M. Hoffman <mhoffman@lightlink.com> Cc: Roland Dreier <rolandd@cisco.com> Cc: Tilman Schmidt <tilman@imap.cc> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Jeff Garzik <jeff@garzik.org> Cc: Stephen Hemminger <shemminger@linux-foundation.org> Cc: Greg KH <greg@kroah.com> Cc: Jeremy Fitzhardinge <jeremy@goop.org> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Alessandro Zummo <a.zummo@towertech.it> Cc: David Brownell <david-b@pacbell.net> Cc: James Smart <James.Smart@Emulex.Com> Cc: Andrew Vasquez <andrew.vasquez@qlogic.com> Cc: "Antonino A. Daplas" <adaplas@pol.net> Cc: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Cc: Russell King <rmk@arm.linux.org.uk> Cc: Jaroslav Kysela <perex@suse.cz> Cc: Takashi Iwai <tiwai@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-10-16gigaset: remove pointless lockingTilman Schmidt
Remove pointless taking of spinlock around reading a single pointer-sized or smaller variable. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-21Use menuconfig objects: ISDN/GigasetJan Engelhardt
Change Kconfig objects from "menu, config" into "menuconfig" so that the user can disable the whole feature without having to enter the menu first. Signed-off-by: Jan Engelhardt <jengelh@gmx.de> Cc: Tilman Schmidt <tilman@imap.cc> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-21Use menuconfig objects - CONFIG_ISDN_I4LTilman Schmidt
Remove a menu statement and several dependencies from the Kconfig files in the drivers/isdn tree as they have become unnecessary by the transformation of CONFIG_ISDN from "menu, config" into "menuconfig". (Modified version of a patch originally proposed by Jan Engelhardt.) Signed-off-by: Tilman Schmidt <tilman@imap.cc> Cc: Jan Engelhardt <jengelh@computergmbh.de> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-05-08usb_gigaset: don't kmalloc(0)Tilman Schmidt
Zero-sized allocations are pointless anyway, and the SLUB allocator complains about them, so stop doing that. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Hansjoerg Lipp <hjlipp@web.de> Cc: Greg KH <greg@kroah.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-04-25[SK_BUFF]: Introduce skb_copy_from_linear_data{_offset}Arnaldo Carvalho de Melo
To clearly state the intent of copying from linear sk_buffs, _offset being a overly long variant but interesting for the sake of saving some bytes. Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2007-03-29[PATCH] drivers/isdn/gigaset: mark some static data as const (v2)Tilman Schmidt
Mark some static arrays as const that aren't and shouldn't be modified, and remove incorrect static attribute from some variables. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Hansjoerg Lipp <hjlipp@web.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-01[PATCH] drivers/isdn/gigaset: build asyncdata.o into the gigaset module (fix)Tilman Schmidt
a) Remove #define acrobatics that have become unnecessary by the move of asyncdata.o into the common part. b) Correct the rule for building the common part into the kernel when some or all hardware specific parts are built as modules. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Cc: Adrian Bunk <bunk@stusta.de> Cc: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-20[PATCH] drivers/isdn/gigaset/: build asyncdata.o into the gigaset moduleAdrian Bunk
LD drivers/isdn/gigaset/built-in.o drivers/isdn/gigaset/ser_gigaset.o: In function `gigaset_m10x_send_skb': (.text+0xe50): multiple definition of `gigaset_m10x_send_skb' drivers/isdn/gigaset/usb_gigaset.o:(.text+0x0): first defined here drivers/isdn/gigaset/ser_gigaset.o: In function `gigaset_m10x_input': (.text+0x1121): multiple definition of `gigaset_m10x_input' drivers/isdn/gigaset/usb_gigaset.o:(.text+0x2d1): first defined here make[4]: *** [drivers/isdn/gigaset/built-in.o] Error 1 Signed-off-by: Adrian Bunk <bunk@stusta.de> Cc: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-16[PATCH] correct CONFIG_GIGASET_M101 Makefile entryAdrian Bunk
Advanced Mathematics, lesson 1: 101 != 105 ;-) Signed-off-by: Adrian Bunk <bunk@stusta.de> 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>
2007-02-12[PATCH] drivers/isdn/gigaset: new M101 driver (v2)Tilman Schmidt
This patch adds the line discipline based driver for the Gigaset M101 wireless RS232 adapter. It also improves the documentation a bit. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Hansjoerg Lipp <hjlipp@web.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-12[PATCH] drivers/isdn/gigaset: reduce kernel message spamTilman Schmidt
Reduce the number of kernel messages the Gigaset drivers produce in case of an excessively long device response, from one per character exceeding the limit to one per overlong message. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-12[PATCH] drivers/isdn/gigaset: reduce mutex scopeTilman Schmidt
Do not lock the cardstate structure mutex earlier than necessary. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-11[PATCH] fix gregkh-usb-usbcore-remove-unused-bandwith-related-codeAndrew Morton
drivers/isdn/gigaset/bas-gigaset.c: In function 'dump_urb': drivers/isdn/gigaset/bas-gigaset.c:258: error: 'struct urb' has no member named 'bandwidth' Cc: Alan Stern <stern@rowland.harvard.edu> Cc: Greg KH <greg@kroah.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-11[PATCH] Char: tty_wakeup cleanupJiri Slaby
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>
2007-01-26[PATCH] Gigaset ISDN driver error handling fixesTilman Schmidt
Fix several flaws in the error handling of the Siemens Gigaset ISDN driver, including one that would cause an Oops when connecting more than one device of the same type. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2006-12-13[PATCH] isdn/gigaset: fix possible missing wakeupTilman Schmidt
Eliminate some possibilities for user processes writing to the Gigaset character device to be left sleeping indefinitely, by adding wakeup calls to error paths and properly disposing of pending write requests when the device is disconnected. It also removes unnecessary NULL checks before usb_free_urb() and usb_kill_urb() calls. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-12-08[PATCH] tty: switch to ktermiosAlan Cox
This is the grungy swap all the occurrences in the right places patch that goes with the updates. At this point we have the same functionality as before (except that sgttyb() returns speeds not zero) and are ready to begin turning new stuff on providing nobody reports lots of bugs If you are a tty driver author converting an out of tree driver the only impact should be termios->ktermios name changes for the speed/property setting functions from your upper layers. If you are implementing your own TCGETS function before then your driver was broken already and its about to get a whole lot more painful for you so please fix it 8) Also fill in c_ispeed/ospeed on init for most devices, although the current code will do this for you anyway but I'd like eventually to lose that extra paranoia [akpm@osdl.org: bluetooth fix] [mp3@de.ibm.com: sclp fix] [mp3@de.ibm.com: warning fix for tty3270] [hugh@veritas.com: fix tty_ioctl powerpc build] [jdike@addtoit.com: uml: fix ->set_termios declaration] Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Martin Peschke <mp3@de.ibm.com> Acked-by: Peter Oberparleiter <oberpar@de.ibm.com> Cc: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Hugh Dickins <hugh@veritas.com> Signed-off-by: Jeff Dike <jdike@addtoit.com> Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-12-08[PATCH] isdn/gigaset: use bitrev8Akinobu Mita
Use bitrev8 for gigaset isdn driver. Acked-by: Karsten Keil <kkeil@suse.de> Cc: Kai Germaschewski <kai.germaschewski@gmx.de> Acked-by: Hansjoerg Lipp <hjlipp@web.de> Acked-by: Tilman Schmidt <tilman@imap.cc> Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-12-07[PATCH] slab: remove SLAB_KERNELChristoph Lameter
SLAB_KERNEL is an alias of GFP_KERNEL. Signed-off-by: Christoph Lameter <clameter@sgi.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-12-07[PATCH] slab: remove SLAB_ATOMICChristoph Lameter
SLAB_ATOMIC is an alias of GFP_ATOMIC Signed-off-by: Christoph Lameter <clameter@sgi.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-12-01Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6Linus Torvalds
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6: (103 commits) usbcore: remove unused argument in autosuspend USB: keep count of unsuspended children USB hub: simplify remote-wakeup handling USB: struct usb_device: change flag to bitflag OHCI: make autostop conditional on CONFIG_PM USB: Add autosuspend support to the hub driver EHCI: Fix root-hub and port suspend/resume problems USB: create a new thread for every USB device found during the probe sequence USB: add driver for the USB debug devices USB: added dynamic major number for USB endpoints USB: pegasus error path not resetting task's state USB: endianness fix for asix.c USB: build the appledisplay driver USB serial: replace kmalloc+memset with kzalloc USB: hid-core: canonical defines for Apple USB device IDs USB: idmouse cleanup USB: make drivers/usb/core/driver.c:usb_device_match() static USB: lh7a40x_udc remove double declaration USB: pxa2xx_udc recognizes ixp425 rev b0 chip usbtouchscreen: add support for DMC TSC-10/25 devices ...
2006-12-01Driver core: convert tty core to use struct deviceGreg Kroah-Hartman
Converts from using struct "class_device" to "struct device" making everything show up properly in /sys/devices/ with symlinks from the /sys/class directory. Also fixes up the isdn drivers that were putting something in the class device's directory. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-12-01usb: usb-gigaset free kill urb cleanupMariusz Kozlowski
- usb_free_urb() cleanup - usb_kill_urb() cleanup Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-11-06[PATCH] isdn/gigaset: convert warning messageTilman Schmidt
Make the failed-to-allocate-skb warning a non-debug message. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Cc: Hansjoerg Lipp <hjlipp@web.de> Cc: Karsten Keil <kkeil@suse.de> Cc: Kai Germaschewski <kai.germaschewski@gmx.de> Cc: Akinobu Mita <akinobu.mita@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-30[PATCH] isdn/gigaset: avoid cs->dev null pointer dereferenceAkinobu Mita
When gigaset_initbcs() is called, cs->dev is not initialized yet. If dev_alloc_skb() failed in this function, NULL poinster dereference will happen at dev_warn(). Cc: Kai Germaschewski <kai.germaschewski@gmx.de> Cc: Hansjoerg Lipp <hjlipp@web.de> Cc: Tilman Schmidt <tilman@imap.cc> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-05IRQ: Maintain regs pointer globally rather than passing to IRQ handlersDavid Howells
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)
2006-10-02[PATCH] isdn4linux: Gigaset driver: fix __must_check warningTilman Schmidt
This patch to the Siemens Gigaset driver fixes the compile warning "ignoring return value of 'class_device_create_file', declared with attribute warn_unused_result" appearing with CONFIG_ENABLE_MUST_CHECK=y in release 2.6.18-rc1-mm1. Signed-off-by: Tilman Schmidt <tilman@imap.cc> Acked-by: Hansjoerg Lipp <hjlipp@web.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-02[PATCH] const struct tty_operationsJeff Dike
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>
2006-09-27USB: Dealias -110 code (more complete)Pete Zaitcev
The purpose of this patch is to split off the case when a device does not reply on the lower level (which is reported by HC hardware), and a case when the device accepted the request, but does not reply at upper level. This redefinition allows to diagnose issues easier, without asking the user if the -110 happened "immediately". The usbmon splits such cases already thanks to its timestamp, but it's not always available. I adjusted all drivers which I found affected (by searching for "urb"). Out of tree drivers may suffer a little bit, but I do not expect much breakage. At worst they may print a few messages. Signed-off-by: Pete Zaitcev <zaitcev@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2006-06-30Remove obsolete #include <linux/config.h>Jörn Engel
Signed-off-by: Jörn Engel <joern@wohnheim.fh-wedel.de> Signed-off-by: Adrian Bunk <bunk@stusta.de>
2006-06-29Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/devfs-2.6Linus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/devfs-2.6: (22 commits) [PATCH] devfs: Remove it from the feature_removal.txt file [PATCH] devfs: Last little devfs cleanups throughout the kernel tree. [PATCH] devfs: Rename TTY_DRIVER_NO_DEVFS to TTY_DRIVER_DYNAMIC_DEV [PATCH] devfs: Remove the tty_driver devfs_name field as it's no longer needed [PATCH] devfs: Remove the line_driver devfs_name field as it's no longer needed [PATCH] devfs: Remove the videodevice devfs_name field as it's no longer needed [PATCH] devfs: Remove the gendisk devfs_name field as it's no longer needed [PATCH] devfs: Remove the miscdevice devfs_name field as it's no longer needed [PATCH] devfs: Remove the devfs_fs_kernel.h file from the tree [PATCH] devfs: Remove devfs_remove() function from the kernel tree [PATCH] devfs: Remove devfs_mk_cdev() function from the kernel tree [PATCH] devfs: Remove devfs_mk_bdev() function from the kernel tree [PATCH] devfs: Remove devfs_mk_symlink() function from the kernel tree [PATCH] devfs: Remove devfs_mk_dir() function from the kernel tree [PATCH] devfs: Remove devfs_*_tape() functions from the kernel tree [PATCH] devfs: Remove devfs support from the sound subsystem [PATCH] devfs: Remove devfs support from the ide subsystem. [PATCH] devfs: Remove devfs support from the serial subsystem [PATCH] devfs: Remove devfs from the init code [PATCH] devfs: Remove devfs from the partition code ...
2006-06-27[PATCH] spin/rwlock init cleanupsIngo Molnar
locking init cleanups: - convert " = SPIN_LOCK_UNLOCKED" to spin_lock_init() or DEFINE_SPINLOCK() - convert rwlocks in a similar manner this patch was generated automatically. Motivation: - cleanliness - lockdep needs control of lock initialization, which the open-coded variants do not give - it's also useful for -rt and for lock debugging in general Signed-off-by: Ingo Molnar <mingo@elte.hu> 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>
2006-06-26[PATCH] devfs: Rename TTY_DRIVER_NO_DEVFS to TTY_DRIVER_DYNAMIC_DEVGreg Kroah-Hartman
I've always found this flag confusing. Now that devfs is no longer around, it has been renamed, and the documentation for when this flag should be used has been updated. Also fixes all drivers that use this flag. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>