Commit Graph

17337 Commits (4afaf54b3b97fa8cf2d1d9bcd7612b195acb53ae)

Author SHA1 Message Date
Alexey Starikovskiy 4afaf54b3b ACPI: ibm_acpi: allow clean removal
Allow clean removal by setting notify_installed in the right place.

Signed-off-by: Alexey Starikovskiy <alexey.y.starikovskiy@intel.com>
Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
Signed-off-by: Len Brown <len.brown@intel.com>
2006-12-19 23:07:39 -05:00
Henrique de Moraes Holschuh f9ff43a626 ACPI: ibm-acpi: update version and copyright
Bump up module version, add myself to copyright and MODULE_AUTHOR.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:47 -05:00
Henrique de Moraes Holschuh 9a8e1738c1 ACPI: ibm-acpi: style fixes and cruft removal
This patch just fixes style, move some #defines to enums, and removes some
old cruft.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:47 -05:00
Henrique de Moraes Holschuh fb87a811a4 ACPI: ibm-acpi: backlight device cleanup
This patch cleans up the recently added backlight device support by Holger
Macht <hmacht@suse.de> to fit well with the rest of the code, using the
ibms struct as the other "subdrivers" in ibm-acpi.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:45 -05:00
Henrique de Moraes Holschuh 2df910b4c3 ACPI: ibm-acpi: make non-generic bay support optional
This patch makes it possible to disable ibm-acpi non-generic bay support,
as generic bay support already works well for a number of ThinkPads.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:45 -05:00
Henrique de Moraes Holschuh e0298997ac ACPI: ibm-acpi: add support for the ultrabay on the T60,X60
This patch adds support for the ultrabay on the T60, X60 and other new
ThinkPads that have a SATA ultrabay.

I intend to keep bay and dock support in ibm-acpi working and updated until
it finally gets deprecated and removed in favour of the generic dock and
bay support.  But we aren't there yet.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:45 -05:00
Henrique de Moraes Holschuh 16663a87ad ACPI: ibm-acpi: implement fan watchdog command
This patch implements a fan control safety watchdog, by request of the
authors of userspace fan control scripts.

When the watchdog timer expires, the equivalent action of a "fan enable"
command is executed.  The watchdog timer is reset at every reception of a
fan control command that could change the state of the fan itself.

This command is meant to be used by userspace fan control daemons, to make
sure the fan is never left set to an unsafe level because of userspace
problems.

Users of the X31/X40/X41 "speed" command are on their own, the current
implementation of "speed" is just too incomplete to be used safely,
anyway.  Better to never use it, and just use the "level" command instead.

The watchdog is programmed using echo "watchdog <number>" > fan, where
number is the number of seconds to wait before doing an "enable", and zero
disables the watchdog.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:44 -05:00
Henrique de Moraes Holschuh 778b4d742b ACPI: ibm-acpi: workaround for EC 0x2f initialization bug
A few ThinkPads fail to initialize EC register 0x2f both in the EC
firmware and ACPI DSDT.  If the BIOS and the ACPI DSDT also do not
initialize it, then the initial status of that register does not
correspond to reality.

On all reported buggy machines, EC 0x2f will read 0x07 (fan level 7) upon
cold boot, when the EC is actually in mode 0x80 (auto mode).  Since
returning a text string ("unknown") would break a number of userspace
programs, instead we correct the reading for the most probably correct
answer, and return it is in auto mode.

The workaround flags the status and level as unknown on module load/kernel
boot, until we are certain at least one fan control command was issued,
either by us, or by something else.

