[Kernelpatches-commits] mfasheh commits r5 - in trunk/mfasheh/vendor/RedHat/RHAS21: . netdump netdump/bcm5700 netdump/e1000_4412k1 netdump/tigon3

svn-commits at oss.oracle.com svn-commits at oss.oracle.com
Mon May 10 20:32:47 CDT 2004


Author: mfasheh
Date: 2004-05-10 19:32:45 -0500 (Mon, 10 May 2004)
New Revision: 5

Added:
   trunk/mfasheh/vendor/RedHat/RHAS21/netdump/
   trunk/mfasheh/vendor/RedHat/RHAS21/netdump/bcm5700/
   trunk/mfasheh/vendor/RedHat/RHAS21/netdump/bcm5700/bcm5700-netdump.patch
   trunk/mfasheh/vendor/RedHat/RHAS21/netdump/e1000_4412k1/
   trunk/mfasheh/vendor/RedHat/RHAS21/netdump/e1000_4412k1/e1000_4412k1-netdump-2.4.9e.12.patch
   trunk/mfasheh/vendor/RedHat/RHAS21/netdump/pcnet32-netdump-2.4.9-e.12.patch
   trunk/mfasheh/vendor/RedHat/RHAS21/netdump/tigon3/
   trunk/mfasheh/vendor/RedHat/RHAS21/netdump/tigon3/tigon3-netdump-2.4.9-e.3.patch
   trunk/mfasheh/vendor/RedHat/RHAS21/netdump/tigon3/tigon3-netdump-2.4.9-e.8.patch
Log:
* add some of my netdump patches



Added: trunk/mfasheh/vendor/RedHat/RHAS21/netdump/bcm5700/bcm5700-netdump.patch
===================================================================
--- trunk/mfasheh/vendor/RedHat/RHAS21/netdump/bcm5700/bcm5700-netdump.patch	2004-05-11 00:28:39 UTC (rev 4)
+++ trunk/mfasheh/vendor/RedHat/RHAS21/netdump/bcm5700/bcm5700-netdump.patch	2004-05-11 00:32:45 UTC (rev 5)
@@ -0,0 +1,46 @@
+--- linux/drivers/addon/bcm5700/b57um.c.orig	2002-10-10 16:03:46.000000000 -0700
++++ linux/drivers/addon/bcm5700/b57um.c	2002-10-10 16:30:00.000000000 -0700
+@@ -96,6 +96,9 @@
+ 
+ static int enable_wol[MAX_UNITS] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
+ 
++/* Added by mark.fasheh at oracle.com to help enable netdump on these cards */
++static void poll_bcm5700 (struct net_device *dev);
++
+ /* Operational parameters that usually are not changed. */
+ /* Time in jiffies before concluding the transmitter is hung. */
+ #define TX_TIMEOUT  (2*HZ)
+@@ -777,6 +780,11 @@
+ 			printk(KERN_INFO "%s: Setting AMD762 Northbridge to enable PCI ordering compliance\n", bcm5700_driver);
+ 		}
+ 	}
++
++#ifdef HAVE_POLL_CONTROLLER
++	dev->poll_controller = &poll_bcm5700;
++#endif
++
+ 	return 0;
+ 
+ }
+@@ -2606,4 +2614,20 @@
+ 	return ((tv.tv_sec * 1000000) + tv.tv_usec);
+ }
+ 
+-
++
++#ifdef HAVE_POLL_CONTROLLER
++
++/*
++ * Polling 'interrupt' - used by things like netconsole to send skbs
++ * without having to re-enable interrupts. It's not called while
++ * the interrupt routine is executing.
++ */
++
++static void poll_bcm5700 (struct net_device *dev)
++{
++	if (!netdump_mode) disable_irq(dev->irq);
++	bcm5700_interrupt (dev->irq, dev, NULL);
++	if (!netdump_mode) enable_irq(dev->irq);
++}
++
++#endif

