Commit Graph

5031 Commits

Author SHA1 Message Date
Linus Torvalds 541ab4af11 Don't touch USB controller IO registers when they are disabled
The USB "handoff" code is an early PCI quirk to make sure we own the USB
controller (as opposed to the BIOS/SMM).  But if the controller isn't
even enabled yet, don't try to access it.

Acked-by: Paul Mackerras <paulus@samba.org> (who had an alternate patch)
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-31 21:12:40 -08:00
Andrew Morton a717f77362 [PATCH] revert ide-scsi highmem cleanup
Jeff Garzik <jgarzik@pobox.com> points out that this was wrong: we need to
disable local interrupts while holding KM_IRQ0 due to IRQ sharing.

And holding interrupts off during a big PIO opration is expensive, so we only
want to do that if we know the page was highmem.

So revert commit 17fd47ab4d

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-31 14:22:04 -08:00
Arthur Othieno f2c84c0e84 [PATCH] i386: CONFIG_PC removal
CONFIG_PC is left-over cruft after the introduction of CONFIG_X86_PC with
the subarch split.  Remove it, and fixup the remaining users to depend on
CONFIG_X86_PC instead.

Signed-off-by: Arthur Othieno <a.othieno@bluewin.ch>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-31 09:20:54 -08:00
Jens Axboe 581c1b1439 [PATCH] noop-iosched: avoid corrupted request merging
Tejun Heo notes:

   "I'm currently debugging this.  The problem is that we are using the
    generic dispatch queue directly in the noop sched and merging is NOT
    allowed on dispatch queues but generic handling of last_merge tries
    to merge requests.  I'm still trying to verify this, so I'll be back
    with results soon."

In the meantime, disable merging for noop by setting REQ_NOMERGE in
elevator_noop_add_request().

Eventually, we should add a noop_list and do the dispatching like in the
other io schedulers.  Merging is still beneficial for noop (and it has
always done it).

Signed-off-by: Jens Axboe <axboe@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-31 07:46:28 -08:00
Jens Axboe 4fc207419d [PATCH] Fix on-the-fly switch from cfq i/o scheduler
Don't clear ->elevator_data on exit, if we are switching queues we are
overwriting the data of the new io scheduler.

Signed-off-by: Jens Axboe <axboe@suse.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-31 07:41:28 -08:00
Linus Torvalds c1d962035d Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/libata-dev 2005-10-31 07:34:07 -08:00
Linus Torvalds 4fd5f8267d Merge master.kernel.org:/home/rmk/linux-2.6-drvmodel
Manual #include fixups for clashes - there may be some unnecessary
2005-10-31 07:32:56 -08:00
Paul Mackerras eb16292ba8 Input: adbhid - fix OOPS introduced by dynalloc conversion
The problem is that adbhid[]->input is NULL, so the kernel oopses with
a null pointer dereference as soon as a key is pressed.

Signed-off-by: Paul Mackerras <paulus@samba.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2005-10-31 01:30:32 -05:00
Dmitry Torokhov 76440d5e13 Input: lkkbd - fix debug message in lkkbd_interrupt()
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2005-10-31 01:30:19 -05:00
Dmitry Torokhov 1259f2b365 Input: pcspkr - fix setting name and phys for the device
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2005-10-31 01:30:05 -05:00
Dmitry Torokhov 995fc4df0b Input: fix input_dev registration message
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2005-10-31 01:29:51 -05:00
Dmitry Torokhov 7972720aaa Input: evdev - allow querying SW state from compat ioctl
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2005-10-31 01:29:37 -05:00
Dmitry Torokhov e0be618d1e Input: evdev - allow querying EV_SW bits from compat_ioctl
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2005-10-31 01:29:23 -05:00
Jeff Garzik 005a5a06a6 [libata] locking rewrite (== fix)
A lot of power packed into a little patch.

This change eliminates the sharing between our controller-wide spinlock
and the SCSI core's Scsi_Host lock.  As the locking in libata was
already highly compartmentalized, always referencing our own lock, and
never scsi_host::host_lock.

