]> pilppa.org Git - linux-2.6-omap-h63xx.git/log
linux-2.6-omap-h63xx.git
17 years agoBtrfs: Stop using radix trees for the block group cache
Chris Mason [Mon, 15 Oct 2007 20:15:19 +0000 (16:15 -0400)]
Btrfs: Stop using radix trees for the block group cache

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agoBtrfs: Fix extent_buffer and extent_state leaks
Chris Mason [Mon, 15 Oct 2007 20:14:48 +0000 (16:14 -0400)]
Btrfs: Fix extent_buffer and extent_state leaks

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agoBtrfs: Go back to kmaps instead of page_address in extent_buffers
Chris Mason [Mon, 15 Oct 2007 20:14:41 +0000 (16:14 -0400)]
Btrfs: Go back to kmaps instead of page_address in extent_buffers

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agoBtrfs: Avoid memcpy where possible in extent_buffers
Chris Mason [Mon, 15 Oct 2007 20:14:37 +0000 (16:14 -0400)]
Btrfs: Avoid memcpy where possible in extent_buffers

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agoBtrfs: Optimizations for the extent_buffer code
Chris Mason [Mon, 15 Oct 2007 20:14:27 +0000 (16:14 -0400)]
Btrfs: Optimizations for the extent_buffer code

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agoBtrfs: Create extent_buffer interface for large blocksizes
Chris Mason [Mon, 15 Oct 2007 20:14:19 +0000 (16:14 -0400)]
Btrfs: Create extent_buffer interface for large blocksizes

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agobtrfs_get_extent should treat inline extents as though they hold a whole block
Chris Mason [Thu, 20 Sep 2007 18:14:42 +0000 (14:14 -0400)]
btrfs_get_extent should treat inline extents as though they hold a whole block

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agoBtrfs: factor page private preparations into a helper
Christoph Hellwig [Mon, 17 Sep 2007 15:25:58 +0000 (11:25 -0400)]
Btrfs: factor page private preparations into a helper

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agoBtrfs: Fix double free and off by one in inode.c
Yan [Mon, 17 Sep 2007 15:13:12 +0000 (11:13 -0400)]
Btrfs: Fix double free and off by one in inode.c

The first change removes  potential double free, the second fix a off
by one error.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agoBtrfs: truncate: don't update inode->i_blocks when extent is a hole
Yan [Mon, 17 Sep 2007 15:13:11 +0000 (11:13 -0400)]
Btrfs: truncate: don't update inode->i_blocks when extent is a hole

I think check whether extent is a hole before update 'inode->i_blocks'
is unconditional required. (original codes check it only when
del_item isn't equal to 0)

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agocreate btrfs_path slab with the correct size
Yan [Mon, 17 Sep 2007 15:08:52 +0000 (11:08 -0400)]
create btrfs_path slab with the correct size

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agofix found_type decrement in btrfs_truncate_in_trans
Yan [Mon, 17 Sep 2007 15:08:38 +0000 (11:08 -0400)]
fix found_type decrement in btrfs_truncate_in_trans

found_type has already been decreased by codes above the change,  I
think decrease it by one again doesn't make sense.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agoBtrfs: Fix duplicate ENOSPC checks in find_free_extent
Chris Mason [Mon, 17 Sep 2007 15:00:51 +0000 (11:00 -0400)]
Btrfs: Fix duplicate ENOSPC checks in find_free_extent

find_free_extent would fail to wrap around to the start of the drive because
it was doing the enospc case checking twice in some cases, causing it
to return -ENOSPC early.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years agoBtrfs: Use balance_dirty_pages_nr on btree blocks
Chris Mason [Mon, 17 Sep 2007 14:58:06 +0000 (10:58 -0400)]
Btrfs: Use balance_dirty_pages_nr on btree blocks

btrfs_btree_balance_dirty is changed to pass the number of pages dirtied
for more accurate dirty throttling.  This lets the VM make better decisions
about when to force some writeback.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
17 years ago[ARM] dma: rename consistent.c to dma-mapping.c
Russell King [Thu, 25 Sep 2008 14:59:19 +0000 (15:59 +0100)]
[ARM] dma: rename consistent.c to dma-mapping.c

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years ago[ARM] Print details relevant to how we handle the cache
Russell King [Thu, 25 Sep 2008 14:39:20 +0000 (15:39 +0100)]
[ARM] Print details relevant to how we handle the cache

This replaces the original cache type decoding printks.  We now
indicate how we're treating the cache which we found, rather
than what we found.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years ago[ARM] Introduce new bitmask based cache type macros
Russell King [Thu, 25 Sep 2008 14:35:28 +0000 (15:35 +0100)]
[ARM] Introduce new bitmask based cache type macros

Rather than trying to (inaccurately) decode the cache type from the
registers each time we need to decide what type of cache we have,
use a bitmask initialized early during boot.

Since the setup is a one-off initialization, we can be a little more
clever and take account of the CPU architecture as well.

Note that we continue to achieve the compactness on optimised kernels
by forcing tests to always-false or always-true as appropriate, thereby
allowing the compiler to do build-time code elimination.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years agoI2C: Remove old zero byte hack
Tony Lindgren [Thu, 25 Sep 2008 13:58:44 +0000 (16:58 +0300)]
I2C: Remove old zero byte hack

This should not be needed with new style I2C drivers.

Signed-off-by: Tony Lindgren <tony@atomide.com>
17 years ago[ARM] Remove cache type printks
Russell King [Thu, 25 Sep 2008 13:45:02 +0000 (14:45 +0100)]
[ARM] Remove cache type printks

The cache type register found in ARMv5 and later CPUs changes format
and meaning depending on the CPU architecture version.  Currently,
this code:
a) doesn't work for everything - Xscale's are identified as
   'unknown 5'.