Added: trunk/mfasheh/vendor/RedHat/RHAS21/netdump/e1000_4412k1/e1000_4412k1-netdump-2.4.9e.12.patch
===================================================================
--- trunk/mfasheh/vendor/RedHat/RHAS21/netdump/e1000_4412k1/e1000_4412k1-netdump-2.4.9e.12.patch	2004-05-11 00:28:39 UTC (rev 4)
+++ trunk/mfasheh/vendor/RedHat/RHAS21/netdump/e1000_4412k1/e1000_4412k1-netdump-2.4.9e.12.patch	2004-05-11 00:32:45 UTC (rev 5)
@@ -0,0 +1,41 @@
+--- linux-2.4.9-e.12/drivers/addon/e1000_4412k1/e1000_main.c.orig	2003-03-14 12:11:29.000000000 -0800
++++ linux-2.4.9-e.12/drivers/addon/e1000_4412k1/e1000_main.c	2003-03-13 15:40:14.000000000 -0800
+@@ -175,6 +175,8 @@
+ #ifdef CONFIG_PM
+ static int e1000_resume(struct pci_dev *pdev);
+ #endif
++/* Added to enable netdump on these cards */
++static void e1000_poll (struct net_device *netdev);
+ 
+ struct notifier_block e1000_notifier_reboot = {
+ 	.notifier_call	= e1000_notify_reboot,
+@@ -399,6 +401,9 @@
+ 	netdev->do_ioctl = &e1000_ioctl;
+ 	netdev->tx_timeout = &e1000_tx_timeout;
+ 	netdev->watchdog_timeo = HZ;
++#ifdef HAVE_POLL_CONTROLLER
++        netdev->poll_controller = &e1000_poll;
++#endif
+ 
+ 	netdev->irq = pdev->irq;
+ 	netdev->mem_start = mmio_start;
+@@ -2360,4 +2365,19 @@
+ }
+ #endif
+ 
++#ifdef HAVE_POLL_CONTROLLER
++/*
++ * Polling 'interrupt' - used by things like netconsole to send skbs
++ * without having to re-enable interrupts. It's not called while
++ * the interrupt routine is executing.
++ */
++
++static void e1000_poll (struct net_device *netdev)
++{
++	if (!netdump_mode) disable_irq(netdev->irq);
++	e1000_intr (netdev->irq, netdev, NULL);
++	if (!netdump_mode) enable_irq(netdev->irq);
++}
++#endif
++
+ /* e1000_main.c */

