Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d4a76f8a authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (21 commits)
  r8169: avoid losing MSI interrupts
  tcp: tcp_vegas ssthresh bugfix
  mac8390: fix regression caused during net_device_ops conversion
  gianfar: fix BUG under load after introduction of skb recycling
  wimax/i2400m: usb: fix device reset on autosuspend while not yet idle
  RxRPC: Error handling for rxrpc_alloc_connection()
  ipv4: Fix oops with FIB_TRIE
  pktgen: do not access flows[] beyond its length
  gigaset: beyond ARRAY_SIZE of iwb->data
  IPv6: set RTPROT_KERNEL to initial route
  net: fix rtable leak in net/ipv4/route.c
  net: fix length computation in rt_check_expire()
  wireless: beyond ARRAY_SIZE of intf->crypto_stats
  iwlwifi: update 5000 ucode support to version 2 of API
  cfg80211: fix race between core hint and driver's custom apply
  airo: fix airo_get_encode{,ext} buffer overflow like I mean it...
  ath5k: fix interpolation with equal power levels
  iwlwifi: do not cancel delayed work inside spin_lock_irqsave
  ath5k: fix exp off-by-one when computing OFDM delta slope
  wext: verify buffer size for SIOCSIWENCODEEXT
  ...
parents 60a0cd52 7682455e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -175,7 +175,7 @@ int gigaset_isowbuf_getbytes(struct isowbuf_t *iwb, int size)
		return -EINVAL;
	}
	src = iwb->read;
	if (unlikely(limit > BAS_OUTBUFSIZE + BAS_OUTBUFPAD ||
	if (unlikely(limit >= BAS_OUTBUFSIZE + BAS_OUTBUFPAD ||
		     (read < src && limit >= src))) {
		pr_err("isoc write buffer frame reservation violated\n");
		return -EFAULT;
+1 −1
Original line number Diff line number Diff line
@@ -102,7 +102,7 @@ obj-$(CONFIG_HAMACHI) += hamachi.o
obj-$(CONFIG_NET) += Space.o loopback.o
obj-$(CONFIG_SEEQ8005) += seeq8005.o
obj-$(CONFIG_NET_SB1000) += sb1000.o
obj-$(CONFIG_MAC8390) += mac8390.o 8390.o
obj-$(CONFIG_MAC8390) += mac8390.o
obj-$(CONFIG_APNE) += apne.o 8390.o
obj-$(CONFIG_PCMCIA_PCNET) += 8390.o
obj-$(CONFIG_HP100) += hp100.o
+10 −1
Original line number Diff line number Diff line
@@ -1885,8 +1885,17 @@ int gfar_clean_rx_ring(struct net_device *dev, int rx_work_limit)

			if (unlikely(!newskb))
				newskb = skb;
			else if (skb)
			else if (skb) {
				/*
				 * We need to reset ->data to what it
				 * was before gfar_new_skb() re-aligned
				 * it to an RXBUF_ALIGNMENT boundary
				 * before we put the skb back on the
				 * recycle list.
				 */
				skb->data = skb->head + NET_SKB_PAD;
				__skb_queue_head(&priv->rx_recycle, skb);
			}
		} else {
			/* Increment the number of packets */
			dev->stats.rx_packets++;
+5 −5
Original line number Diff line number Diff line
@@ -304,7 +304,7 @@ struct net_device * __init mac8390_probe(int unit)
	if (!MACH_IS_MAC)
		return ERR_PTR(-ENODEV);

	dev = alloc_ei_netdev();
	dev = ____alloc_ei_netdev(0);
	if (!dev)
		return ERR_PTR(-ENOMEM);

@@ -481,10 +481,10 @@ void cleanup_module(void)
static const struct net_device_ops mac8390_netdev_ops = {
	.ndo_open 		= mac8390_open,
	.ndo_stop		= mac8390_close,
	.ndo_start_xmit		= ei_start_xmit,
	.ndo_tx_timeout		= ei_tx_timeout,
	.ndo_get_stats		= ei_get_stats,
	.ndo_set_multicast_list = ei_set_multicast_list,
	.ndo_start_xmit		= __ei_start_xmit,
	.ndo_tx_timeout		= __ei_tx_timeout,
	.ndo_get_stats		= __ei_get_stats,
	.ndo_set_multicast_list = __ei_set_multicast_list,
	.ndo_validate_addr	= eth_validate_addr,
	.ndo_set_mac_address 	= eth_mac_addr,
	.ndo_change_mtu		= eth_change_mtu,
+57 −45
Original line number Diff line number Diff line
@@ -3554,43 +3554,43 @@ static irqreturn_t rtl8169_interrupt(int irq, void *dev_instance)
	int handled = 0;
	int status;

	/* loop handling interrupts until we have no new ones or
	 * we hit a invalid/hotplug case.
	 */
	status = RTL_R16(IntrStatus);

	/* hotplug/major error/no more work/shared irq */
	if ((status == 0xffff) || !status)
		goto out;

	while (status && status != 0xffff) {
		handled = 1;

		/* Handle all of the error cases first. These will reset
		 * the chip, so just exit the loop.
		 */
		if (unlikely(!netif_running(dev))) {
			rtl8169_asic_down(ioaddr);
		goto out;
			break;
		}

	status &= tp->intr_mask;
	RTL_W16(IntrStatus,
		(status & RxFIFOOver) ? (status | RxOverflow) : status);

	if (!(status & tp->intr_event))
		goto out;

		/* Work around for rx fifo overflow */
		if (unlikely(status & RxFIFOOver) &&
		(tp->mac_version == RTL_GIGA_MAC_VER_11)) {
			netif_stop_queue(dev);
			rtl8169_tx_timeout(dev);
		goto out;
			break;
		}

		if (unlikely(status & SYSErr)) {
			rtl8169_pcierr_interrupt(dev);
		goto out;
			break;
		}

		if (status & LinkChg)
			rtl8169_check_link_status(dev, tp, ioaddr);

	if (status & tp->napi_event) {
		/* We need to see the lastest version of tp->intr_mask to
		 * avoid ignoring an MSI interrupt and having to wait for
		 * another event which may never come.
		 */
		smp_rmb();
		if (status & tp->intr_mask & tp->napi_event) {
			RTL_W16(IntrMask, tp->intr_event & ~tp->napi_event);
			tp->intr_mask = ~tp->napi_event;

@@ -3601,7 +3601,17 @@ static irqreturn_t rtl8169_interrupt(int irq, void *dev_instance)
				dev->name, status);
			}
		}
out:

		/* We only get a new MSI interrupt when all active irq
		 * sources on the chip have been acknowledged. So, ack
		 * everything we've seen and check if new sources have become
		 * active to avoid blocking all interrupts from the chip.
		 */
		RTL_W16(IntrStatus,
			(status & RxFIFOOver) ? (status | RxOverflow) : status);
		status = RTL_R16(IntrStatus);
	}

	return IRQ_RETVAL(handled);
}

@@ -3617,13 +3627,15 @@ static int rtl8169_poll(struct napi_struct *napi, int budget)

	if (work_done < budget) {
		napi_complete(napi);
		tp->intr_mask = 0xffff;
		/*
		 * 20040426: the barrier is not strictly required but the
		 * behavior of the irq handler could be less predictable
		 * without it. Btw, the lack of flush for the posted pci
		 * write is safe - FR

		/* We need for force the visibility of tp->intr_mask
		 * for other CPUs, as we can loose an MSI interrupt
		 * and potentially wait for a retransmit timeout if we don't.
		 * The posted write to IntrMask is safe, as it will
		 * eventually make it to the chip and we won't loose anything
		 * until it does.
		 */
		tp->intr_mask = 0xffff;
		smp_wmb();
		RTL_W16(IntrMask, tp->intr_event);
	}
Loading