b) is not able to tell whether the caches are VIVT or VIPT from the
   cache type.
c) prints rubbish on some ARMv6 and ARMv7+ CPUs.

The two solutions to this are:
1. Add yet more code to decode and print the various different register
   formats.
2. Remove the code altogther.

The code only exists to decode and print the cache parameters.
Increasing the complexity of it just for the sake of a few prinks
isn't worth it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years agotwl4030-core: cleanups
David Brownell [Thu, 25 Sep 2008 07:33:57 +0000 (00:33 -0700)]
twl4030-core: cleanups

A bunch of little cleanups to twl4030-core.

 - Remove needless header inclusions, symbols, and
   forward declarations.

 - Make coding style more standard.

And shrink the object size a bit.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Tony Lindgren <tony@atomide.com>
17 years agosome drivers switch away from OMAP-specific GPIO calls
David Brownell [Thu, 25 Sep 2008 02:35:56 +0000 (19:35 -0700)]
some drivers switch away from OMAP-specific GPIO calls

This updates most of the OMAP drivers which are in mainline to
switch to using the cross-platform GPIO calls instead of the
older OMAP-specific ones.

This is all fairly brainless/obvious stuff.  Probably the
most interesting bit is to observe that the omap-keypad
code seems to now have a portable core that could work with
non-OMAP matrix keypads.  (That would improve with hardware
IRQ debouncing enabled, of course...)

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Tony Lindgren <tony@atomide.com>
17 years agoALSA: fix locking in snd_pcm_open*() and snd_rawmidi_open*()
Takashi Iwai [Thu, 25 Sep 2008 12:51:03 +0000 (14:51 +0200)]
ALSA: fix locking in snd_pcm_open*() and snd_rawmidi_open*()

The PCM and rawmidi open callbacks have a lock against card->controls_list
but it takes a wrong one, card->controls_rwsem, instead of a right one
card->ctl_files_rwlock.  This patch fixes them.

This change also fixes automatically the potential deadlocks due to
mm->mmap_sem in munmap and copy_from/to_user, reported by Sitsofe
Wheeler:

  A: snd_ctl_elem_user_tlv(): card->controls_rwsem => mm->mmap_sem
  B: snd_pcm_open(): card->open_mutex => card->controls_rwsem
  C: munmap: mm->mmap_sem => snd_pcm_release(): card->open_mutex

The patch breaks the chain.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
17 years agohsmmc: request_irq says which controller is involved
David Brownell [Sun, 21 Sep 2008 21:16:14 +0000 (14:16 -0700)]
hsmmc: request_irq says which controller is involved

Make the hsmmc driver irq requests say which controller they're
associated with (e.g. "mmc0") so /proc/interrupts is more useful.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Tony Lindgren <tony@atomide.com>
17 years agoPM: Fixed clockdomain state control for OMAP3
Tero Kristo [Thu, 25 Sep 2008 12:35:49 +0000 (15:35 +0300)]
PM: Fixed clockdomain state control for OMAP3

Hardware supervised control for clockdomain power state transitions now
enabled in omap3_pm_init(). Also fixed set_pwrdm_state() to allow state
changes between sleep states (i.e. RET<->OFF.)

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
17 years agoOMAP3: GPIO: Enable debounce clock only when debounce is enabled v3.
Jouni Hogander [Thu, 25 Sep 2008 12:35:47 +0000 (15:35 +0300)]
OMAP3: GPIO: Enable debounce clock only when debounce is enabled v3.

This patch changes gpio "driver" to enable debounce clock for
gpio-bank only when debounce is enabled for some gpio in that bank.

Gpio functional clocks are also renamed in clock tree, gpioX_fck ->
gpioX_dbck.

This patch triggers problem with gpio wake-up and Omap3. Gpios in PER
domain aren't capable to generate wake-up if PER domain is in sleep
state. For this iopad wake-up should be used and needed pad
configuration should be done. Enabling iopad wake-up for gpio pads is
left for bootloader or omap mux configuration in kernel.

Signed-off-by: Jouni Hogander <jouni.hogander@nokia.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
17 years agoARM: OMAP: Improve 34xx detection
Tony Lindgren [Thu, 25 Sep 2008 12:34:00 +0000 (15:34 +0300)]
ARM: OMAP: Improve 34xx detection

Fix it for ES3.0. Also use ES3.0 now as the default for unknown
future revision, and make the code easier to follow.

Also fixed omap detection for ES2.1 and ES3.0 with a patch from
Tero Kristo.

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
17 years agoI2C: Clean-up i2c-omap
Tony Lindgren [Thu, 25 Sep 2008 11:35:48 +0000 (14:35 +0300)]
I2C: Clean-up i2c-omap

Clean-up i2c-omap

Signed-off-by: Tony Lindgren <tony@atomide.com>
17 years ago[ARM] pxa: remove references to pxa_gpio_mode() in comments
Russell King [Thu, 25 Sep 2008 12:35:27 +0000 (13:35 +0100)]
[ARM] pxa: remove references to pxa_gpio_mode() in comments

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years ago[ARM] pxa: avoid needless pxa_gpio_mode() during resume
Russell King [Thu, 25 Sep 2008 12:30:07 +0000 (13:30 +0100)]
[ARM] pxa: avoid needless pxa_gpio_mode() during resume