Added: trunk/mfasheh/vendor/RedHat/RHAS21/netdump/pcnet32-netdump-2.4.9-e.12.patch
===================================================================
--- trunk/mfasheh/vendor/RedHat/RHAS21/netdump/pcnet32-netdump-2.4.9-e.12.patch	2004-05-11 00:28:39 UTC (rev 4)
+++ trunk/mfasheh/vendor/RedHat/RHAS21/netdump/pcnet32-netdump-2.4.9-e.12.patch	2004-05-11 00:32:45 UTC (rev 5)
@@ -0,0 +1,53 @@
+--- linux-2.4.9-e.12_autofs4/drivers/net/pcnet32.c.backup	2003-11-20 13:38:03.000000000 -0800
++++ linux-2.4.9-e.12_autofs4/drivers/net/pcnet32.c	2003-11-20 13:49:15.000000000 -0800
+@@ -307,6 +307,9 @@ static void pcnet32_set_multicast_list(s
+ #ifdef HAVE_PRIVATE_IOCTL
+ static int  pcnet32_mii_ioctl(struct net_device *, struct ifreq *, int);
+ #endif
++#ifdef HAVE_POLL_CONTROLLER
++static void pcnet32_poll(struct net_device *netdev);
++#endif
+ 
+ enum pci_flags_bit {
+     PCI_USES_IO=1, PCI_USES_MEM=2, PCI_USES_MASTER=4,
+@@ -788,7 +791,9 @@ pcnet32_probe1(unsigned long ioaddr, uns
+ #endif
+     dev->tx_timeout = pcnet32_tx_timeout;
+     dev->watchdog_timeo = (HZ >> 1);
+-
++#ifdef HAVE_POLL_CONTROLLER
++    dev->poll_controller = &pcnet32_poll;
++#endif
+     lp->next = pcnet32_dev;
+     pcnet32_dev = dev;
+ 
+@@ -798,7 +803,7 @@ pcnet32_probe1(unsigned long ioaddr, uns
+     return 0;
+ }
+ 
+-
++
+ static int
+ pcnet32_open(struct net_device *dev)
+ {
+@@ -1604,6 +1609,20 @@ static void __exit pcnet32_cleanup_modul
+     }
+ }
+ 
++#ifdef HAVE_POLL_CONTROLLER
++/*
++ * Polling 'interrupt' - used by things like netconsole to send skbs
++ * without having to re-enable interrupts. It's not called while
++ * the interrupt routine is executing.
++ */
++static void pcnet32_poll(struct net_device *netdev)
++{
++	if (!netdump_mode) disable_irq(netdev->irq);
++	pcnet32_interrupt(netdev->irq, netdev, NULL);
++	if (!netdump_mode) enable_irq(netdev->irq);
++}
++#endif
++
+ module_init(pcnet32_init_module);
+ module_exit(pcnet32_cleanup_module);
+ 

Added: trunk/mfasheh/vendor/RedHat/RHAS21/netdump/tigon3/tigon3-netdump-2.4.9-e.3.patch
===================================================================
--- trunk/mfasheh/vendor/RedHat/RHAS21/netdump/tigon3/tigon3-netdump-2.4.9-e.3.patch	2004-05-11 00:28:39 UTC (rev 4)
+++ trunk/mfasheh/vendor/RedHat/RHAS21/netdump/tigon3/tigon3-netdump-2.4.9-e.3.patch	2004-05-11 00:32:45 UTC (rev 5)
@@ -0,0 +1,46 @@
+--- linux/drivers/net/tg3.c.orig	2002-10-11 11:08:12.000000000 -0700
++++ linux/drivers/net/tg3.c	2002-10-11 11:06:58.000000000 -0700
+@@ -178,6 +178,9 @@
+ #define tr16(reg)		readw(tp->regs + (reg))
+ #define tr8(reg)		readb(tp->regs + (reg))
+ 
++/* Added by mark.fasheh at oracle.com to help enable netdump on these cards */
++static void poll_tg3 (struct net_device *dev);
++
+ static void tg3_write_mem(struct tg3 *tp, u32 off, u32 val)
+ {
+ 	unsigned long flags;
+@@ -6227,6 +6230,9 @@
+ 	dev->watchdog_timeo = TG3_TX_TIMEOUT;
+ 	dev->change_mtu = tg3_change_mtu;
+ 	dev->irq = pdev->irq;
++#ifdef HAVE_POLL_CONTROLLER
++	dev->poll_controller = &poll_tg3;
++#endif
+ 
+ 	err = tg3_get_invariants(tp);
+ 	if (err) {
+@@ -6398,5 +6404,23 @@
+ 	pci_unregister_driver(&tg3_driver);
+ }
+ 
++#ifdef HAVE_POLL_CONTROLLER
++
++/*
++ * Polling 'interrupt' - used by things like netconsole to send skbs
++ * without having to re-enable interrupts. It's not called while
++ * the interrupt routine is executing.
++ */
++
++static void poll_tg3 (struct net_device *dev)
++{
++	if (!netdump_mode) disable_irq(dev->irq);
++	tg3_interrupt (dev->irq, dev, NULL);
++	if (!netdump_mode) enable_irq(dev->irq);
++}
++
++#endif
++
++
+ module_init(tg3_init);
+ module_exit(tg3_cleanup);

Added: trunk/mfasheh/vendor/RedHat/RHAS21/netdump/tigon3/tigon3-netdump-2.4.9-e.8.patch
===================================================================
--- trunk/mfasheh/vendor/RedHat/RHAS21/netdump/tigon3/tigon3-netdump-2.4.9-e.8.patch	2004-05-11 00:28:39 UTC (rev 4)
+++ trunk/mfasheh/vendor/RedHat/RHAS21/netdump/tigon3/tigon3-netdump-2.4.9-e.8.patch	2004-05-11 00:32:45 UTC (rev 5)
@@ -0,0 +1,103 @@
+--- linux-2.4.9-e.8/drivers/net/tg3.c.orig	2002-10-29 12:02:56.000000000 -0800
++++ linux-2.4.9-e.8/drivers/net/tg3.c	2002-10-29 14:31:07.000000000 -0800
+@@ -178,6 +178,9 @@
+ #define tr16(reg)		readw(tp->regs + (reg))
+ #define tr8(reg)		readb(tp->regs + (reg))
+ 
++/* Added to enable netdump on these cards */
++static void poll_tg3 (struct net_device *dev);
++
+ static void tg3_write_mem(struct tg3 *tp, u32 off, u32 val)
+ {
+ 	unsigned long flags;
+@@ -2255,15 +2258,16 @@
+ 	unsigned int i;
+ 	u32 len, entry, base_flags;
+ 	int would_hit_hwbug;
++	unsigned long flags;
+ 
+ 	len = (skb->len - skb->data_len);
+ 
+-	spin_lock_irq(&tp->lock);
++	spin_lock_irqsave(&tp->lock, flags);
+ 
+ 	/* This is a hard error, log it. */
+ 	if (unlikely(TX_BUFFS_AVAIL(tp) <= (skb_shinfo(skb)->nr_frags + 1))) {
+ 		netif_stop_queue(dev);
+-		spin_unlock_irq(&tp->lock);
++		spin_unlock_irqrestore(&tp->lock, flags);
+ 		printk(KERN_ERR PFX "%s: BUG! Tx Ring full when queue awake!\n",
+ 		       dev->name);
+ 		return 1;
+@@ -2376,7 +2380,7 @@
+ 		netif_stop_queue(dev);
+ 
+ out_unlock:
+-	spin_unlock_irq(&tp->lock);
++	spin_unlock_irqrestore(&tp->lock, flags);
+ 
+ 	dev->trans_start = jiffies;
+ 
+@@ -2388,15 +2392,16 @@
+ 	struct tg3 *tp = dev->priv;
+ 	dma_addr_t mapping;
+ 	u32 len, entry, base_flags;
+-
++	unsigned long flags;
++	
+ 	len = (skb->len - skb->data_len);
+ 
+-	spin_lock_irq(&tp->lock);
++	spin_lock_irqsave(&tp->lock, flags);
+ 
+ 	/* This is a hard error, log it. */
+ 	if (unlikely(TX_BUFFS_AVAIL(tp) <= (skb_shinfo(skb)->nr_frags + 1))) {
+ 		netif_stop_queue(dev);
+-		spin_unlock_irq(&tp->lock);
++		spin_unlock_irqrestore(&tp->lock, flags);
+ 		printk(KERN_ERR PFX "%s: BUG! Tx Ring full when queue awake!\n",
+ 		       dev->name);
+ 		return 1;
+@@ -2465,7 +2470,7 @@
+ 	if (TX_BUFFS_AVAIL(tp) <= (MAX_SKB_FRAGS + 1))
+ 		netif_stop_queue(dev);
+ 
+-	spin_unlock_irq(&tp->lock);
++	spin_unlock_irqrestore(&tp->lock, flags);
+ 
+ 	dev->trans_start = jiffies;
+ 
+@@ -6284,6 +6289,9 @@
+ 	dev->watchdog_timeo = TG3_TX_TIMEOUT;
+ 	dev->change_mtu = tg3_change_mtu;
+ 	dev->irq = pdev->irq;
++#ifdef HAVE_POLL_CONTROLLER
++	dev->poll_controller = &poll_tg3;
++#endif
+ 
+ 	err = tg3_get_invariants(tp);
+ 	if (err) {
+@@ -6436,6 +6444,23 @@
+ 	return 0;
+ }
+ 
++#ifdef HAVE_POLL_CONTROLLER
++/*
++ * Polling 'interrupt' - used by things like netconsole to send skbs
++ * without having to re-enable interrupts. It's not called while
++ * the interrupt routine is executing.
++ */
++
++static void poll_tg3 (struct net_device *dev)
++{
++  struct tg3 *tp = (struct tg3 *) dev->priv;
++
++  if (!netdump_mode) disable_irq(dev->irq);
++  tg3_interrupt (dev->irq, dev, NULL);
++  if (!netdump_mode) enable_irq(dev->irq);
++}
++#endif
++
+ static struct pci_driver tg3_driver = {
+ 	name:		DRV_MODULE_NAME,
+ 	id_table:	tg3_pci_tbl,



More information about the Kernelpatches-commits mailing list