As a side effect, this change eliminates a deadlock from calling
scsi_finish_command() while inside our spinlock.
2005-10-30 23:31:48 -05:00
Jeff Garzik e533825447 [libata] ata_tf_to_host cleanups
Integrate ata_exec() and ata_tf_to_host() into their only caller,
ata_bus_edd().

Rename ata_tf_to_host_nolock() to ata_tf_to_host().

This makes locking a bit easier to review, and may help pave the way for
future changes.
2005-10-30 21:37:17 -05:00
Paul Mackerras 23fd07750a Merge ../linux-2.6 by hand 2005-10-31 13:37:12 +11:00
Linus Torvalds ed28f96ac1 Merge master.kernel.org:/home/rmk/linux-2.6-serial 2005-10-30 17:48:37 -08:00
Linus Torvalds 1480d0a31d Merge master.kernel.org:/home/rmk/linux-2.6-arm 2005-10-30 17:48:00 -08:00
Linus Torvalds fc8e3d177f Merge master.kernel.org:/home/rmk/linux-2.6-mmc 2005-10-30 17:47:00 -08:00
Tim Schmielau 4e57b68178 [PATCH] fix missing includes
I recently picked up my older work to remove unnecessary #includes of
sched.h, starting from a patch by Dave Jones to not include sched.h
from module.h. This reduces the number of indirect includes of sched.h
by ~300. Another ~400 pointless direct includes can be removed after
this disentangling (patch to follow later).
However, quite a few indirect includes need to be fixed up for this.

In order to feed the patches through -mm with as little disturbance as
possible, I've split out the fixes I accumulated up to now (complete for
i386 and x86_64, more archs to follow later) and post them before the real
patch.  This way this large part of the patch is kept simple with only
adding #includes, and all hunks are independent of each other.  So if any
hunk rejects or gets in the way of other patches, just drop it.  My scripts
will pick it up again in the next round.

Signed-off-by: Tim Schmielau <tim@physik3.uni-rostock.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:32 -08:00
Randy Dunlap 3e6716e748 [PATCH] hpet: hpet driver cleanups
- Use kzalloc() instead of kmalloc + memset.
- Clean/fix some printk's.
- Use NULL for pointers instead of 0.
- Combine hpet busy searching locations into a function call.

Signed-off-by: Randy Dunlap <randy_d_dunlap@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:31 -08:00
Randy Dunlap b6ab126211 [PATCH] hpet: use HPET physical addresses for dup. detection
- Use HPET physical address to detect duplicates, not logical addresses.
  Using logical (mapped) addresses fails to detect duplicates
  because ioremap() returns a new mapped address each time.

- iounmap() regions when duplicate/busy areas are found.

Signed-off-by: Randy Dunlap <randy_d_dunlap@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:31 -08:00
Randy Dunlap 757c472409 [PATCH] hpet: allow HPET FIXED_MEM32 resource type
Allow the ACPI HPET description table to use a resource type of FIXED_MEM32
for the HPET reource.  Use the fixed resoure size of 1 KB for the HPET
resource as per the HPET spec.

Signed-off-by: Randy Dunlap <randy_d_dunlap@linux.intel.com>
Acked-by: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:31 -08:00
Clemens Ladisch 318db8f03b [PATCH] hpet: simplify initialization message
When booting, display the timer frequency in Hertz instead of as tick length
in nanoseconds.  Apart from saving a local variable, this makes the message
more easily comprehensible.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Cc: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:31 -08:00
Clemens Ladisch c860ed9fb5 [PATCH] hpet: remove superfluous indirections
In the hpet_ioctl_common() function, devp->hd_hpets is already cached in the
hpetp variable, so we can use just that.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Cc: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:30 -08:00
Clemens Ladisch 3d5640d1c7 [PATCH] hpet: fix access to multiple HPET devices
Fix two instances where a function would access the first HPET device instead
of the current one.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Cc: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:30 -08:00
Clemens Ladisch 7522e4ecdf [PATCH] hpet: fix uninitialized variable in hpet_register()
Clear the ht_opaque field in the hpet_register() function before searching for
a free timer to prevent the function from incorrectly assuming that the search
succeeded afterwards.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Cc: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:30 -08:00
Clemens Ladisch af95eade68 [PATCH] hpet: fix division by zero in HPET_INFO
Fix a division by zero that happened when the HPET_INFO ioctl was called
before a timer frequency had been set.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Cc: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:30 -08:00
Clemens Ladisch 8e8505be9c [PATCH] hpet: fix HPET_INFO calls from kernel space
Fix a wrong memory access in hpet_ioctl_common().  It was not possible to use
the HPET_INFO ioctl from kernel space because it always called copy_to_user().

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Cc: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:30 -08:00
Clemens Ladisch 0d29086177 [PATCH] hpet: allow shared interrupts
This patch adds support for shared HPET interrupts.