The pin configurations are restored early on during resume.  There's
no need for drivers to re-affirm the gpio modes.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years agosched: maintain only task entities in cfs_rq->tasks list
Bharata B Rao [Thu, 25 Sep 2008 04:23:54 +0000 (09:53 +0530)]
sched: maintain only task entities in cfs_rq->tasks list

cfs_rq->tasks list is used by the load balancer to iterate
over all the tasks. Currently it holds all the entities
(both task and group entities) because of which there is
a need to check for group entities explicitly during load
balancing. This patch changes the cfs_rq->tasks list to
hold only task entities.

Signed-off-by: Bharata B Rao <bharata@linux.vnet.ibm.com>
Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agox86_64: be less annoying on boot
Bill Nottingham [Wed, 24 Sep 2008 18:35:17 +0000 (14:35 -0400)]
x86_64: be less annoying on boot

Remove mostly useless message on every boot.

Signed-off-by: Bill Nottingham <notting@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years ago[ARM] Update mach-types
Russell King [Thu, 25 Sep 2008 09:12:25 +0000 (10:12 +0100)]
[ARM] Update mach-types

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years agox86 gart: remove unnecessary initialization
FUJITA Tomonori [Wed, 24 Sep 2008 13:41:10 +0000 (22:41 +0900)]
x86 gart: remove unnecessary initialization

There is no point to have such initialization in struct dma_mapping_ops.

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agox86: restore old GART alloc_coherent behavior
FUJITA Tomonori [Wed, 24 Sep 2008 11:48:37 +0000 (20:48 +0900)]
x86: restore old GART alloc_coherent behavior

Currently, GART alloc_coherent tries to allocate pages with GFP_DMA32
for a device having dma_masks > 24bit < 32bits. If GART gets an
address that a device can't access to, GART try to map the address to
a virtual I/O address that the device can access to.

But Andi pointed out, "The GART is somewhere in the 4GB range so you
cannot use it to map anything < 4GB. Also GART is pretty small."

http://lkml.org/lkml/2008/9/12/43

That is, it's possible that GART doesn't have virtual I/O address
space that a device can access to. The above behavior doesn't work for
a device having dma_masks > 24bit < 32bits.

This patch restores old GART alloc_coherent behavior (before the
alloc_coherent rewrite).

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agorevert "x86: make GART to respect device's dma_mask about virtual mappings"
FUJITA Tomonori [Wed, 24 Sep 2008 11:48:36 +0000 (20:48 +0900)]
revert "x86: make GART to respect device's dma_mask about virtual mappings"

This reverts:

commit bee44f294efd8417f5e68553778a6cc957af1547
Author: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Date:   Fri Sep 12 19:42:35 2008 +0900

    x86: make GART to respect device's dma_mask about virtual mappings

I wrote the above commit to fix a GART alloc_coherent regression, that
can't handle a device having dma_masks > 24bit < 32bits, introduced by
the alloc_coherent rewrite:

  http://lkml.org/lkml/2008/8/12/200

After the alloc_coherent rewrite, GART alloc_coherent tried to
allocate pages with GFP_DMA32. If GART got an address that a device
can't access to, GART mapped the address to a virtual I/O address. But
GART mapping mechanism didn't take account of dma mask, so GART could
use a virtual I/O address that the device can't access to again.

Alan pointed out:

" This is indeed a specific problem found with things like older
  AACRAID where control blocks must be below 31bits and the GART
  is above 0x80000000. "

The above commit modified GART mapping mechanism to take care of dma
mask. But Andi pointed out, "The GART is somewhere in the 4GB range so
you cannot use it to map anything < 4GB. Also GART is pretty small."

http://lkml.org/lkml/2008/9/12/43

That means it's possible that GART doesn't have virtual I/O address
space that a device can access to. The above commit (to modify GART
mapping mechanism to take care of dma mask) can't fix the regression
reliably so let's avoid making GART more complicated.

We need a solution that always works for dma_masks > 24bit <
32bits. That's how GART worked before the alloc_coherent rewrite.

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Acked-by: Joerg Roedel <joerg.roedel@amd.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agox86: export pci-nommu's alloc_coherent
FUJITA Tomonori [Wed, 24 Sep 2008 11:48:35 +0000 (20:48 +0900)]
x86: export pci-nommu's alloc_coherent

This patch exports nommu_alloc_coherent (renamed
dma_generic_alloc_coherent). GART needs this function.

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years ago[ARM] pxa: introduce cpu_is_pxa26x()
Eric Miao [Thu, 11 Sep 2008 02:43:02 +0000 (10:43 +0800)]
[ARM] pxa: introduce cpu_is_pxa26x()

PXA26x (PXA261/262) is actually a PXA250 with stacked Intel(R)
StartaFlash. And this can be decided by bit 3 (PKG_TYPE) of
BOOT_DEF register.

Due to this extra I/O register access, make cpu_is_pxa26x() a
public function instead of a macro.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years ago[ARM] pxa: make cpu_is_pxa2* macros more consistent
Eric Miao [Thu, 11 Sep 2008 02:27:30 +0000 (10:27 +0800)]
[ARM] pxa: make cpu_is_pxa2* macros more consistent

