Takashi Iwai [Mon, 7 Nov 2005 10:14:57 +0000 (11:14 +0100)]
[PATCH] Fix wrong irq enable via rtc_control()
rtc_control() may be called in the interrupt context in ALSA rtc-timer
driver. The patch fixes the wrong irq enable in rtc.c, and also fixes
the possible race of bit flags.
Adds a new CONFIG_PPC_64K_PAGES which, when enabled, changes the kernel
base page size to 64K. The resulting kernel still boots on any
hardware. On current machines with 4K pages support only, the kernel
will maintain 16 "subpages" for each 64K page transparently.
Note that while real 64K capable HW has been tested, the current patch
will not enable it yet as such hardware is not released yet, and I'm
still verifying with the firmware architects the proper to get the
information from the newer hypervisors.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Russell King [Sun, 6 Nov 2005 21:41:08 +0000 (21:41 +0000)]
[ARM] Fix /proc/cpuinfo format for ARM SMP
glibc expects to count lines beginning with "processor" to determine
the number of processors, not lines beginning with "Processor". So,
give glibc the format it expects.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
We don't want to call dump_cpu_info() from cpu_init() after boot since
it produces a lot of unnecessary noise - since cpu_init() gets called
on resume and hotplug cpu insertion events.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Russell King [Sun, 30 Oct 2005 21:42:11 +0000 (22:42 +0100)]
[PATCH] kbuild: permanently fix kernel configuration include mess
Include autoconf.h into every kernel compilation via the gcc command line
using -imacros. This ensures that we have the kernel configuration
included from the start, rather than relying on each file having #include
<linux/config.h> as appropriate. History has shown that this is something
which is difficult to get right.
Since we now include the kernel configuration automatically, make
configcheck becomes meaningless, so remove it.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Bart Oldeman [Sat, 5 Nov 2005 23:54:07 +0000 (12:54 +1300)]
[PATCH] reset tss->io_bitmap_owner in sys_ioperm()
my patch "x86: initialise tss->io_bitmap_owner to something" (commit ID d5cd4aadd3d220afac8e3e6d922e333592551f7d) introduced a problem with a
program (DOSEMU) that called ioperm after already doing some port i/o.
The problem is that a process switch return causes tss->io_bitmap_base
to be set to IO_BITMAP_OFFSET so that the fault (that *really* sets the
io bitmap) never triggers.
Samuel Thibault [Sat, 5 Nov 2005 21:19:50 +0000 (22:19 +0100)]
[PATCH] Set the vga cursor even when hidden
Some visually impaired people use hardware devices which directly read
the vga screen. When newt for instance asks to hide the cursor for
better visual aspect, the kernel puts the vga cursor out of the screen,
so that the cursor position can't be read by the hardware device. This
is a great loss for such people.
Here is a patch which uses the same technique as CUR_NONE for hiding the
cursor while still moving it.
Mario, you should apply it to the speakup kernel for access floppies
asap. I'll submit a 2.4 patch too.
Russell King [Sat, 5 Nov 2005 21:22:39 +0000 (21:22 +0000)]
[DRIVER MODEL] Fix sgivwfb
Statically allocated devices in module data is a potential cause
of oopsen. The device may be in use by a userspace process, which
will keep a reference to the device. If the module is unloaded,
the module data will be freed. Subsequent use of the platform
device will cause a kernel oops.
Use generic platform device allocation/release code in modules.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Russell King [Sat, 5 Nov 2005 21:22:13 +0000 (21:22 +0000)]
[DRIVER MODEL] Fix gbefb
Statically allocated devices in module data is a potential cause
of oopsen. The device may be in use by a userspace process, which
will keep a reference to the device. If the module is unloaded,
the module data will be freed. Subsequent use of the platform
device will cause a kernel oops.
Use generic platform device allocation/release code in modules.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Russell King [Sat, 5 Nov 2005 21:21:38 +0000 (21:21 +0000)]
[DRIVER MODEL] Fix arcfb
Release code in driver modules is a potential cause of oopsen.
The device may be in use by a userspace process, which will keep
a reference to the device. If the module is unloaded, the module
text will be freed. Subsequently, when the last reference is
dropped, the release code will be called, which no longer exists.
Use generic platform device allocation/release code in modules.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Russell King [Sat, 5 Nov 2005 21:21:10 +0000 (21:21 +0000)]
[DRIVER MODEL] Fix macsonic
Release code in driver modules is a potential cause of oopsen.
The device may be in use by a userspace process, which will keep
a reference to the device. If the module is unloaded, the module
text will be freed. Subsequently, when the last reference is
dropped, the release code will be called, which no longer exists.
Use generic platform device allocation/release code in modules.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Russell King [Sat, 5 Nov 2005 21:20:47 +0000 (21:20 +0000)]
[DRIVER MODEL] Fix jazzsonic
Release code in driver modules is a potential cause of oopsen.
The device may be in use by a userspace process, which will keep
a reference to the device. If the module is unloaded, the module
text will be freed. Subsequently, when the last reference is
dropped, the release code will be called, which no longer exists.
Use generic platform device allocation/release code in modules.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Russell King [Sat, 5 Nov 2005 21:20:21 +0000 (21:20 +0000)]
[DRIVER MODEL] Fix depca
Release code in driver modules is a potential cause of oopsen.
The device may be in use by a userspace process, which will keep
a reference to the device. If the module is unloaded, the module
text will be freed. Subsequently, when the last reference is
dropped, the release code will be called, which no longer exists.
Use generic platform device allocation/release code in modules.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Matt Porter [Wed, 2 Nov 2005 23:13:06 +0000 (16:13 -0700)]
[PATCH] phy address mask support for generic phy layer
Adds a phy_mask field to struct mii_bus and uses it. This field
indicates each phy address to be ignored when probing the mdio bus.
This support is needed for the fs_enet and ibm_emac drivers to be
converted to the generic phy layer among other drivers. Many systems
lock up on probing certain phy addresses or probing doesn't return
0xffff when nothing is found at the address. A new driver I'm
working on also makes use of this mask.
Signed-off-by: Matt Porter <mporter@kernel.crashing.org> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Don Fry [Tue, 1 Nov 2005 21:13:35 +0000 (13:13 -0800)]
[PATCH] pcnet32: Prevent hang with 79c976
Some boards using the 79c976 pcnet32 chip will hang the system if the
ethtool --register-dump is performed with the device operational. The
request to read bcr30 is retried by the PCI device infinitely without
returning data, hanging the system.
Tested ia32 and ppc64.
Signed-off-by: Don Fry <brazilnut@us.ibm.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Don Fry [Tue, 1 Nov 2005 20:50:57 +0000 (12:50 -0800)]
[PATCH] pcnet32: AT2700/2701 and Bugzilla 2699 & 4551
This patch is a better fix for Allied Telesyn 2700/2701 FX boards than
the change made in early January this year. It allows the user to
select the speed/duplex via module_param, but if no selection is made,
forces the speed to 100 FD. It fixes both Bugzilla bugs 2669 and 4551.
Tested ia32 and ppc64 by myself, and by the originator of bug 2669.
Signed-off-by: Don Fry <brazilnut@us.ibm.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Don Fry [Tue, 1 Nov 2005 20:04:33 +0000 (12:04 -0800)]
[PATCH] pcnet32: show name of failing device
Display the name eth%d or pci_name() of device which fails to allocate
memory. When changing ring size via ethtool, it also releases the
lock before returning on error. Added comment that the caller of
pcnet32_alloc_ring must call pcnet32_free_ring on error, to avoid leak.
Tested ia32 by forcing allocation errors.
Signed-off-by: Don Fry <brazilnut@us.ibm.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Ananda Raju [Mon, 31 Oct 2005 21:55:31 +0000 (16:55 -0500)]
[PATCH] S2io: Multi buffer mode support
Hi,
This patch provides dynamic two buffer-mode and 3 buffer-mode options.
Previously 2 buffer-mode was compilation option. Now with this patch applied
one can load driver in 2 buffer-mode with module-load parameter
ie.
#insmod s2io.ko rx_ring_mode=2
This patch also provides 3 buffer-mode which provides header separation
functionality. In 3 buffer-mode skb->data will have L2/L3/L4 headers and
"skb_shinfo(skb)->frag_list->data" will have have L4 payload.
one can load driver in 3 buffer-mode with same above module-load parameter
ie.
#insmod s2io.ko rx_ring_mode=3
Please review the patch.
Signed-off-by: Ananda Raju <ananda.raju@neterion.com> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
fid is declared as a u32 (unsigned int), and then a few lines later, it is checked for a value < 0, which is clearly useless.
In the two locations this function is used, in one it is *explicitly* given a negative number, which would be ignored with the
current definition.
Thanks to LinuxICC (http://linuxicc.sf.net).
Signed-off-by: Gabriel A. Devenyi <ace@staticwave.ca> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Alan Stern [Fri, 4 Nov 2005 19:44:41 +0000 (14:44 -0500)]
[SCSI] sd: Fix refcounting
Currently the driver takes a reference only for requests coming by way
of the gendisk, not for requests coming by way of the struct device or
struct scsi_device. Such requests can arrive in the rescan, flush,
and shutdown pathways.
The patch also makes the scsi_disk keep a reference to the underlying
scsi_device, and it erases the scsi_device's pointer to the scsi_disk
when the scsi_device is removed (since the pointer should no longer be
used).
This resolves Bugzilla entry #5237.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Pierre Ossman [Sat, 5 Nov 2005 10:36:35 +0000 (10:36 +0000)]
[MMC] Use controller id instead of driver name for printks
The printks that aren't for debugging should use the name of the controller,
not the driver name. Multiple MMC controllers aren't that common today, but
this is the right way to do things.
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Pierre Ossman [Sat, 5 Nov 2005 10:16:50 +0000 (10:16 +0000)]
[MMC] Fix chip config in wbsd
There is a broken if clause in the wbsd driver that can cause the
driver to try and configure the chip even though none is found. This
results in i/o on invalid ports.
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
[PATCH] nvidiafb: Geforce 7800 series support added
This adds support for the Nvidia Geforce 7800 series of cards to the
nvidiafb framebuffer driver. All it does is add the PCI device id for
the 7800, 7800 GTX, 7800 GO, and 7800 GTX GO cards to the module device
table for the nvidiafb.ko driver, so that nvidiafb.ko will actually work
on these cards.
I also added the relevant PCI device ids to linux/pci_ids.h
I tested it on my 7800 GTX here and it works like a charm. I now can
get framebuffer support on this card! Woo hoo!! Nothing like 200x75 text
mode to make your eyes BLEED. ;)
Paul Mackerras [Fri, 4 Nov 2005 23:36:59 +0000 (10:36 +1100)]
powerpc: Fix vmlinux.lds.S for 32-bit
We can't currently use asm-ppc/page.h in vmlinux.lds.S, so until
we have a merged page.h, define PAGE_SIZE and KERNELBASE locally.
Also gets rid of some dynamic executable cruft that we had for
32-bit. With -Ttext=$(KERNELBASE) this didn't cause any problem,
but when we changed to putting . = KERNELBASE in the vmlinux.lds.S
this cruft caused the text to get linked at 0xa0 instead of
0xc0000000. Oops.
Trond Myklebust [Fri, 4 Nov 2005 20:38:11 +0000 (15:38 -0500)]
NFSv4: Recover locks too when returning a delegation
Delegations allow us to cache posix and BSD locks, however when the
delegation is recalled, we need to "flush the cache" and send
the cached LOCK requests to the server.
Trond Myklebust [Fri, 4 Nov 2005 20:35:02 +0000 (15:35 -0500)]
NFSv4: Return any delegations before sillyrenaming the file
I missed this one... Any form of rename will result in a delegation
recall, so it is more efficient to return the one we hold before
trying the rename.
Trond Myklebust [Fri, 4 Nov 2005 20:33:38 +0000 (15:33 -0500)]
NFSv4: Fix problem with OPEN_DOWNGRADE
RFC 3530 states that for OPEN_DOWNGRADE "The share_access and share_deny
bits specified must be exactly equal to the union of the share_access and
share_deny bits specified for some subset of the OPENs in effect for
current openowner on the current file.
Setattr is currently violating the NFSv4 rules for OPEN_DOWNGRADE in that
it may cause a downgrade from OPEN4_SHARE_ACCESS_BOTH to
OPEN4_SHARE_ACCESS_WRITE despite the fact that there exists no open file
with O_WRONLY access mode.
Fix the problem by replacing nfs4_find_state() with a modified version of
nfs_find_open_context().
Nicolas Pitre [Fri, 4 Nov 2005 17:17:30 +0000 (17:17 +0000)]
[ARM] 3097/1: change library link ordering
Patch from Nicolas Pitre
We have an optimized sha1 routine (arch/arm/lib/sha1.S) meant to
override the generic one in lib/sha1.c.
Unfortunately lib/lib.a is listed _before_ arch/arm/lib/lib.a in the
link argument list and therefore the architecture specific lib functions
are not picked up before the generic versions.
This patch is a quick fix to change that ordering for ARM. Here's what
the kbuild maintainer had to say about it (was also CC'd on lkml):
On Wed, 2 Nov 2005, Sam Ravnborg wrote:
> This looks like an obvious way to achive correct ordering.
> We could change it so arch defines always took precedence but
> the above is so simple that it is not worth the effort.
Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Add platform devices for flash to Lubbock and Mainstone board files.
Once in place, the two existing mtd map drivers for the boards will be
converted to use a single pxa2xx map driver in the linux-mtd tree.
Take 4: flash_platform_data .map_name vs. .name cleaned up, resync with
merged irda patch context.
Signed-off-by: Todd Poynor <tpoynor@mvista.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Dave Jiang [Fri, 4 Nov 2005 17:15:44 +0000 (17:15 +0000)]
[ARM] 3086/1: ixp2xxx error irq handling
Patch from Dave Jiang
This provides support for IXP2xxx error interrupt handling. Previously there was a patch to remove this (although the original stuff was broken). Well, now the error bits are needed again. These are used extensively by the micro-engine drivers according to Deepak and also we will need it for the new EDAC code that Alan Cox is trying to push into the main kernel.
Re-submit of 3072/1, generated against git tree pulled today. AFAICT, this git tree pulled in all the ARM changes that's in arm.diff. Please let me know if there are additional changes. Thx!
Signed-off-by: Dave Jiang <djiang@mvista.com> Signed-off-by: Deepak Saxena <dsaxena@plexity.net> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Nicolas Pitre [Fri, 4 Nov 2005 17:15:43 +0000 (17:15 +0000)]
[ARM] 3094/1: remove PLD stuff from old uaccess code
Patch from Nicolas Pitre
ARM processors that have pld instructions are not using those copy_user
implementation anymore. Let's remove the useless PLD lines which were
half wrong anyway.
Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Clemens Ladisch [Wed, 2 Nov 2005 10:32:52 +0000 (11:32 +0100)]
[ALSA] usb-audio: start submitting URBs in the prepared state
Modules: USB generic driver
If we submit all our URBs when a playback stream is started, the first
hwptr_done update for each URB happens at the same time. This results
in an underrun when there isn't enough PCM data available at this
point for all URBs.
To avoid this, we begin submitting our URBs earlier (when the stream
is prepared), with empy packets. When the stream is started, the
prepare_playback_urb() call for each URB will be run only when the
respective URB has completed previously, so the first hwptr_done
updates will be done nicely staggered.
Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
AMD Au1x00 ALSA driver fails compilation with the alternate spinlock
implementation because it doesn't do locking/unlocking correctly in some
places (passes spinlock by value).
Signed-off-by: Konstantin Baydarov <kbaidarov@ru.mvista.com> Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Lee Revell [Tue, 25 Oct 2005 09:25:29 +0000 (11:25 +0200)]
[ALSA] emu10k1 - Use 31 bit DMA mask for Audigy
Modules: EMU10K1/EMU10K2 driver
It appears that either the Audigy DMA engine or the Linux kernel cannot
handle 32 bit DMA with this device. Problem manifests as noise when
using more than 2GB of RAM, possibly only on 64 bit machines.
The OSS driver actually uses a 29 bit DMA mask for both devices, this
seems like overkill for now.
Signed-off-by: Lee Revell <rlrevell@joe-job.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Andreas Mohr [Tue, 25 Oct 2005 09:17:45 +0000 (11:17 +0200)]
[ALSA] AZT3328 driver update
Modules: AZT3328 driver
this is now an even much more reworked patch (#3) for my azt3328.c ALSA driver.
IOW I spent another 4 evenings to get the sequencer timer to work properly
(my head is still hurting) and do lots of other cleanups.
Note that despite the extensive sequencer timer additions, the driver object
is still only 2kB bigger than the previous version, due to those many
optimizations...
Changes in version #3:
- fully working ALSA sequencer timer support for the card's 1024000Hz
DirectX timer (downscaling adjustable via seqtimer_scaling module param)
- an insane amount of code optimizations
- many, many cleanups
Changes in version #2:
- FOUND the 1us DirectX timer area (yay!), made the code respect it
properly
- renamed some 'weird' mixer control names according to ControlNames.txt
- cleanup unneeded debug messages, reformatting
- improved I/O register documentation
- constified many more structs
Changes in version #1:
- improves/fixes some fatal playback/recording interaction
- improves IRQ handler performance (and actually fixes some weird code)
- coalesces some I/O accesses
- slightly improves I/O interface documentation
- improves/fixes logging
- defines out some less important debug code
- constifies some data
Signed-off-by: Andreas Mohr <andi@lisas.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Clemens Ladisch [Mon, 24 Oct 2005 15:02:03 +0000 (17:02 +0200)]
[ALSA] clean up device types symbols
Modules: ALSA Core,ALSA Minor Numbers
Remove the unused and undefined symbols SNDRV_DEVICE_TYPE_{MIXER,
PCM_PLOOP,PCM_CLOOP}, and introduce a new symbol SNDRV_MINOR_GLOBAL
for non-card-specific devices like the sequencer or the timer.
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Use schedule_timeout_{,un}interruptible() instead of
set_current_state()/schedule_timeout() to reduce kernel size. Also use
human-time conversion functions instead of hard-coded division to avoid
rounding issues.
Wei Ni [Mon, 24 Oct 2005 09:04:51 +0000 (11:04 +0200)]
[ALSA] intel8x0 - fix capture for M1563
Modules: Intel8x0 driver
1.In intel8x0_measure_ac97_clock routine, when stop DMA, there is not stop
DMA corectly, but start another PCM In2 DMA engine.
2.In do_ali_reset routine, there is only need to enable PCM IN and PCM OUT.