firefly-linux-kernel-4.4.55.git
16 years agoath9k: Remove redundant data structure ath9k_txq_info
Sujith [Thu, 7 Aug 2008 05:23:10 +0000 (10:53 +0530)]
ath9k: Remove redundant data structure ath9k_txq_info

Use ath9k_tx_queue_info which contains the same elements,
and merge get/set functions of tx queue properties.
Also, fix whitespace damage in struct ath_softc.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoath9k: Cleanup data structures related to HW capabilities
Sujith [Thu, 7 Aug 2008 05:22:38 +0000 (10:52 +0530)]
ath9k: Cleanup data structures related to HW capabilities

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoath9k: work around gcc ICEs
Adrian Bunk [Tue, 5 Aug 2008 19:06:51 +0000 (22:06 +0300)]
ath9k: work around gcc ICEs

This patch works around an internal compiler error (gcc bug #37014) in
all gcc 4.2 compilers and the gcc 4.3 series up to at least 4.3.1
on at least powerpc and mips.

Many thanks to Andrew Pinski for analyzing the gcc bug.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoath9k: Add new Atheros IEEE 802.11n driver
Luis R. Rodriguez [Mon, 4 Aug 2008 07:16:41 +0000 (00:16 -0700)]
ath9k: Add new Atheros IEEE 802.11n driver

This adds the new mac80211 11n ath9k Atheros driver. Only STA support
is currently enabled and tested.

Signed-off-by: Senthil Balasubramanian <senthilkumar@atheros.com>
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: Jack Howarth <howarth@bromo.msbb.uc.edu>
Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com>
Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: Pavel Roskin <proski@gnu.org>
Signed-off-by: Vasanthakumar Thiagarajan <vasanth@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoath5k: remove Atheros 11n devices from supported list
Luis R. Rodriguez [Mon, 4 Aug 2008 07:16:40 +0000 (00:16 -0700)]
ath5k: remove Atheros 11n devices from supported list

Remove Atheros 11n devices from being claimed by ath5k as its
now handled by ath9k.

Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agolist.h: add list_cut_position()
Luis R. Rodriguez [Wed, 6 Aug 2008 20:28:54 +0000 (13:28 -0700)]
list.h: add list_cut_position()

This adds list_cut_position() which lets you cut a list into
two lists given a pivot in the list.

Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agolist.h: Add list_splice_tail() and list_splice_tail_init()
Luis R. Rodriguez [Wed, 6 Aug 2008 22:21:26 +0000 (15:21 -0700)]
list.h: Add list_splice_tail() and list_splice_tail_init()

If you are using linked lists for queues list_splice() will not do what
you would expect even if you use the elements passed reversed. We need
to handle these differently. We add list_splice_tail() and
list_splice_tail_init().

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agopktgen: multiqueue etc.
Robert Olsson [Thu, 7 Aug 2008 09:23:01 +0000 (02:23 -0700)]
pktgen: multiqueue etc.

Sofar far pktgen have had a restriction to only use one device per kernel
thread. With the new multiqueue architecture this is no longer adequate.

The patch below is an effort to remove this by in pktgen configuration
adding a tag to  the device name a la eth0@0 etc. The tag is used for
usual device config just as before. Also a new flag is introduced to mirror
queue_map with sending threads smp_processor_id() QUEUE_MAP_CPU.

An example: We use 4 CPU's to send to one 10g interface (eth0)
 and we use the new tagging to send a mix of packet sizes, 64, 576 and
 1500 bytes. Also we use TX queues according to smp_processor_id()

 PGDEV=/proc/net/pktgen/kpktgend_0
 pgset "add_device eth0@0"

 PGDEV=/proc/net/pktgen/kpktgend_1
 pgset "add_device eth0@1"

 PGDEV=/proc/net/pktgen/kpktgend_2
 pgset "add_device eth0@2"

 PGDEV=/proc/net/pktgen/kpktgend_3
 pgset "add_device eth0@3"
....
PGDEV=/proc/net/pktgen/eth0@0
pgset "pkt_size 64"
pgset "flag QUEUE_MAP_CPU"

PGDEV=/proc/net/pktgen/eth0@1
pgset "pkt_size 572"
pgset "flag QUEUE_MAP_CPU"

PGDEV=/proc/net/pktgen/eth0@2
pgset "pkt_size 1496"

PGDEV=/proc/net/pktgen/eth0@3
pgset "pkt_size 1496"
pgset "flag QUEUE_MAP_CPU"

Signed-off-by: Robert Olsson <robert.olsson@its.uu.se>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoMerge branch 'upstream-davem' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik...
David S. Miller [Thu, 7 Aug 2008 09:10:27 +0000 (02:10 -0700)]
Merge branch 'upstream-davem' of /linux/kernel/git/jgarzik/netdev-2.6

16 years agoMerge branch 'for-jeff' of git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux...
Jeff Garzik [Thu, 7 Aug 2008 08:05:46 +0000 (04:05 -0400)]
Merge branch 'for-jeff' of git://git./linux/kernel/git/chris/linux-2.6 into tmp

16 years agoWAN: remove extra help text from HDLC_PPP config option
Krzysztof Halasa [Mon, 30 Jun 2008 20:09:15 +0000 (22:09 +0200)]
WAN: remove extra help text from HDLC_PPP config option

Remove extra help text from HDLC_PPP config option.

Signed-off-by: Krzysztof HaƂasa <khc@pm.waw.pl>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agonet/core: Allow receive on active slaves.
Joe Eykholt [Thu, 3 Jul 2008 01:22:02 +0000 (18:22 -0700)]
net/core: Allow receive on active slaves.

If a packet_type specifies an active slave to bonding and not just any
interface, allow it to receive frames that came in on that interface.

Signed-off-by: Joe Eykholt <jre@nuovasystems.com>
Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agonet/core: Allow certain receives on inactive slave.
Joe Eykholt [Thu, 3 Jul 2008 01:22:01 +0000 (18:22 -0700)]
net/core: Allow certain receives on inactive slave.

Allow a packet_type that specifies the exact device to receive
even on an inactive bonding slave devices.  This is important for some
L2 protocols such as LLDP and FCoE.  This can eventually be used
for the bonding special cases as well.

Signed-off-by: Joe Eykholt <jre@nuovasystems.com>
Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agonet/core: Uninline skb_bond().
Joe Eykholt [Thu, 3 Jul 2008 01:22:00 +0000 (18:22 -0700)]
net/core: Uninline skb_bond().

Otherwise subsequent changes need multiple return values.

Signed-off-by: Joe Eykholt <jre@nuovasystems.com>
Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agobonding: Don't destroy bonding master when removing slave via sysfs
Moni Shoua [Thu, 3 Jul 2008 01:21:59 +0000 (18:21 -0700)]
bonding: Don't destroy bonding master when removing slave via sysfs

It is wrong to destroy a bonding master from a context that uses the sysfs
of that bond. When last IPoIB slave is unenslaved from by writing to a
sysfs file (for bond0 this would be /sys/class/net/bond0/bonding/slaves)
the driver tries to destroy the bond. This is wrong and can lead to a
lockup or a crash.  This fix lets the bonding master stay and relies on
the user to destroy the bonding master if necessary (i.e. before module
ib_ipoib is unloaded)

This patch affects only bonds of IPoIB slaves. Ethernet slaves stay
unaffected.

Signed-off-by: Moni Shoua <monis@voltaire.com>
Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agobonding: refactor mii monitor
Jay Vosburgh [Thu, 3 Jul 2008 01:21:58 +0000 (18:21 -0700)]
bonding: refactor mii monitor

Refactor mii monitor.  As with the previous ARP monitor refactor,
the motivation for this is to handle locking rationally (in this case,
removing conditional locking) and generally clean up the code.

This patch breaks up the monolithic mii monitor into two phases:
an inspection phase, followed by an optional commit phase.  The commit phase
is the only portion that requires RTNL or makes changes to state, and is
only called when inspection finds something to change.

Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agotcp: Fix kernel panic when calling tcp_v(4/6)_md5_do_lookup
Gui Jianfeng [Thu, 7 Aug 2008 06:50:04 +0000 (23:50 -0700)]
tcp: Fix kernel panic when calling tcp_v(4/6)_md5_do_lookup

If the following packet flow happen, kernel will panic.
MathineA MathineB
SYN
---------------------->
         SYN+ACK
<----------------------
ACK(bad seq)
---------------------->
When a bad seq ACK is received, tcp_v4_md5_do_lookup(skb->sk, ip_hdr(skb)->daddr))
is finally called by tcp_v4_reqsk_send_ack(), but the first parameter(skb->sk) is
NULL at that moment, so kernel panic happens.
This patch fixes this bug.