The driver previously acknowledged interrupts for both edge and level
interrupts, but didn't actually allow a shared interrupt in the latter case.

We use a new per-timer flag to save whether the timer's interrupt might be
shared, and use it to do the processing required for level interrupts only if
necessary.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Acked-by: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:29 -08:00
Clemens Ladisch 189e2dd137 [PATCH] hpet: allow non-power-of-two frequencies
It was only the RTC hardware that restricted interrupt frequencies to a power
of two.  There is no reason to take over this restriction into the HPET
driver, so remove the offending check.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Acked-by: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:29 -08:00
Clemens Ladisch 3f992e1bb7 [PATCH] hpet: remove superfluous register reads
This patch removes several reads of a timer's config register that serve no
purpose whatsoever.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Acked-by: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:29 -08:00
Clemens Ladisch 642d30bbc7 [PATCH] hpet: remove unused variable
The variable hpet_ntimer is never read, so remove it.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Acked-by: Bob Picco <bob.picco@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:29 -08:00
Clemens Ladisch ba3f213f8a [PATCH] HPET: make frequency calculations 32 bit safe
On 32-bit architectures, the multiplication in the argument for
hpet_time_div() often overflows.  In the typical case of a 14.32 MHz timer,
this happens when the desired frequency exceeds 61 Hz.

To avoid this multiplication, we can precompute and store the hardware
timer frequency, instead of the period, in the device structure, which
leaves us with a simple division when computing the number of timer ticks.

As a side effect, this also removes a theoretical bug where the timer
interpolator's frequency would be computed as a 32-bit value even if the
HPET frequency is greater than 2^32 Hz (the HPET spec allows up to 10 GHz).

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:29 -08:00
Clemens Ladisch 9090e6db87 [PATCH] hpet: disallow zero interrupt frequency
Disallow setting an interrupt frequency of zero (which would result in a
division by zero), and disallow enabling the interrupt when the frequency
hasn't yet been set (which would use an interrupt period of zero).

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:29 -08:00
Randy Dunlap 874ec33ff9 [PATCH] sparse cleanups: NULL pointers, C99 struct init.
Convert most of the remaining "Using plain integer as NULL pointer" sparse
warnings to use NULL.  (Not duplicating patches that are already in -mm,
-bird, or -kj.)

Convert isdn driver struct initializer to use C99 syntax.

Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:29 -08:00
Andrew Morton b888c87b74 [PATCH] tpm-tidies
- Various whitespace fixes

- Use kzalloc()

Acked-by: Kylene Hall <kjhall@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:29 -08:00
Marcel Selhorst 1b8333b02a [PATCH] Infineon TPM: move infineon driver off pci_dev
Move the Infineon TPM driver off pci device and makes it a pure pnp-driver.
It includes pnp-port validation and region requesting.

Signed-off-by: Marcel Selhorst <selhorst@crypto.rub.de>
Signed-off-by: Kylene Hall <kjhall@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:28 -08:00
Kylene Jo Hall 570302a311 [PATCH] tpm: move nsc driver off pci_dev
This patch changes the nsc driver from a pci driver to a platform driver.

Signed-off-by: Kylene Hall <kjhall@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:28 -08:00
Kylene Jo Hall 682e97acea [PATCH] tpm: move atmel driver off pci_dev
This patch changes the atmel driver from a pci driver to a platform driver.

