Age | Commit message (Collapse) | Author |
|
This patch adds some basic ethtool operations to virtio_net so
I could test SG without GSO (which was really useful because TSO
turned out to be buggy :)
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> (remove MTU setting)
|
|
On Mon, 2008-05-26 at 17:42 +1000, Rusty Russell wrote:
> If we fail to transmit a packet, we assume the queue is full and put
> the skb into last_xmit_skb. However, if more space frees up before we
> xmit it, we loop, and the result can be transmitting the same skb twice.
>
> Fix is simple: set skb to NULL if we've used it in some way, and check
> before sending.
...
> diff -r 564237b31993 drivers/net/virtio_net.c
> --- a/drivers/net/virtio_net.c Mon May 19 12:22:00 2008 +1000
> +++ b/drivers/net/virtio_net.c Mon May 19 12:24:58 2008 +1000
> @@ -287,21 +287,25 @@ again:
> free_old_xmit_skbs(vi);
>
> /* If we has a buffer left over from last time, send it now. */
> - if (vi->last_xmit_skb) {
> + if (unlikely(vi->last_xmit_skb)) {
> if (xmit_skb(vi, vi->last_xmit_skb) != 0) {
> /* Drop this skb: we only queue one. */
> vi->dev->stats.tx_dropped++;
> kfree_skb(skb);
> + skb = NULL;
> goto stop_queue;
> }
> vi->last_xmit_skb = NULL;
With this, may drop an skb and then later in the function discover that
we could have sent it after all. Poor wee skb :)
How about the incremental patch below?
Cheers,
Mark.
Subject: [PATCH] virtio_net: Delay dropping tx skbs
Currently we drop the skb in start_xmit() if we have a
queued buffer and fail to transmit it.
However, if we delay dropping it until we've stopped the
queue and enabled the tx notification callback, then there
is a chance space might become available for it.
Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
|
|
* git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6: (76 commits)
ide: use proper printk() KERN_* levels in ide-probe.c
ide: fix for EATA SCSI HBA in ATA emulating mode
ide: remove stale comments from drivers/ide/Makefile
ide: enable local IRQs in all handlers for TASKFILE_NO_DATA data phase
ide-scsi: remove kmalloced struct request
ht6560b: remove old history
ht6560b: update email address
ide-cd: fix oops when using growisofs
gayle: release resources on ide_host_add() failure
palm_bk3710: add UltraDMA/100 support
ide: trivial sparse annotations
ide: ide-tape.c sparse annotations and unaligned access removal
ide: drop 'name' parameter from ->init_chipset method
ide: prefix messages from IDE PCI host drivers by driver name
it821x: remove DECLARE_ITE_DEV() macro
it8213: remove DECLARE_ITE_DEV() macro
ide: include PCI device name in messages from IDE PCI host drivers
ide: remove <asm/ide.h> for some archs
ide-generic: remove ide_default_{io_base,irq}() inlines (take 3)
ide-generic: is no longer needed on ppc32
...
|
|
git://git.kernel.org/pub/scm/linux/kernel/git/ak/linux-acpi-2.6
* 'release-2.6.27' of git://git.kernel.org/pub/scm/linux/kernel/git/ak/linux-acpi-2.6:
acpi: fix crash in core ACPI code, triggered by CONFIG_ACPI_PCI_SLOT=y
ACPI: thinkpad-acpi: don't misdetect in get_thinkpad_model_data() on -ENOMEM
ACPI: thinkpad-acpi: bump up version to 0.21
ACPI: thinkpad-acpi: add bluetooth and WWAN rfkill support
ACPI: thinkpad-acpi: WLSW overrides other rfkill switches
ACPI: thinkpad-acpi: prepare for bluetooth and wwan rfkill support
ACPI: thinkpad-acpi: consolidate wlsw notification function
ACPI: thinkpad-acpi: minor refactor on radio switch init
Revert "ACPI: don't walk tables if ACPI was disabled"
Revert "dock: bay: Don't call acpi_walk_namespace() when ACPI is disabled."
Revert "Fix FADT parsing"
ACPI : Set FAN device to correct state in boot phase
ACPI: Ignore _BQC object when registering backlight device
ACPI: stop complaints about interrupt link End Tags and blank IRQ descriptors
|
|
git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6:
PCI: fixup sparse endianness warnings in proc.c
PCI PM: make more PCI PM core functionality available to drivers
PCI/DMAR: don't assume presence of RMRRs
PCI hotplug: fix error path in pci_slot's register_slot
|
|
While at it:
- fixup printk() messages in save_match() and hwif_init().
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
IDE probing code used to skip devices attached to EATA SCSI HBA
in ATA emulating mode but because of warm-plug support port I/O
resources are no longer freed if no devices are detected on a port
and the decision about the driver to use is left up to the user.
Remove no longer valid EATA SCSI HBA quirk from do_identify().
Noticed-by: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
It is already done by task_no_data_intr() and there is no reason
not to do it in other TASKFILE_NO_DATA data phase handlers.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
This converts ide-scsi to use blk_get/put_request instead of
kmalloc/kfree.
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Remove the ancient version history. Git does a better job.
From: Jan Evert van Grootheest <j.e.van.grootheest@caiway.nl>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Update email address.
From: Jan Evert van Grootheest <j.e.van.grootheest@caiway.nl>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
cdrom_read_capacity() will blindly return the capacity from the device
without sanity-checking it. This later causes code in fs/buffer.c to
oops.
Fix this by checking that the device is telling us sensible things.
From: Jens Axboe <jens.axboe@oracle.com>
Cc: Michael Buesch <mb@bu3sch.de>
Cc: Jan Kara <jack@suse.cz>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: <stable@kernel.org>
Cc: Borislav Petkov <petkovbb@googlemail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
[bart: print device name instead of driver name]
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
[harvey: blocklen is a big-endian value]
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
"gayle: reserve memory resources at once" patch temporary removed
freeing of resources on failure (to ease convertion to ide_host_add()
interface). This patch fixes it.
Thanks to Geert for noticing the issue.
Noticed-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
This controller supports UltraDMA up to mode 5 but it should be clocked with
at least twice the data strobe frequency, so enable mode 5 for 100+ MHz IDECLK.
While at it, start passing the correct device to clk_get() -- it worked anyway
but WTF? :-/
Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
If this is actually unaligned the access of speed/max_speed above
is already broken and needs a get_unaligned. Otherwise it is
aligned and they can be removed.
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Cc: Borislav Petkov <petkovbb@googlemail.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
There should be no functional changes caused by this patch.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Prefix messages from IDE PCI host drivers by driver name instead of marketed
chipset name (it is still possible to exactly identify the particular chipset
basing on driver messages).
As a bonus this provides nice code savings for some drivers:
text data bss dec hex filename
3826 112 8 3946 f6a drivers/ide/pci/amd74xx.o.before
2786 112 8 2906 b5a drivers/ide/pci/amd74xx.o.after
764 108 0 872 368 drivers/ide/pci/cs5520.o.before
680 108 0 788 314 drivers/ide/pci/cs5520.o.after
1680 112 4 1796 704 drivers/ide/pci/generic.o.before
1155 112 4 1271 4f7 drivers/ide/pci/generic.o.after
7128 792 0 7920 1ef0 drivers/ide/pci/hpt366.o.before
6984 792 0 7776 1e60 drivers/ide/pci/hpt366.o.after
2800 148 0 2948 b84 drivers/ide/pci/pdc202xx_new.o.before
2523 148 0 2671 a6f drivers/ide/pci/pdc202xx_new.o.after
2831 148 0 2979 ba3 drivers/ide/pci/pdc202xx_old.o.before
2683 148 0 2831 b0f drivers/ide/pci/pdc202xx_old.o.after
3776 112 4 3892 f34 drivers/ide/pci/piix.o.before
2804 112 4 2920 b68 drivers/ide/pci/piix.o.after
4693 116 0 4809 12c9 drivers/ide/pci/siimage.o.before
4600 116 0 4716 126c drivers/ide/pci/siimage.o.after
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
While at it:
* it821x_chipsets[] -> it821x_chipset.
* Fix it821x_chipset's name field (as it is used for IT8211/8212).
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
While at it:
* it8213_chipsets[] -> it8213_chipset.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
While at it:
* Apply small fixes to messages (s/dma/DMA/, remove trailing '.', etc).
* Fix printk() call in ide_setup_pci_baseregs() to use KERN_INFO.
* Move printk() call from ide_pci_clear_simplex() to the caller.
* Cleanup do_ide_setup_pci_device() a bit.
* amd74xx.c: remove superfluous PCI device revision information.
* hpt366.c: fix two printk() calls in ->init_chipset to use KERN_INFO.
* pdc202xx_new.c: fix printk() call in ->init_chipset to use KERN_INFO.
* pdc202xx_old.c: fix driver message in pdc202xx_init_one().
* via82cxxx.c: fix driver warning message in via_init_one().
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Replace ide_default_{io_base,irq}() inlines by legacy_{bases,irqs}[].
v2:
Add missing zero-ing of hws[] (caught during testing by Borislav Petkov).
v3:
Fix zero-oing of hws[] for _real_ this time.
There should be no functional changes caused by this patch.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Move ide_probe_legacy() call to ide_generic_init() so it fails
early if necessary and returns the proper error value (nowadays
ide_default_io_base() is used only by ide-generic).
Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
Fix the refcounting for dev2 while at it.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|