Andrew Morton [Mon, 19 Jan 2004 02:17:48 +0000 (18:17 -0800)]
[PATCH] ppc64: shared processor support, from Dave Engebretsen
From: Anton Blanchard <anton@samba.org>
Initial round of code to add shared processor support into 2.6. This adds
h_call interfaces, paca/VPA fields, and vpa register. Add adds new idle loop
code.
Andrew Morton [Mon, 19 Jan 2004 02:17:03 +0000 (18:17 -0800)]
[PATCH] ppc64: fix sched_clock, from Paul Mackerras:
From: Anton Blanchard <anton@samba.org>
Currently the sched_clock implementation for PPC64 is bogus. It just reads
the timebase register, which counts at some fixed rate, typically around
100MHz. This patch adds code to calculate a suitable multiplier from the
timebase frequency, and use that in sched_clock().
Andrew Morton [Mon, 19 Jan 2004 02:13:20 +0000 (18:13 -0800)]
[PATCH] ppc64: Open Firmware device tree manipulation support, from Nathan Lynch
From: Anton Blanchard <anton@samba.org>
Implementation of /proc/ppc64/ofdt, for manipulation of Open Firmware
device tree (/proc/device-tree). Supports addition and removal of
OF device nodes.
Andrew Morton [Mon, 19 Jan 2004 02:11:09 +0000 (18:11 -0800)]
[PATCH] ppc64: Change to new OF device tree API, from Nathan Lynch
From: Anton Blanchard <anton@samba.org>
Attached is a patch which replaces all the uses of the old device tree API in
arch/ppc64. Patch is against 2.6.0-test5 (cset 1.1328) from ameslab bk, plus
the patch from my previous message. I've tested this on a pSeries LPAR.
Andrew Morton [Mon, 19 Jan 2004 02:10:48 +0000 (18:10 -0800)]
[PATCH] ppc64: New Open Firmware device tree API, from Nathan Lynch
From: Anton Blanchard <anton@samba.org>
This is an adaptation of the new Open Firmware device tree traversal API from
ppc32, originally written by Benjamin Herrenschmidt. This patch is against
2.6.0-test3, but should apply ok to the latest 2.5 ameslab tree.
These functions are meant to be SMP-safe alternatives to the current set of
query/traversal routines (find_devices, find_type_devices, et al).
Andrew Morton [Mon, 19 Jan 2004 02:10:29 +0000 (18:10 -0800)]
[PATCH] ppc64: support for ibm,phandle OF property, from Dave Engebretsen:
From: Anton Blanchard <anton@samba.org>
Upcoming partition firmware requires the use of the ibm,phandle property for
matching device nodes. Add a new field in device_node to contain this data.
Andrew Morton [Mon, 19 Jan 2004 02:07:58 +0000 (18:07 -0800)]
[PATCH] input: i8042 suspend
From: Dmitry Torokhov <dtor_core@ameritech.net>
Add suspend methods to restore original controller state on suspend as some
BIOS don't like the state we leave it in. Also synchroniously delete the
polling timer on module exit.
Andrew Morton [Mon, 19 Jan 2004 02:07:34 +0000 (18:07 -0800)]
[PATCH] raw.c refcounting fix
From: viro@parcelfarce.linux.theplanet.co.uk
raw.c has a refcounting bug (patch attached).
As for the theory... If you have a pathname - use filp_open() or
open_bdev_excl() and be done with that. bdget() et.al. are OK only if you
really have nothing better than device number and that's a situation that
should be avoided unless you really have no choice.
Said that, we have the following primitives:
* lookup_bdev(): takes a pathname, returns a reference to block_device.
* bdget(): takes a number, returns a reference to block_device.
* blkdev_get(): takes a reference to block_device and opens it. If open
fails - drops the reference to block_device passed to it.
* blkdev_put(): takes a reference to block_device and closes it. The
reference is dropped.
* bdput(): drops a reference to block_device.
Note that behaviour of blkdev_get() and blkdev_put() is such that it makes
for minimal cleanup code.
bd_claim()/bd_release() is the exclusion mechanism - that's what mount,
swapon, open with O_EXCL, etc. are using to avoid stepping on each others
toes. bd_claim() claims bdev for given owner; if it's already owned and
not by the same owner you'll get -EBUSY. bd_release() reverts the effect
of bd_claim(). Note that if you claim the thing N times (with the same
owner, obviously), you'll need N bd_release() before it stops being owned.
raw.c grabbed a reference to bdev only after blkdev_get(). If blkdev_get()
failed (e.g. media being absent), you've got an unbalanced bdput().
Andrew Morton [Mon, 19 Jan 2004 02:07:25 +0000 (18:07 -0800)]
[PATCH] cramfs: use pagecache better
From: viro@parcelfarce.linux.theplanet.co.uk
Patch switches cramfs_read() to direct use of pagecache and
eliminates all messing with buffer_heads. Fixes the interaction with
ramdisk (there set_blocksize() simply killed the ramdisk contents) and
gets code less brittle overall.
For bdevfs inodes (ones created along with struct block_device by
fs/block_dev.c) we have inode->i_bdev equal to &BDEV_I(inode)->bdev (i.e.
it's at the constant offset from inode). New helper added for such inodes
(I_BDEV(inode)). A bunch of places (mostly in block_dev.c) switched to use
of that helper. A bunch of places that used
file->f_dentry->d_inode->i_bdev->bd_inode
switched to
file->f_mapping->host
- those expressions are equal whenever the former is valid.
generic_osync_inode() got an extra argument - mapping and doesn't calculate
inode->i_mapping anymore. Callers updated and switched to use of
->f_mapping.
In a bunch of places we used file->f_dentry->d_inode->i_sem to protect
fdatasync et.al. Replaced with corrent file->f_mapping->host->i_sem - the
object we are protecting is address_space, so we want an exclusion that would
work for redirected ->i_mapping. For normal files (not coda, not bdev) it's
all the same, of course - there we have
A lot of places used to use ->f_dentry->d_inode->i_mapping all over the
place. Replaced with use of ->f_mapping. For now - just the places where we
literally could do search-and-replace.
presto_journal_close() switched to passing struct presto_file_data * instead
of bogus struct file *. The only field of struct file we used to look at was
file->private_data and most of the callers allocated on-stack struct file,
assigned file.private_data and passed the sucker to presto_journal_close().
Idiocy removed.
Looks like they started with case where the data they wanted all along was,
indeed, in ->private_data of already available struct file, so they just
passed pointer to struct file. And when they found that they need to call it
in other places where there was no such struct file, they'd done it the dumb
way instead of fixing the prototype...
Andrew Morton [Mon, 19 Jan 2004 02:05:49 +0000 (18:05 -0800)]
[PATCH] bdev: open() changes
The first of a series which move us toward blockdev hotplug support. After
these we have achieved the following:
a) For "normal" (not bdevfs) inodes of block devices we never look at
->i_mapping.
b) For the same inodes we only look at ->i_bdev in bd_acquire() where it's
used only as "here's what we'd found the last time" sort of cached value.
If it's NULL, we just recalculate it.
c) Lots of messy expressions had been trimmed down, while we are at it.
(a) and (b) allow us to start doing proper block hotplug - we can destroy the
association between inode and bdev at any time, unhash bdev in question and
have new open() do everything from scratch, without waiting for old opened
files to close. The goal is to be able to say "revoke everything over that
gendisk"/"revoke that partition" and have it do the right thing.
This patch:
Where the old code called (block device) ->open(inode, file), use
->open(inode->i_bdev->bd_inode, file). Changes in drivers:
* none to those that only used inode->i_bdev and inode->i_rdev in their
->open() (bdev->bd_inode->i_bdev == bdev, so we are OK)
* floppy.c and floppy98.c used to call permission(inode, ...) in
floppy_open(). Switched to permission(file->f_dentry->d_inode, ...)
Andrew Morton [Mon, 19 Jan 2004 02:05:15 +0000 (18:05 -0800)]
[PATCH] kyrofb support
From: Paul Mundt <lethal@linux-sh.org>
This patch adds support for the Kyro graphics boards (STG4000/PowerVR
3/etc= .) to 2.6. This is a direct port and substantial cleanup / rewrite
of the 2.4 driver that's available in the sh64 tree at linux-sh.bkbits.net.
Some of the overlay code and the STG4000 bits are still a bit ugly, so be
forewarned.
Andrew Morton [Mon, 19 Jan 2004 02:05:04 +0000 (18:05 -0800)]
[PATCH] SH Merge
From: Paul Mundt <lethal@linux-sh.org>
Here's a rather large update for SH (this is a bit large mainly since a
number of things have piled up, and Linus didn't want any of this during
feature freeze time). All of these changes are specific to the SH platform,
and as such, shouldn't effect any other platforms.
Bjorn Helgaas [Fri, 16 Jan 2004 22:03:20 +0000 (22:03 +0000)]
[SERIAL] make ACPI serial module unload work
Patch from Bjorn Helgaas
This patch makes ACPI serial ports work right when the serial driver
is built as a module. Previously, loading worked fine, but we
didn't clean up on module removal.
Bjorn Helgaas [Fri, 16 Jan 2004 21:56:06 +0000 (21:56 +0000)]
[SERIAL] make HCDP dependent on serial console
Patch from Bjorn Helgaas
I propose the following HCDP Kconfig patch. It makes HCDP
selectable only when serial console has been selected. One
desirable side effect is that both are then available only
when statically compiled in (i.e., not built as a module).
The HCDP support doesn't actually depend on IA64, but I left
that in for now because nobody else implements support for it
and I don't want people confused by a selectable option that
doesn't do anything. Maybe a "depends on EFI" or something
will be useful eventually.
Roland McGrath [Thu, 15 Jan 2004 12:47:18 +0000 (04:47 -0800)]
[PATCH] fix pdeath_signal SMP locking
Obviously almost noone uses the pdeath_signal feature, since this has gone
unnoticed for quite some time.
This patch calls the function that does the right locking for the context
of this call (inside exit_notify). The names of the signal.c entrypoints
are a little confusing.
David Mosberger [Thu, 15 Jan 2004 08:39:13 +0000 (00:39 -0800)]
ia64: Replace unwcheck shell-script with a Python script which works
correctly even on 32-bit hosts. As an added bonus, it's faster,
too. Run "unwcheck" by default, but for now, don't let unwcheck
errors cause the kernel build to fail.
David Jeffery [Thu, 15 Jan 2004 07:53:07 +0000 (02:53 -0500)]
[PATCH] ips fix for large mem 64bit machines
This patch fixes DMA bugs on x86-64 and ia64 machines. The driver was
using commands that only support 32bit addresses in places that could
return 64bit addresses. One place was DMAing off the stack. The other
place was causing problems on x86-64 machines by calling pci_map()
functions on a region allocated by pci_alloc_consistent().
David Jeffery [Thu, 15 Jan 2004 07:51:50 +0000 (02:51 -0500)]
[PATCH] ips 2/2: minor fixes
This patch fixes two minor bugs. It allows zero length write commands
through to devices. It also prevents the writing of any '\0'
characters at the end of version numbers to ips's /proc/scsi files.
James Bottomley [Thu, 15 Jan 2004 05:23:57 +0000 (00:23 -0500)]
g_NCR5380 - 2.6.0 - problem with reloading module
From: "Randy.Dunlap" <rddunlap@osdl.org>
The problem is that the detect function requests an IO region
of 16 bytes (at least when a command line override parameter is
used) but the release function only tries to release 8 bytes,
and this request isn't done because it doesn't match any allocated
IO region. [NCR53C400 extensions are not enabled, so
NCR5380_region_size is 8, not 16, but the request uses
NCR5380_region_size regardless.]
Fix: save the allocated region size in instance->n_io_ports and release
that size only;