Kylene Jo Hall [Sat, 22 Apr 2006 09:38:19 +0000 (02:38 -0700)]
[PATCH] tpm: msecs_to_jiffies cleanups
The timeout and duration values used in the tpm driver are not exposed to
userspace. This patch converts the storage units to jiffies with
msecs_to_jiffies. They were always being used in jiffies so this
simplifies things removing the need for calculation all over the place.
The change necessitated a type change in the tpm_chip struct to hold
jiffies.
Signed-off-by: Kylie Hall <kjhall@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
The driver for the next generation of TPM chips version 1.2 including support
for interrupts. The Trusted Computing Group has written the TPM Interface
Specification (TIS) which defines a common interface for all manufacturer's
1.2 TPM's thus the name tpm_tis.
Signed-off-by: Leendert van Doorn <leendert@watson.ibm.com> Signed-off-by: Kylene Hall <kjhall@us.ibm.com> Cc: Greg KH <greg@kroah.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Kylene Jo Hall [Sat, 22 Apr 2006 09:37:50 +0000 (02:37 -0700)]
[PATCH] tpm: new 1.2 sysfs files
Many of the sysfs files were calling the TPM_GetCapability command with array.
Since for 1.2 more sysfs files of this type are coming I am generalizing the
array so there can be one array and the unique parts can be filled in just
before the command is called.
This updated version of the patch breaks the multi-value sysfs file into
separate files pointed out by Greg. It also addresses the code redundancy and
ugliness in the tpm_show_* functions pointed out on another patch by Dave
Hansen.
Signed-off-by: Kylene Hall <kjhall@us.ibm.com> Cc: Greg KH <greg@kroah.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Kylene Jo Hall [Sat, 22 Apr 2006 09:37:38 +0000 (02:37 -0700)]
[PATCH] tpm: command duration update
With the TPM 1.2 Specification, each command is classified as short, medium or
long and the chip tells you the maximum amount of time for a response to each
class of command. This patch provides and array of the classifications and a
function to determine how long the response should be waited for. Also, it
uses that information in the command processing to determine how long to poll
for. The function is exported so the 1.2 driver can use the functionality to
determine how long to wait for a DataAvailable interrupt if interrupts are
being used.
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>
Kylene Jo Hall [Sat, 22 Apr 2006 09:37:26 +0000 (02:37 -0700)]
[PATCH] tpm: return chip from tpm_register_hardware
Changes in the 1.2 TPM Specification make it necessary to update some fields
of the chip structure in the initialization function after it is registered
with tpm.c thus tpm_register_hardware was modified to return a pointer to the
structure. This patch makes that change and the associated changes in
tpm_atmel and tpm_nsc. The changes to tpm_infineon will be coming in a patch
from Marcel Selhorst.
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>
Kylene Jo Hall [Sat, 22 Apr 2006 09:37:15 +0000 (02:37 -0700)]
[PATCH] tpm: chip struct update
To assist with chip management and better support the possibility of having
multiple TPMs in the system of the same kind, the struct tpm_vendor_specific
member of the tpm_chip was changed from a pointer to an instance. This patch
changes that declaration and fixes up all accesses to the structure member
except in tpm_infineon which is coming in a patch from Marcel Selhorst.
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>
Kylene Jo Hall [Sat, 22 Apr 2006 09:37:05 +0000 (02:37 -0700)]
[PATCH] tpm: reorganize sysfs files
Many of the sysfs files were calling the TPM_GetCapability command with array.
Since for 1.2 more sysfs files of this type are coming I am generalizing the
array so there can be one array and the unique parts can be filled in just
before the command is called.
Signed-off-by: Kylene Hall <kjhall@us.ibm.com> Cc: Greg KH <greg@kroah.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Kylene Jo Hall [Sat, 22 Apr 2006 09:36:56 +0000 (02:36 -0700)]
[PATCH] tpm: spacing cleanups
The following patch set contains numerous changes to the base tpm driver
(tpm.c) to support the next generation of TPM chips. The changes include new
sysfs files because of more relevant data being available, a function to
access the timeout and duration values for the chip, and changes to make use
of those duration values. Duration in the TPM specification is defined as the
maximum amount of time the chip could take to return the results. Commands
are in one of three categories short, medium and long. Also included are
cleanups of how the commands for the sysfs files are composed to reduce a
bunch of redundant arrays.
This patch:
Fix minor spacing issues.
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>
Kylene Jo Hall [Sat, 22 Apr 2006 09:36:46 +0000 (02:36 -0700)]
[PATCH] tpm: fix missing string
A string corresponding to the tcpa_pc_event_id POST_CONTENTS was missing
causing an overflow bug when access was attempted in the get_event_name
function.
This bug was found by Coverity.
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>
Jan Kara [Sat, 22 Apr 2006 09:36:24 +0000 (02:36 -0700)]
[PATCH] Fix reiserfs deadlock
reiserfs_cache_default_acl() should return whether we successfully found
the acl or not. We have to return correct value even if reiserfs_get_acl()
returns error code and not just 0. Otherwise callers such as
reiserfs_mkdir() can unnecessarily lock the xattrs and later functions such
as reiserfs_new_inode() fail to notice that we have already taken the lock
and try to take it again with obvious consequences.
Signed-off-by: Jan Kara <jack@suse.cz> Cc: <reiserfs-dev@namesys.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Fix Altix system controller (snsc) device names to include the slot number
of the blade whose associated system controller is the target of the device
interface. Including the slot number avoids a problem we're currently
having where slots within the same enclosure are attempting to create
multiple kobjects with identical names.
Signed-off-by: Greg Howard <ghoward@sgi.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Mike Waychison [Sat, 22 Apr 2006 09:36:06 +0000 (02:36 -0700)]
[PATCH] x86_64: Fix a race in the free_iommu path
We do this by removing a micro-optimization that tries to avoid grabbing
the iommu_bitmap_lock spinlock and using a bus-locked operation.
This still races with other simultaneous alloc_iommu or free_iommu(size >
1) which both use bus-unlocked operations.
The end result of this race is eventually ending up with an
iommu_gart_bitmap that has bits errornously set all over, making large
contiguous iommu space allocations fail with 'PCI-DMA: Out of IOMMU space'.
Signed-off-by: Mike Waychison <mikew@google.com> Signed-off-by: Andi Kleen <ak@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
[PATCH] x86_64: Pass -32 to the assembler when compiling the 32bit vsyscall pages
This quietens warnings and actually fixes a bug. The unwind tables would
come out wrong without -32, causing pthread cancellation during them to
crash in the gcc runtime.
The problem seems to only happen with newer binutils (it doesn't happen
with 2.16.91.0.2 but happens wit 2.16.91.0.5)
Thanks to David Altobelli <david.altobelli@hp.com> and Brian Baker
<Brian.B@hp.com> for test case and initial analysis.
Lee Schermerhorn [Sat, 22 Apr 2006 09:35:48 +0000 (02:35 -0700)]
[PATCH] add migratepage address space op to shmem
Basic problem: pages of a shared memory segment can only be migrated once.
In 2.6.16 through 2.6.17-rc1, shared memory mappings do not have a
migratepage address space op. Therefore, migrate_pages() falls back to
default processing. In this path, it will try to pageout() dirty pages.
Once a shared memory page has been migrated it becomes dirty, so
migrate_pages() will try to page it out. However, because the page count
is 3 [cache + current + pte], pageout() will return PAGE_KEEP because
is_page_cache_freeable() returns false. This will abort all subsequent
migrations.
This patch adds a migratepage address space op to shared memory segments to
avoid taking the default path. We use the "migrate_page()" function
because it knows how to migrate dirty pages. This allows shared memory
segment pages to migrate, subject to other conditions such as # pte's
referencing the page [page_mapcount(page)], when requested.
I think this is safe. If we're migrating a shared memory page, then we
found the page via a page table, so it must be in memory.
Can be verified with memtoy and the shmem-mbind-test script, both
available at: http://free.linux.hp.com/~lts/Tools/
Signed-off-by: Lee Schermerhorn <lee.schermerhorn@hp.com> Acked-by: Christoph Lameter <clameter@sgi.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Andy Whitcroft [Sat, 22 Apr 2006 09:35:41 +0000 (02:35 -0700)]
[PATCH] x86_64: sparsemem does not need node_mem_map
Seems we are trying to init the node_mem_map when we don't need to, for
example when SPARSEMEM is enabled. This causes the error below during
compilation. Use CONFIG_FLAT_NODE_MEM_MAP to gate allocation and init.
arch/x86_64/mm/numa.c: In function `setup_node_zones':
arch/x86_64/mm/numa.c:191: error: structure has no member
named `node_mem_map'
Signed-off-by: Andy Whitcroft <apw@shadowen.org> Acked-by: Andi Kleen <ak@muc.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
[PATCH] isdn4linux: Siemens Gigaset base driver: fix disconnect handling
Fix a possible Oops in the Siemens Gigaset base driver when the device is
unplugged while an ISDN connection is still active, and makes sure that the
isdn4linux link level (LL) is properly informed if a connection is broken
by the USB cable being unplugged.
- Avoid unsafe checks of URB status fields outside the URB completion
handlers, keep track of in-use URBs myself instead.
- If an isochronous transfer URB completes with status==0, also check the
status of the frame descriptors.
- Verify length of interrupt messages received from the device.
- Align the length limit on transmitted AT commands with the device
documentation.
- In case of AT response receive overrun, keep newly arrived instead of old
unread data.
- Remove redundant check of device ID in the USB probe function.
- Correct and improve some comments and formatting.
Signed-off-by: Tilman Schmidt <tilman@imap.cc> Acked-by: Hansjoerg Lipp <hjlipp@web.de> Cc: Karsten Keil <kkeil@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Sergei Shtylyov [Sun, 16 Apr 2006 15:42:35 +0000 (19:42 +0400)]
[PATCH] NEx000: fix RTL8019AS base address for RBTX4938
Correct the base address of the Realtek RTL8019AS chip on the Toshiba RBTX4938
board -- this should make the driver work at least when CONFIG_PCI is enabled.
Signed-off-by: Yuri Shpilevsky <yshpilevsky@ru.mvista.com> Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
for_each_cpu() actually iterates across all possible CPUs. We've had mistakes
in the past where people were using for_each_cpu() where they should have been
iterating across only online or present CPUs. This is inefficient and
possibly buggy.
We're renaming for_each_cpu() to for_each_possible_cpu() to avoid this in the
future.
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: Russell King <rmk+kernel@arm.linux.org.uk>
Andrew Morton [Thu, 20 Apr 2006 20:41:18 +0000 (21:41 +0100)]
[ARM] add_memory() build fix
This is back again. Offending patch is x86_64-mm-hotadd-reserve.patch
arch/arm/kernel/setup.c:435: error: conflicting types for 'add_memory'
include/linux/memory_hotplug.h:102: error: previous declaration of 'add_memory' was here
arch/arm/kernel/setup.c:435: error: conflicting types for 'add_memory'
include/linux/memory_hotplug.h:102: error: previous declaration of 'add_memory' was here
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
The irq2gpio array was recently converted from an array of ints to an
array of chars (by patch 3368/1.) However, this array contains elements
that are -1, and on ARM, the char type is unsigned by default, so this
patch broke the GPIO check in ixp4xx_set_irq_type.
Change the 'char' to be a 'signed char' to fix this.
Signed-off-by: Lennert Buytenhek <buytenh@wantstofly.org> Signed-off-by: Deepak Saxena <dsaxena@plexity.net> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
[PATCH] i386/x86-64: Fix x87 information leak between processes
AMD K7/K8 CPUs only save/restore the FOP/FIP/FDP x87 registers in FXSAVE
when an exception is pending. This means the value leak through
context switches and allow processes to observe some x87 instruction
state of other processes.
This was actually documented by AMD, but nobody recognized it as
being different from Intel before.
The fix first adds an optimization: instead of unconditionally
calling FNCLEX after each FXSAVE test if ES is pending and skip
it when not needed. Then do a x87 load from a kernel variable to
clear FOP/FIP/FDP.
This means other processes always will only see a constant value
defined by the kernel in their FP state.
I took some pain to make sure to chose a variable that's already
in L1 during context switch to make the overhead of this low.
Also alternative() is used to patch away the new code on CPUs
who don't need it.
Patch for both i386/x86-64.
The problem was discovered originally by Jan Beulich. Richard
Brunner provided the basic code for the workarounds, with contribution
from Jan.
Adrian Bunk [Thu, 20 Apr 2006 09:43:21 +0000 (02:43 -0700)]
[PATCH] update OBSOLETE_OSS_DRIVER schedule and dependencies
Update the schedule for the removal of drivers depending on
OBSOLETE_OSS_DRIVER as follows:
- adjust OBSOLETE_OSS_DRIVER dependencie
- from the release of 2.6.16 till the release of 2.6.17:
approx. two months for users to report problems with the ALSA
drivers for the same hardware
- after the release of 2.6.17 (and before 2.6.18):
remove the subset of drivers marked at OBSOLETE_OSS_DRIVER without
known regressions in the ALSA drivers for the same hardware
Additionally, correct some OBSOLETE_OSS_DRIVER dependencies.
A rationale of the changes is in
http://lkml.org/lkml/2006/1/28/135
Signed-off-by: Adrian Bunk <bunk@stusta.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Jon Masters [Thu, 20 Apr 2006 09:43:20 +0000 (02:43 -0700)]
[PATCH] sound: fix hang in mpu401_uart.c
This fixes a hang in mpu401_uart.c that can occur when the mpu401 interface
is non-existent or otherwise doesn't respond to commands but we issue IO
anyway. snd_mpu401_uart_cmd now returns an error code that is passed up
the stack so that an open() will fail immediately in such cases.
Eventually discovered after wine/cxoffice would constantly cause hard
lockups on my desktop immediately after loading (emulating Windows too
well). Turned out that I'd recently moved my sound cards around and using
/dev/sequencer now talks to a sound card with a broken MPU.
This second version changes -EFAULT to -EIO and frees open resources on
error too. Test booted and seems to work ok.
Signed-off-by: Jon Masters <jcm@jonmasters.org> Cc: Jaroslav Kysela <perex@suse.cz> Acked-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Jean Delvare [Thu, 20 Apr 2006 09:43:18 +0000 (02:43 -0700)]
[PATCH] i2c-i801: Fix resume when PEC is used
Fix for bug #6395:
Fail to resume on Tecra M2 with ADM1032 and Intel 82801DBM
The BIOS of the Tecra M2 doesn't like it when it has to reboot or resume
after the i2c-i801 driver has left the SMBus in PEC mode. The most simple
fix is to clear the PEC bit after after every transaction. That's what
this driver was doing up to 2.6.15 (inclusive).
Thanks to Daniele Gaffuri for the very good report.
Signed-off-by: Jean Delvare <khali@linux-fr.org> Cc: Greg KH <greg@kroah.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Johannes Goecke [Thu, 20 Apr 2006 09:43:17 +0000 (02:43 -0700)]
[PATCH] MSI-K8T-Neo2-Fir OnboardSound and additional Soundcard
On the MSI-K8T-NEO2 FIR ( Athlon-64, Socket 939 with VIA-K8T800- Chipset
and onboard Sound,... ) the BIOS lets you choose "DISABLED" or "AUTO" for
the On-Board Sound Device.
If you add another PCI-Sound-Card the BIOS disables the on-board device.
So far I have a Quirk, that does set the correspondent BIT in the
PCI-registers to enable the soundcard.
But how to ensure that the code is executed ONLY on excactly this kind of
boards (not any other with similar Chipset)?
Cc: Jaroslav Kysela <perex@suse.cz> Acked-by: Takashi Iwai <tiwai@suse.de> Cc: Lee Revell <rlrevell@joe-job.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
[PATCH] cs5535_gpio.c: call cdev_del() during module_exit to unmap kobject references and other cleanups
During module unloading, cdev_del() must be called to unmap cdev related
kobject references and other cleanups(such as inode->i_cdev being set to
NULL) which prevents the OOPS upon subsequent loading, usage and unloading
of modules(as seen in the mail thread
http://marc.theaimsgroup.com/?l=linux-kernel&m=114533640609018&w=2).
Darren Jenkins [Thu, 20 Apr 2006 09:43:13 +0000 (02:43 -0700)]
[PATCH] fix section mismatch in pm2fb.o
WARNING: drivers/video/pm2fb.o - Section mismatch: reference
to .init.data: from .text after 'pm2fb_set_par' (at offset 0xd5d)
WARNING: drivers/video/pm2fb.o - Section mismatch: reference
to .init.data: from .text after 'pm2fb_set_par' (at offset 0xd82)
They are caused because pm2fb_set_par() uses lowhsync and lowvsync which
are marked __devinitdata.
Signed-off-by: Darren Jenkins <darrenrjenkins@gmail.com> Signed-off-by: Adrian Bunk <bunk@stusta.de> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
[PATCH] kprobes: NULL out non-relevant fields in struct kretprobe
In cases where a struct kretprobe's *_handler fields are non-NULL, it is
possible to cause a system crash, due to the possibility of calls ending up
in zombie functions. Documentation clearly states that unused *_handlers
should be set to NULL, but kprobe users sometimes fail to do so.
Fix it by setting the non-relevant fields of the struct kretprobe to NULL.
Signed-off-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com> Acked-by: Jim Keniston <jkenisto@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
We added the ability to change a block device's IO elevator scheduler both
at kernel boot and on-the-fly, but we only documented the elevator= boot
parameter. Add a quick how-to on doing it on the fly.
Jayachandran C [Thu, 20 Apr 2006 07:14:49 +0000 (00:14 -0700)]
[EBTABLES]: Clean up vmalloc usage in net/bridge/netfilter/ebtables.c
Make all the vmalloc calls in net/bridge/netfilter/ebtables.c follow
the standard convention. Remove unnecessary casts, and use '*object'
instead of 'type'.
Signed-off-by: Jayachandran C. <c.jayachandran@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: David S. Miller <davem@davemloft.net>
David S. Miller [Thu, 20 Apr 2006 07:10:50 +0000 (00:10 -0700)]
[NET]: Add skb->truesize assertion checking.
Add some sanity checking. truesize should be at least sizeof(struct
sk_buff) plus the current packet length. If not, then truesize is
seriously mangled and deserves a kernel log message.
Currently we'll do the check for release of stream socket buffers.
But we can add checks to more spots over time.
Incorporating ideas from Herbert Xu.
Signed-off-by: David S. Miller <davem@davemloft.net>
where the tailcall at the end overwrites the incoming stack-frame.
Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
[ I would _really_ like to have a way to tell gcc about calling
conventions. The "prevent_tail_call()" macro is pretty ugly ] Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Johannes Berg [Wed, 19 Apr 2006 22:42:28 +0000 (15:42 -0700)]
[SUNGEM]: Marvell PHY suspend.
In a short discussion with Benjamin Herrenschmidt he mentioned
that Marvell PHYs are powered down the same way as the other
ones we currently handle. Thus actually do that, hopefully
saving some power during suspend.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: David S. Miller <davem@davemloft.net>
David S. Miller [Wed, 19 Apr 2006 22:37:13 +0000 (15:37 -0700)]
[LLC]: Use pskb_trim_rcsum() in llc_fixup_skb().
Kernel Bugzilla #6409
If we use plain skb_trim(), that's wrong, because if
the SKB is cloned, and it can be because we unshared
it in the caller, we have to allow reallocation. The
pskb_trim*() family of routines is therefore the most
appropriate here.
Signed-off-by: David S. Miller <davem@davemloft.net>
I've just realised that the RtNetlink code does not check the
permission for SIOCGIWENCODE and SIOCGIWENCODEEXT, which means that
any user can read the encryption keys. The fix is trivial and should
go in 2.6.17 alonside the two other patch I sent you last week.
Signed-off-by: Jean Tourrilhes <jt@hpl.hp.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Erik Mouw [Thu, 13 Apr 2006 13:02:27 +0000 (15:02 +0200)]
[PATCH] bcm43xx: iw_priv_args names should be <16 characters
The room for the names in bcm43xx_priv_wx_args[] are IFNAMSIZ long and
IFNAMSIZ is defined as 16, so the names in bcm43xx_priv_wx_args should
be 15 characters (16 including the trailing \0). This patch fixes that
for the "set_shortpreambl", "get_shortpreambl", "set_swencryption", and
"get_swencryption" private calls. Patch is against 2.6.17-rc1.
Signed-off-by: Erik Mouw <erik@harddisk-recovery.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Randy Dunlap [Tue, 11 Apr 2006 21:31:56 +0000 (14:31 -0700)]
[PATCH] bcm43xx wireless: fix printk format warnings
Fix printk format warnings:
drivers/net/wireless/bcm43xx/bcm43xx_debugfs.c:456: warning: format ‘%u’ expects type ‘unsigned int’, but argument 3 has type ‘size_t’
drivers/net/wireless/bcm43xx/bcm43xx_debugfs.c:460: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 2 has type ‘size_t’
drivers/net/wireless/bcm43xx/bcm43xx_debugfs.c:476: warning: format ‘%u’ expects type ‘unsigned int’, but argument 3 has type ‘size_t’
drivers/net/wireless/bcm43xx/bcm43xx_debugfs.c:480: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 2 has type ‘size_t’
drivers/net/wireless/bcm43xx/bcm43xx_dma.c:200: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 2 has type ‘dma_addr_t’
drivers/net/wireless/bcm43xx/bcm43xx_dma.c:311: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 2 has type ‘dma_addr_t’
drivers/net/wireless/bcm43xx/bcm43xx_dma.c:733: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 2 has type ‘dma_addr_t’
Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg [Thu, 13 Apr 2006 00:42:42 +0000 (02:42 +0200)]
[PATCH] softmac: fix event sending
Softmac is sending custom events to userspace already, but it
should _really_ be sending the right WEXT events instead. This
patch fixes that.
Signed-off-by: Dan Williams <dcbw@redhat.com> Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Below patch allows using iw_mode auto with softmac. bcm43xx forces managed
so this bug wasn't noticed earlier, but this was one of the problems why
zd1211 didn't work earlier.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
[PATCH] softmac: return -EAGAIN from getscan while scanning
Below patch was developed after discussion with Daniel Drake who
mentioned to me that wireless tools expect an EAGAIN return from getscan
so that they can wait for the scan to finish before printing out the
results.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Michael Buesch [Thu, 6 Apr 2006 23:42:55 +0000 (01:42 +0200)]
[PATCH] softmac: fix spinlock recursion on reassoc
This fixes a spinlock recursion on receiving a reassoc request.
On reassoc, the softmac calls back into the driver. This results in a
driver lock recursion. This schedules the assoc workqueue, instead
of calling it directly.
Probably, we should defer the _whole_ management frame processing
to a tasklet or workqueue, because it does several callbacks into the driver.
That is dangerous.
This fix should go into linus's tree, before 2.6.17 is released, because it
is remote exploitable (DoS by crash).
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Jean Tourrilhes [Tue, 4 Apr 2006 22:59:46 +0000 (15:59 -0700)]
[PATCH] Revert NET_RADIO Kconfig title change
2.6.17-rc1 changed the title for the entry CONFIG_NET_RADIO. I
personally disagree with this change and want it reverted. Patch for
2.6.17-rc1.
Rationale : WIRELESS_EXT is an invisible option. Therefore,
the only way for a user to enable it is via NET_RADIO. Some users need
to do that for out-of-tree drivers. Therefore it should be mentionned
in the title of the option.
Rationale2 : the option just below is called "Wireless
Extension API over RtNetlink". Some users may confuse this option for
the main "Wireless Extension" option. Therefore reverting this change
help disambiguate the relation between those two options.
Signed-off-by: Jean Tourrilhes <jt@hpl.hp.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Check the permissions when user-space try to read the
encryption parameters via SIOCGIWENCODEEXT. This is trivial and
probably should go in 2.6.17...
Bug was found by Brian Eaton <eaton.lists@gmail.com>, thanks !
Signed-off-by: Jean Tourrilhes <jt@hpl.hp.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Dan Williams [Fri, 31 Mar 2006 20:08:46 +0000 (15:08 -0500)]
[PATCH] wireless/airo: clean up WEXT association and scan events
Airo firmware versions >= 5.30.17 send re-association events to the
driver that are currently unrecognized, causing spurious disassociation
events to be sent to user space. Loss of sync due to scan requests also
results in disassociation events sent to user space. This patch traps
those two events; suppressing sync-loss on scan, and sending the correct
association event on re-association notifications.
Signed-off-by: Dan Williams <dcbw@redhat.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Randy Dunlap [Mon, 27 Mar 2006 22:53:41 +0000 (14:53 -0800)]
[PATCH] softmac uses Wiress Ext.
softmac uses wireless extensions, so let it SELECT that config option;
WARNING: "wireless_send_event" [net/ieee80211/softmac/ieee80211softmac.ko] undefined!
Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Merge branch 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband
* 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband:
IB/mthca: make a function static
IB/ipath: Fix whitespace
IB/ipath: Make more names static
IB/mad: Fix RMPP version check during agent registration
IB/srp: Remove request from list when SCSI abort succeeds
Hal Rosenstock [Thu, 13 Apr 2006 01:29:10 +0000 (21:29 -0400)]
IB/mad: Fix RMPP version check during agent registration
Only check that RMPP version is not specified when MAD class does not
support RMPP. Just because a class is allowed to use RMPP doesn't
mean that rmpp_version needs to be set for the MAD agent to
register. Checking this was a recent change which was too pedantic.
Signed-off-by: Hal Rosenstock <halr@voltaire.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
Roland Dreier [Wed, 19 Apr 2006 18:40:10 +0000 (11:40 -0700)]
IB/srp: Remove request from list when SCSI abort succeeds
If a SCSI abort succeeds, then the aborted request should to be
removed from the list of pending requests. This fixes list corruption
after an abort occurs.
* git://git.linux-nfs.org/pub/linux/nfs-2.6:
SUNRPC: Dead code in net/sunrpc/auth_gss/auth_gss.c
NFS: remove needless check in nfs_opendir()
NFS: nfs_show_stats; for_each_possible_cpu(), not NR_CPUS
NFS: make 2 functions static
NFS,SUNRPC: Fix compiler warnings if CONFIG_PROC_FS & CONFIG_SYSCTL are unset
NFS: fix PROC_FS=n compile error
VFS: Fix another open intent Oops
RPCSEC_GSS: fix leak in krb5 code caused by superfluous kmalloc
Eric Sesterhenn [Wed, 19 Apr 2006 17:06:49 +0000 (13:06 -0400)]
SUNRPC: Dead code in net/sunrpc/auth_gss/auth_gss.c
Hi,
the coverity checker spotted that cred is always NULL
when we jump to out_err ( there is just one case, when
we fail to allocate the memory for cred )
This is Coverity ID #79
Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Adrian Bunk [Tue, 18 Apr 2006 17:14:13 +0000 (13:14 -0400)]
NFS: fix PROC_FS=n compile error
fs/built-in.o: In function `nfs_show_stats':inode.c:(.text+0x15481a): undefined reference to `rpc_print_iostats'
net/built-in.o: In function `rpc_destroy_client': undefined reference to `rpc_free_iostats'
net/built-in.o: In function `rpc_clone_client': undefined reference to `rpc_alloc_iostats'
net/built-in.o: In function `rpc_new_client': undefined reference to `rpc_alloc_iostats'
net/built-in.o: In function `xprt_release': undefined reference to `rpc_count_iostats'
make: *** [.tmp_vmlinux1] Error 1
Signed-off-by: Adrian Bunk <bunk@stusta.de> Cc: Trond Myklebust <trond.myklebust@fys.uio.no> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
J. Bruce Fields [Tue, 18 Apr 2006 17:14:02 +0000 (13:14 -0400)]
RPCSEC_GSS: fix leak in krb5 code caused by superfluous kmalloc
I was sloppy when generating a previous patch; I modified the callers of
krb5_make_checksum() to allocate memory for the buffer where the result is
returned, then forgot to modify krb5_make_checksum to stop allocating that
memory itself. The result is a per-packet memory leak. This fixes the
problem by removing the now-superfluous kmalloc().
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Merge branch 'splice' of git://brick.kernel.dk/data/git/linux-2.6-block
* 'splice' of git://brick.kernel.dk/data/git/linux-2.6-block:
[PATCH] splice: fixup writeout path after ->map changes
[PATCH] splice: offset fixes
[PATCH] tee: link_pipe() must be careful when dropping one of the pipe locks
[PATCH] splice: cleanup the SPLICE_F_NONBLOCK handling
[PATCH] splice: close i_size truncate races on read
If at least 1 byte was transferred to the device, return number of bytes,
otherwise:
- return -EFBIG - if file offset is past the maximum allowable offset or
size is greater than framebuffer length
- return -ENOSPC - if size is greater than framebuffer length - offset
Randy Dunlap [Wed, 19 Apr 2006 05:22:11 +0000 (22:22 -0700)]
[PATCH] savagefb: fix section mismatch warnings
Fix modpost section mismatch warnings in savagefb driver:
WARNING: drivers/video/savage/savagefb.o - Section mismatch: reference to .init.text: from .exit.text after 'savagefb_remove' (at offset 0x66)
WARNING: drivers/video/savage/savagefb.o - Section mismatch: reference to .init.text: from .exit.text after 'savagefb_remove' (at offset 0x6e)
WARNING: drivers/video/savage/savagefb.o - Section mismatch: reference to .init.text: from .text.savagefb_resume after 'savagefb_resume' (at offset 0x70)
Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Randy Dunlap [Wed, 19 Apr 2006 05:22:10 +0000 (22:22 -0700)]
[PATCH] radeonfb section mismatches
Marking radeon_pci_register() as __devinit clears up all section
mismatch warnings that are caused by radeon_pci_register() calling
various __devinit function. Is there some reason not to do this?
WARNING: drivers/video/aty/radeonfb.o - Section mismatch: reference to .init.text: from .text.radeonfb_pci_register after 'radeonfb_pci_register' (at offset 0x628)
WARNING: drivers/video/aty/radeonfb.o - Section mismatch: reference to .init.text: from .text.radeonfb_pci_register after 'radeonfb_pci_register' (at offset 0x6b5)
WARNING: drivers/video/aty/radeonfb.o - Section mismatch: reference to .init.text: from .text.radeonfb_pci_register after 'radeonfb_pci_register' (at offset 0x6bd)
WARNING: drivers/video/aty/radeonfb.o - Section mismatch: reference to .init.text:radeon_probe_screens from .text.radeonfb_pci_register after 'radeonfb_pci_register' (at offset 0x7d6)
WARNING: drivers/video/aty/radeonfb.o - Section mismatch: reference to .init.text:radeon_check_modes from .text.radeonfb_pci_register after 'radeonfb_pci_register' (at offset 0x7e5)
Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Cc: "Antonino A. Daplas" <adaplas@pol.net> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Jean Delvare [Wed, 19 Apr 2006 05:22:09 +0000 (22:22 -0700)]
[PATCH] fb: Fix section mismatch in savagefb
Fix the following section mismatch:
WARNING: drivers/video/savage/savagefb.o - Section mismatch: reference to .init.data: from .text.savagefb_probe after 'savagefb_probe' (at offset 0x5e2)
Signed-off-by: Jean Delvare <khali@linux-fr.org> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
From http://bugzilla.kernel.org/show_bug.cgi?id=6358
The alim15x3.c havn't been update for 3 years. Recently when we use this
"ULI M1573" south bridge chip found that can't mount CDROM(VCD) smoothly,
must waiting for a long time. After I check the "ULI M1573" south bridge
datasheet, I found the reason. The reason is the "ULI M1573" version in
the Linux is "0xC7" not "0xC4" anymore So I was modified the source than it
was successed.
Cc: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl> Acked-by: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>