Signed-off-by: Kylene Hall <kjhall@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:28 -08:00
Kylene Jo Hall ce2c87d4f7 [PATCH] tpm: change from pci_dev to dev power management functions
This patch is in support of moving away from the lpc bus pci_dev.  The power
management prototypes used by platform drivers is different but the
functionality remains the same.

Signed-off-by: Kylene Hall <kjhall@us.ibm.com
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:28 -08:00
Kylene Jo Hall e659a3fe20 [PATCH] tpm: remove pci dependency
Since the tpm does not have it's own pci id we have been consuming the lpc
bus.  This is not correct and causes problems to support non lpc bus chips.
This patch removes the dependency on pci_dev from tpm.c The subsequent patches
will stop the supported chips from registering as pci drivers.

Signed-off-by: Kylene Hall <kjhall@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:28 -08:00
Kylene Jo Hall b4ed3e3cbb [PATCH] tpm: add status function to allow non-lpc bus chips
This patch is in preparation of supporting chips that are not necessarily on
the lpc bus and thus are not accessed with inb's and outb's.  The patch
replaces the call to get the chip's status in the tpm.c file with a vendor
specific status function.  The patch also defines the function for each of the
current supported devices.

Signed-off-by: Kylene Hall <kjhall@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:28 -08:00
Andi Kleen 162a88f7b8 [PATCH] Don't set dcdbas driver to default m
It's nasty to set random drivers to default m because people who just press
enter on make oldconfig get these.  Remove the default m

Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:28 -08:00
Bjorn Helgaas d269cdd0e2 [PATCH] rocketport: make it work when statically linked into kernel
The driver had incorrectly wrapped module_init(rp_init) in #ifdef MODULE,
so it worked only when compiled as a module.

Tested by Wolfgang Denk with this device:

    00:0e.0 Communication controller: Comtrol Corporation RocketPort 8 port w/RJ11 connectors (rev 04)
        Control: I/O+ Mem- BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
        Status: Cap- 66Mhz- UDF- FastB2B- ParErr- DEVSEL=slow >TAbort- <TAbort- <MAbort- >SERR- <PERR-
        Interrupt: pin A routed to IRQ 11
        Region 0: I/O ports at 7000 [size=64]

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:27 -08:00
Laurent Riffard ed8b39d0aa [PATCH] watchdog: update .owner field of struct pci_driver
This updates .owner field of struct pci_driver.

This allows SYSFS to create the symlink from the driver to the module which
provides it.

Signed-off-by: Laurent Riffard <laurent.riffard@free.fr>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:26 -08:00
Laurent Riffard 413a42e2ea [PATCH] SyncLink adapters: updates .owner field of struct pci_driver
This updates .owner field of struct pci_driver.

This allows SYSFS to create the symlink from the driver to the module which
provides it.

Signed-off-by: Laurent Riffard <laurent.riffard@free.fr>
Cc: Paul Fulghum <paulkf@microgate.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:26 -08:00
Laurent Riffard 8f04dd0792 [PATCH] epca: update .owner field of struct pci_driver
This updates .owner field of struct pci_driver.

This allows SYSFS to create the symlink from the driver to the module which
provides it.

Signed-off-by: Laurent Riffard <laurent.riffard@free.fr>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:26 -08:00
Pozsar Balazs 1a66ddcb77 [PATCH] fix vgacon blanking
This patch fixes a long-standing vgacon bug: characters with the bright bit
set were left on the screen and not blacked out.  All I did was that I
lookuped up some examples on the net about setting the vga palette, and
added the call missing from the linux kernel, but included in all other
ones.  It works for me.

You can test this by writing something with the bright set to the
console, for example:
  echo -e "\e[1;31mhello there\e[0m"
and then wait for the console to blank itself (by default, after 10 mins
of inactivity), maybe making it faster using
  setterm -blank 1
so you only have to wait 1 minute.

Signed-off-by: Pozsar Balazs <pozsy@uhulinux.hu>
Cc: James Simmons <jsimmons@infradead.org>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:26 -08:00
Andrew Morton 0b360adbdb [PATCH] setkeys needs root
Because people can play games reprogramming keys and leaving traps for the
next user of the console.

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2005-10-30 17:37:25 -08:00