1. add a CPUID table in the comment

2. make cpu_is_pxa25x() true for PXA210/250/255/26x

3. PXA210 is treated as PXA25x, all related code modified to
   reflect this

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years ago[ARM] pxa: merge common cpu_is_pxa255() code together
Eric Miao [Thu, 11 Sep 2008 02:25:59 +0000 (10:25 +0800)]
[ARM] pxa: merge common cpu_is_pxa255() code together

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years agoDocumentation: fix the now deprecated reference to {set,reset}_scoop_gpio
Eric Miao [Thu, 18 Sep 2008 18:15:08 +0000 (02:15 +0800)]
Documentation: fix the now deprecated reference to {set,reset}_scoop_gpio

Due to recent patches removing the now deprecated references to
{set,reset}_scoop_gpio() and converting them to the generic GPIO
API, the references in the documentation also need to be fixed.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Cc: Liam Girdwood <lrg@kernel.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years ago[ARM] corgi_lcd: use GPIO API for BACKLIGHT_ON and BACKLIGHT_CONT
Eric Miao [Sun, 7 Sep 2008 03:30:06 +0000 (11:30 +0800)]
[ARM] corgi_lcd: use GPIO API for BACKLIGHT_ON and BACKLIGHT_CONT

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
17 years agox86: signal_32.c: introduce macro ia32_setup_frame and ia32_setup_rt_frame
Hiroshi Shimamoto [Thu, 25 Sep 2008 02:13:29 +0000 (19:13 -0700)]
x86: signal_32.c: introduce macro ia32_setup_frame and ia32_setup_rt_frame

Make 32-bit setup_rt_frame() look like 64-bit version for unification.

Signed-off-by: Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agox86: signal: introduce helper macro is_ia32
Hiroshi Shimamoto [Thu, 25 Sep 2008 02:13:11 +0000 (19:13 -0700)]
x86: signal: introduce helper macro is_ia32

Introduce new macro is_ia32 for unification of setup_rt_frame().
No effect in binary, compiler will optimize.

Signed-off-by: Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agox86: signal_64.c: introduce helper function signr_convert()
Hiroshi Shimamoto [Thu, 25 Sep 2008 02:12:54 +0000 (19:12 -0700)]
x86: signal_64.c: introduce helper function signr_convert()

This helper function is for unification of setup_rt_frame().
No effect in binary.

Signed-off-by: Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agox86: signal_32.c: introduce signr_convert()
Hiroshi Shimamoto [Thu, 25 Sep 2008 02:10:29 +0000 (19:10 -0700)]
x86: signal_32.c: introduce signr_convert()

Introduce signr_convert().
This function will help unification of setup_rt_frame().

Signed-off-by: Hiroshi Shimamoto <h-shimamoto@ct.jp.nec.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
17 years agoe1000: remove unused Kconfig option for disabling packet split
Brandeburg, Jesse [Tue, 16 Sep 2008 20:01:28 +0000 (13:01 -0700)]
e1000: remove unused Kconfig option for disabling packet split

Since the e1000/e1000e split, no hardware supported by e1000
supports packet split, just remove the Kconfig option and associated
code from the driver.

Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agodrivers/net/bonding: sparse fixes for exported tables
Ben Dooks [Sun, 14 Sep 2008 15:56:12 +0000 (16:56 +0100)]
drivers/net/bonding: sparse fixes for exported tables

The following sparse warnings are being generated
because bonding.h is missing definitons for items
declared in bond_main.c but also used in bond_sysfs.h

Also export bond_dev_list as this is also declared
in bond_main but used elsewhere in drivers/net/bonding.

bond_main.c:105:20: warning: symbol 'bonding_defaults' was not declared. Should it be static?
bond_main.c:148:1: warning: symbol 'bond_dev_list' was not declared. Should it be static?
bond_main.c:162:22: warning: symbol 'bond_lacp_tbl' was not declared. Should it be static?
bond_main.c:168:22: warning: symbol 'bond_mode_tbl' was not declared. Should it be static?
bond_main.c:179:22: warning: symbol 'xmit_hashtype_tbl' was not declared. Should it be static?
bond_main.c:186:22: warning: symbol 'arp_validate_tbl' was not declared. Should it be static?
bond_main.c:194:22: warning: symbol 'fail_over_mac_tbl' was not declared. Should it be static?

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years ago[netdrvr] convert sbmac tx to spin_lock_irqsave to prevent early IRQ enable
Weiwei Wang [Thu, 18 Sep 2008 00:23:48 +0000 (08:23 +0800)]
[netdrvr] convert sbmac tx to spin_lock_irqsave to prevent early IRQ enable

Netpoll will call the interrupt handler with interrupts
disabled when using kgdboe, so spin_lock_irqsave() should
be used instead of spin_lock_irq() to prevent interrupts
from being incorrectly enabled.

Signed-off-by: Weiwei Wang <weiwei.wang@windriver.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agofs-enet: remove code associated with !CONFIG_PPC_MERGE
Kumar Gala [Mon, 22 Sep 2008 21:52:18 +0000 (14:52 -0700)]
fs-enet: remove code associated with !CONFIG_PPC_MERGE

Now that arch/ppc is gone we don't need CONFIG_PPC_MERGE anymore remove
the dead code associated with !CONFIG_PPC_MERGE.