We don't work around the bug by doing a "fan enable" at module
load/startup (which would initialize the EC register) because it is not
known if these ThinkPad ACPI DSDT might have set the fan to level 7
instead of "auto" (we don't know if they can do this or not) due to a
thermal condition, and we don't want to override that, should they be
capable of it.

We should be setting the workaround flag to "status known" upon resume, as
both reports and a exaustive search on the DSDT tables at acpi.sf.net show
that the DSDTs always enable the fan on resume, thus working around the
bug.  But since we don't have suspend/resume handlers in ibm-acpi yet and
the "EC register 0x2f was modified" logic is likely to catch the change
anyway, we don't.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:44 -05:00
Henrique de Moraes Holschuh 49a13cd6a2 ACPI: ibm-acpi: store embedded controller firmware version for matching
This patch changes the ThinkPad Embedded Controller DMI matching
code to store the firmware version of the EC for later usage, e.g.
for quirks.

It also prints the firmware version when starting up.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:44 -05:00
Henrique de Moraes Holschuh a12095c2b5 ACPI: ibm-acpi: fix and extend fan control functions
This patch extend fan control functions, implementing enable/disable for
all write access modes, implementing level control for all level-capable
write access modes.

The patch also updates the documentation, explaining levels auto and
disengaged.

ABI changes:
	1. Support level 0 as an equivalent to disable
	2. Add support for level auto and level disengaged when doing
	   EC 0x2f fan control
	3. Support enable/disable for all level-based write access modes
	4. Add support for level command on FANS thinkpads, as per
	   thinkwiki reports

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:43 -05:00
Henrique de Moraes Holschuh 1c6a334e9c ACPI: ibm-acpi: fix and extend fan enable
This patch fix fan enable to attempt to do the right thing and not slow
down the fan if it is forced to the maximum speed.  It also extends fan
enable to work on older thinkpads.

ABI changes:
	1.  Support enable/disable for all level-based write access modes

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:40 -05:00
Henrique de Moraes Holschuh bab812a329 ACPI: ibm-acpi: extend fan status functions
This patch fixes fan_read to return correct values for all fan access
modes.  It also implements some fan access mode status output that was
missing, and normalizes the proc fan abi to return consistent data across
all fan read/write modes.

Userspace ABI changes and extensions:
	1. Return status: enable/disable for *all* modes
	   (this actually improves compatibility with userspace utils!)
	2. Return level: auto and level: disengaged for EC 2f access mode
	3. Return level: <number> for EC 0x2f access mode
	4. Return level 0 as well as "disabled" in level-aware modes

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:40 -05:00
Henrique de Moraes Holschuh a8b7a6626d ACPI: ibm-acpi: document fan control
This patch documents the ThinkPad fan control strategies.  Source of the
data:

0. ibm-acpi source
1. DSDTs for various ThinkPads (770, X31, X40, X41, T43, A21m, T22)
2. http://thinkwiki.org/wiki/Embedded_Controller_Firmware#Firmware_Issues
3. http://thinkwiki.org/wiki/How_to_control_fan_speed
4. Various threads about windows fan control utilities in thinkpads.com

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:40 -05:00
Henrique de Moraes Holschuh 18ad7996e1 ACPI: ibm-acpi: cleanup fan_write
This patch cleans up fan_write so that it is much easier to read and
extend.  It separates the proc api handling from the operations themselves.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:39 -05:00
Henrique de Moraes Holschuh c52f0aa574 ACPI: ibm-acpi: break fan_read into separate functions
This patch breaks fan_read mechanics into a generic function to get fan
status and speed, and leaves only the procfs interface code in fan_read.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:39 -05:00
Henrique de Moraes Holschuh 3ef8a6096c ACPI: ibm-acpi: clean up fan_read
This patch cleans up fan_read so that it is much easier to read and
extend.

The patch fixes the userspace ABI to return "status: not supported" (like
all other ibm-acpi functions) when neither fan status or fan control are
possible.

It also fixes the userspace ABI to return EIO if ACPI access to the EC
fails, instead of returning "status: unreadable" or "speed: unreadable".

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:39 -05:00
Henrique de Moraes Holschuh 69ba91cbd6 ACPI: ibm-acpi: prepare to cleanup fan_read and fan_write
This patch lays some groundwork for a fan_read and fan_write cleanup in the
next patches.  To do so, it provides a new fan_init initializer, and also some
constants (through enums).

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:39 -05:00
Henrique de Moraes Holschuh 60eb0b35a9 ACPI: ibm-acpi: Implement direct-ec-access thermal reading modes for up to 16 sensors
This patch extends ibm-acpi to support reading thermal sensors directly
through ACPI EC register access.  It uses a DMI match to detect ThinkPads
with a new-style embedded controller, that are known to have forward-
compatible register maps and use 0x00 to fill in non-used registers and
export thermal sensors at EC offsets 0x78-7F and 0xC0-C7.

Direct ACPI EC register access is implemented for 8-sensor and 16-sensor
new-style ThinkPad controller firmwares as an experimental feature.  The
code does some limited sanity checks on the temperatures read through EC
access, and will default to the old ACPI TMP0-7 mode if anything is amiss.

Userspace ABI is not changed for 8 sensors, but /proc/acpi/ibm/thermal is
extended for 16 sensors if the firmware supports 16 sensors.

A documentation update is also provided.

The information about the ThinkPad register map was determined by studying
ibm-acpi "ecdump" output from various ThinkPad models, submitted by
subscribers of the linux-thinkpad mailinglist.  Futher information was
gathered from the DSDT tables, as they describe the EC register map in
recent ThinkPads.

DSDT source shows that TMP0-7 access and direct register access are
actually the same thing on these firmwares, but unfortunately IBM never
did update their DSDT EC register map to export TMP8-TMP15 for the second
range of sensors.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:38 -05:00
Henrique de Moraes Holschuh a26f878abc ACPI: ibm-acpi: Use a enum to select the thermal sensor reading strategy
This patch consolidades all decisions regarding the strategy to be used to
read thinkpad thermal sensors into a single enum, and refactors the
thermal sensor reading code to use a much more readable (and easier to
extend) switch() construct, in a separate function.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:38 -05:00
Henrique de Moraes Holschuh 8d29726434 ACPI: ibm-acpi: trivial Lindent cleanups
This patch just makes drives/acpi/ibm-acpi.c Lindent-clean, as requested by
Len Brown.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:34 -05:00
Henrique de Moraes Holschuh 3dfd35cd21 ACPI: ibm-acpi: do not use / in driver names
ibm-acpi uses sub-device names like ibm/hotkey, which get in the way of
a sysfs conversion.  Fix it to use ibm_hotkey instead.  Thanks to Zhang
Rui for noticing this.

Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
2006-12-07 01:38:31 -05:00
Holger Macht c926355724 ACPI: toshiba_acpi: Add support for the generic backlight device
Add support for the generic backlight interface below /sys/class/backlight.
Keep the procfs brightness handling for backward compatibility.

To achive this, add two generic functions get_lcd and set_lcd
to be used both by the procfs related and the sysfs related methods.

[apw@shadowen.org: backlight users need to select BACKLIGHT_CLASS_DEVICE]

Signed-off-by: Holger Macht <hmacht@suse.de>
Signed-off-by: Andy Whitcroft <apw@shadowen.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Len Brown <len.brown@intel.com>
2006-10-21 01:37:28 -04:00
Holger Macht 2039a6eb72 ACPI: asus_acpi: Add support for the generic backlight device
Add support for the generic backlight interface below /sys/class/backlight.
Keep the procfs brightness handling for backward compatibility.

[apw@shadowen.org: backlight users need to select BACKLIGHT_CLASS_DEVICE]

Signed-off-by: Holger Macht <hmacht@suse.de>
Signed-off-by: Andy Whitcroft <apw@shadowen.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Len Brown <len.brown@intel.com>
2006-10-21 01:36:00 -04:00
Holger Macht 8acb025085 ACPI: ibm_acpi: Add support for the generic backlight device
Add support for the generic backlight interface below /sys/class/backlight.
The patch keeps the procfs brightness handling for backward compatibility.

Add two generic functions brightness_get and brightness_set
to be used both by the procfs related and the sysfs related methods.

[apw@shadowen.org: backlight users need to select BACKLIGHT_CLASS_DEVICE]

Signed-off-by: Holger Macht <hmacht@suse.de>
Signed-off-by: Andy Whitcroft <apw@shadowen.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Len Brown <len.brown@intel.com>
2006-10-21 01:34:48 -04:00
Nicolas Pitre c7a3bd177f [PATCH] fix PXA2xx UDC compilation error
This was apparently missed by the move to the generic IRQ code.

Signed-off-by: Nicolas Pitre <nico@cam.org>
Cc: Greg KH <greg@kroah.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 17:56:39 -07:00
Olaf Hering e17e31e388 [PATCH] Fix up rpaphp driver for pci hotplug header move
Use grep instead of make during interface changes.

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 17:56:39 -07:00
Linus Torvalds b2ef7858db Revert "[mv643xx] Add pci device table for auto module loading."
This reverts commit 4596c75c23 as
requested by Olaf Hering. It causes compile errors, and says Olaf:

  "This change is also wrong, the autoloading works perfect with 2.6.18,
   no need to add random PCI ids.

   See commit a0245f7ad5, platform devices
   have now a modalias entry in sysfs.  The network card is not a PCI
   device."

Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:40:48 -07:00
Linus Torvalds c144879164 Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: (36 commits)
  [Bluetooth] Fix HID disconnect NULL pointer dereference
  [Bluetooth] Add missing entry for Nokia DTL-4 PCMCIA card
  [Bluetooth] Add support for newer ANYCOM USB dongles
  [NET]: Can use __get_cpu_var() instead of per_cpu() in loopback driver.
  [IPV4] inet_peer: Group together avl_left, avl_right, v4daddr to speedup lookups on some CPUS
  [TCP]: One NET_INC_STATS() could be NET_INC_STATS_BH in tcp_v4_err()
  [NETFILTER]: Missing check for CAP_NET_ADMIN in iptables compat layer
  [NETPOLL]: initialize skb for UDP
  [IPV6]: Fix route.c warnings when multiple tables are disabled.
  [TG3]: Bump driver version and release date.
  [TG3]: Add lower bound checks for tx ring size.
  [TG3]: Fix set ring params tx ring size implementation
  [NET]: reduce per cpu ram used for loopback stats
  [IPv6] route: Fix prohibit and blackhole routing decision
  [DECNET]: Fix input routing bug
  [TCP]: Bound TSO defer time
  [IPv4] fib: Remove unused fib_config members
  [IPV6]: Always copy rt->u.dst.error when copying a rt6_info.
  [IPV6]: Make IPV6_SUBTREES depend on IPV6_MULTIPLE_TABLES.
  [IPV6]: Clean up BACKTRACK().
  ...
2006-10-20 10:27:38 -07:00
Doug Warzecha b95936cb92 [PATCH] firmware/dcdbas: add size check in smi_data_write
Add a size check in smi_data_write to prevent possible wrapping problems
with large pos values when calling smi_data_buf_realloc on 32-bit.

Signed-off-by: Doug Warzecha <Douglas_Warzecha@dell.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:26:44 -07:00
Dave Jones 1cd441f998 [PATCH] ipmi: fix return codes in failure case
These returns should be negative, like the others in this function.

Signed-off-by: Dave Jones <davej@redhat.com>
Acked-by: Corey Minyard <minyard@acm.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:26:44 -07:00
Amol Lad fca4edb48b [PATCH] drivers/isdn: ioremap balanced with iounmap
ioremap must be balanced by an iounmap and failing to do so can result
in a memory leak.

Signed-off-by: Amol Lad <amol@verismonetworks.com>
Acked-by: Karsten Keil <kkeil@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:26:43 -07:00
Alan Cox a31baca58c [PATCH] irq updates: make eata_pio compile
Signed-off-by: Alan Cox <alan@redhat.com>
Cc: James Bottomley <James.Bottomley@steeleye.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:26:38 -07:00
Yasunori Goto 887b95931b [PATCH] acpi memory hotplug: remove strange add_memory fail message
I wrote a patch to avoid redundant memory hot-add call at boot time.  This
was cause of strange fail message of memory hotplug like "ACPI: add_memory
failed".  Memory is recognized by early boot code with EFI/E820.

But, if DSDT describes memory devices for them, then hot-add code is called
for already recognized memory, and it shows fail messages with -EEXIST.
So, sys admin will misunderstand this message as something wrong by it.

This patch avoids them by preventing redundant hot-add call until
completion of driver initialization.

[akpm@osdl.org: cleanups]
Signed-off-by: Yasunori Goto <y-goto@jp.fujitsu.com>
Cc: "Brown, Len" <len.brown@intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:26:38 -07:00
Yasunori Goto 6cbe44cd8d [PATCH] Change log level of a message of acpi_memhotplug to KERN_DEBUG
I suppose this message seems quite useless except debugging.  It just shows
"Hotplug Mem Device".  System admin can't know anything by this message.
So, I would like to change it to KERN_DEBUG.

Signed-off-by: Yasunori Goto <y-goto@jp.fujitsu.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:26:37 -07:00
Darrick J. Wong c5a114f1fb [PATCH] fix "ACPI: Processor native C-states using MWAIT"
This patch breaks C-state discovery on my IBM IntelliStation Z30 because
the return value of acpi_processor_get_power_info_fadt is not assigned to
"result" in the case that acpi_processor_get_power_info_cst returns
-ENODEV.  Thus, if ACPI provides C-state data via the FADT and not _CST (as
is the case on this machine), we incorrectly exit the function with -ENODEV
after reading the FADT.  The attached patch sets the value of result so
that we don't exit early.

Signed-off-by: Darrick J. Wong <djwong@us.ibm.com>
Acked-by: "Pallipadi, Venkatesh" <venkatesh.pallipadi@intel.com>
Acked-by: "Brown, Len" <len.brown@intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:26:37 -07:00
Randy Dunlap 74e8b51d25 [PATCH] Kconfig serial typos
Fix typo (repeated) in serial Kconfig.

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:26:36 -07:00
Andrew Morton 3fcfab16c5 [PATCH] separate bdi congestion functions from queue congestion functions
Separate out the concept of "queue congestion" from "backing-dev congestion".
Congestion is a backing-dev concept, not a queue concept.

The blk_* congestion functions are retained, as wrappers around the core
backing-dev congestion functions.

This proper layering is needed so that NFS can cleanly use the congestion
functions, and so that CONFIG_BLOCK=n actually links.

Cc: "Thomas Maier" <balagi@justmail.de>
Cc: "Jens Axboe" <jens.axboe@oracle.com>
Cc: Trond Myklebust <trond.myklebust@fys.uio.no>
Cc: David Howells <dhowells@redhat.com>
Cc: Peter Osterlund <petero2@telia.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:26:35 -07:00
Auke Kok e8e82b76e0 [PATCH] e100: fix reboot -f with netconsole enabled
When rebooting with netconsole over e100, the driver shutdown code would
deadlock with netpoll.  Reduce shutdown code to a bare minimum while retaining
WoL and suspend functionality.

Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-10-20 10:26:35 -07:00
Marcel Holtmann 8602b4fe6e [Bluetooth] Add missing entry for Nokia DTL-4 PCMCIA card
The device id for the Nokia DTL-4 PCMCIA card was missing. This patch
adds it back to the list of supported devices.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
2006-10-20 01:15:04 -07:00
Marcel Holtmann 0eab934f4b [Bluetooth] Add support for newer ANYCOM USB dongles
This patch adds the vendor and product id of the ANYCOM Bluetooth
USB-200 and USB-250 dongles and sets a flag to send HCI_Reset as
the first command.

Signed-off-by: Marcel Holtmann <marcel@holtmann.org
2006-10-20 01:15:03 -07:00
Eric Dumazet 58f539740b [NET]: Can use __get_cpu_var() instead of per_cpu() in loopback driver.
As BHs are off in loopback_xmit(), preemption cannot occurs, so we can
use __get_cpu_var() instead of per_cpu() (and avoid a
preempt_enable()/preempt_disable() pair)

Signed-off-by: Eric Dumazet <dada1@cosmosbay.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-10-20 00:32:41 -07:00
David S. Miller 6ba7511b7c [TG3]: Bump driver version and release date.
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-10-18 20:56:06 -07:00
Michael Chan bc3a9254a7 [TG3]: Add lower bound checks for tx ring size.
The minimum tx ring size must be greater than MAX_SKB_FRAGS or 3
times that on some chips with TSO bugs.

Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-10-18 20:55:18 -07:00
Ranjit Manomohan 42952231c6 [TG3]: Fix set ring params tx ring size implementation
Fixes the implementation of the ethtool set ring parameters for the
tg3 transmit ring.  The size of tx_pending is taken into account
before doing a netif_wake_queue.  This prevents the interface from
locking up when smaller transmit ring sizes are used.

Signed-off-by: Ranjit Manomohan <ranjitm@google.com>
Acked-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-10-18 20:54:26 -07:00
Eric Dumazet 5175c3786c [NET]: reduce per cpu ram used for loopback stats
We dont need a full struct net_device_stats (currently 23 long : 184 bytes on 
x86_64) per possible CPU, but only two counters : bytes and packets

We save few CPU cycles too in loopback_xmit() not updating 4 fields, but 2. 

Signed-off-by: Eric Dumazet <dada1@cosmosbay.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2006-10-18 20:51:57 -07:00
Linus Torvalds ce9e3d9953 Merge branch 'ubuntu-updates' of master.kernel.org:/pub/scm/linux/kernel/git/bcollins/ubuntu-2.6
* 'ubuntu-updates' of master.kernel.org:/pub/scm/linux/kernel/git/bcollins/ubuntu-2.6:
  [pci_ids] Add Quicknet XJ vendor/device ID's.
  [valkyriefb] Ifdef for when CONFIG_NVRAM isn't enabled.
  [platinumfb] Ifdef for when CONFIG_NVRAM isn't enabled.
  [igafb] Add pci dev table for module auto loading.
  [controlfb] Ifdef for when CONFIG_NVRAM isn't enabled.
  [hid-core] TurboX Keyboard needs NOGET quirk.
  [ixj] Add pci dev table for module auto loading.
  [initio] Add pci dev table for module auto loading.
  [fdomain] Add pci dev table for module auto loading.
  [BusLogic] Add pci dev table for auto module loading.
  [mv643xx] Add pci device table for auto module loading.
  [alim7101] Add pci dev table for auto module loading.
2006-10-18 18:30:00 -07:00
Linus Torvalds 64d9a39ec9 Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/hwmon-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/hwmon-2.6:
  hwmon: Fix debug messages in w83781d
  hwmon: Let w83781d and lm78 load again
  w83627ehf: Fix the detection of fan5
  k8temp: Documentation update
  smsc47m1: List the SMSC LPC47M112 as supported
  hwmon: Fix documentation typos
  adm9240: Update Grant Coady's email address
  w83791d: Fix unchecked return status
2006-10-18 17:52:27 -07:00
Linus Torvalds 17e6c600b2 Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/aoe-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/aoe-2.6:
  aoe: fix sysfs_create_file warnings
  aoe: revert printk macros
  aoe: update driver version
  aoe: remove sysfs comment
  aoe: use bio->bi_idx
  aoe: module parameter for device timeout
  aoe: zero copy write 2 of 2
  aoe: improve retransmission heuristics
  aoe: jumbo frame support 2 of 2
  aoe: clean up printks via macros
  aoe: jumbo frame support 1 of 2
  aoe: zero copy write 1 of 2
  aoe: remove unused NARGS enum
  aoe: update copyright date
  aoe: eliminate isbusy message
2006-10-18 17:51:05 -07:00
Linus Torvalds b6aefcce74 Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/pci-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/pci-2.6: (22 commits)
  PCI Hotplug: move pci_hotplug.h to include/linux/
  change pci hotplug subsystem maintainer to Kristen
  PCI: optionally sort device lists breadth-first
  cpcihp_generic: prevent loading without "bridge" parameter
  pci: Additional search functions
  PCI: quirks: switch quirks code offender to use pci_get API
  PCI: Update MSI-HOWTO.txt according to pci_msi_supported()
  PCI: Improve pci_msi_supported() comments
  PCI hotplug: ioremap balanced with iounmap
  shpchp: remove unnecessary cmd_busy member from struct controller
  shpchp: fix command completion check
  pci: Stamp out pci_find_* usage in fakephp
  PCI: fix pcie_portdrv_restore_config undefined without CONFIG_PM error
  Fix DMA resource allocation in ACPIPnP
  PCI: Turn pci_fixup_video into generic for embedded VGA
  PCI: add ICH7/8 ACPI/GPIO io resource quirks
  PCI: pcie-check-and-return-bus_register-errors fix
  PCI: VIA IRQ quirk behaviour change
  pciehp: Remove unnecessary check in pciehp_ctrl.c
  pciehp - add missing locking
  ...
2006-10-18 17:50:40 -07:00
Linus Torvalds 65740356cc Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-2.6:
  driver core: kmalloc() failure check in driver_probe_device
  Driver core: bus: remove indentation level
  Driver core: Don't ignore error returns from probing
  Driver core: Don't leak 'old_class_name' in drivers/base/core.c::device_rename()
  driver core fixes: sysfs_create_group() retval in topology.c
  driver core fixes: device_create_file() retval check in dmapool.c
  driver core fixes: device_add() cleanup on error
  driver core fixes: bus_add_device() cleanup on error
  driver core fixes: bus_add_attrs() retval check
  driver core fixes: sysfs_create_link() retval check in class.c
  sysfs: update obsolete comment in sysfs_update_file
  sysfs: remove duplicated dput in sysfs_update_file
  HOWTO: bug report addition
  Fix dev_printk() is now GPL-only
  Driver core: plug device probe memory leak
  Documentation: feature-removal-schedule typo
2006-10-18 17:50:16 -07:00