aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
AgeCommit message (Collapse)AuthorFilesLines
2006-03-31[PATCH] vt: add TIOCL_GETKMSGREDIRECTRafael J. Wysocki1-0/+4
Add TIOCL_GETKMSGREDIRECT needed by the userland suspend tool to get the current value of kmsg_redirect from the kernel so that it can save it and restore it after resume. Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl> Acked-by: Pavel Machek <pavel@suse.cz> Cc: Michael Kerrisk <mtk-manpages@gmx.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] ISDN: fix a few memory leaks in sc_ioctl()Jesper Juhl1-4/+5
Fix a few memory leaks in drivers/isdn/sc/ioctl.c::sc_ioctl() Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com> Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] drivers/char/[i]stallion: Clean up kmalloc usageTobias Klauser2-54/+24
Delete two useless kmalloc wrappers and use kmalloc/kzalloc. Some weird NULL checks are also simplified. Signed-off-by: Tobias Klauser <tklauser@nuerscht.ch> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] 3c59x: fix networking for 10base2 NICsSteffen Klassert1-9/+12
The "3c59x: use mii_check_media" patch introduced a netif_carrier_off in vortex_up. 10base2 stoped working because of this. This is removed. Tx/Rx reset is back in vortex_up because the 3c900B-Combo stops working after changing from half duplex to full duplex when Tx/Rx reset is done with vortex_timer. Also brought back some mii stuff to be sure that it does not break something else. Thanks to Pete Clements <clem@clem.clem-digital.net> for reporting and testing. Signed-off-by: Steffen Klassert <klassert@mathematik.tu-chemnitz.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] "3c59x collision statistics fix" fixAndrew Morton1-7/+5
The pre-2.6.16 patch "3c59x collision statistics fix" accidentally caused vortex_error() to not run iowrite16(TxEnable, ioaddr + EL3_CMD) if we got a maxCollisions interrupt but MAX_COLLISION_RESET is not set. Thanks to Pete Clements <clem@clem.clem-digital.net> for reporting and testing. Acked-by: Steffen Klassert <klassert@mathematik.tu-chemnitz.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] IPMI: convert from semaphores to mutexesCorey Minyard4-55/+63
Convert the remaining semaphores to mutexes in the IPMI driver. The watchdog was using a semaphore as a real semaphore (for IPC), so the conversion there required adding a completion. Signed-off-by: Corey Minyard <minyard@acm.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] IPMI: tidy up various thingsCorey Minyard5-33/+35
Tidy up various coding standard things, mostly removing the space after !, but also break some long lines and fix a few other spacing inconsistencies. Also fixes some bad error reporting when deleting an IPMI user. Signed-off-by: Corey Minyard <minyard@acm.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] IPMI: fix startup race conditionCorey Minyard2-27/+41
Matt Domsch noticed a startup race with the IPMI kernel thread, it was possible (though extraordinarly unlikely) that a message could come in before the upper layer was ready to handle it. This patch splits the startup processing of an IPMI interface into two parts, one to get ready and one to actually start the processes to receive messages from the interface. [akpm@osdl.org: cleanups] Signed-off-by: Corey Minyard <minyard@acm.org> Cc: Matt Domsch <Matt_Domsch@dell.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] make tty_insert_flip_string a non-GPL exportAndrew Morton1-1/+1
Alan sayeth "Based on Linus original comments about _GPL we should export tty_insert_flip_char as EXPORT_SYMBOL because it used to be EXPORT_SYMBOL equivalent (trivial inline). The other features are new extensions are were not available to drivers before so need not be provided except as _GPL functionality as far as I can see." Addresses http://bugzilla.kernel.org/show_bug.cgi?id=6294 Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Cc: Russell King <rmk@arm.linux.org.uk> Cc: Paul Fulghum <paulkf@microgate.com> Cc: Philippe Vouters <Philippe.Vouters@laposte.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] edac_752x needs CONFIG_HOTPLUGRandy Dunlap1-1/+1
EDAC_752X uses pci_scan_single_device(), which is only available if CONFIG_HOTPLUG is enabled, so limit this driver with HOTPLUG. Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Cc: Dave Peterson <dsp@llnl.gov> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] Don't pass boot parameters to argv_init[]OGAWA Hirofumi12-26/+27
The boot cmdline is parsed in parse_early_param() and parse_args(,unknown_bootoption). And __setup() is used in obsolete_checksetup(). start_kernel() -> parse_args() -> unknown_bootoption() -> obsolete_checksetup() If __setup()'s callback (->setup_func()) returns 1 in obsolete_checksetup(), obsolete_checksetup() thinks a parameter was handled. If ->setup_func() returns 0, obsolete_checksetup() tries other ->setup_func(). If all ->setup_func() that matched a parameter returns 0, a parameter is seted to argv_init[]. Then, when runing /sbin/init or init=app, argv_init[] is passed to the app. If the app doesn't ignore those arguments, it will warning and exit. This patch fixes a wrong usage of it, however fixes obvious one only. Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] uml: kconfigsAl Viro3-4/+2
kconfig sanitized around drivers/net Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> 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-03-31[PATCH] drivers/mtd/maps/vmax301.c: fix off by one vmax_mtdPetri T. Koistinen1-1/+1
Fix an obvious off-by-one error (vmax_mtd[] contains two elements). Signed-off-by: Adrian Bunk <bunk@stusta.de> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] mtd: fix broken name_to_dev_t() declarationHerbert Poetzl1-2/+1
drivers/mtd/devices/blkmtd.c uses a local declaration of name_to_dev_t() which is inconsistant with the real one. the following patch fixes this by removing the local declaration and including mount.h instead this patch was originally done by Micah Anderson. Signed-off-by: Herbert Poetzl <herbert@13thfloor.at> Acked-by: Micah Anderson <micah@riseup.net> Acked-by: Daniel Hokka Zakrisson <daniel@hozac.com> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] mtd/redboot: Handle holes in fis tablePeter Korsgaard1-5/+1
Redboot simply sets the first character of a fis entry to 0xff on "fis delete". The kernel redboot parser stops parsing on such an entry, and without this patch any entries after a deleted image would not be detected. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] Add chip used in collie to jedec_probePavel Machek1-0/+17
This adds flash chip used in Sharp Zaurus sl5500 (collie) to jedec_probe. Values work for read-only access, but I have not figured out how to do read-write. Signed-off-by: Pavel Machek <pavel@suse.cz> Cc: Richard Purdie <rpurdie@rpsys.net> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] Dead code in mtd/maps/pci.cEric Sesterhenn1-3/+0
This fixes coverity bug #12. The first two gotos in the function still have the initial value for mtd set. And the third goto just triggers for !mtd Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] Kill ifdefs in mtdcore.cPavel Machek1-9/+4
Kill unneccessary ifdefs in mtdcore.c. Signed-off-by: Pavel Machek <pavel@suse.cz> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Adrian Bunk <bunk@stusta.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] Fix debug statement in inftlcore.cEric Sesterhenn / snakebyte1-1/+1
Fix a copy/paste bug found by cpminer inside the inftlcore.c file Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de> Acked-by: Greg Ungerer <gerg@snapgear.com> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] mtd cmdlinepart: allow zero offset valueAtsushi Nemoto1-3/+4
Current cmdlinepart.c uses offset value 0 to specify a continuous partition. This prevents creating a second partition starting at 0. For example, I can split 4MB device using "mtdparts=id:2M,2M", but I can not do "mtdparts=id:2M@2M,2M@0" to swap mtd0 and mtd1. This patch introduces special OFFSET_CONTINUOUS value for a continuous partition and allows 0 for offset value. Also this patch replaces 0xffffffff with UINT_MAX for SIZE_REMAINING. Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] drivers/mtd: Use ARRAY_SIZE macroTobias Klauser22-45/+31
Use ARRAY_SIZE macro instead of sizeof(x)/sizeof(x[0]) and remove duplicates of the macro. Signed-off-by: Tobias Klauser <tklauser@nuerscht.ch> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] MTD_NAND_SHARPSL and MTD_NAND_NANDSIM should be tristate'sAdrian Bunk1-9/+8
MTD_NAND=m and MTD_NAND_SHARPSL=y or MTD_NAND_NANDSIM=y are illegal combinations that mustn't be allowed. This patch fixes this bug by making MTD_NAND_SHARPSL and MTD_NAND_NANDSIM tristate's. Additionally, it fixes some whitespace damage at these options. Signed-off-by: Adrian Bunk <bunk@stusta.de> Acked-by: Richard Purdie <rpurdie@rpsys.net> Acked-by: "Artem B. Bityutskiy" <dedekind@yandex.ru> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] drivers/mtd/: small cleanupsAdrian Bunk2-9/+3
- chips/sharp.c: make two needlessly global functions static - move some declarations to a header file where they belong to Signed-off-by: Adrian Bunk <bunk@stusta.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] sem2mutex: drivers/mtd/Ingo Molnar6-64/+67
Semaphore to mutex conversion. The conversion was generated via scripts, and the result was validated automatically via a script as well. Signed-off-by: Ingo Molnar <mingo@elte.hu> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] sem2mutex: mtd/doc2000.cIngo Molnar1-3/+4
Semaphore to mutex conversion. The conversion was generated via scripts, and the result was validated automatically via a script as well. Signed-off-by: Ingo Molnar <mingo@elte.hu> Cc: Thomas Gleixner <tglx@linutronix.de> Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-31[PATCH] m25p80: printk warning fixAndrew Morton1-1/+1
drivers/mtd/devices/m25p80.c: In function `m25p80_erase': drivers/mtd/devices/m25p80.c:189: warning: signed size_t format, different type arg (arg 6) Acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-30Merge git://git.kernel.org/pub/scm/linux/kernel/git/kyle/parisc-2.6Linus Torvalds19-276/+174
* git://git.kernel.org/pub/scm/linux/kernel/git/kyle/parisc-2.6: (24 commits) [PARISC] Fix double free when removing HIL drivers [PARISC] Add atomic_sub_and_test [PARISC] Enabled some NLS modules in a500, b180 and c3000 defconfigs [PARISC] Kill duplicated EXPORT_SYMBOL warnings [PARISC] Move ioremap EXPORT_SYMBOL from parisc_ksyms.c [PARISC] Make local_t use atomic_long_t [PARISC] Update defconfigs [PARISC] Add PREEMPT support [PARISC] More useful readwrite lock helpers [PARISC] Convert HIL drivers to use input_allocate_device [PARISC] Fixup CONFIG_EISA a bit [PARISC] getsockopt should be ENTRY_COMP [PARISC] Remove obsolete CONFIG_DEBUG_IOREMAP [PARISC] Temporary FIXME for ioremapping EISA regions [PARISC] Enable ioremap functionality unconditionally [PARISC] Fix stifb with IOREMAP and a 64-bit kernel [PARISC] Add CONFIG_HPPA_IOREMAP to conditionally enable ioremap [PARISC] Add STRICT_MM_TYPECHECKS [PARISC] Fix IOREMAP with a 64-bit kernel [PARISC] Add parisc implementation of flush_kernel_dcache_page() ...
2006-03-30Merge branch 'for-linus' of ↵Linus Torvalds15-89/+142
git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband: IB/mad: RMPP support for additional classes IB/mad: include GID/class when matching receives IB/mthca: Fix section mismatch problems IPoIB: Fix oops with raw sockets IB/mthca: Fix check of size in SRQ creation IB/srp: Fix unmapping of fake scatterlist
2006-03-30Merge branch 'upstream-linus' of ↵Linus Torvalds3-124/+112
master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev * 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev: [PATCH] sata_mv: three bug fixes [PATCH] libata: ata_dev_init_params() fixes [PATCH] libata: Fix interesting use of "extern" and also some bracketing [PATCH] libata: Simplex and other mode filtering logic [PATCH] libata - ATA is both ATA and CFA [PATCH] libata: Add ->set_mode hook for odd drivers [PATCH] libata: BMDMA handling updates [PATCH] libata: kill trailing whitespace [PATCH] libata: add FIXME above ata_dev_xfermask() [PATCH] libata: cosmetic changes in ata_bus_softreset() [PATCH] libata: kill E.D.D.
2006-03-30Merge branch 'drm-patches' of ↵Linus Torvalds16-318/+413
git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6 * 'drm-patches' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6: drm: remove drm_{alloc,free}_pages drm: sis fix compile warning drm: add new radeon PCI ids.. drm: read breadcrumb in IRQ handler drm: fixup i915 breadcrumb read/write drm: remove pointless checks in radeon_state drm: fixup improper cast. drm: rationalise some pci ids drm: Add general-purpose packet for manipulating scratch registers (r300) drm: rework radeon memory map (radeon 1.23) drm: update r300 register names drm: fixup PCI DMA support
2006-03-30[PARISC] Fix double free when removing HIL driversKyle McMartin3-5/+2
On Thu, Mar 30, 2006 at 08:31:02AM -0500, Dmitry Torokhov wrote: > Don't do that, its double free. input_unregister_device() normally > causes release() to be called and free the device. input_free_device > is only to be called when input_register_device has not been called or > failed. > > Plus you might want to unregister device after closing serio port, > otherwise your interrupt routine might be referencing already freed > memory. Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
2006-03-30[PARISC] Convert HIL drivers to use input_allocate_deviceHelge Deller3-93/+109
Convert HIL drivers to use input_allocate_device() - avoids crashes. Signed-off-by: Helge Deller <deller@parisc-linux.org> Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
2006-03-30[PARISC] Fix stifb with IOREMAP and a 64-bit kernelHelge Deller3-127/+19
Kill various warnings when built using ioremap. Remove stifb_{read,write} functions, which are now obsolete (and stack abusers!) Disable stifb mmap() functionality on a 64-bit kernel, it will crash the machine. Signed-off-by: Helge Deller <deller@parisc-linux.org> Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
2006-03-30[PARISC] I/O-Space must be ioremap_nocache()'dHelge Deller12-53/+47
Addresses in F-space must be accessed uncached on most parisc machines. Signed-off-by: Helge Deller <deller@parisc-linux.org> Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
2006-03-30[PARISC] Clarify pdc_stable license termsThibaut VARENE1-3/+2
pdc_stable.c is explicitly licensed under GPL version 2. Signed-off-by: Thibaut VARENE <varenet@parisc-linux.org> Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
2006-03-30IB/mad: RMPP support for additional classesHal Rosenstock3-44/+59
Add RMPP support for additional management classes that support it. Also, validate RMPP is consistent with management class specified. Signed-off-by: Hal Rosenstock <halr@voltaire.com> Signed-off-by: Sean Hefty <sean.hefty@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-03-30IB/mad: include GID/class when matching receivesJack Morgenstein3-29/+67
Received responses are currently matched against sent requests based on TID only. According to the spec, responses should match based on the combination of TID, management class, and requester LID/GID. Without the additional qualification, an agent that is responding to two requests, both of which have the same TID, can match RMPP ACKs with the incorrect transaction. This problem can occur on the SM node when responding to SA queries. Signed-off-by: Jack Morgenstein <jackm@mellanox.co.il> Signed-off-by: Sean Hefty <sean.hefty@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-03-29Merge branch 'mv-merge'Jeff Garzik1-18/+24
Conflicts: drivers/scsi/sata_mv.c
2006-03-29[PATCH] sata_mv: three bug fixesMark Lord1-18/+23
(1) A DMA transfer size of 0x10000 was not being written as 0x0000 in the PRDs. Fixed. (1) The DEV_IRQ interrupt cause bit happens spuriously during EDMA operation, and was not being ignored by the driver. This led to various "drive busy" errors being reported, with associated unpredictable behaviour. Fixed. (2) If a SATA or PCI interrupt was received with no outstanding command, the interrupt handler still attempted to invoke ata_qc_complete(), triggering assert()/BUG_ON() behaviour elsewhere in libata. Fixed. The driver still has issues with confusion after error-recovery, but should now be reliable in the absence of drive errors. I will be looking more into the error-handling bugs next. Signed-Off-By: Mark Lord <mlord@pobox.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] libata: ata_dev_init_params() fixesAlbert Lee1-6/+8
ata_dev_init_params() fixes: - Get the "heads" and "sectors" parameters from caller instead of implicitly from dev->id[]. - Return AC_ERR_INVALID instead of 0 if an invalid parameter is found Signed-off-by: Albert Lee <albertcc@tw.ibm.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] libata: Fix interesting use of "extern" and also some bracketingAlan Cox1-2/+2
Signed-off-by: Alan Cox <alan@redhat.com> Last of the set, just clean up some oddments. Assuming the whole set is now ok then the remaining differences are the setup of PIO_0 at reset and the ->data_xfer method. Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] libata: Simplex and other mode filtering logicAlan Cox1-2/+29
Add a field to the host_set called 'flags' (was host_set_flags changed to suit Jeff) Add a simplex_claimed field so we can remember who owns the DMA channel Add a ->mode_filter() hook to allow drivers to filter modes Add docs for mode_filter and set_mode Filter according to simplex state Filter cable in core This provides the needed framework to support all the mode rules found in the PATA world. The simplex filter deals with 'to spec' simplex DMA systems found in older chips. The cable filter avoids duplicating the same rules in each chip driver with PATA. Finally the mode filter is neccessary because drive/chip combinations have errata that forbid certain modes with some drives or types of ATA object. Drive speed setup remains per channel for now and the filters now use the framework Tejun put into place which cleans them up a lot from the older libata-pata patches. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] libata - ATA is both ATA and CFAAlan Cox1-1/+1
I think this is still needed with the new probe code (which btw seems to be missing docs in upstream ?). Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] libata: Add ->set_mode hook for odd driversAlan Cox1-1/+5
Some hardware doesn't want the usual mode setup logic running. This allows the hardware driver to replace it for special cases in the least invasive way possible. Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] libata: BMDMA handling updatesAlan Cox1-4/+22
This is the minimal patch set to enable the current code to be used with a controller following SFF (ie any PATA and early SATA controllers) safely without crashes if there is no BMDMA area or if BMDMA is not assigned by the BIOS for some reason. Simplex status is recorded but not acted upon in this change, this isn't a problem with the current drivers as none of them are for simplex hardware. A following diff will deal with that. The flags in the probe structure remain ->host_set_flags although Jeff asked me to rename them, simply because the rename would break the usual Linux rules that old code should break when there are changes. not compile and run and then blow up/eat your computer/etc. Renaming this later is a trivial exercise once a better name is chosen. Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] ixp2000: fix gcc4 breakageLennert Buytenhek1-4/+1
gcc4 doesn't like us declaring a static function inside another function. We can do away with this construct altogether and use BUILD_BUG_ON() instead (idea from Andi Kleen.) Signed-off-by: Lennert Buytenhek <buytenh@wantstofly.org> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] b44: ensure valid mac addrGary Zambrano1-0/+9
Added code to check for invalid MAC address from eeprom or user input. Signed-off-by: Gary Zambrano <zambrano@broadcom.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] Janitor: drivers/net/pcnet32: fix incorrect commentsLinas Vepstas1-2/+2
The comments concerning how the pcnet32 ethernet device driver selects the MAC addr to use are incorrect. A recent patch (in the last 3 months) changed how the code worked, but did not change the comments. Side comment: the new behaviour is good; I've got a pcnet32 card which powers up with garbage in the CSR's, and a good MAC addr in the PROM. Signed-off-by: Linas Vepstas <linas@linas.org> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] net: remove CONFIG_NET_CBUS conditional for NS8390Arthur Othieno1-1/+1
Don't bother testing for CONFIG_NET_CBUS ("NEC PC-9800 C-bus cards"); it went out with the rest of PC98 subarch. Signed-off-by: Arthur Othieno <apgo@patchbomb.org> Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] natsemi: Support oversized EEPROMsMark Brown1-4/+14
The natsemi chip can have a larger EEPROM attached than it itself uses for configuration. This patch adds support for user space access to such an EEPROM. Signed-off-by: Mark Brown <broonie@sirena.org.uk> Cc: Tim Hockin <thockin@hockin.org> Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] spidernet : enable tx checksum offloading by defaultJens Osterkamp1-1/+1
This enables TX checksum offloading for the spidernet driver by default. Signed-off-by: Jens Osterkamp <Jens.Osterkamp@de.ibm.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] bonding: support carrier state for masterJay Vosburgh4-28/+102
Add support for the bonding master to specify its carrier state based upon the state of the slaves. For 802.3ad, the bond is up if there is an active, parterned aggregator. For other modes, the bond is up if any slaves are up. Updates driver version to 3.0.3. Based on a patch by jamal <hadi@cyberus.ca>. Signed-off-by: Jay Vosburgh <fubar@us.ibm.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29Merge branch 'upstream' of ↵Jeff Garzik34-9/+15547
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
2006-03-29[PATCH] acenic: fix section mismatchesRandy Dunlap1-5/+5
Fix section mismatches in acenic driver: WARNING: drivers/net/acenic.o - Section mismatch: reference to .init.data:tigon2FwText from .text between 'acenic_probe_one' (at offset 0x2409) and 'ace_interrupt' WARNING: drivers/net/acenic.o - Section mismatch: reference to .init.data:tigon2FwRodata from .text between 'acenic_probe_one' (at offset 0x2422) and 'ace_interrupt' Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] spidernet : reduce console spamJens Osterkamp1-1/+1
This patch reduces the message level of the RX ram full messages from err to debug to prevent spamming the console leaving it in the logfiles though. From: Jens Osterkamp <Jens.Osterkamp@de.ibm.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] via-rhine: link state fixRoger Luethi1-0/+21
Problems with link state detection have been reported several times in the past months. Denis Vlasenko did all the work tracking it down. Jeff Garzik suggested the proper place for the fix. When using the mii library, the driver needs to check mii->force_media and set dev->state accordingly. Signed-off-by: Roger Luethi <rl@hellgate.ch> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] axnet_cs.c : add hardware multicast supportKomuro1-8/+53
Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29[PATCH] libata: kill trailing whitespaceTejun Heo1-1/+1
Kill trailing whitespace. Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-03-29Merge branch 'master'Jeff Garzik604-12068/+34985
2006-03-29b44: fix force mac address before ifconfig upGary Zambrano1-0/+5
Initializing the b44 MAC & PCI functional blocks in the controller must occur inside init_one(). This will allow access to the MAC registers. The controller was being powered up in b44_open() which would not allow access to the registers before ifconfig was up. Philip Kohlbecher found this bug. Signed-off-by: Gary Zambrano <zambrano@broadcom.com>
2006-03-29Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6Linus Torvalds1-49/+69
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: [NETFILTER]: Rename init functions. [TCP]: Fix RFC2465 typo. [INET]: Introduce tunnel4/tunnel6 [NET]: deinline 200+ byte inlines in sock.h [ECONET]: Convert away from SOCKOPS_WRAPPED [NET]: Fix ipx/econet/appletalk/irda ioctl crashes [NET]: Kill Documentation/networking/TODO [TG3]: Update version and reldate [TG3]: Skip timer code during full lock [TG3]: Speed up SRAM access [TG3]: Fix PHY loopback on 5700 [TG3]: Fix bug in 40-bit DMA workaround code [TG3]: Fix probe failure due to invalid MAC address
2006-03-29Merge git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpcLinus Torvalds26-89/+321
* git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (67 commits) [PATCH] powerpc: Remove oprofile spinlock backtrace code [PATCH] powerpc: Add oprofile calltrace support to all powerpc cpus [PATCH] powerpc: Add oprofile calltrace support [PATCH] for_each_possible_cpu: ppc [PATCH] for_each_possible_cpu: powerpc [PATCH] lock PTE before updating it in 440/BookE page fault handler [PATCH] powerpc: Kill _machine and hard-coded platform numbers ppc: Fix compile error in arch/ppc/lib/strcase.c [PATCH] git-powerpc: WARN was a dumb idea [PATCH] powerpc: a couple of trivial compile warning fixes powerpc: remove OCP references powerpc: Make uImage default build output for MPC8540 ADS powerpc: move math-emu over to arch/powerpc powerpc: use memparse() for mem= command line parsing ppc: fix strncasecmp prototype [PATCH] powerpc: make ISA floppies work again [PATCH] powerpc: Fix some initcall return values [PATCH] powerpc: Workaround for pSeries RTAS bug [PATCH] spufs: fix __init/__exit annotations [PATCH] powerpc: add hvc backend for rtas ...
2006-03-29IB/mthca: Fix section mismatch problemsRoland Dreier9-12/+12
Quite a few cleanup functions in mthca were marked as __devexit. However, they could also be called from error paths during initialization, so they cannot be marked that way. Just delete all of the incorrect annotations. Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-03-29IPoIB: Fix oops with raw socketsRoland Dreier1-1/+1
ipoib_hard_header() needs to handle the case that daddr is NULL. This can happen when packets are injected via a raw socket, and IPoIB shouldn't oops in this case. Reported by Anton Blanchard <anton@samba.org> Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-03-29IB/mthca: Fix check of size in SRQ creationJack Morgenstein1-1/+1
The previous patch for Tavor broke MemFree logic. The driver should perform limit check only for Tavor. For MemFree, the check is incorrect, since ds (WQE stride) is always a power-of-2 (although the max_desc_size may not be). In Tavor, however, WQE stride and desc_size are the same, and are not necessarily power-of-2. The check was really for the WQE stride (and it Tavor, we use max_desc_size for the stride). Signed-off-by: Jack Morgenstein <jackm@mellanox.co.il> Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-03-29IB/srp: Fix unmapping of fake scatterlistRoland Dreier1-2/+2
The recently merged patch to create a fake scatterlist for non-SG SCSI commands had a bug: the driver ended up doing dma_unmap_sg() on a scatterlist scmnd->request_buffer rather than the fake scatter list it created. Fix this so that the driver unmaps the same thing it maps. Signed-off-by: Roland Dreier <rolandd@cisco.com>
2006-03-28Merge branch 'for-linus' of ↵Linus Torvalds7-182/+86
master.kernel.org:/pub/scm/linux/kernel/git/scjody/ieee1394 * 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/scjody/ieee1394: ohci1394: cleanup the "Unexpected PCI resource length" warning. sbp2: misc debug logging cleanups sbp2: proper treatment of DID_OK ieee1394: set read permission for parameter disable_irm sbp2: check for ARM failure ohci1394: clean up asynchronous and physical request filters programming ieee1394: remove amdtp remains from ieee1394_core.h ieee1394: remove devfs support Signed-off-by: Jody McIntyre <scjody@modernduck.com> sbp2: prevent unloading of 1394 low-level driver
2006-03-28[PATCH] do_SAK: don't depend on session ID 0Eric W. Biederman1-3/+13
I'm not really certain what the thinking was but the code obviously wanted to walk processes other than just those in it's session, for purposes of do_SAK. Just walking those tasks that don't have a session assigned sounds at the very least incomplete. So modify the code to kill everything in the session and anything else that might have the tty open. Hopefully this helps if the do_SAK functionality is ever finished. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] do_tty_hangup: use group_send_sig_info not send_group_sig_infoEric W. Biederman1-2/+2
We already have the tasklist_lock so there is no need for us to reacquire it with send_group_sig_info. reader/writer locks allow multiple readers and thus recursion so the old code was ok just wastful. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-29Merge ../linux-2.6Paul Mackerras185-3203/+11497
2006-03-28Merge with ↵Jody McIntyre185-3203/+11497
git+ssh://master.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git
2006-03-28ohci1394: cleanup the "Unexpected PCI resource length" warning.Jody McIntyre1-2/+2
This warning happens in practice because the resource length reported by the chipset is too large. This is not actually a problem, so don't warn about it. If it happens to be too small, warn about that, but with a different message so people who are used to ignoring the old message don't. Signed-off-by: Jody McIntyre <scjody@modernduck.com>
2006-03-28sbp2: misc debug logging cleanupsStefan Richter1-77/+33
- move call of scsi_print_command from sbp2_send_command to the beginning of sbp2_queue_command to show also commands which are not sent - put sbp2's name into scsi_print_sense - use __FUNCTION__ in log messages - remove a few less useful log messages and comments Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Signed-off-by: Jody McIntyre <scjody@modernduck.com>
2006-03-28sbp2: proper treatment of DID_OKStefan Richter1-3/+5
Sbp2 relied on DID_OK to be defined as 0. Always shift DID_OK into the right position anyway, and explicitly return DID_OK together with CHECK_CONDITION. Also comment on some #if 0 code. The patch does not change current behaviour. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Signed-off-by: Jody McIntyre <scjody@modernduck.com>
2006-03-28ieee1394: set read permission for parameter disable_irmStefan Richter1-1/+1
No need to hide it from /sys/module/ieee1394/parameters/. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Signed-off-by: Jody McIntyre <scjody@modernduck.com>
2006-03-28[TG3]: Update version and reldateMichael Chan1-2/+2
Update version to 3.55. Signed-off-by: Michael Chan <mchan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-03-28[TG3]: Skip timer code during full lockMichael Chan1-0/+4
Skip the main timer code if interrupts are disabled in the full lock state. Signed-off-by: Michael Chan <mchan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-03-28[TG3]: Speed up SRAM accessMichael Chan1-23/+30
Speed up SRAM read and write functions if possible by using MMIO instead of config. cycles. With this change, the post reset signature done at the end of D3 power change must now be moved before the D3 power change. IBM reported a problem on powerpc blades during ethtool self test that was caused by the memory test taking excessively long. Config. cycles are very slow on powerpc and the memory test can take more than 10 seconds to complete using config. cycles. As a result, NETDEV WATCHDOG can be triggered during self test and the chip can end up in a funny state. Signed-off-by: Michael Chan <mchan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-03-28[TG3]: Fix PHY loopback on 5700Michael Chan1-1/+4
Fix PHY loopback failure on some 5700 devices. Signed-off-by: Michael Chan <mchan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-03-28[TG3]: Fix bug in 40-bit DMA workaround codeMichael Chan1-1/+1
Need to check the TG3_FLAG_40BIT_DMA_BUG flag in the workaround code path instead of device flags. Signed-off-by: Michael Chan <mchan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-03-28[TG3]: Fix probe failure due to invalid MAC addressMichael Chan1-22/+28
Some older bootcode in some devices may report 0 MAC address in SRAM when booting up from low power state. This patch fixes the problem by checking for a valid MAC address in SRAM and falling back to NVRAM if necessary. Thanks to walt <wa1ter@myrealbox.com> for reporting the problem and helping to debug it. Signed-off-by: Michael Chan <mchan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2006-03-28sbp2: check for ARM failureStefan Richter1-3/+7
Sbp2 did not check for successful registration of the lower address range when CONFIG_IEEE1394_SBP2_PHYS_DMA was set. If hpsb_register_addrspace failed, a "login timed-out" would occur which is misleading. Now sbp2 logs a sensible error message. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Signed-off-by: Jody McIntyre <scjody@modernduck.com>
2006-03-28ohci1394: clean up asynchronous and physical request filters programmingStefan Richter1-18/+19
Various cleanups of how ohci1394 programs AsynchronousRequestFilter, PhysicalRequestFilter, and physUpperBoundOffset. In particular, do not rewrite registers within the bus reset interrupt handler if bus resets do not affect the registers in the first place. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Signed-off-by: Jody McIntyre <scjody@modernduck.com>
2006-03-28ieee1394: remove amdtp remains from ieee1394_core.hStefan Richter1-2/+0
since amdtp driver was deleted Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Signed-off-by: Jody McIntyre <scjody@modernduck.com>
2006-03-28ieee1394: remove devfs supportStefan Richter5-73/+5
Devfs has been disabled in the last kernel releases, so let's remove it from ieee1394core, raw1394, video1394, dv1394. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Cc: Dan Dennedy <dan@dennedy.org> Signed-off-by: Jody McIntyre <scjody@modernduck.com>
2006-03-28Signed-off-by: Jody McIntyre <scjody@modernduck.com>Jody McIntyre1-3/+5
2006-03-28sbp2: prevent unloading of 1394 low-level driverStefan Richter1-0/+9
When a new SBP-2 unit is added, sbp2 now takes a reference on the 1394 low-level driver (ohci1394 or pcilynx). This prevents the 1394 host driver module from being unloaded, e.g. by an administrative routine cleanup of unused kernel modules or when another 1394 driver which depends on ohci1394 is unloaded. The reference is dropped when the SBP-2 unit was disconnected, when sbp2 is unloaded or detached from the unit, or when addition of the SBP-2 unit failed. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> Signed-off-by: Jody McIntyre <scjody@modernduck.com>
2006-03-29drm: remove drm_{alloc,free}_pagesDave Airlie3-131/+0
drm_alloc_pages and drm_free_pages can now be removed. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Dave Airlie <airlied@linux.ie>
2006-03-29drm: sis fix compile warningDave Airlie1-1/+1
Prevent a gcc warning in the SIS DRM driver. offset is a unsigned int and the printk wants a long. Signed-off-by: Jon Mason <jdmason@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Dave Airlie <airlied@linux.ie>
2006-03-28Merge master.kernel.org:/home/rmk/linux-2.6-serialLinus Torvalds5-1398/+68
* master.kernel.org:/home/rmk/linux-2.6-serial: [SERIAL] Provide Cirrus EP93xx AMBA PL010 serial support. [SERIAL] amba-pl010: allow platforms to specify modem control method [SERIAL] Remove obsoleted au1x00_uart driver [SERIAL] Small time UART configuration fix for AU1100 processor
2006-03-28Merge master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreqLinus Torvalds2-93/+73
* master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreq: [CPUFREQ] cpufreq_conservative: keep ignore_nice_load and freq_step values when reselected [CPUFREQ] powernow: remove private for_each_cpu_mask() [CPUFREQ] hotplug cpu fix for powernow-k8 [PATCH] cpufreq_ondemand: add range check [PATCH] cpufreq_ondemand: keep ignore_nice_load value when it is reselected [PATCH] cpufreq_ondemand: Warn if it cannot run due to too long transition latency [PATCH] cpufreq_conservative: alternative initialise approach [PATCH] cpufreq_conservative: make for_each_cpu() safe [PATCH] cpufreq_conservative: alter default responsiveness [PATCH] cpufreq_conservative: aligning of codebase with ondemand
2006-03-28[CPUFREQ] cpufreq_conservative: keep ignore_nice_load and freq_step values ↵Mattia Dongili1-2/+2
when reselected Keep the value of ignore_nice_load and freq_step of the conservative governor after the governor is deselected and reselected. Signed-off-by: Mattia Dongili <malattia@linux.it> Signed-off-by: Dave Jones <davej@redhat.com>
2006-03-28[PATCH] Typo fixesAlexey Dobriyan16-17/+17
Fix a lot of typos. Eyeballed by jmc@ in OpenBSD. Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] Replace 0xff.. with correct DMA_xBIT_MASKMatthias Gehre21-37/+55
Replace all occurences of 0xff.. in calls to function pci_set_dma_mask() and pci_set_consistant_dma_mask() with the corresponding DMA_xBIT_MASK from linux/dma-mapping.h. Signed-off-by: Matthias Gehre <M.Gehre@gmx.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] drivers/scsi/*: use time_after() and friendsMarcelo Feitoza Parisi5-6/+11
They deal with wrapping correctly and are nicer to read. Signed-off-by: Marcelo Feitoza Parisi <marcelo@feitoza.com.br> Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Cc: James Bottomley <James.Bottomley@steeleye.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] ide-tape: use time_after(), time_after_eq()Marcelo Feitoza Parisi1-2/+3
They deal with wrapping correctly and are nicer to read. Signed-off-by: Marcelo Feitoza Parisi <marcelo@feitoza.com.br> Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Cc: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl> Cc: Jens Axboe <axboe@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] nvidia-agp: use time_before_eq()Marcelo Feitoza Parisi1-1/+2
It deals with wrapping correctly and is nicer to read. Signed-off-by: Marcelo Feitoza Parisi <marcelo@feitoza.com.br> Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Cc: Dave Jones <davej@codemonkey.org.uk> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] drivers/block/*: use time_after() and friendsMarcelo Feitoza Parisi2-12/+14
They deal with wrapping correctly and are nicer to read. Signed-off-by: Marcelo Feitoza Parisi <marcelo@feitoza.com.br> Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Cc: Jens Axboe <axboe@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] Make most file operations structs in fs/ constArjan van de Ven1-1/+1
This is a conversion to make the various file_operations structs in fs/ const. Basically a regexp job, with a few manual fixups The goal is both to increase correctness (harder to accidentally write to shared datastructures) and reducing the false sharing of cachelines with things that get dirty in .data (while .rodata is nicely read only and thus cache clean) Signed-off-by: Arjan van de Ven <arjan@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] mark f_ops const in the inodeArjan van de Ven14-20/+20
Mark the f_ops members of inodes as const, as well as fix the ripple-through this causes by places that copy this f_ops and then "do stuff" with it. Signed-off-by: Arjan van de Ven <arjan@infradead.org> Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] for_each_possible_cpu: oprofile.KAMEZAWA Hiroyuki1-2/+2
This patch replaces for_each_cpu with for_each_possible_cpu. Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] for_each_possible_cpu: loopback device.KAMEZAWA Hiroyuki1-1/+1
This patch replaces for_each_cpu with for_each_possible_cpu. Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] ide_generic_all_on() warning fixAndrew Morton1-1/+2
drivers/ide/pci/generic.c:45: warning: `ide_generic_all_on' defined but not used Cc: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] Small fixes backported to old IDE SiS driverAlan Cox1-0/+2
Some quick backport bits from the libata PATA work to fix things found in the sis driver. The piix driver needs some fixes too but those are way to large and need someone working on old IDE with time to do them. This patch fixes the case where random bits get loaded into SIS timing registers according to the description of the correct behaviour from Vojtech Pavlik. It also adds the SiS5517 ATA16 chipset which is not currently supported by the driver. Thanks to Conrad Harriss for loaning me the machine with the 5517 chipset. Signed-off-by: Alan Cox <alan@redhat.com> Acked-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] ide: AMD756 no host side cable detectionRene Herman1-6/+2
>From http://marc.theaimsgroup.com/?l=linux-kernel&m=110304128900342&w=2 AMD756 doesn't support host side cable detection. Do disk side only and don't advice obsolete options. Acked-by: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] drivers/block/acsi_slm.c: size_t can't be < 0Alexey Dobriyan1-2/+0
A size_t can't be < 0. (akpm: and rw_verify_area() already did that check) Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] drivers/block/paride/pd.c: fix an off-by-one errorAdrian Bunk1-1/+2
The Coverity checker found this off-by-one error. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] Add oprofile_add_ext_sampleBrian Rogan1-3/+10
On ppc64 we look at a profiling register to work out the sample address and if it was in userspace or kernel. The backtrace interface oprofile_add_sample does not allow this. Create oprofile_add_ext_sample and make oprofile_add_sample use it too. Signed-off-by: Anton Blanchard <anton@samba.org> Cc: Philippe Elie <phil.el@wanadoo.fr> Cc: John Levon <levon@movementarian.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] capi: register_chrdev() fixAndrew Morton1-3/+5
If the user specified `major=0' (odd thing to do), capi.c will use dynamic allocation. We need to pick up that major for subsequent unregister_chrdev(). Acked-by: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] paride-pt: register_chrdev fixAndrew Morton1-3/+5
If the user specified `major=0' (odd thing to do), pt.c will use dynamic allocation. We need to pick up that major for subsequent unregister_chrdev(). Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] paride: register_chrdev fixAndrew Morton1-3/+5
If the user specified `major=0' (odd thing to do), pg.c will use dynamic allocation. We need to pick up that major for subsequent unregister_chrdev(). Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] let BLK_DEV_RAM_COUNT depend on BLK_DEV_RAMAdrian Bunk1-1/+2
It's purely cosmetic, but with the patch there's no longer a BLK_DEV_RAM_COUNT setting in the .config if BLK_DEV_RAM=n. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] synclink_gt: remove uneeded async codePaul Fulghum1-4/+0
Remove code in async receive handling that serves no purpose with new tty receive buffering. Previously this code tried to free up receive buffer space, but now does nothing useful while making expensive calls. Signed-off-by: Paul Fulghum <paulkf@microgate.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] synclink_gt add gpio featurePaul Fulghum1-4/+242
Add driver support for general purpose I/O feature of the Synclink GT adapters. Signed-off-by: Paul Fulghum <paulkf@micrgate.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] synclink: remove dead codePaul Fulghum1-30/+1
Remove dead code from synclink driver. This was used previously when the write method had a from_user flag, which has been removed. Signed-off-by: Paul Fulghum <paulkf@microgate.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28[PATCH] powerpc: Kill _machine and hard-coded platform numbersBenjamin Herrenschmidt19-33/+42
This removes statically assigned platform numbers and reworks the powerpc platform probe code to use a better mechanism. With this, board support files can simply declare a new machine type with a macro, and implement a probe() function that uses the flattened device-tree to detect if they apply for a given machine. We now have a machine_is() macro that replaces the comparisons of _machine with the various PLATFORM_* constants. This commit also changes various drivers to use the new macro instead of looking at _machine. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-03-28[PATCH] powerpc: add hvc backend for rtasArnd Bergmann3-0/+146
Current Cell hardware is using the console through a set of rtas calls. This driver is needed to get console output on those boards. Signed-off-by: Arnd Bergmann <abergman@de.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-03-28[PATCH] powerpc: hvc_console updatesRyan S. Arnold5-41/+115
These are some updates from both Ryan and Arnd for the hvc_console driver: The main point is to enable the inclusion of a console driver for rtas, which is currrently needed for the cell platform. Also shuffle around some data-type declarations and moves some functions out of include/asm-ppc64/hvconsole.h and into a new drivers/char/hvc_console.h file. Signed-off-by: "Ryan S. Arnold" <rsa@us.ibm.com> Signed-off-by: Arnd Bergmann <abergman@de.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-03-27Merge git://git.kernel.org/pub/scm/linux/kernel/git/brodo/cpufreq-2.6Dave Jones2-91/+71
2006-03-27Merge branch 'for-linus' of git://brick.kernel.dk/data/git/linux-2.6-blockLinus Torvalds5-17/+9
* 'for-linus' of git://brick.kernel.dk/data/git/linux-2.6-block: [PATCH] Don't make debugfs depend on DEBUG_KERNEL [PATCH] Fix blktrace compile with sysfs not defined [PATCH] unused label in drivers/block/cciss. [BLOCK] increase size of disk stat counters [PATCH] blk_execute_rq_nowait-speedup [PATCH] ide-cd: quiet down GPCMD_READ_CDVD_CAPACITY failure [BLOCK] ll_rw_blk: kmalloc -> kzalloc conversion [PATCH] kzalloc() conversion in drivers/block [PATCH] update max_sectors documentation
2006-03-27[PATCH] md: Convert reconfig_sem to reconfig_mutexNeilBrown1-7/+7
... being careful that mutex_trylock is inverted wrt down_trylock Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] sem2mutex: drivers/mdArjan van de Ven4-24/+28
Semaphore to mutex conversion. The conversion was generated via scripts, and the result was validated automatically via a script as well. Signed-off-by: Arjan van de Ven <arjan@infradead.org> Signed-off-by: Ingo Molnar <mingo@elte.hu> Cc: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Restore 'remaining' count when retrying an write operationNeilBrown1-0/+3
When retrying a write due to barrier failure, we don't reset 'remaining', so it goes negative and never hits 0 again. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Fix md grow/size code to correctly find the maximum available spaceNeilBrown1-1/+1
An md array can be asked to change the amount of each device that it is using, and in particular can be asked to use the maximum available space. This currently only works if the first device is not larger than the rest. As 'size' gets changed and so 'fit' becomes wrong. So check if a 'fit' is required early and don't corrupt it. Signed-off-by: Doug Ledford <dledford@redhat.com> Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Remove bi_end_io call out from under a spinlockNeilBrown1-2/+4
raid5 overloads bi_phys_segments to count the number of blocks that the request was broken in to so that it knows when the bio is completely handled. Accessing this must always be done under a spinlock. In one case we also call bi_end_io under that spinlock, which probably isn't ideal as bi_end_io could be expensive (even though it isn't allowed to sleep). So we reducde the range of the spinlock to just accessing bi_phys_segments. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Remove some stray semi-colons after functions called in macro..NeilBrown1-2/+2
wait_event_lock_irq puts a ';' after its usage of the 4th arg, so we don't need to. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Improve comments about locking situation in raid5 make_requestNeilBrown1-1/+14
Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Support suspending of IO to regions of an md arrayNeilBrown2-0/+73
This allows user-space to access data safely. This is needed for raid5 reshape as user-space needs to take a backup of the first few stripes before allowing reshape to commence. It will also be useful in cluster-aware raid1 configurations so that all cluster members can leave a section of the array untouched while a resync/recovery happens. A 'start' and 'end' of the suspended range are written to 2 sysfs attributes. Note that only one range can be suspended at a time. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Make 'reshape' a possible sync_action actionNeilBrown1-1/+8
This allows reshape to be triggerred via sysfs (which is the only way to start it happening). Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Split reshape handler in check_reshape and start_reshapeNeilBrown3-33/+56
check_reshape checks validity and does things that can be done instantly - like adding devices to raid1. start_reshape initiates a restriping process to convert the whole array. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Only checkpoint expansion progress occasionallyNeilBrown1-11/+42
Instead of checkpointing at each stripe, only checkpoint when a new write would overwrite uncheckpointed data. Block any write to the uncheckpointed area. Arbitrarily checkpoint at least every 3Meg. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Checkpoint and allow restart of raid5 reshapeNeilBrown3-23/+191
We allow the superblock to record an 'old' and a 'new' geometry, and a position where any conversion is up to. The geometry allows for changing chunksize, layout and level as well as number of devices. When using verion-0.90 superblock, we convert the version to 0.91 while the conversion is happening so that an old kernel will refuse the assemble the array. For version-1, we use a feature bit for the same effect. When starting an array we check for an incomplete reshape and restart the reshape process if needed. If the reshape stopped at an awkward time (like when updating the first stripe) we refuse to assemble the array, and let user-space worry about it. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Final stages of raid5 expand codeNeilBrown3-3/+152
This patch adds raid5_reshape and end_reshape which will start and finish the reshape processes. raid5_reshape is only enabled in CONFIG_MD_RAID5_RESHAPE is set, to discourage accidental use. Read the 'help' for the CONFIG_MD_RAID5_RESHAPE entry. and Make sure that you have backups, just in case. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Core of raid5 resize processNeilBrown2-25/+174
This patch provides the core of the resize/expand process. sync_request notices if a 'reshape' is happening and acts accordingly. It allocated new stripe_heads for the next chunk-wide-stripe in the target geometry, marking them STRIPE_EXPANDING. Then it finds which stripe heads in the old geometry can provide data needed by these and marks them STRIPE_EXPAND_SOURCE. This causes stripe_handle to read all blocks on those stripes. Once all blocks on a STRIPE_EXPAND_SOURCE stripe_head are read, any that are needed are copied into the corresponding STRIPE_EXPANDING stripe_head. Once a STRIPE_EXPANDING stripe_head is full, it is marks STRIPE_EXPAND_READY and then is written out and released. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Infrastructure to allow normal IO to continue while array is ↵NeilBrown1-30/+58
expanding We need to allow that different stripes are of different effective sizes, and use the appropriate size. Also, when a stripe is being expanded, we must block any IO attempts until the stripe is stable again. Key elements in this change are: - each stripe_head gets a 'disk' field which is part of the key, thus there can sometimes be two stripe heads of the same area of the array, but covering different numbers of devices. One of these will be marked STRIPE_EXPANDING and so won't accept new requests. - conf->expand_progress tracks how the expansion is progressing and is used to determine whether the target part of the array has been expanded yet or not. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Allow stripes to be expanded in preparation for expanding an arrayNeilBrown3-7/+130
Before a RAID-5 can be expanded, we need to be able to expand the stripe-cache data structure. This requires allocating new stripes in a new kmem_cache. If this succeeds, we copy cache pages over and release the old stripes and kmem_cache. We then allocate new pages. If that fails, we leave the stripe cache at it's new size. It isn't worth the effort to shrink it back again. Unfortuanately this means we need two kmem_cache names as we, for a short period of time, we have two kmem_caches. So they are raid5/%s and raid5/%s-alt Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Split disks array out of raid5 conf structure so it is easier to ↵NeilBrown2-6/+14
grow The remainder of this batch implements raid5 reshaping. Currently the only shape change that is supported is added a device, but it is envisioned that changing the chunksize and layout will also be supported, as well as changing the level (e.g. 1->5, 5->6). The reshape process naturally has to move all of the data in the array, and so should be used with caution. It is believed to work, and some testing does support this, but wider testing would be great for increasing my confidence. You will need a version of mdadm newer than 2.3.1 to make use of raid5 growth. This is because mdadm need to take a copy of a 'critical section' at the start of the array incase there is a crash at an awkward moment. On restart, mdadm will restore the critical section and allow reshape to continue. I hope to release a 2.4-pre by early next week - it still needs a little more polishing. This patch: Previously the array of disk information was included in the raid5 'conf' structure which was allocated to an appropriate size. This makes it awkward to change the size of that array. So we split it off into a separate kmalloced array which will require a little extra indexing, but is much easier to grow. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Update status_resync to handle LARGE devicesNeilBrown1-6/+24
status_resync - used by /proc/mdstat to report the status of a resync, assumes that device sizes will always fit into an 'unsigned long' This is no longer the case... Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Fix the 'failed' count for version-0 superblocksNeilBrown1-3/+2
We are counting failed devices twice, once of the device that is failed, and once for the hole that has been left in the array. Remove the former so 'failed' matches 'missing'. Storing these counts in the superblock is a bit silly anyway.... Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Add '4' to the list of levels for which bitmaps are supportedNeilBrown1-1/+2
I really should make this a function of the personality.... Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] md: Make sure QUEUE_FLAG_CLUSTER is set properly for md.NeilBrown1-0/+1
This flag should be set for a virtual device iff it is set for all underlying devices. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm: remove unnecessary typecastKevin Corry1-1/+1
Signed-off-by: Kevin Corry <kevcorry@us.ibm.com> Cc: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm/md dependency tree in sysfs: dm to use bd_claim_by_diskJun'ichi Nomura1-10/+10
Use bd_claim_by_disk. Following symlinks are created if dm-0 maps to sda: /sys/block/dm-0/slaves/sda --> /sys/block/sda /sys/block/sda/holders/dm-0 --> /sys/block/dm-0 Signed-off-by: Jun'ichi Nomura <j-nomura@ce.jp.nec.com> Cc: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm/md dependency tree in sysfs: md to use bd_claim_by_diskJun'ichi Nomura1-0/+2
Use bd_claim_by_disk. Following symlinks are created if md0 is built from sda and sdb /sys/block/md0/slaves/sda --> /sys/block/sda /sys/block/md0/slaves/sdb --> /sys/block/sdb /sys/block/sda/holders/md0 --> /sys/block/md0 /sys/block/sdb/holders/md0 --> /sys/block/md0 Signed-off-by: Jun'ichi Nomura <j-nomura@ce.jp.nec.com> Cc: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm store geometryDarrick J. Wong3-1/+104
Allow drive geometry to be stored with a new DM_DEV_SET_GEOMETRY ioctl. Device-mapper will now respond to HDIO_GETGEO. If the geometry information is not available, zero will be returned for all of the parameters. Signed-off-by: Darrick J. Wong <djwong@us.ibm.com> Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm table: store mdMike Anderson4-16/+39
Store an up-pointer to the owning struct mapped_device in every table when it is created. Access it with: struct mapped_device *dm_table_get_md(struct dm_table *t) Tables linked to md must be destroyed before the md itself. Signed-off-by: Mike Anderson <andmike@us.ibm.com> Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm: tidy mdptrAlasdair G Kergon3-12/+16
Change dm_get_mdptr() to take a struct mapped_device instead of dev_t. Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm: store md nameMike Anderson1-0/+2
The patch stores a printable device number in struct mapped_device for use in warning messages and with a proposed netlink interface. Signed-off-by: Mike Anderson <andmike@us.ibm.com> Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm flush queue EINTRJun'ichi Nomura1-1/+4
If dm_suspend() is cancelled, bios already added to the deferred list need to be submitted. Otherwise they remain 'in limbo' until there's a dm_resume(). Signed-off-by: Jun'ichi Nomura <j-nomura@ce.jp.nec.com> Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm snapshot: fix kcopyd destructorAlasdair G Kergon2-2/+21
Before removing a snapshot, wait for the completion of any kcopyd jobs using it. Do this by maintaining a count (nr_jobs) of how many outstanding jobs each kcopyd_client has. The snapshot destructor first unregisters the snapshot so that no new kcopyd jobs (created by writes to the origin) will reference that particular snapshot. kcopyd_client_destroy() is now run next to wait for the completion of any outstanding jobs before the snapshot exception structures (that those jobs reference) are freed. Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm: make sure QUEUE_FLAG_CLUSTER is set properlyNeilBrown1-0/+9
This flag should be set for a virtual device iff it is set for all underlying devices. Signed-off-by: Neil Brown <neilb@suse.de> Acked-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] dm: remove SECTOR_FORMATAndrew Morton6-34/+32
We don't know what type sector_t has. Sometimes it's unsigned long, sometimes it's unsigned long long. For example on ppc64 it's unsigned long with CONFIG_LBD=n and on x86_64 it's unsigned long long with CONFIG_LBD=n. The way to handle all of this is to always use unsigned long long and to always typecast the sector_t when printing it. Acked-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] drivers/md/dm-raid1.c: Fix inconsistent mirroring after interrupted ↵Jun'ichi Nomura1-1/+13
recovery dm-mirror has potential data corruption problem: while on-disk log shows that all disk contents are in-sync, actual contents of the disks are not synchronized. This problem occurs if initial recovery (synching) is interrupted and resumed. Attached patch fixes this problem. Background: rh_dec() changes the region state from RH_NOSYNC (out-of-sync) to RH_CLEAN (in-sync), which results in the corresponding bit of clean_bits being set. This is harmful if on-disk log is used and the map is removed/suspended before the initial sync is completed. The clean_bits is written down to the on-disk log at the map removal, and, upon resume, it's read and copied to sync_bits. Since the recovery process refers to the sync_bits to find a region to be recovered, the region whose state was changed from RH_NOSYNC to RH_CLEAN is no longer recovered. If you haven't applied dm-raid1-read-balancing.patch proposed in dm-devel sometimes ago, the contents of the mirrored disk just corrupt silently. If you have, balanced read may get bogus data from out-of-sync disks. The patch keeps RH_NOSYNC state unchanged. It will be changed to RH_RECOVERING when recovery starts and get reclaimed when the recovery completes. So it doesn't leak the region hash entry. Description: Keep RH_NOSYNC state unchanged when I/O on the region completes. rh_dec() changes the region state from RH_NOSYNC (out-of-sync) to RH_CLEAN (in-sync), which results in the corresponding bit of clean_bits being set. This is harmful if on-disk log is used and the map is removed/suspended before the initial sync is completed. The clean_bits is written down to the on-disk log at the map removal, and, upon resume, it's read and copied to sync_bits. Since the recovery process refers to the sync_bits to find a region to be recovered, the region whose state was changed from RH_NOSYNC to RH_CLEAN is no longer recovered. If you haven't applied dm-raid1-read-balancing.patch proposed in dm-devel sometimes ago, the contents of the mirrored disk just corrupt silently. If you have, balanced read may get bogus data from out-of-sync disks. The RH_NOSYNC region will be changed to RH_RECOVERING when recovery starts on the region and get reclaimed when the recovery completes. So it doesn't leak the region hash entry. Alasdair said: I've analysed the relevant part of the state machine and I believe that the patch is correct. (Further work on this code is still needed - this patch has the side-effect of holding onto memory unnecessarily for long periods of time under certain workloads - but better that than corrupting data.) Signed-off-by: Jun'ichi Nomura <j-nomura@ce.jp.nec.com> Acked-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] device-mapper snapshot: fix invalidationAlasdair G Kergon1-121/+174
When a snapshot becomes invalid, s->valid is set to 0. In this state, a snapshot can no longer be accessed. When s->lock is acquired, before doing anything else, s->valid must be checked to ensure the snapshot remains valid. This patch eliminates some races (that may cause panics) by adding some missing checks. At the same time, some unnecessary levels of indentation are removed and snapshot invalidation is moved into a single function that always generates a device-mapper event. Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] device-mapper snapshot: replace sibling listAlasdair G Kergon1-42/+80
The siblings "list" is used unsafely at the moment. Firstly, only the element on the list being changed gets locked (via the snapshot lock), not the next and previous elements which have pointers that are also being changed. Secondly, if you have two or more snapshots and write to the same chunk a second time before every snapshot has finished making its private copy of the data, if you're unlucky, _origin_write() could attempt its list_merge() and dereference a 'last' pointer to a pending_exception structure that has just been freed. Analysis reveals that the list is actually only there for reference counting. If 5 pending_exceptions are needed in origin_write, then the 5 are joined together into a 5-element list - without a separate list head because there's nowhere suitable to store it. As the pending_exceptions complete, they are removed from the list one-by-one and any contents of origin_bios get moved across to one of the remaining pending_exceptions on the list. Whichever one is last is detected because list_empty() is then true and the origin_bios get submitted. The fix proposed here uses an alternative reference counting mechanism by choosing one of the pending_exceptions as primary and maintaining an atomic counter there. Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] device-mapper snapshot: fix origin_write pending_exception submissionAlasdair G Kergon1-22/+19
Say you have several snapshots of the same origin and then you issue a write to some place in the origin for the first time. Before the device-mapper snapshot target lets the write go through to the underlying device, it needs to make a copy of the data that is about to be overwritten. Each snapshot is independent, so it makes one copy for each snapshot. __origin_write() loops through each snapshot and checks to see whether a copy is needed for that snapshot. (A copy is only needed the first time that data changes.) If a copy is needed, the code allocates a 'pending_exception' structure holding the details. It links these together for all the snapshots, then works its way through this list and submits the copying requests to the kcopyd thread by calling start_copy(). When each request is completed, the original pending_exception structure gets freed in pending_complete(). If you're very unlucky, this structure can get freed *before* the submission process has finished walking the list. This patch: 1) Creates a new temporary list pe_queue to hold the pending exception structures; 2) Does all the bookkeeping up-front, then walks through the new list safely and calls start_copy() for each pending_exception that needed it; 3) Avoids attempting to add pe->siblings to the list if it's already connected. [NB This does not fix all the races in this code. More patches will follow.] Signed-off-by: Alasdair G Kergon <agk@redhat.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] video/sis/init301.c:SiS_ChrontelDoSomething2(): remove dead codeAdrian Bunk1-10/+1
The Coverity checker spotted these two unused variables. Signed-off-by: Adrian Bunk <bunk@stusta.de> Cc: "Antonino A. Daplas" <adaplas@pol.net> Cc: Thomas Winischhofer <thomas@winischhofer.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] drivers/video: Use ARRAY_SIZE macroTobias Klauser17-57/+58
Use ARRAY_SIZE macro instead of sizeof(x)/sizeof(x[0]) and remove duplicates of ARRAY_SIZE. Some coding style and trailing whitespaces are also fixed. Compile-tested where possible (some are other arch or BROKEN) Signed-off-by: Tobias Klauser <tklauser@nuerscht.ch> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] fbdev: add modeline for 1680x1050@60Olaf Hering1-0/+4
Add a modeline for the Philips 200W display. aty128fb does not do DDC, it picks 1920x1440 or similar. It works ok with nvidiafb because it can ask for DDC data. mode "1680x1050-60" # D: 146.028 MHz, H: 65.191 kHz, V: 59.863 Hz geometry 1680 1050 1680 1050 16 timings 6848 280 104 30 3 176 6 hsync high vsync high rgba 5/11,6/5,5/0,0/0 endmode hwinfo --monitor 20: None 00.0: 10000 Monitor [Created at monitor.206] Unique ID: rdCR.pzUFTofo1S4 Parent ID: 002j.bJRsY88eNSC Hardware Class: monitor Model: "PHILIPS Philips 200W" Vendor: PHL "PHILIPS" Device: eisa 0x0832 "Philips 200W" Serial ID: "VN 016596" Resolution: 720x400@70Hz Resolution: 640x480@60Hz Resolution: 640x480@67Hz Resolution: 640x480@72Hz Resolution: 640x480@75Hz Resolution: 800x600@56Hz Resolution: 800x600@60Hz Resolution: 800x600@72Hz Resolution: 800x600@75Hz Resolution: 832x624@75Hz Resolution: 1024x768@60Hz Resolution: 1024x768@70Hz Resolution: 1024x768@75Hz Resolution: 1280x1024@75Hz Resolution: 1152x864@70Hz Resolution: 1152x864@75Hz Resolution: 1280x960@60Hz Resolution: 1280x1024@60Hz Resolution: 1680x1050@60Hz Size: 433x271 mm Driver Info #0: Max. Resolution: 1680x1050 Vert. Sync Range: 56-85 Hz Hor. Sync Range: 30-93 kHz Config Status: cfg=new, avail=yes, need=no, active=unknown Attached to: #5 (VGA compatible controller) Signed-off-by: Olaf Hering <olh@suse.de> Acked-by: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] sparse: Fix warnings in newport driver about non-static functionsRalf Baechle1-2/+2
There are more sparse warnings but fixing those will require some more work than I want to do without hardware for testing at hand. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] Add ID for Quadro NVS280Pavel Roskin1-0/+2
Quadro NVS280 is a dual-head PCIe card with PCI ID 10de:00fd and subsystem ID 10de:0215. Signed-off-by: Pavel Roskin <proski@gnu.org> Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] imsttfb: Remove dead codeAntonino A. Daplas1-4/+4
clk_p is always 0. Coverity Bug 67 Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] atyfb: Remove dead codeAntonino A. Daplas1-3/+5
Remove code that can never be reached. Coverity Bug 67 Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] savagefb: Remove NULL checkAntonino A. Daplas1-2/+1
Remove unnecessary NULL check. Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] i810fb: Remove NULL checkAntonino A. Daplas1-2/+1
Remove unnecessary NULL check. Being a function private to the driver, out_edid can never be NULL. Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] nvidiafb: Remove NULL check #2Antonino A. Daplas1-2/+1
Remove unnecessary NULL check. Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] nvidiafb: Remove NULL checkAntonino A. Daplas1-2/+0
Remove unnecessary NULL check, as struct info will never be NULL. Coverity Bug 835 Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] rivafb: Remove NULL checkAntonino A. Daplas1-2/+0
Remove unnecessary NULL check, as struct info will never be NULL. Coverity Bug 836 Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] framebuffer: cmap-setting return valuesAlan Curry3-7/+7
A set of 3 small bugfixes, all of which are related to bogus return values of fb colormap-setting functions. First, fb_alloc_cmap returns -1 if memory allocation fails. This is a hard condition to reproduce since you'd have to be really low on memory, but from studying the contexts in which it is called, I think this function should be returning a negative errno, and the -1 will be seen as an EPERM. Switching it to -ENOMEM makes sense. Second, the store_cmap function which is called for writes to /sys/class/graphics/fb0/color_map returns 0 for success, but it should be returning the count of bytes written since its return value ends up in userspace as the result of the write() syscall. Third, radeonfb returns 1 instead of a negative errno when FBIOPUTCMAP is called with an oversized colormap. This is seen in userspace as a return value of 1 from the ioctl() syscall with errno left unchanged. A more useful return value would be -EINVAL. Signed-off-by: Alan Curry <pacman@TheWorld.com> Cc: "Antonino A. Daplas" <adaplas@pol.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] fbdev: Make BIOS EDID reading configurableAntonino A. Daplas2-3/+19
DDC reading via the Video BIOS may take several tens of seconds with some combination of display cards and monitors. Make this option configurable. It defaults to `y' to minimise disruption. Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] au1200fb: Alchemy Au1200 framebuffer driverRalf Baechle4-0/+4428
Add support for Alchemy Au1200 framebuffer driver Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] matrox maven: memory allocation and other cleanupsJean Delvare1-30/+25
A few cleanups which were done to almost all i2c drivers some times ago, but matroxfb_maven was forgotten: * Don't allocate two different structures at once. * Use kzalloc instead of kmalloc+memset. * Use strlcpy instead of strcpy. * Drop duplicate error message on client deregistration failure. Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: Petr Vandrovec <vandrove@vc.cvut.cz> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] matroxfb: simply return what i2c_add_driver() doesArthur Othieno1-12/+5
insmod will tell us when the module failed to load. We do no further processing on the return from i2c_add_driver(), so just return what i2c_add_driver() did, instead of storing it. Add __init/__exit annotations while we're at it. Signed-off-by: Arthur Othieno <apgo@patchbomb.org> Acked-by: Jean Delvare <khali@linux-fr.org> Acked-by: Petr Vandrovec <petr@vandrovec.name> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] fbdev: framebuffer driver for Geode GXDavid Vrabel7-2/+1003
A framebuffer driver for the display controller in AMD Geode GX processors (Geode GX533, Geode GX500 etc.). Tested at 640x480, 800x600, 1024x768 and 1280x1024 at 8, 16, and 24 bpp with both CRT and TFT. No accelerated features currently implemented and compression remains disabled. This driver requires that the BIOS (or the SoftVG/Firmbase code in the BIOS) has created an appropriate virtual PCI header. Signed-off-by: David Vrabel <dvrabel@arcom.com> Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] nvidiafb: add suspend and resume hooksAntonino A. Daplas3-31/+97
Add suspend and resume hooks to make software suspend more reliable. Resuming from standby should generally work. Resuming from mem and from disk requires that the GPU is disabled. Adding these to the suspend script... fbset -accel false -a /* suspend here */ fbset -accel true -a ... should generally work. In addition, resuming from mem requires that the video card has to be POSTed by the BIOS or some other utility. Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] vgacon: Add support for soft scrollbackAntonino A. Daplas2-43/+225
The scrollback buffer of the VGA console is located in VGA RAM. This RAM is fixed in size and is very small. To make the scrollback buffer larger, it must be placed instead in System RAM. This patch adds this feature. The feature and the size of the buffer are made as a kernel config option. Besides consuming kernel memory, this feature will slow down the console by approximately 20%. Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Cc: Jindrich Makovicka <makovick@kmlinux.fjfi.cvut.cz> Cc: Martin Mares <mj@ucw.cz> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] vgacon: fix EGA cursor resize functionSamuel Thibault1-8/+19
This corrects cursor resize on ega boards: registers are write-only, so we shouldn't even try to read them. And on ega, 31/30 produces a flat cursor. Using 31/31 is better: except with 32 pixels high fonts, it shouldn't show up. Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] pnp: PNP: adjust pnp_register_driver signatureBjorn Helgaas2-27/+8
Remove the assumption that pnp_register_driver() returns the number of devices claimed. Returning the count is unreliable because devices may be hot-plugged in the future. This changes the convention to "zero for success, or a negative error value," which matches pci_register_driver(), acpi_bus_register_driver(), and platform_driver_register(). Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Cc: Adam Belay <ambx1@neo.rr.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] pnp: IRDA: adjust pnp_register_driver signatureBjorn Helgaas1-1/+1
Remove the assumption that pnp_register_driver() returns the number of devices claimed. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Cc: Adam Belay <ambx1@neo.rr.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] pnp: parport: adjust pnp_register_driver signatureBjorn Helgaas1-20/+11
Remove the assumption that pnp_register_driver() returns the number of devices claimed. parport_pc_init() does nothing with "count", so remove it. Then nobody uses the return value of parport_pc_find_ports(), so make it void. Finally, update pnp_register_driver() usage. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Cc: Adam Belay <ambx1@neo.rr.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: M48T86 driverAlessandro Zummo3-0/+220
Add a driver for the ST M48T86 / Dallas DS12887 RTC. This is a platform driver. The platform device must provide I/O routines to access the RTC. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Cc: Greg KH <greg@kroah.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: SA1100/PXA2XX driverRichard Purdie3-0/+398
Add an RTC subsystem driver for the ARM SA1100/PXA2XX processor RTC. Signed-off-by: Richard Purdie <rpurdie@rpsys.net> Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: EP93XX driverAlessandro Zummo3-1/+174
This patch adds a driver for the RTC embedded in the Cirrus Logic EP93XX family of processors. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: RS5C372 driverAlessandro Zummo3-0/+305
RTC class aware driver for the Ricoh RS5C372 chip used, among others, on the Synology DS101. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: PCF8563 driverAlessandro Zummo3-0/+365
An RTC class aware driver for the Philips PCF8563 RTC and Epson RTC8564 chips. This chip is used on the Iomega NAS100D. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: DS1672 driverAlessandro Zummo3-0/+244
Driver for the Dallas/Maxim DS1672 chip, found on the Loft (http://www.giantshoulderinc.com). Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: test device/driverAlessandro Zummo3-0/+220
Interrupts can be generated by echo "alarm|tick|update" >/sys/class/rtc/rtcX/device/irq Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: X1205 driverAlessandro Zummo3-0/+632
A port of the existing x1205 driver under the new RTC subsystem. It is actually under test within the NSLU2 project (http://www.nslu2-linux.org) and it is working quite well. It is the first driver under this new subsystem and should be used as a guide to port other drivers. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: dev interfaceAlessandro Zummo3-0/+394
Add the dev interface to the RTC subsystem. Each RTC will be available under /dev/rtcX . A symlink from /dev/rtc0 to /dev/rtc cab be obtained with the following udev rule: KERNEL=="rtc0", SYMLINK+="rtc" Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: proc interfaceAlessandro Zummo3-1/+174
Add the proc interface to the RTC subsystem. The first RTC driver which registers with the class will be accessible by /proc/driver/rtc . This is required for compatibility with the standard RTC driver and to avoid breaking any user space application which may erroneusly rely on this. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: sysfs interfaceAlessandro Zummo3-0/+138
This patch adds the sysfs interface to the RTC subsystem. Each RTC client will have his own entry under /sys/classs/rtc/rtcN . Within this entry some attributes are exported by the subsystem, like date and time. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: I2C cleanupAlessandro Zummo5-1181/+0
This patch, completely optional, removes from drivers/i2c/chips all the drivers that are implemented in the new RTC subsystem. It should be noted that none of the current driver is actually integrated, i.e. usable without further patches. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: classAlessandro Zummo5-3/+537
Add the basic RTC subsystem infrastructure to the kernel. rtc/class.c - registration facilities for RTC drivers rtc/interface.c - kernel/rtc interface functions rtc/hctosys.c - snippet of code that copies hw clock to sw clock at bootup, if configured to do so. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC subsystem: ARM cleanupAlessandro Zummo1-1/+1
This patch removes from the ARM subsytem some of the rtc-related functions that have been included in the RTC subsystem. It also fixes some naming collisions. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] RTC Subsystem: library functionsAlessandro Zummo5-0/+115
RTC and date/time related functions. Signed-off-by: Alessandro Zummo <a.zummo@towertech.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] Notifier chain update: API changesAlan Stern18-155/+113
The kernel's implementation of notifier chains is unsafe. There is no protection against entries being added to or removed from a chain while the chain is in use. The issues were discussed in this thread: http://marc.theaimsgroup.com/?l=linux-kernel&m=113018709002036&w=2 We noticed that notifier chains in the kernel fall into two basic usage classes: "Blocking" chains are always called from a process context and the callout routines are allowed to sleep; "Atomic" chains can be called from an atomic context and the callout routines are not allowed to sleep. We decided to codify this distinction and make it part of the API. Therefore this set of patches introduces three new, parallel APIs: one for blocking notifiers, one for atomic notifiers, and one for "raw" notifiers (which is really just the old API under a new name). New kinds of data structures are used for the heads of the chains, and new routines are defined for registration, unregistration, and calling a chain. The three APIs are explained in include/linux/notifier.h and their implementation is in kernel/sys.c. With atomic and blocking chains, the implementation guarantees that the chain links will not be corrupted and that chain callers will not get messed up by entries being added or removed. For raw chains the implementation provides no guarantees at all; users of this API must provide their own protections. (The idea was that situations may come up where the assumptions of the atomic and blocking APIs are not appropriate, so it should be possible for users to handle these things in their own way.) There are some limitations, which should not be too hard to live with. For atomic/blocking chains, registration and unregistration must always be done in a process context since the chain is protected by a mutex/rwsem. Also, a callout routine for a non-raw chain must not try to register or unregister entries on its own chain. (This did happen in a couple of places and the code had to be changed to avoid it.) Since atomic chains may be called from within an NMI handler, they cannot use spinlocks for synchronization. Instead we use RCU. The overhead falls almost entirely in the unregister routine, which is okay since unregistration is much less frequent that calling a chain. Here is the list of chains that we adjusted and their classifications. None of them use the raw API, so for the moment it is only a placeholder. ATOMIC CHAINS ------------- arch/i386/kernel/traps.c: i386die_chain arch/ia64/kernel/traps.c: ia64die_chain arch/powerpc/kernel/traps.c: powerpc_die_chain arch/sparc64/kernel/traps.c: sparc64die_chain arch/x86_64/kernel/traps.c: die_chain drivers/char/ipmi/ipmi_si_intf.c: xaction_notifier_list kernel/panic.c: panic_notifier_list kernel/profile.c: task_free_notifier net/bluetooth/hci_core.c: hci_notifier net/ipv4/netfilter/ip_conntrack_core.c: ip_conntrack_chain net/ipv4/netfilter/ip_conntrack_core.c: ip_conntrack_expect_chain net/ipv6/addrconf.c: inet6addr_chain net/netfilter/nf_conntrack_core.c: nf_conntrack_chain net/netfilter/nf_conntrack_core.c: nf_conntrack_expect_chain net/netlink/af_netlink.c: netlink_chain BLOCKING CHAINS --------------- arch/powerpc/platforms/pseries/reconfig.c: pSeries_reconfig_chain arch/s390/kernel/process.c: idle_chain arch/x86_64/kernel/process.c idle_notifier drivers/base/memory.c: memory_chain drivers/cpufreq/cpufreq.c cpufreq_policy_notifier_list drivers/cpufreq/cpufreq.c cpufreq_transition_notifier_list drivers/macintosh/adb.c: adb_client_list drivers/macintosh/via-pmu.c sleep_notifier_list drivers/macintosh/via-pmu68k.c sleep_notifier_list drivers/macintosh/windfarm_core.c wf_client_list drivers/usb/core/notify.c usb_notifier_list drivers/video/fbmem.c fb_notifier_list kernel/cpu.c cpu_chain kernel/module.c module_notify_list kernel/profile.c munmap_notifier kernel/profile.c task_exit_notifier kernel/sys.c reboot_notifier_list net/core/dev.c netdev_chain net/decnet/dn_dev.c: dnaddr_chain net/ipv4/devinet.c: inetaddr_chain It's possible that some of these classifications are wrong. If they are, please let us know or submit a patch to fix them. Note that any chain that gets called very frequently should be atomic, because the rwsem read-locking used for blocking chains is very likely to incur cache misses on SMP systems. (However, if the chain's callout routines may sleep then the chain cannot be atomic.) The patch set was written by Alan Stern and Chandra Seetharaman, incorporating material written by Keith Owens and suggestions from Paul McKenney and Andrew Morton. [jes@sgi.com: restructure the notifier chain initialization macros] Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Chandra Seetharaman <sekharan@us.ibm.com> Signed-off-by: Jes Sorensen <jes@sgi.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27[PATCH] hostap: Fix EAPOL frame encryptionJouni Malinen1-1/+1
Fixed encrypted of EAPOL frames from wlan#ap interface (hostapd). This was broken when moving to use new frame control field defines in net/ieee80211.h. hostapd uses Protected flag, not protocol version (which was cleared in this function anyway). This fixes WPA group key handshake and re-authentication. http://hostap.epitest.fi/bugz/show_bug.cgi?id=126 Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-27[PATCH] hostap: Make hostap_tx_encrypt() staticJouni Malinen2-6/+3
hostap_tx_encrypt() is used only inside hostap_80211_tx.c and there are no plans to use it elsewhere in the future either, so let's make it static. As a bonus, this should silence Coverity scanner from complaining about bogus FORWARD_NULL case (CID: 274). Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-27[PATCH] zd1201 wireless stat updateJean Tourrilhes1-1/+1
The "dev->get_wireless_stats" field is deprecated and slowly be surely going away. Most drivers have been updated months ago. Actually, there is an annoying message for driver still using it, but it seems that user of zd1201 were not annoyed enough ;-) Signed-off-by: Jean Tourrilhes <jt@hpl.hp.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2006-03-27[PATCH] PCMCIA_SPECTRUM must select FW_LOADERAdrian Bunk1-0/+1
PCMCIA_SPECTRUM must select FW_LOADER. Reported by "Alexander E. Patrakov" <patrakov@ums.usu.ru>. Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>