With this change the pre_request_irq() and post_free_irq() calls became
nops so they have been removed.  Also removed fs_request_irq() and
fs_free_irq() and just called request_irq() and free_irq().

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: Scott Wood <scottwood@freescale.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agonetdev: drop CONFIG_PPC_MERGE from Kconfig
Kumar Gala [Mon, 22 Sep 2008 21:52:19 +0000 (14:52 -0700)]
netdev: drop CONFIG_PPC_MERGE from Kconfig

Now that arch/ppc is dead CONFIG_PPC_MERGE is always defined for all
powerpc platforms so we don't need to depend on it.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Josh Boyer <jwboyer@linux.vnet.ibm.com>
Cc: David Gibson <david@gibson.dropbear.id.au>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoatl2: add tx bytes statistic
Jay Cliburn [Sat, 20 Sep 2008 22:37:05 +0000 (17:37 -0500)]
atl2: add tx bytes statistic

Signed-off-by: Jay Cliburn <jacliburn@bellsouth.net>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoforcedeth fix: take phy out of reset during power up
Ayaz Abdulla [Mon, 22 Sep 2008 13:55:35 +0000 (09:55 -0400)]
forcedeth fix: take phy out of reset during power up

This patch will add the phy reset bit into the power up mask which is
used during power up. Certain BIOSes will place the phy in reset and
therefore the driver must take the phy out of reset when it loads.

Signed-off-by: Ayaz Abdulla <aabdulla@nvidia.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoe1000e: avoid duplicated output of device name in kernel warning
Frans Pop [Mon, 22 Sep 2008 21:52:22 +0000 (14:52 -0700)]
e1000e: avoid duplicated output of device name in kernel warning

With 2.6.27-rc3 I noticed the following messages in my boot log:

0000:01:00.0: 0000:01:00.0: Warning: detected DSPD enabled in EEPROM
0000:01:00.0: eth0: (PCI Express:2.5GB/s:Width x1) 00:16:76:04:ff:09

The second seems correct, but the first has a silly repetition of the
PCI device before the actual message. The message originates from
e1000_eeprom_checks in e1000e/netdev.c.

With this patch below the first message becomes

  e1000e 0000:01:00.0: Warning: detected DSPD enabled in EEPROM

which makes it similar to directly preceding messages.

Use dev_warn instead of e_warn in e1000_eeprom_checks() as the interface
name has not yet been assigned at that point.

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Frans Pop <elendil@planet.nl>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoatl1e: remove the unneeded (struct atl1e_adapter *)
Jie Yang [Mon, 22 Sep 2008 21:52:25 +0000 (14:52 -0700)]
atl1e: remove the unneeded (struct atl1e_adapter *)

Remove the unneeded (struct atl1e_adapter *) casts, for hw->adapter
already has type atl1e_adapter *.

Signed-off-by: Jie Yang <jie.yang@atheros.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agogianfar: free/iounmap memory after an error in mii bus initialization
Andy Fleming [Mon, 22 Sep 2008 21:10:25 +0000 (14:10 -0700)]
gianfar: free/iounmap memory after an error in mii bus initialization

Recent changes to MII bus initialization code added exit points which
didn't free or iounmap the bus before returning.

Addresses http://bugzilla.kernel.org/show_bug.cgi?id=11372.

Signed-off-by: Andy Fleming <afleming@freescale.com>
Reported-by: Daniel Marjamki <danielm77@spray.se>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agone.c: fix rmmod, platform driver improvements
David Fries [Mon, 22 Sep 2008 21:10:20 +0000 (14:10 -0700)]
ne.c: fix rmmod, platform driver improvements

Removing the module would cause a kernel oops as platform_driver_probe
failed to detect a device and unregistered the platform driver on module
init, and cleanup_module would unregister the already unregistered driver.
The suspend and resume functions weren't being called.

platform_driver support was added earlier, but without any
platform_device_register* calls I don't think it was being used.  Now all
devices are registered using platform_device_register_simple and pointers
are kept to unregister the ones that the probe failed for or unregister
all devices on module shutdown.  init_module no longer calls ne_init to
reduce confusion (and multiple unregister paths that caused the rmmod
oops).  With the devices now registered they are added to the platform
driver and get suspend and resume events.

netif_device_detach(dev) was added before unregister_netdev(dev) when
removing the region as occationally I would see a race condition where the
device was still being used in unregister_netdev.

Signed-off-by: David Fries <david@fries.net>
Cc: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Cc: Paul Gortmaker <p_gortmaker@yahoo.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agogianfar: Fix error in mdio reset timeout
Trent Piepho [Mon, 22 Sep 2008 17:03:56 +0000 (10:03 -0700)]
gianfar: Fix error in mdio reset timeout

The loop with the timeout used "while (...  && timeout--)", which means
than when the timeout occurs, "timeout" will be -1 after the loop has
exited.  The code that checks if the looped exited because of a timeout
used "if (timeout <= 0)".  Seems ok, except timeout is unsigned, and
(unsigned)-1 isn't less than zero!

Using "--timeout" in the loop fixes this problem, as now "timeout" will be
0 when the loop times out.

This also fixes a bug in the existing code, where it will erroneously think
a timeout occurred if the condition the loop was waiting for is satisfied
on the final iteration before a timeout.

Signed-off-by: Trent Piepho <tpiepho@freescale.com>
Acked-by: Andy Fleming <afleming@freescale.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoe1000e: remove failed request for sw/fw/hw flag
Bruce Allan [Tue, 23 Sep 2008 22:46:38 +0000 (15:46 -0700)]
e1000e: remove failed request for sw/fw/hw flag