OOPS output is as following:
[  302.812793] IP: [<c05cfaa6>] tcp_v4_md5_do_lookup+0x12/0x42
[  302.817075] Oops: 0000 [#1] SMP
[  302.819815] Modules linked in: ipv6 loop dm_multipath rtc_cmos rtc_core rtc_lib pcspkr pcnet32 mii i2c_piix4 parport_pc i2c_core parport ac button ata_piix libata dm_mod mptspi mptscsih mptbase scsi_transport_spi sd_mod scsi_mod crc_t10dif ext3 jbd mbcache uhci_hcd ohci_hcd ehci_hcd [last unloaded: scsi_wait_scan]
[  302.849946]
[  302.851198] Pid: 0, comm: swapper Not tainted (2.6.27-rc1-guijf #5)
[  302.855184] EIP: 0060:[<c05cfaa6>] EFLAGS: 00010296 CPU: 0
[  302.858296] EIP is at tcp_v4_md5_do_lookup+0x12/0x42
[  302.861027] EAX: 0000001e EBX: 00000000 ECX: 00000046 EDX: 00000046
[  302.864867] ESI: ceb69e00 EDI: 1467a8c0 EBP: cf75f180 ESP: c0792e54
[  302.868333]  DS: 007b ES: 007b FS: 00d8 GS: 0000 SS: 0068
[  302.871287] Process swapper (pid: 0, ti=c0792000 task=c0712340 task.ti=c0746000)
[  302.875592] Stack: c06f413a 00000000 cf75f180 ceb69e00 00000000 c05d0d86 000016d0 ceac5400
[  302.883275]        c05d28f8 000016d0 ceb69e00 ceb69e20 681bf6e3 00001000 00000000 0a67a8c0
[  302.890971]        ceac5400 c04250a3 c06f413a c0792eb0 c0792edc cf59a620 cf59a620 cf59a634
[  302.900140] Call Trace:
[  302.902392]  [<c05d0d86>] tcp_v4_reqsk_send_ack+0x17/0x35
[  302.907060]  [<c05d28f8>] tcp_check_req+0x156/0x372
[  302.910082]  [<c04250a3>] printk+0x14/0x18
[  302.912868]  [<c05d0aa1>] tcp_v4_do_rcv+0x1d3/0x2bf
[  302.917423]  [<c05d26be>] tcp_v4_rcv+0x563/0x5b9
[  302.920453]  [<c05bb20f>] ip_local_deliver_finish+0xe8/0x183
[  302.923865]  [<c05bb10a>] ip_rcv_finish+0x286/0x2a3
[  302.928569]  [<c059e438>] dev_alloc_skb+0x11/0x25
[  302.931563]  [<c05a211f>] netif_receive_skb+0x2d6/0x33a
[  302.934914]  [<d0917941>] pcnet32_poll+0x333/0x680 [pcnet32]
[  302.938735]  [<c05a3b48>] net_rx_action+0x5c/0xfe
[  302.941792]  [<c042856b>] __do_softirq+0x5d/0xc1
[  302.944788]  [<c042850e>] __do_softirq+0x0/0xc1
[  302.948999]  [<c040564b>] do_softirq+0x55/0x88
[  302.951870]  [<c04501b1>] handle_fasteoi_irq+0x0/0xa4
[  302.954986]  [<c04284da>] irq_exit+0x35/0x69
[  302.959081]  [<c0405717>] do_IRQ+0x99/0xae
[  302.961896]  [<c040422b>] common_interrupt+0x23/0x28
[  302.966279]  [<c040819d>] default_idle+0x2a/0x3d
[  302.969212]  [<c0402552>] cpu_idle+0xb2/0xd2
[  302.972169]  =======================
[  302.974274] Code: fc ff 84 d2 0f 84 df fd ff ff e9 34 fe ff ff 83 c4 0c 5b 5e 5f 5d c3 90 90 57 89 d7 56 53 89 c3 50 68 3a 41 6f c0 e8 e9 55 e5 ff <8b> 93 9c 04 00 00 58 85 d2 59 74 1e 8b 72 10 31 db 31 c9 85 f6
[  303.011610] EIP: [<c05cfaa6>] tcp_v4_md5_do_lookup+0x12/0x42 SS:ESP 0068:c0792e54
[  303.018360] Kernel panic - not syncing: Fatal exception in interrupt

Signed-off-by: Gui Jianfeng <guijianfeng@cn.fujitsu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agopkt_sched: Fix "parent is root" test in qdisc_create().
David S. Miller [Thu, 7 Aug 2008 06:35:59 +0000 (23:35 -0700)]
pkt_sched: Fix "parent is root" test in qdisc_create().

As noticed by Stephen Hemminger, the root qdisc is denoted by
TC_H_ROOT, not zero.

Signed-off-by: David S. Miller <davem@davemloft.net>
16 years ago[netdrvr] Drivers should not set IFF_* flag themselves
Wang Chen [Tue, 22 Jul 2008 05:13:12 +0000 (13:13 +0800)]
[netdrvr] Drivers should not set IFF_* flag themselves

Some hardware set promisc when they are requested to set IFF_ALLMULTI flag.
It's ok, but if drivers set IFF_PROMISC flag when they set promisc,
it will broken upper layer handle for promisc and allmulti.
In addition, drivers can use their own hardware programming to make it.
So do not allow drivers to set IFF_* flags.

This is a general driver fix, so I didn't split it to pieces and send
to specific driver maintainers.

Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agodm9000: Support MAC address setting through platform data.
Laurent Pinchart [Wed, 23 Jul 2008 15:41:52 +0000 (17:41 +0200)]
dm9000: Support MAC address setting through platform data.

The dm9000 driver reads the chip's MAC address from the attached EEPROM. When
no EEPROM is present, or when the MAC address is invalid, it falls back to
reading the address from the chip.

This patch lets platform code set the desired MAC address through platform
data.

Signed-off-by: Laurent Pinchart <laurentp@cse-semaphore.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years ago3c59x: use netdev_alloc_skb
Stephen Hemminger [Fri, 25 Jul 2008 19:07:22 +0000 (12:07 -0700)]
3c59x: use netdev_alloc_skb

Fix possible bug where end of receive buffer could be overwritten.
The allocation needs to allow for the reserved space. This would only happen
if device received packet greater than Ethernet standard MTU.

Change this driver to use netdev_alloc_skb rather than setting skb->dev
directly. For the initial allocation it doesn't need to be GFP_ATOMIC.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoethtool: Expand ethtool_cmd.speed to 32 bits
Brandon Philips [Tue, 15 Jul 2008 09:18:41 +0000 (02:18 -0700)]
ethtool: Expand ethtool_cmd.speed to 32 bits

Introduce the speed_hi field to ethtool_cmd, using the reserved space,
to expand the speed field to 2^32 Megabits/second.

Making this field expansion now gives us plenty of time to fix up the
user-space pieces that use SIOCETHTOOL before hardware faster than 64
Gb/s is available.

Signed-off-by: Brandon Philips <bphilips@suse.de>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agopegasus: add blacklist support to fix Belkin bluetooth dongle.
Ben Collins [Wed, 30 Jul 2008 19:39:02 +0000 (12:39 -0700)]
pegasus: add blacklist support to fix Belkin bluetooth dongle.

Reference: https://launchpad.net/bugs/140511

The Belkin bluetooth dongle unfortunately shares the vendor and device id
with the network adapter which causes lockups whenever the bluetooth
dongle is inserted.

Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
Signed-off-by: Ben Collins <ben.collins@canonical.com>
Cc: Greg Kroah-Hartman <gregkh@suse.de>
Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agodrivers/net/netxen/netxen_nic_hw.c: fix printk warnings
Andrew Morton [Wed, 30 Jul 2008 19:50:12 +0000 (12:50 -0700)]
drivers/net/netxen/netxen_nic_hw.c: fix printk warnings

drivers/net/netxen/netxen_nic_hw.c: In function 'netxen_nic_pci_mem_read_direct':
drivers/net/netxen/netxen_nic_hw.c:1414: warning: format '%llx' expects type 'long long unsigned int', but argument 3 has type 'u64'
drivers/net/netxen/netxen_nic_hw.c: In function 'netxen_nic_pci_mem_write_direct':
drivers/net/netxen/netxen_nic_hw.c:1487: warning: format '%llx' expects type 'long long unsigned int', but argument 3 has type 'u64'

You don't know what type was used for u64 hence they cannot be printed without
casting.

Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agohamradio: add missing sanity check to tty operation
Eugene Teo [Wed, 30 Jul 2008 19:38:59 +0000 (12:38 -0700)]
hamradio: add missing sanity check to tty operation

Add missing sanity check to tty operation.

Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Eugene Teo <eteo@redhat.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agodrivers/net: coding styles fixes to drivers/net/8390.c
Gustavo F. Padovan [Sat, 2 Aug 2008 18:55:13 +0000 (15:55 -0300)]
drivers/net: coding styles fixes to drivers/net/8390.c

Fix all errors and warnings reported by checkpatch.pl

Signed-off-by: Gustavo F. Padovan <gustavo@las.ic.unicamp.br>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agodrivers/net: coding styles fixes to drivers/net/8390p.c
Gustavo F. Padovan [Sat, 2 Aug 2008 18:55:12 +0000 (15:55 -0300)]
drivers/net: coding styles fixes to drivers/net/8390p.c

Fix all errors and warnings reported by checkpatch.pl

Signed-off-by: Gustavo F. Padovan <gustavo@las.ic.unicamp.br>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agodrivers/net: Remove 'return' of void function NS8390p_init()
Gustavo F. Padovan [Sat, 2 Aug 2008 18:55:11 +0000 (15:55 -0300)]
drivers/net: Remove 'return' of void function NS8390p_init()

We don't need this into a void function.

Signed-off-by: Gustavo F. Padovan <gustavo@las.ic.unicamp.br>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years ago[netdrvr] sh_eth: Add SH7619 support
Yoshinori Sato [Wed, 6 Aug 2008 23:49:00 +0000 (19:49 -0400)]
[netdrvr] sh_eth: Add SH7619 support

Add support SH7619 Internal ethernet controler.

Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoMETH: fix MAC address setup
Thomas Bogendoerfer [Wed, 30 Jul 2008 23:14:24 +0000 (01:14 +0200)]
METH: fix MAC address setup

Setup of the mac filter lost the upper 16bit of the mac address. This
bug got unconvered by a patch, which fixed the promiscous handling.

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoxen-netfront: use netif_start_queue() on xennet_open()
Eduardo Habkost [Thu, 31 Jul 2008 20:36:55 +0000 (17:36 -0300)]
xen-netfront: use netif_start_queue() on xennet_open()

xen-netfront never called netif_start_queue() and was was waking the
queue on xennet_open(), triggering the BUG_ON() on __netif_schedule().

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoqla3xxx: driver version change.
root [Thu, 31 Jul 2008 20:46:08 +0000 (13:46 -0700)]
qla3xxx: driver version change.

Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoqla3xxx: cleanup: Remove some unused structure definitions and structure elements.
Ron Mercer [Thu, 31 Jul 2008 20:46:07 +0000 (13:46 -0700)]
qla3xxx: cleanup: Remove some unused structure definitions and structure elements.

Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoqla3xxx: cleanup: Remove some unused defined constants in the header file.
Ron Mercer [Thu, 31 Jul 2008 20:46:06 +0000 (13:46 -0700)]
qla3xxx: cleanup: Remove some unused defined constants in the header file.

Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoqla3xxx: fix: Fix IFF_MULTICAST setting.
Ron Mercer [Thu, 31 Jul 2008 20:46:05 +0000 (13:46 -0700)]
qla3xxx: fix: Fix IFF_MULTICAST setting.

The driver was erroneously clearing this bit though the hardware supports multicast.

Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoqla3xxx: fix: Remove unused set_multicast function.
Ron Mercer [Thu, 31 Jul 2008 20:46:04 +0000 (13:46 -0700)]
qla3xxx: fix: Remove unused set_multicast function.

This device is one side of a two-function adapter (NIC and iSCSI).
Promiscuous mode setting/clearing is not allowed from the NIC side.

Signed-off-by: Ron Mercer <ron.mercer@qlogic.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agonetxen: fix promisc mode, mtu setting
Dhananjay Phadke [Fri, 1 Aug 2008 10:14:59 +0000 (03:14 -0700)]
netxen: fix promisc mode, mtu setting

For NX3031, multicast filtering, promisc mode, and max frame size
setting is handled by firmware, driver needs to send request to
enable/disable it.

For old chip revisions / firmware, driver still sets it directly.

Added function pointer to set mtu according to chip revision.

Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agonetxen: fix cmd ring init
Dhananjay Phadke [Fri, 1 Aug 2008 10:14:58 +0000 (03:14 -0700)]
netxen: fix cmd ring init

Initialize producer and consumer indices during netdev open(), only
for old firmware/chip.

Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agonetxen: fix legacy interrupts
Dhananjay Phadke [Fri, 1 Aug 2008 10:14:57 +0000 (03:14 -0700)]
netxen: fix legacy interrupts

Fix legacy interrupt mode for NX3031 chips, read pci interrupt state
in hardware to guard against spurious interrupt.

Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agonetxen: add new board types
Dhananjay Phadke [Fri, 1 Aug 2008 10:14:56 +0000 (03:14 -0700)]
netxen: add new board types

Add couple of new board configurations based on NX3031 chip.

Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agonetxen: fix link status, link speed
Dhananjay Phadke [Fri, 1 Aug 2008 10:14:55 +0000 (03:14 -0700)]
netxen: fix link status, link speed

For NX3031, the phy is managed by firmware, so driver should avoid
setting any phy registers.

Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoremove bogus CONFIG_GFAR_NAPI's
Adrian Bunk [Mon, 4 Aug 2008 08:59:36 +0000 (11:59 +0300)]
remove bogus CONFIG_GFAR_NAPI's

The commit that made the CONFIG_GFAR_NAPI code unconditional was
included at the same time as a new CONFIG_GFAR_NAPI user, resulting
in these bugus #ifdef's.

Reported-by: Robert P. J. Day <rpjday@crashcourse.ca>
Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agonet/fs_enet: remove redundant messages for performance
Li Yang [Wed, 6 Aug 2008 07:08:50 +0000 (15:08 +0800)]
net/fs_enet: remove redundant messages for performance

Currently when we do a packet flood to the Ethernet port, the console
reports error every time when a packet is dropped.  This is too
redundant and cost performance.  Remove message for this type of event.

Signed-off-by: Li Yang <leoli@freescale.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoforcedeth: add tx pause limit
Ayaz Abdulla [Wed, 6 Aug 2008 16:12:34 +0000 (12:12 -0400)]
forcedeth: add tx pause limit

This patch adds support for limiting the number of tx pause frames to a
default of 8. Previously, hardware would send out continuous stream of
pause frames.

Signed-off-by: Ayaz Abdulla <aabdulla@nvidia.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoforcedeth: add jumbo frame support for mcp79
Ayaz Abdulla [Wed, 6 Aug 2008 16:12:18 +0000 (12:12 -0400)]
forcedeth: add jumbo frame support for mcp79

This patch adds jumbo frame support for MCP79 chipsets.

Signed-off-by: Ayaz Abdulla <aabdulla@nvidia.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoforcedeth: add new tx stat counters
Ayaz Abdulla [Wed, 6 Aug 2008 16:11:42 +0000 (12:11 -0400)]
forcedeth: add new tx stat counters

This patch adds support for new tx statistic counters in the hardware -
unicast, multicast, and broadcast

Signed-off-by: Ayaz Abdulla <aabdulla@nvidia.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoforcedeth: fix rx error policy
Ayaz Abdulla [Wed, 6 Aug 2008 16:11:03 +0000 (12:11 -0400)]
forcedeth: fix rx error policy

This patch enforces a stricter policy on rx errors. The driver needs to
verify whether there are multiple rx errors versus a single error.

Signed-off-by: Ayaz Abdulla <aabdulla@nvidia.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoMerge branch 'via-velocity' of git://git.kernel.org/pub/scm/linux/kernel/git/romieu...
Jeff Garzik [Thu, 7 Aug 2008 06:05:01 +0000 (02:05 -0400)]
Merge branch 'via-velocity' of git://git./linux/kernel/git/romieu/netdev-2.6 into tmp

16 years agosky2: fix PM related regressions
Stephen Hemminger [Mon, 4 Aug 2008 20:33:37 +0000 (13:33 -0700)]
sky2: fix PM related regressions

Fix the problems reported for 2.6.27-rc1 caused by over aggressive
power management. Turning clock off on PCI Express is problematic for WOL,
and when doing multi-booting.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoigb: remove igb_init_managability as it is deprecated
Alexander Duyck [Mon, 4 Aug 2008 22:00:27 +0000 (15:00 -0700)]
igb: remove igb_init_managability as it is deprecated

igb_init_managability does not actually perform any function as the two
registers it attempts to write are both read only on the host.  This patch
removes the function and all references to it from the driver.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoigb: remove three redundant functions left in the code
Alexander Duyck [Mon, 4 Aug 2008 22:00:18 +0000 (15:00 -0700)]
igb: remove three redundant functions left in the code

Three functions were left in the code that are no longer used.  I am removing
these functions just to keep the code clean.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoigb: correct issue of set_mta member of mac.ops not being populated
Alexander Duyck [Mon, 4 Aug 2008 22:00:06 +0000 (15:00 -0700)]
igb: correct issue of set_mta member of mac.ops not being populated

The igb_mta_set function was not being correctly used

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoigb: fixes 82576 serdes init to correctly support manual flow control changes
Alexander Duyck [Mon, 4 Aug 2008 21:59:56 +0000 (14:59 -0700)]
igb: fixes 82576 serdes init to correctly support manual flow control changes

This patch changes the PCS configuration for serdes so that the flow
control options change be set via the ethtool -A option.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoigb: fix null pointer dereference seen with fiber NICs
Alexander Duyck [Mon, 4 Aug 2008 21:59:46 +0000 (14:59 -0700)]
igb: fix null pointer dereference seen with fiber NICs

With a fiber or serdes NIC installed the driver was causing a null pointer
dereference on driver unload.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoigb: fix comments
Alexander Duyck [Mon, 4 Aug 2008 21:59:37 +0000 (14:59 -0700)]
igb: fix comments

The internal name was used in comments, replaced with silicon part number.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoatl1: deal with hardware rx checksum bug
Jay Cliburn [Tue, 5 Aug 2008 00:05:10 +0000 (19:05 -0500)]
atl1: deal with hardware rx checksum bug

The L1 hardware contains a bug that flags a fragmented IP packet
as having an incorrect TCP/UDP checksum, even though the packet
is perfectly valid and its checksum is correct.  There's no way to
distinguish between one of these good packets and a packet that
actually contains a TCP/UDP checksum error, so all we can do is
allow the packet to be handed up to the higher layers and let it
be sorted out there.

Add a comment describing this condition and remove the code that
currently fails to handle what may or may not be a checksum error.

Signed-off-by: Jay Cliburn <jacliburn@bellsouth.net>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoe1000e: remove inapplicable test for ioport
Bruce Allan [Tue, 5 Aug 2008 00:21:53 +0000 (17:21 -0700)]
e1000e: remove inapplicable test for ioport

There are currently no devices supported by the e1000e driver which need
ioport resources, remove the test for it and all unnecessary code
associated with it (struct e1000_adapter elements, local variables, etc.)

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoe1000e: fix drv load issues
Jesse Brandeburg [Tue, 5 Aug 2008 00:21:40 +0000 (17:21 -0700)]
e1000e: fix drv load issues

a few people seem to have problems maintaining gigabit link
and it was root caused to an interaction between the managability
firmware on the host and the driver, not communicating.

The form of communication they use is the drv_load bit.

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoe1000e: perform basic 82573 EEPROM checks for known issues
Auke Kok [Tue, 5 Aug 2008 00:21:20 +0000 (17:21 -0700)]
e1000e: perform basic 82573 EEPROM checks for known issues

82573 EEPROMs have been shipped out with known issues. While most
people will never see the issues some people do and we know
how to address them. Warn the user if we find one of these
EEPROM issues.

Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoe1000e: convert ndev_ printks to something smaller
Jeff Kirsher [Tue, 5 Aug 2008 00:20:41 +0000 (17:20 -0700)]
e1000e: convert ndev_ printks to something smaller

The ndev_* printk's are too lenghty and we don't need to specify
the adapter/netdev struct at all, making this a lot more readable.

Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agomyri10ge: set 64bits consistent DMA mask
Brice Goglin [Wed, 6 Aug 2008 14:15:23 +0000 (16:15 +0200)]
myri10ge: set 64bits consistent DMA mask

Set 64bits consistent DMA mask since it improves performance
in some cases. No need to check the return value since it is
not required for the driver to work.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agomyri10ge: update firmware headers
Brice Goglin [Wed, 6 Aug 2008 14:14:43 +0000 (16:14 +0200)]
myri10ge: update firmware headers

Update myri10ge firmware headers.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
16 years agoipv4: Fix over-ifdeffing of ip_static_sysctl_init.
David S. Miller [Thu, 7 Aug 2008 01:30:43 +0000 (18:30 -0700)]
ipv4: Fix over-ifdeffing of ip_static_sysctl_init.

Noticed by Paulius Zaleckas.

Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoipsec: Interfamily IPSec BEET, ipv4-inner ipv6-outer
Joakim Koskela [Wed, 6 Aug 2008 09:40:25 +0000 (02:40 -0700)]
ipsec: Interfamily IPSec BEET, ipv4-inner ipv6-outer

Here's a revised version, based on Herbert's comments, of a fix for
the ipv4-inner, ipv6-outer interfamily ipsec beet mode. It fixes the
network header adjustment during interfamily, as well as makes sure
that we reserve enough room for the new ipv6 header if we might have
something else as the inner family. Also, the ipv4 pseudo header
construction was added.

Signed-off-by: Joakim Koskela <jookos@gmail.com>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoipsec: Interfamily IPSec BEET
Joakim Koskela [Wed, 6 Aug 2008 09:39:30 +0000 (02:39 -0700)]
ipsec: Interfamily IPSec BEET

Here's a revised version, based on Herbert's comments, of a fix for
the ipv6-inner, ipv4-outer interfamily ipsec beet mode. It fixes the
network header adjustment in interfamily, and doesn't reserve space
for the pseudo header anymore when we have ipv6 as the inner family.

Signed-off-by: Joakim Koskela <jookos@gmail.com>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agonetfilter: fix two recent sysctl problems
Krzysztof Piotr Oledzki [Wed, 6 Aug 2008 09:35:44 +0000 (02:35 -0700)]
netfilter: fix two recent sysctl problems

Starting with 9043476f726802f4b00c96d0c4f418dde48d1304 ("[PATCH]
sanitize proc_sysctl") we have two netfilter releated problems:

 - WARNING: at kernel/sysctl.c:1966 unregister_sysctl_table+0xcc/0x103(),
   caused by wrong order of ini/fini calls

 - net.netfilter is duplicated and has truncated set of records

Thanks to very useful guidelines from Al Viro, this patch fixes both
of them.

Signed-off-by: Krzysztof Piotr Oledzki <ole@ans.pl>
Acked-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoipv6: replace dst_metric() with dst_mtu() in net/ipv6/route.c.
Rami Rosen [Wed, 6 Aug 2008 09:34:21 +0000 (02:34 -0700)]
ipv6: replace dst_metric() with dst_mtu() in net/ipv6/route.c.

This patch replaces dst_metric() with dst_mtu() in net/ipv6/route.c.

Signed-off-by: Rami Rosen <ramirose@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoipv4: replace dst_metric() with dst_mtu() in net/ipv4/route.c.
Rami Rosen [Wed, 6 Aug 2008 09:33:49 +0000 (02:33 -0700)]
ipv4: replace dst_metric() with dst_mtu() in net/ipv4/route.c.

This patch replaces dst_metric() with dst_mtu() in net/ipv4/route.c.

Signed-off-by: Rami Rosen <ramirose@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoLinux 2.6.27-rc2
Linus Torvalds [Wed, 6 Aug 2008 04:49:54 +0000 (21:49 -0700)]
Linux 2.6.27-rc2

16 years agoRe-introduce "[SCSI] extend the last_sector_bug flag to cover more sectors"
Linus Torvalds [Wed, 6 Aug 2008 04:42:21 +0000 (21:42 -0700)]
Re-introduce "[SCSI] extend the last_sector_bug flag to cover more sectors"

This re-introduces commit 2b142900784c6e38c8d39fa57d5f95ef08e735d8,
which was reverted due to the regression it caused by commit
fca082c9f1e11ec07efa8d2f9f13688521253f36.

That regression was not root-caused by the original commit, it was just
uncovered by it, and the real fix was done by Alan Stern in commit
580da34847488b404218d1d7f53b156f245f5555 ("Fix USB storage hang on
command abort").

We can thus re-introduce the change that was confirmed by Alan Jenkins
to be still required by his odd card reader.

Cc: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
Cc: Alan Stern <stern@rowland.harvard.edu>
Cc: James Bottomley <James.Bottomley@HansenPartnership.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
Linus Torvalds [Wed, 6 Aug 2008 02:37:42 +0000 (19:37 -0700)]
Merge git://git./linux/kernel/git/davem/net-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (78 commits)
  AX.25: Fix sysctl registration if !CONFIG_AX25_DAMA_SLAVE
  pktgen: mac count
  pktgen: random flow
  bridge: Eliminate unnecessary forward delay
  bridge: fix compile warning in net/bridge/br_netfilter.c
  ipv4: remove unused field in struct flowi (include/net/flow.h).
  tg3: Fix 'scheduling while atomic' errors
  net: Kill plain NET_XMIT_BYPASS.
  net_sched: Add qdisc __NET_XMIT_BYPASS flag
  net_sched: Add qdisc __NET_XMIT_STOLEN flag
  iwl3945: fix merge mistake for packet injection
  iwlwifi: grap nic access before accessing periphery registers
  iwlwifi: decrement rx skb counter in scan abort handler
  iwlwifi: fix unhandled interrupt when HW rfkill is on
  iwlwifi: implement iwl5000_calc_rssi
  iwlwifi: memory allocation optimization
  iwlwifi: HW bug fixes
  p54: Fix potential concurrent access to private data
  rt2x00: Disable link tuning in rt2500usb
  iwlwifi: Don't use buffer allocated on the stack for led names
  ...

16 years agoAX.25: Fix sysctl registration if !CONFIG_AX25_DAMA_SLAVE
Ralf Baechle [Wed, 6 Aug 2008 01:46:57 +0000 (18:46 -0700)]
AX.25: Fix sysctl registration if !CONFIG_AX25_DAMA_SLAVE

Since 49ffcf8f99e8d33ec8afb450956804af518fd788 ("sysctl: update
sysctl_check_table") setting struct ctl_table.procname = NULL does no
longer work as it used to the way the AX.25 code is expecting it to
resulting in the AX.25 sysctl registration code to break if
CONFIG_AX25_DAMA_SLAVE was not set as in some distribution kernels.
Kernel releases from 2.6.24 are affected.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agopktgen: mac count
Robert Olsson [Wed, 6 Aug 2008 01:45:05 +0000 (18:45 -0700)]
pktgen: mac count

dst_mac_count and src_mac_count patch from Eneas Hunguana
We have sent one mac address to much.

Signed-off-by: Robert Olsson <robert.olsson@its.uu.se>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agopktgen: random flow
Robert Olsson [Wed, 6 Aug 2008 01:44:26 +0000 (18:44 -0700)]
pktgen: random flow

Random flow generation has not worked. This fixes it.

Signed-off-by: Robert Olsson <robert.olsson@its.uu.se>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agobridge: Eliminate unnecessary forward delay
Stephen Hemminger [Wed, 6 Aug 2008 01:42:51 +0000 (18:42 -0700)]
bridge: Eliminate unnecessary forward delay

From: Stephen Hemminger <shemminger@vyatta.com>

Based upon original patch by Herbert Xu, which contained
the following problem description:

--------------------
When the forward delay is set to zero, we still delay the setting
of the forwarding state by one or possibly two timers depending
on whether STP is enabled.  This could either turn out to be
instantaneous, or horribly slow depending on the load of the
machine.

As there is nothing preventing us from enabling forwarding straight
away, this patch eliminates this potential delay by executing the
code directly if the forward delay is zero.

The effect of this problem is that immediately after the carrier
comes on a port, the bridge will drop all packets received from
that port until it enters forwarding mode, thus causing unnecessary
packet loss.

Note that this patch doesn't fully remove the delay due to the
link watcher.  We should also check the carrier state when we
are about to drop an incoming packet because the port is disabled.
But that's for another patch.
--------------------

This version of the fix takes a different approach, in that
it just does the state change directly.

Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agodocbook: fix s390 fatal error after header files moved
Randy Dunlap [Tue, 5 Aug 2008 21:59:29 +0000 (14:59 -0700)]
docbook: fix s390 fatal error after header files moved

Fix (fatal error) s390 docbook file to handle renamed header files.

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agodrivers/media/video/vino.c needs v4l2-ioctl.h
Andrew Morton [Tue, 5 Aug 2008 20:01:42 +0000 (13:01 -0700)]
drivers/media/video/vino.c needs v4l2-ioctl.h

mips allmodconfig:

  drivers/media/video/vino.c: In function `vino_free_buffer_with_count':
  drivers/media/video/vino.c:811: warning: passing arg 1 of `virt_to_phys' makes pointer from integer without a cast
  drivers/media/video/vino.c: In function `vino_allocate_buffer':
  drivers/media/video/vino.c:889: warning: passing arg 1 of `virt_to_phys' makes pointer from integer without a cast
  drivers/media/video/vino.c: In function `vino_ioctl':
  drivers/media/video/vino.c:4364: error: implicit declaration of function `video_usercopy'

The patch fixes the error, but not the warnings.

Cc: Mauro Carvalho Chehab <mchehab@infradead.org>
Cc: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agomm: fix uninitialized variables for find_vma_prepare callers
Benny Halevy [Tue, 5 Aug 2008 20:01:41 +0000 (13:01 -0700)]
mm: fix uninitialized variables for find_vma_prepare callers

gcc 4.3.0 correctly emits the following warnings.
When a vma covering addr is found, find_vma_prepare indeed returns without
setting pprev, rb_link, and rb_parent.

  mm/mmap.c: In function `insert_vm_struct':
  mm/mmap.c:2085: warning: `rb_parent' may be used uninitialized in this function
  mm/mmap.c:2085: warning: `rb_link' may be used uninitialized in this function
  mm/mmap.c:2084: warning: `prev' may be used uninitialized in this function
  mm/mmap.c: In function `copy_vma':
  mm/mmap.c:2124: warning: `rb_parent' may be used uninitialized in this function
  mm/mmap.c:2124: warning: `rb_link' may be used uninitialized in this function
  mm/mmap.c:2123: warning: `prev' may be used uninitialized in this function
  mm/mmap.c: In function `do_brk':
  mm/mmap.c:1951: warning: `rb_parent' may be used uninitialized in this function
  mm/mmap.c:1951: warning: `rb_link' may be used uninitialized in this function
  mm/mmap.c:1949: warning: `prev' may be used uninitialized in this function
  mm/mmap.c: In function `mmap_region':
  mm/mmap.c:1092: warning: `rb_parent' may be used uninitialized in this function
  mm/mmap.c:1092: warning: `rb_link' may be used uninitialized in this function
  mm/mmap.c:1089: warning: `prev' may be used uninitialized in this function

Hugh adds: in fact, none of find_vma_prepare's callers use those values
when a vma is found to be already covering addr, it's either an error or
an occasion to munmap and repeat.  Okay, let's quieten the compiler (but I
would prefer it if pprev, rb_link and rb_parent were meaningful in that
case, rather than whatever's in them from descending the tree).

Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Hugh Dickins <hugh@veritas.com>
Cc: "Ryan Hope" <rmh3093@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agopm_qos: spelling fixes
Richard Hughes [Tue, 5 Aug 2008 20:01:35 +0000 (13:01 -0700)]
pm_qos: spelling fixes

A documentation cleanup patch.  With a minor tweak to clarify units for
kbs.

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: mark gross <mgross@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoproc: fix warnings
Alexander Beregalov [Tue, 5 Aug 2008 20:01:34 +0000 (13:01 -0700)]
proc: fix warnings

proc: fix warnings

 fs/proc/base.c:2429: warning: format '%llu' expects type 'long long unsigned int', but argument 3 has type 'u64'
 fs/proc/base.c:2429: warning: format '%llu' expects type 'long long unsigned int', but argument 4 has type 'u64'
 fs/proc/base.c:2429: warning: format '%llu' expects type 'long long unsigned int', but argument 5 has type 'u64'
 fs/proc/base.c:2429: warning: format '%llu' expects type 'long long unsigned int', but argument 6 has type 'u64'
 fs/proc/base.c:2429: warning: format '%llu' expects type 'long long unsigned int', but argument 7 has type 'u64'
 fs/proc/base.c:2429: warning: format '%llu' expects type 'long long unsigned int', but argument 8 has type 'u64'
 fs/proc/base.c:2429: warning: format '%llu' expects type 'long long unsigned int', but argument 9 has type 'u64'

Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
Acked-by: Andrea Righi <righi.andrea@gmail.com>
Cc: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agodrivers/misc/sgi-gru/grutlbpurge.c: removed duplicated #include
Huang Weiyi [Tue, 5 Aug 2008 20:01:33 +0000 (13:01 -0700)]
drivers/misc/sgi-gru/grutlbpurge.c: removed duplicated #include

Removed duplicated include <linux/delay.h> in
drivers/misc/sgi-gru/grutlbpurge.c.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Cc: Jack Steiner <steiner@sgi.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoomfs: fix warning
Alexander Beregalov [Tue, 5 Aug 2008 20:01:33 +0000 (13:01 -0700)]
omfs: fix warning

fs/omfs/inode.c:495: warning: format '%llx' expects type 'long long
unsigned int', but argument 2 has type 'u64'
fs/omfs/inode.c:495: warning: format '%llx' expects type 'long
long unsigned int', but argument 3 has type '__be64'

Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
Acked-by: Bob Copeland <me@bobcopeland.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agokernel-doc: skip nested struct/union cleanly
Randy Dunlap [Tue, 5 Aug 2008 20:01:32 +0000 (13:01 -0700)]
kernel-doc: skip nested struct/union cleanly

Fix handling of nested structs or unions.  The regex to strip (eliminate)
nested structs or unions was limited to only 0 or 1 matches.  This can
cause an uneven number of left/right braces to be stripped, which causes
this:

Warning(linux-2.6.27-rc1-git2//include/net/mac80211.h:336): No description found for parameter '}'

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agodma: fix order calculation in dma_mark_declared_memory_occupied()
Jan Beulich [Tue, 5 Aug 2008 20:01:31 +0000 (13:01 -0700)]
dma: fix order calculation in dma_mark_declared_memory_occupied()

get_order() takes byte-sized input, not a page-granular one.

Irrespective of this fix I'm inclined to believe that this doesn't work
right anyway - bitmap_allocate_region() has an implicit assumption of
'pos' being suitable for 'order', which this function doesn't seem to
enforce (and since it's being called with a byte-granular value there's no
reason to believe that the callers would make sure device_addr is passed
accordingly - it's also not documented that way).

Signed-off-by: Jan Beulich <jbeulich@novell.com>
Cc: James E.J. Bottomley <James.Bottomley@HansenPartnership.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Dmitry Baryshkov <dbaryshkov@gmail.com>
Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoatyfb_base.c: fix warning
Alexander Beregalov [Tue, 5 Aug 2008 20:01:29 +0000 (13:01 -0700)]
atyfb_base.c: fix warning

drivers/video/aty/atyfb_base.c:2663: warning: 'aty_resume_chip' defined
but not used

Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
Cc: Ville Syrjala <syrjala@sci.fi>
Cc: Antonino A. Daplas <adaplas@pol.net>
Cc: Mark Asselstine <asselsm@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agodrivers/video/fsl-diu-fb.c: add missing of_node_put
Julia Lawall [Tue, 5 Aug 2008 20:01:28 +0000 (13:01 -0700)]
drivers/video/fsl-diu-fb.c: add missing of_node_put

of_node_put is needed before discarding a value received from
of_find_node_by_type, eg in error handling code.

The semantic patch that makes the change is as follows:
(http://www.emn.fr/x-info/coccinelle/)

// <smpl>
@@
struct device_node *n;
struct device_node *n1;
struct device_node *n2;
statement S;
identifier f1,f2;
expression E1,E2;
constant C;
@@

n = of_find_node_by_type(...)
...
if (!n) S
... when != of_node_put(n)
    when != n1 = f1(n,...)
    when != E1 = n
    when any
    when strict
(
+ of_node_put(n);
  return -C;
|
  of_node_put(n);
|
  n2 = f2(n,...)
|
  E2 = n
|
  return ...;
)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Acked-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Cc: Timur Tabi <timur@freescale.com>
Cc: York Sun <yorksun@freescale.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoradeonfb: give i2c buses nicer names
Jean Delvare [Tue, 5 Aug 2008 20:01:27 +0000 (13:01 -0700)]
radeonfb: give i2c buses nicer names

The name of the i2c buses shows in the output of "i2cdetect -l", so
it's important to give informative names.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agofbcon: fix scrolling after logo is cleared
Krzysztof Helt [Tue, 5 Aug 2008 20:01:26 +0000 (13:01 -0700)]
fbcon: fix scrolling after logo is cleared

If the 'clear' command is used on the frame buffer with a logo the upper
area is filled by few lines but not scrolled anymore.

Fix this by removing the protected area for the logo if any part of the
logo is cleared.

Signed-off-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoradeon: misc corrections
David Miller [Tue, 5 Aug 2008 20:01:25 +0000 (13:01 -0700)]
radeon: misc corrections

I have a new PCI-E radeon RV380 series card (PCI device ID 5b64) that
hangs in my sparc64 boxes when the init scripts set the font.  The problem
goes away if I disable acceleration.

I haven't figured out that bug yet, but along the way I found some
corrections to make based upon some auditing.

1) The RB2D_DC_FLUSH_ALL value used by the kernel fb driver
   and the XORG video driver differ.  I've made the kernel
   match what XORG is using.

2) In radeonfb_engine_reset() we have top-level code structure
   that roughly looks like:

if (family is 300, 350, or V350)
do this;
else
do that;
...
if (family is NOT 300, OR
    family is NOT 350, OR
    family is NOT V350)
do another thing;

   this last conditional makes no sense, is always true,
   and obviously was likely meant to be "family is NOT
   300, 350, or V350".  So I've made the code match the
   intent.

Signed-off-by: David S. Miller <davem@davemloft.net>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Tested-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoRemove the deprecated cli() sti() functions
Mark Asselstine [Tue, 5 Aug 2008 20:01:24 +0000 (13:01 -0700)]
Remove the deprecated cli() sti() functions

These functions have been deprecated for some time now but remained until
all legacy callers could be removed.  With a few commits in 2.6.26 this
has happened so now we can remove these deprecated functions.

Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com>
Reviewed-by: Matthew Wilcox <willy@linux.intel.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agobacklight: add MODULE_ALIAS() to pwm_backlight driver
Ben Dooks [Tue, 5 Aug 2008 20:01:24 +0000 (13:01 -0700)]
backlight: add MODULE_ALIAS() to pwm_backlight driver

Add the missing MODULE_ALIAS() to the pwm_backlight driver.

Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Cc: Richard Purdie <rpurdie@rpsys.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agobacklight: add more information output to pwm_backlight
Ben Dooks [Tue, 5 Aug 2008 20:01:22 +0000 (13:01 -0700)]
backlight: add more information output to pwm_backlight

Make the error paths in the pwm_backlight driver more informative in the
probe path, especially for the times that it finds an error.

Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Cc: Richard Purdie <rpurdie@rpsys.net>
Acked-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoblackfin RTC driver: drop PIE/stopwatch code since the hardware can only do a max...
Mike Frysinger [Tue, 5 Aug 2008 20:01:21 +0000 (13:01 -0700)]
blackfin RTC driver: drop PIE/stopwatch code since the hardware can only do a max of 1HZ and this same functionality is provided by UIE

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Cc: David Brownell <david-b@pacbell.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoblackfin RTC driver: convert PIE handling to irq_set_state() as pointed out by David...
Mike Frysinger [Tue, 5 Aug 2008 20:01:21 +0000 (13:01 -0700)]
blackfin RTC driver: convert PIE handling to irq_set_state() as pointed out by David Brownell

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Cc: David Brownell <david-b@pacbell.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoblackfin RTC driver: wait for the write complete interrupt complete before sleeping
Mike Frysinger [Tue, 5 Aug 2008 20:01:20 +0000 (13:01 -0700)]
blackfin RTC driver: wait for the write complete interrupt complete before sleeping

Since we use the write complete interrupt, wait for it
to complete before sleeping so we don't wake right back up due to it

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Cc: David Brownell <david-b@pacbell.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoblackfin RTC driver: disable the write complete irq upon close
Mike Frysinger [Tue, 5 Aug 2008 20:01:19 +0000 (13:01 -0700)]
blackfin RTC driver: disable the write complete irq upon close

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Cc: David Brownell <david-b@pacbell.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoblackfin RTC driver: don't bother passing the rtc struct down to bfin_rtc_int_{set...
Mike Frysinger [Tue, 5 Aug 2008 20:01:18 +0000 (13:01 -0700)]
blackfin RTC driver: don't bother passing the rtc struct down to bfin_rtc_int_{set,clear} since it isnt needed (shaves off ~100bytes)

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Cc: David Brownell <david-b@pacbell.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoblackfin RTC driver: add support for power management framework
Mike Frysinger [Tue, 5 Aug 2008 20:01:18 +0000 (13:01 -0700)]
blackfin RTC driver: add support for power management framework

Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Cc: David Brownell <david-b@pacbell.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoblackfin RTC driver: Fix bug Only RTC interrupt can wake up deeper sleep core
Sonic Zhang [Tue, 5 Aug 2008 20:01:17 +0000 (13:01 -0700)]
blackfin RTC driver: Fix bug Only RTC interrupt can wake up deeper sleep core

Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Cc: David Brownell <david-b@pacbell.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoblackfin RTC driver: if we dont define irq_set_freq, the common rtc-dev layer will...
Mike Frysinger [Tue, 5 Aug 2008 20:01:15 +0000 (13:01 -0700)]
blackfin RTC driver: if we dont define irq_set_freq, the common rtc-dev layer will give us the same behavior of returning ENOTTY

Signed-off-by: Mike Frysinger <michael.frysinger@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Cc: David Brownell <david-b@pacbell.net>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>