Benjamin Li [Mon, 26 Feb 2007 19:06:32 +0000 (11:06 -0800)]
qla3xxx: Remove unnecessary memset() in qla3xxx_send()
We do not need to zero out the 64 byte MAC request I/O control block.
By zeroing out the control block and setting it to proper fields is
redundant work. This is because in the qla3xxx_send() function we will
already set the proper fields in this structure. The unused fields are
not looked at by the hardware and do not need to be zeroed out.
Signed-off-by: Benjamin Li <benjamin.li@qlogic.com> Signed-off-by: Ron Mercer <ron.mercer@qlogic.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Benjamin Li [Mon, 26 Feb 2007 19:06:31 +0000 (11:06 -0800)]
qla3xxx: Return proper error codes when the 4022/4032 is being probed
The return code was not properly set when when allocating memory or mapping
memory failed. Depending on the stack, the return code would sometimes
return 0, which indicates everything was ok, when in fact there was an error.
This would cause trouble when the module was removed. Now, we will pass
back the proper return code when an error occurs during the PCI probe.
Signed-off-by: Benjamin Li <benjamin.li@qlogic.com> Signed-off-by: Ron Mercer <ron.mercer@qlogic.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
It looks like the skge driver inherited another bug from the sk98lin code.
If I send from 1000mbit port to a machine on 100mbit port, the switch should
be doing hardware flow control, but no pause frames show up in the statistics.
This is the analog of the recent sky2 fixes. The device needs to listen
for multicast pause frames and then not discard them.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org> Signed-off-by: Jeff Garzik <jeff@garzik.org>
Linas Vepstas [Tue, 20 Feb 2007 22:41:03 +0000 (16:41 -0600)]
spidernet: fix racy double-free of skb
It appears that under certain circumstances, a race will result
in a double-free of an skb. This patch null's out the skb pointer
upon the skb free, avoiding the inadvertent deref of bogus data.
The next patch fixes the actual race.
Linas Vepstas [Tue, 20 Feb 2007 22:40:06 +0000 (16:40 -0600)]
spidernet: separate hardware state from driver state.
This patch separates the hardware descriptor state from the
driver descriptor state, per (old) suggestion from Ben Herrenschmidt.
This compiles and boots and seems to work.
Ishizaki Kou [Tue, 20 Feb 2007 22:37:42 +0000 (16:37 -0600)]
spidernet: remove txram full logging
This patches removes logging for SPIDER_NET_GTMFLLINT interrupts.
Since the interrupts are not irregular, and they happen frequently
when using 100Mbps network switches.
Jens Osterkamp [Tue, 20 Feb 2007 22:30:50 +0000 (16:30 -0600)]
sungem_phy: support bcm5461 phy, autoneg.
This version moves the medium variable to the card specific structure and
changes the GMII_* to BCM54XX_* #defines.
This patch adds improved version of enable_fiber for both the 5421 and
the 5461 phy. It is now possible to specify with these wether you want
autonegotiation or not. This is needed for bladecenter switches where
some expect autonegotiation and some dont seem to like this at all.
Depending on this flag it sets phy->autoneg accordingly for the fiber mode.
More importantly it implements proper read_link and poll_link functions
for both phys which can handle both copper and fiber mode by determining
the medium first and then branching to the required functions. For fiber
they all work fine, for copper they are not tested but return the result
of the genmii_* function anyway which is supposed to work.
The patch moves the genmii_* functions around to avoid foreward declarations.
Atsushi Nemoto [Thu, 22 Feb 2007 15:39:48 +0000 (00:39 +0900)]
[MIPS] Kill redundant EXTRA_AFLAGS
Many Makefiles in arch/mips have EXTRA_AFLAGS := $(CFLAGS) line. This
is redundant while AFLAGS contains $(cflags-y) and any options only
listed in CFLAGS (not in cflags-y) should be unnecessary for asm
sources.
Linus Torvalds [Mon, 26 Feb 2007 22:55:48 +0000 (14:55 -0800)]
Revert "[CPUFREQ] constify cpufreq_driver where possible."
This reverts commit aeeddc1435c37fa3fc844f31d39c185b08de4158, which was
half-baked and broken. It just resulted in compile errors, since
cpufreq_register_driver() still changes the 'driver_data' by setting
bits in the flags field. So claiming it is 'const' _really_ doesn't
work.
Linus Torvalds [Mon, 26 Feb 2007 21:18:43 +0000 (13:18 -0800)]
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:
IPoIB: Correct debugging output when path record lookup fails
RDMA/cxgb3: Stop the EP Timer on BAD CLOSE
RDMA/cxgb3: cleanups
RDMA/cma: Remove unused node_guid from cma_device structure
IB/cm: Remove ca_guid from cm_device structure
RDMA/cma: Request reversible paths only
IB/core: Set hop limit in ib_init_ah_from_wc correctly
IB/uverbs: Return correct error for invalid PD in register MR
IPoIB: Remove unused local_rate tracking
IPoIB/cm: Improve small message bandwidth
IB/mthca: Make 2 functions static
Alan [Wed, 21 Feb 2007 16:41:23 +0000 (16:41 +0000)]
[PATCH] Fix oops in pata_pcmcia
The change to the devres layer re-orders the execution of cleanup
functions and in turn causes the pcmcia layer to oops as it zaps a
pointer now needed later on. We simply leave the pointer alone.
Signed-off-by: Alan Cox <alan@redhat.com> Acked-by: Jeff Garzik <jeff@garzik.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Roland Dreier [Mon, 26 Feb 2007 20:57:08 +0000 (12:57 -0800)]
IPoIB: Correct debugging output when path record lookup fails
If path_rec_completion() is passed a non-NULL path record pointer
along with an unsuccessful status value, the tracing code incorrectly
prints the (invalid) DLID from the path record rather than the more
interesting status code. The actual logic of the function correctly
uses the path record only if the status indicates a successful lookup.
Ondrej Zajicek [Thu, 22 Feb 2007 16:00:41 +0000 (17:00 +0100)]
[PATCH] Fix build-failure in drivers/video/s3fb.c
Toralf Förster pointed out that drivers/video/s3fb.c would fail to compile:
> ...
> CC drivers/video/s3fb.o
> drivers/video/s3fb.c: In function `s3_pci_remove':
> drivers/video/s3fb.c:1003: warning: unused variable `par'
> drivers/video/s3fb.c: In function `s3fb_setup':
> drivers/video/s3fb.c:1141: error: `mtrr' undeclared (first use in this function)
> drivers/video/s3fb.c:1141: error: (Each undeclared identifier is reported only once
> drivers/video/s3fb.c:1141: error: for each function it appears in.)
> make[2]: *** [drivers/video/s3fb.o] Error 1
> make[1]: *** [drivers/video] Error 2
> make: *** [drivers] Error 2
Ingo Molnar [Thu, 22 Feb 2007 08:38:22 +0000 (09:38 +0100)]
[PATCH] x86: add -freg-struct-return to CFLAGS
Jeremy Fitzhardinge suggested the use of -freg-struct-return, which does
structure-returns (such as when using pte_t) in registers instead of on
the stack.
that is indeed so, and this option reduced the kernel size a bit:
* master.kernel.org:/pub/scm/linux/kernel/git/kyle/parisc-2.6: (78 commits)
[PARISC] Use symbolic last syscall in __NR_Linux_syscalls
[PARISC] Add missing statfs64 and fstatfs64 syscalls
Revert "[PARISC] Optimize TLB flush on SMP systems"
[PARISC] Compat signal fixes for 64-bit parisc
[PARISC] Reorder syscalls to match unistd.h
Revert "[PATCH] make kernel/signal.c:kill_proc_info() static"
[PARISC] fix sys_rt_sigqueueinfo
[PARISC] fix section mismatch warnings in harmony sound driver
[PARISC] do not export get_register/set_register
[PARISC] add ENTRY()/ENDPROC() and simplify assembly of HP/UX emulation code
[PARISC] convert to use CONFIG_64BIT instead of __LP64__
[PARISC] use CONFIG_64BIT instead of __LP64__
[PARISC] add ASM_EXCEPTIONTABLE_ENTRY() macro
[PARISC] more ENTRY(), ENDPROC(), END() conversions
[PARISC] fix ENTRY() and ENDPROC() for 64bit-parisc
[PARISC] Fixes /proc/cpuinfo cache output on B160L
[PARISC] implement standard ENTRY(), END() and ENDPROC()
[PARISC] kill ENTRY_SYS_CPUS
[PARISC] clean up debugging printks in smp.c
[PARISC] factor syscall_restart code out of do_signal
...
Fix conflict in include/linux/sched.h due to kill_proc_info() being made
publicly available to PARISC again.
Bernhard Walle [Mon, 26 Feb 2007 20:10:32 +0000 (12:10 -0800)]
[XFRM]: Fix oops in xfrm4_dst_destroy()
With 2.6.21-rc1, I get an oops when running 'ifdown eth0' and an IPsec
connection is active. If I shut down the connection before running 'ifdown
eth0', then there's no problem. The critical operation of this script is to
kill dhcpd.
This patch fixes that oops. I don't know the network code of the Linux
kernel in deep, so if that fix is wrong, please change it. But please
fix the oops. :)
Signed-off-by: Bernhard Walle <bwalle@suse.de> Acked-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Eric Paris [Thu, 22 Feb 2007 23:11:31 +0000 (18:11 -0500)]
Reassign printk levels in selinux kernel code
Below is a patch which demotes many printk lines to KERN_DEBUG from
KERN_INFO. It should help stop the spamming of logs with messages in
which users are not interested nor is there any action that users should
take. It also promotes some KERN_INFO to KERN_ERR such as when there
are improper attempts to register/unregister security modules.
A similar patch was discussed a while back on list:
http://marc.theaimsgroup.com/?t=116656343500003&r=1&w=2
This patch addresses almost all of the issues raised. I believe the
only advice not taken was in the demoting of messages related to
undefined permissions and classes.
Signed-off-by: Eric Paris <eparis@redhat.com> Acked-by: Stephen Smalley <sds@tycho.nsa.gov>
security/selinux/hooks.c | 20 ++++++++++----------
security/selinux/ss/avtab.c | 2 +-
security/selinux/ss/policydb.c | 6 +++---
security/selinux/ss/sidtab.c | 2 +-
4 files changed, 15 insertions(+), 15 deletions(-) Signed-off-by: James Morris <jmorris@namei.org>
[XFRM_TUNNEL]: Reload header pointer after pskb_may_pull/pskb_expand_head
Please consider applying, this was found on your latest
net-2.6 tree while playing around with that ip_hdr() + turn
skb->nh/h/mac pointers as offsets on 64 bits idea :-)
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Having a work queue for checking carrier leads to lots of race issues.
Simpler to just get the cost when data structure is created and
update on change.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Herbert Xu [Wed, 21 Feb 2007 16:53:47 +0000 (01:53 +0900)]
[IPV4] devinet: Register inetdev earlier.
This patch allocates inetdev at registration for all devices
in line with IPv6. This allows sysctl configuration on the
devices to occur before they're brought up or addresses are
added.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Vlad Yasevich [Wed, 21 Feb 2007 10:06:19 +0000 (02:06 -0800)]
[SCTP]: Strike the transport before updating rto.
Once we reach a point where we exceed the max.path.retrans, strike the
transport before updating the rto. This will force transport switch at
the right time, instead of 1 retransmit too late.
Signed-off-by: Vlad Yasevich <vladislav.yasevich@hp.com> Signed-off-by: Sridhar Samudrala <sri@us.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Vlad Yasevich [Wed, 21 Feb 2007 10:06:04 +0000 (02:06 -0800)]
[SCTP]: Fix connection hang/slowdown with PR-SCTP
The problem that this patch corrects happens when all of the following
conditions are satisfisfied:
1. PR-SCTP is used and the timeout on the chunks is set below RTO.Max.
2. One of the paths on a multihomed associations is brought down.
In this scenario, data will expire within the rto of the initial
transmission and will never be retransmitted. However this data still
fills the send buffer and is counted against the association as outstanding
data. This causes any new data not to be sent and retransmission to not
happen.
The fix is to discount the abandoned data from the outstanding count and
peers rwnd estimation. This allows new data to be sent and a retransmission
timer restarted. Even though this new data will most likely expire within
the rto, the timer still counts as a strike against the transport and forces
the FORWARD-TSN chunk to be retransmitted as well.
Signed-off-by: Vlad Yasevich <vladislav.yasevich@hp.com> Signed-off-by: Sridhar Samudrala <sri@us.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Michael Chan [Wed, 21 Feb 2007 07:25:40 +0000 (23:25 -0800)]
[TG3]: TSO workaround fixes.
1. Add race condition check after netif_stop_queue(). tg3_tx() runs
without netif_tx_lock and can race with tg3_start_xmit_dma_bug() ->
tg3_tso_bug().
2. Firmware TSO in 5703/5704/5705 also have the same TSO limitation,
i.e. they cannot handle TSO headers bigger than 80 bytes. Rename
TG3_FL2_HW_TSO_1_BUG to TG3_FL2_TSO_BUG and set this flag on
these chips as well.
3. Update version to 3.74.
Signed-off-by: Michael Chan <mchan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Joe Jin [Tue, 20 Feb 2007 09:30:15 +0000 (01:30 -0800)]
[IPV6]: Adjust inet6_exit() cleanup sequence against inet6_init()
This patch for adjust inet6_exit() to inverse sequence to inet6_init().
At ipv6_init, it first create proc_root/net/dev_snmp6 entry by call
ipv6_misc_proc_init(), then call addrconf_init() to create the corresponding
device entry at this directory, but at inet6_exit, ipv6_misc_proc_exit()
called first, then call addrconf_init().
Signed-off-by: Joe Jin <joe.jin@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Noriaki TAKAMIYA [Tue, 20 Feb 2007 09:08:41 +0000 (01:08 -0800)]
[IPSEC]: More fix is needed for __xfrm6_bundle_create().
Fixed to set fl_tunnel.fl6_src correctly in xfrm6_bundle_create().
Signed-off-by: Noriaki TAKAMIYA <takamiya@po.ntts.co.jp> Acked-by: Masahide NAKAMURA <nakam@linux-ipv6.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Marcel Holtmann [Sat, 17 Feb 2007 22:58:57 +0000 (23:58 +0100)]
[Bluetooth] Make use of device_move() for RFCOMM TTY devices
In the case of bound RFCOMM TTY devices the parent is not available
before its usage. So when opening a RFCOMM TTY device, move it to
the corresponding ACL device as a child. When closing the device,
move it back to the virtual device tree.
Marcel Holtmann [Sat, 17 Feb 2007 22:58:53 +0000 (23:58 +0100)]
[Bluetooth] Add open and close callbacks for HID device
The open and close callbacks for the HID device are not optional, but
for the Bluetooth HID report mode support it is enough to add empty
dummy callbacks.
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/driver-2.6:
Revert "Driver core: let request_module() send a /sys/modules/kmod/-uevent"
Driver core: fix error by cleanup up symlinks properly
make kernel/kmod.c:kmod_mk static
power management: fix struct layout and docs
power management: no valid states w/o pm_ops
Driver core: more fallout from class_device changes for pcmcia
sysfs: move struct sysfs_dirent to private header
driver core: refcounting fix
Driver core: remove class_device_rename
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6:
USB: export autosuspend delay in sysfs
sysfs: allow attributes to be added to groups
USB: make autosuspend delay a module parameter
USB: minor cleanups for sysfs.c
USB: add a blacklist for devices that can't handle some things we throw at them.
USB: refactor usb device matching and create usb_device_match
USB: Wacom driver updates
gadgetfs: Fixed bug in ep_aio_read_retry.
USB: Use USB defines in usbmouse.c and usbkbd.c
USB: add rationale on why usb descriptor structures have to be packed
USB: ftdi_sio: Adding VID and PID for Tellstick
UHCI: Eliminate asynchronous skeleton Queue Headers
UHCI: Add macros for computing DMA values
USB: Davicom DM9601 usbnet driver
USB: asix.c - Add JVC-PRX1 ids
usbmon: Remove erroneous __exit
USB: add driver for iowarrior devices.
USB: option: add a bunch of new device ids
USB: option: remove duplicate device id table
Linus Torvalds [Mon, 26 Feb 2007 19:40:46 +0000 (11:40 -0800)]
Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus:
[MIPS] Fix port 0 mac address for mips mv6434x platforms
[SERIAL] serial_txx9 driver update
Revert "[PATCH] Generic ioremap_page_range: mips conversion"
[MIPS] Cobalt: Rename "Colo" MTD partition to "firmware".
[MIPS] SMP: Get smp_tune_scheduling to do something useful.
[MIPS] Add basic SMARTMIPS ASE support
David S. Miller [Sun, 25 Feb 2007 06:11:42 +0000 (22:11 -0800)]
[TICK] tick-common: Fix one-shot handling in tick_handle_periodic().
When clockevents_program_event() is given an expire time in the
past, it does not update dev->next_event, so this looping code
would loop forever once the first in-the-past expiration time
was used.
Keep advancing "next" locally to fix this bug.
Acked-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: David S. Miller <davem@davemloft.net>