When the driver fails to acquire the control flag used to serialize
NVM and PHY accesses between the driver, firmware and hardware, remove the
request for the flag otherwise the hardware might grant the flag when it
becomes available but the driver will not release the flag.  This could
cause the firmware to prevent the driver getting the flag for all future
attempts.

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>
17 years agoenic: bug fix: don't set netdev->name too early
Scott Feldman [Wed, 24 Sep 2008 18:23:53 +0000 (11:23 -0700)]
enic: bug fix: don't set netdev->name too early

Bug fix: don't set netdev->name early before netdev registration.  Setting
netdev->name early with dev_alloc_name() would occasionally cause netdev
registration to fail returning error that device was already registered.
Since we're using netdev->name to name MSI-X vectors, we now need to
move the request_irq after netdev registartion, so move it to ->open.

Signed-off-by: Scott Feldman <scofeldm@cisco.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoenic: Bug fix: Free MSI intr with correct data handle
Scott Feldman [Wed, 24 Sep 2008 18:23:42 +0000 (11:23 -0700)]
enic: Bug fix: Free MSI intr with correct data handle

Bug fix: Free MSI intr with correct data handle
Use davem proposed naming for MSI-X tx/rx vectors (ethX-tx-0, ethX-rx-0)

Signed-off-by: Scott Feldman <scofeldm@cisco.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoenic: fixes for review items from Ben Hutchings
Scott Feldman [Wed, 24 Sep 2008 18:23:32 +0000 (11:23 -0700)]
enic: fixes for review items from Ben Hutchings

Fixes for review items from Ben Hutchings:
 - use netdev->net_stats rather than private net_stats
 - use ethtool op .get_sset_count rather than .get_stats_count
 - err out if setting Tx/Rx csum or TSO using ethtool and setting is
   not enabled for device.
 - pass in jiffies + constant to round_jiffies
 - return err if new MTU is out-of-bounds

Signed-off-by: Scott Feldman <scofeldm@cisco.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoenic: Don't indicate IPv6 pkts using soft-LRO
Scott Feldman [Wed, 24 Sep 2008 18:23:22 +0000 (11:23 -0700)]
enic: Don't indicate IPv6 pkts using soft-LRO

LRO is only applied to IPv4 pkts, so don't use the LRO indication functions
for anything other IPv4 pkts.  Every non-IPv4 pkt is indicated using non-
LRO functions.

Signed-off-by: Scott Feldman <scofeldm@cisco.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agor6040: fix wrong assignment in r6040_free_txbufs
Florian Fainelli [Wed, 24 Sep 2008 19:16:40 +0000 (21:16 +0200)]
r6040: fix wrong assignment in r6040_free_txbufs

This patch fixes a wrong assignment in r6040_free_txbufs
on a receive skb pointer while we should actually do this
on the transmit skb pointer.

Signed-off-by: Florian Fainelli <florian@openwrt.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoqeth: avoid qeth recovery problems
Ursula Braun [Fri, 19 Sep 2008 10:56:03 +0000 (12:56 +0200)]
qeth: avoid qeth recovery problems

Do not touch IFF_UP flag during qeth recovery, but invoke dev_close()
in case of failing recovery.
Cancel outstanding control commands in case of Data Checks or
Channel Checks.
Do not invoke qeth_l2_del_all_mc() in case of a hard stop to speed up
removal of qeth devices.

Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com>
Signed-off-by: Frank Blaschka <frank.blaschka@de.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoqeth: use firmware MAC-address for layer2 hsi-devices
Ursula Braun [Fri, 19 Sep 2008 10:56:02 +0000 (12:56 +0200)]
qeth: use firmware MAC-address for layer2 hsi-devices

Real HiperSocket devices in layer2 mode have a firmware-created
MAC-address. This change enables the qeth driver to use this
firmware MAC-address for layer2 HiperSocket devices.

Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com>
Signed-off-by: Frank Blaschka <frank.blaschka@de.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoMerge branch 'for-2.6.28' of git://git.marvell.com/mv643xx_eth into upstream-next
Jeff Garzik [Thu, 25 Sep 2008 00:40:52 +0000 (20:40 -0400)]
Merge branch 'for-2.6.28' of git://git.marvell.com/mv643xx_eth into upstream-next

17 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
Linus Torvalds [Wed, 24 Sep 2008 23:45:07 +0000 (16:45 -0700)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6:
  netfilter: ip6t_{hbh,dst}: Rejects not-strict mode on rule insertion
  ath9k: disable MIB interrupts to fix interrupt storm
  [Bluetooth] Fix USB disconnect handling of btusb driver
  [Bluetooth] Fix wrong URB handling of btusb driver
  [Bluetooth] Fix I/O errors on MacBooks with Broadcom chips

17 years agoMerge branch 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6
Linus Torvalds [Wed, 24 Sep 2008 23:43:44 +0000 (16:43 -0700)]
Merge branch 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6

* 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6:
  i2c: Fix mailing lists in two MAINTAINERS entries
  i2c-dev: Return correct error code on class_create() failure
  i2c-powermac: Fix section for probe and remove functions

17 years agoMerge branch 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Wed, 24 Sep 2008 23:39:50 +0000 (16:39 -0700)]
Merge branch 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip

* 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  x86: prevent stale state of c1e_mask across CPU offline/online, fix

17 years agoMerge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
Linus Torvalds [Wed, 24 Sep 2008 23:38:52 +0000 (16:38 -0700)]
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] Fixe the definition of PTRS_PER_PGD
  [MIPS] au1000: Fix gpio direction

17 years agoMN10300: Make sched_clock() report time since boot
David Howells [Wed, 24 Sep 2008 16:48:31 +0000 (17:48 +0100)]
MN10300: Make sched_clock() report time since boot

Make sched_clock() report time since boot rather than time since last
timer interrupt.

Make sched_clock() expand and scale the 32-bit TSC value running at
IOCLK speed (~33MHz) to a 64-bit nanosecond counter, using cnt32_to_63()
acquired from the ARM arch and without using slow DIVU instructions
every call.

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoMN10300: Move asm-arm/cnt32_to_63.h to include/linux/
David Howells [Wed, 24 Sep 2008 16:48:26 +0000 (17:48 +0100)]
MN10300: Move asm-arm/cnt32_to_63.h to include/linux/

Move asm-arm/cnt32_to_63.h to include/linux/ so that MN10300 can make
use of it too.

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
17 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wirel...
David S. Miller [Wed, 24 Sep 2008 23:21:56 +0000 (16:21 -0700)]
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6

17 years agoMerge branch 'davem-next' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik...
David S. Miller [Wed, 24 Sep 2008 23:09:13 +0000 (16:09 -0700)]
Merge branch 'davem-next' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6

17 years agobonding: add more ethtool support
Stephen Hemminger [Sun, 14 Sep 2008 01:17:09 +0000 (21:17 -0400)]
bonding: add more ethtool support

This patch allows reporting the link, checksum, and feature settings
of bonded device by using generic hooks.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agonetxen: enable msi-x for quad-gig boards
Dhananjay Phadke [Wed, 20 Aug 2008 20:52:48 +0000 (13:52 -0700)]
netxen: enable msi-x for quad-gig boards

NX3031 firmware now supports MSI-X interrupts on Quad GbE boards.

Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agosundance: set carrier status on link change events
Dan Nicholson [Wed, 20 Aug 2008 23:51:59 +0000 (16:51 -0700)]
sundance: set carrier status on link change events

Check if the link is available when a changed interrupt has been received and
set the carrier status appropriately.  The code is copied nearly verbatim from
the dl2k module.  The link status could be used in more places in the driver,
but this is enough to get the carrier status reported to userspace.  Fixes
kernel bug #7487:

    http://bugzilla.kernel.org/show_bug.cgi?id=7487

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agodrivers/net: replace __FUNCTION__ with __func__
Harvey Harrison [Wed, 20 Aug 2008 23:52:04 +0000 (16:52 -0700)]
drivers/net: replace __FUNCTION__ with __func__

__FUNCTION__ is gcc-specific, use __func__

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoehea: Enable DLPAR memory remove
Hannes Hering [Fri, 5 Sep 2008 14:38:22 +0000 (16:38 +0200)]
ehea: Enable DLPAR memory remove

This patch adds the capability flag to the capability list for dynamic LPAR
memory remove to enable this feature.

Signed-off-by: Hannes Hering <hering2@de.ibm.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years ago[netdrvr] usb/hso: throttle to prevent loss of serial data
Denis Joseph Barrow [Fri, 5 Sep 2008 15:12:07 +0000 (17:12 +0200)]
[netdrvr] usb/hso: throttle to prevent loss of serial data

Patch to stop loss of characters on the hso modems,
this patch throttles & unthrottles the modem by
not putting out urbs until the tty/line discipline layer
has enough space for newly received packets.
serial ports. This is required for firmware diagnostics
being done at Option.

Signed-off-by: Denis Joseph Barrow <D.Barow@option.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agomyri10ge: use DCA if DCA is compiled as a module
Brice Goglin [Sat, 13 Sep 2008 20:42:07 +0000 (22:42 +0200)]
myri10ge: use DCA if DCA is compiled as a module

Use DCA in myri10ge when CONFIG_DCA_MODULE is set as well.

And thus force INTEL_IOATDMA to =y so that DCA=y if we are =y.

Signed-off-by: Brice Goglin <brice@myri.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agocxgb3 - remove duplicate tests in lro
Divy Le Ray [Fri, 5 Sep 2008 05:34:13 +0000 (22:34 -0700)]
cxgb3 - remove duplicate tests in lro

The generic lro code checks TCP flags/options.
Remove duplicate tests done in the driver.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agor8169: select MII in Kconfig
Francois Romieu [Sat, 13 Sep 2008 13:04:38 +0000 (15:04 +0200)]
r8169: select MII in Kconfig

drivers/built-in.o: In function `rtl8169_gset_xmii':
r8169.c:(.text+0x82259): undefined reference to `mii_ethtool_gset'

Signed-off-by: Hugh Dickins <hugh@veritas.com>
Acked-by: Francois Romieu <romieu@fr.zoreil.com>
Cc: Edward Hsu <edward_hsu@realtek.com.tw>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoehea: fix mutex and spinlock use
Sebastien Dugue [Thu, 11 Sep 2008 13:34:40 +0000 (15:34 +0200)]
ehea: fix mutex and spinlock use

  Looks like to me that the ehea_fw_handles.lock mutex and the
ehea_bcmc_regs.lock spinlock are taken much longer than necessary and could
as well be pushed inside the functions that need them
(ehea_update_firmware_handles() and ehea_update_bcmc_registrations())
rather than at each callsite.

Signed-off-by: Sebastien Dugue <sebastien.dugue@bull.net>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoixgbe: fix DCA dependency in Kconfig
Jesse Brandeburg [Fri, 12 Sep 2008 03:06:15 +0000 (20:06 -0700)]
ixgbe: fix DCA dependency in Kconfig

ixgbe can depend on dca IF it is enabled.  So if we are compiled as
IXGBE=y, and DCA is enabled, then we must force INTEL_IOATDMA and therefore
DCA to be =y also.

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>
17 years agoixgbe: whitespace/formatting cleanup
Alexander Duyck [Fri, 12 Sep 2008 03:05:39 +0000 (20:05 -0700)]
ixgbe: whitespace/formatting cleanup

This patch cleans up some whitespace items, reorders a couple of functions, and removes some outdated comments.

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>
17 years agoixgbe: correctly add and remove napi queues
Alexander Duyck [Fri, 12 Sep 2008 03:04:56 +0000 (20:04 -0700)]
ixgbe: correctly add and remove napi queues

This patch corrects support for NAPI so that queues are correctly added and
removed during suspend/resume in the event that the number of MSI-X vectors
changes.

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>
17 years agoixgbe: Whitespace, copyright update and version number change patch
Peter P Waskiewicz [Fri, 12 Sep 2008 03:04:46 +0000 (20:04 -0700)]
ixgbe: Whitespace, copyright update and version number change patch

This patch cleans up a bit of whitespace issues with the driver, updates
the copyright information, and bumps the version number up.

Signed-off-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
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>
17 years agoixgbe: bump version
Jeff Kirsher [Fri, 12 Sep 2008 03:03:55 +0000 (20:03 -0700)]
ixgbe: bump version

Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
17 years agoixgbe: xmit frame refactor
Jesse Brandeburg [Fri, 12 Sep 2008 03:03:35 +0000 (20:03 -0700)]
ixgbe: xmit frame refactor

ixgbe_xmit_frame can be refactored to use fewer locals and better
utilize common kernel macros.

also fixed minor buglet with internal to driver vlan flag variable being
passed incorrectly.

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>
17 years agoixgbe: lower stack space usage
Jesse Brandeburg [Fri, 12 Sep 2008 03:03:23 +0000 (20:03 -0700)]
ixgbe: lower stack space usage

some functions were un-necessarily using local variables.

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>
17 years agoixgbe: cleanup defines
Jesse Brandeburg [Fri, 12 Sep 2008 03:03:00 +0000 (20:03 -0700)]
ixgbe: cleanup defines

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>
17 years agoixgbe: move set_num_queues and call it after msix failure
Jesse Brandeburg [Fri, 12 Sep 2008 03:00:29 +0000 (20:00 -0700)]
ixgbe: move set_num_queues and call it after msix failure

This is partial preparation for a future patch which will extend
ixgbe_set_num_queues

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>
17 years agoixgbe: refresh the ixgbe_down function
Jesse Brandeburg [Fri, 12 Sep 2008 03:00:16 +0000 (20:00 -0700)]
ixgbe: refresh the ixgbe_down function

clean up the hardware shutdown sequence to prevent hardware
from continuing to send when resetting or unloading.

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>
17 years agoixgbe: update to latest common code module
Jesse Brandeburg [Fri, 12 Sep 2008 02:59:59 +0000 (19:59 -0700)]
ixgbe: update to latest common code module

This is a massive update that includes infrastructure for further patches
where we will add support for more phy types and eeprom types.

This code is shared as much as possible with other drivers, so the code may
seem a little obtuse at times but wherever possible we keep to the linux
style and methods.

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>
17 years agoixgbe: add clean rx many routine
Jesse Brandeburg [Fri, 12 Sep 2008 02:59:42 +0000 (19:59 -0700)]
ixgbe: add clean rx many routine

in some configurations there can be more than one rx queue per vector
in msi-x mode.  Add functionality to be able to clean this without
changing the performance path single-rx-queue cleanup.

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>
17 years agoixgbe: lro stats were not counted on first ethtool -Scall
Jesse Brandeburg [Fri, 12 Sep 2008 02:59:29 +0000 (19:59 -0700)]
ixgbe: lro stats were not counted on first ethtool -Scall

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>
17 years agoixgbe: fix ring reallocation in ethtool
Jesse Brandeburg [Fri, 12 Sep 2008 02:59:16 +0000 (19:59 -0700)]
ixgbe: fix ring reallocation in ethtool

changing ring sizes in ethtool needs to be robust.  If an allocation fails the
driver must continue operation, with the previous settings.

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>
17 years agoixgbe: add device support for XF LR adapters
Jesse Brandeburg [Fri, 12 Sep 2008 02:58:59 +0000 (19:58 -0700)]
ixgbe: add device support for XF LR adapters

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>
17 years agoixgbe: recycle pages in packet split mode
Jesse Brandeburg [Fri, 12 Sep 2008 02:58:43 +0000 (19:58 -0700)]
ixgbe: recycle pages in packet split mode

most of the time we only need 1500 bytes for a packet which means
we don't need a whole 4k page for each packet.  Share the allocation
by using a reference count to the page and giving half to two
receive descriptors.  This can enable us to use packet split mode
all the time due to the performance increase of allocating half
the pages.

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>