[kernel] r13742 - in dists/lenny/linux-2.6/debian: . patches/bugfix/all patches/series

Ben Hutchings benh at alioth.debian.org
Tue Jun 9 01:05:52 UTC 2009


Author: benh
Date: Tue Jun  9 01:05:44 2009
New Revision: 13742

Log:
Add upstream fixes for driver bugs:
- sata_nv: avoid link reset on controllers where it's broken (Closes: #498271)
- r8169: fix multicast filtering for RTL8101 and RTL8168 (Closes: #514268)
- asus_acpi: don't load asus-acpi if model is not supported (Closes: #524300)
- iwl4965: avoid sleep in softirq context (Closes: #530884)

Added:
   dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-acpi-asus_acpi-unsupported-models.patch
   dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-ata-sata_nv-broken-hardreset.patch
   dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-net-r8169-multicast-8101-8168.patch
   dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-net-wireless-iwl4965-scan-cancel.patch
Modified:
   dists/lenny/linux-2.6/debian/changelog
   dists/lenny/linux-2.6/debian/patches/series/16

Modified: dists/lenny/linux-2.6/debian/changelog
==============================================================================
--- dists/lenny/linux-2.6/debian/changelog	Mon Jun  8 17:38:08 2009	(r13741)
+++ dists/lenny/linux-2.6/debian/changelog	Tue Jun  9 01:05:44 2009	(r13742)
@@ -42,6 +42,14 @@
     kernels (closes: #529312)
   * Fix soft lockups caused by one md resync blocking on another due
     to sharing the same device (closes: #514627)
+  
+  [ Ben Hutchings ]
+  * sata_nv: avoid link reset on controllers where it's broken
+    (Closes: #498271)
+  * r8169: fix multicast filtering for RTL8101 and RTL8168 (Closes: #514268)
+  * asus_acpi: don't load asus-acpi if model is not supported
+    (Closes: #524300)
+  * iwl4965: avoid sleep in softirq context (Closes: #530884)
 
  -- maximilian attems <maks at debian.org>  Mon, 30 Mar 2009 17:11:49 +0200
 

Added: dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-acpi-asus_acpi-unsupported-models.patch
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-acpi-asus_acpi-unsupported-models.patch	Tue Jun  9 01:05:44 2009	(r13742)
@@ -0,0 +1,19 @@
+Fix bug #524300.  The upstream change was:
+
+commit 7745384080ef70f7710530afa3e45477b126e056
+Author: Zhang Rui <rui.zhang at intel.com>
+Date:   Fri Oct 17 01:42:41 2008 -0400
+
+    don't load asus-acpi if model is not supported
+
+--- a/drivers/acpi/asus_acpi.c
++++ b/drivers/acpi/asus_acpi.c
+@@ -1244,6 +1244,8 @@ static int asus_hotk_get_info(void)
+ 			       "default values\n", string);
+ 			printk(KERN_NOTICE
+ 			       "  send /proc/acpi/dsdt to the developers\n");
++			kfree(model);
++			return -ENODEV;
+ 		}
+ 		hotk->methods = &model_conf[hotk->model];
+ 		return AE_OK;

Added: dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-ata-sata_nv-broken-hardreset.patch
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-ata-sata_nv-broken-hardreset.patch	Tue Jun  9 01:05:44 2009	(r13742)
@@ -0,0 +1,203 @@
+Fix bug #498271.  This patch combines the following upstream changes:
+
+7dac745 sata_nv: give up hardreset on nf2
+8d993ea sata_nv: ck804 has borked hardreset too
+2d77570 sata_nv: fix MCP5x reset
+e8caa3c sata_nv: rename nv_nf2_hardreset()
+3c32428 sata_nv: fix generic, nf2/3 detection regression
+4c1eb90 sata_nv: reinstate nv_hardreset() for non generic controllers
+2fd673e sata_nv: disable hardreset for generic
+
+--- a/drivers/ata/sata_nv.c
++++ b/drivers/ata/sata_nv.c
+@@ -305,12 +305,12 @@ static void nv_ck804_host_stop(struct ata_host *host);
+ static int nv_scr_read(struct ata_port *ap, unsigned int sc_reg, u32 *val);
+ static int nv_scr_write(struct ata_port *ap, unsigned int sc_reg, u32 val);
+ 
++static int nv_noclassify_hardreset(struct ata_link *link, unsigned int *class,
++				   unsigned long deadline);
+ static void nv_nf2_freeze(struct ata_port *ap);
+ static void nv_nf2_thaw(struct ata_port *ap);
+ static void nv_ck804_freeze(struct ata_port *ap);
+ static void nv_ck804_thaw(struct ata_port *ap);
+-static int nv_hardreset(struct ata_link *link, unsigned int *class,
+-			unsigned long deadline);
+ static int nv_adma_slave_config(struct scsi_device *sdev);
+ static int nv_adma_check_atapi_dma(struct ata_queued_cmd *qc);
+ static void nv_adma_qc_prep(struct ata_queued_cmd *qc);
+@@ -352,6 +352,7 @@ enum nv_host_type
+ 	NFORCE3 = NFORCE2,	/* NF2 == NF3 as far as sata_nv is concerned */
+ 	CK804,
+ 	ADMA,
++	MCP5x,
+ 	SWNCQ,
+ };
+ 
+@@ -363,10 +364,10 @@ static const struct pci_device_id nv_pci_tbl[] = {
+ 	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_CK804_SATA2), CK804 },
+ 	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP04_SATA), CK804 },
+ 	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP04_SATA2), CK804 },
+-	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_SATA), SWNCQ },
+-	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_SATA2), SWNCQ },
+-	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_SATA), SWNCQ },
+-	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_SATA2), SWNCQ },
++	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_SATA), MCP5x },
++	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_SATA2), MCP5x },
++	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_SATA), MCP5x },
++	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_SATA2), MCP5x },
+ 	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_SATA), GENERIC },
+ 	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_SATA2), GENERIC },
+ 	{ PCI_VDEVICE(NVIDIA, PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_SATA3), GENERIC },
+@@ -405,28 +406,53 @@ static struct scsi_host_template nv_swncq_sht = {
+ 	.slave_configure	= nv_swncq_slave_config,
+ };
+ 
+-static struct ata_port_operations nv_generic_ops = {
++static struct ata_port_operations nv_common_ops = {
+ 	.inherits		= &ata_bmdma_port_ops,
+-	.hardreset		= nv_hardreset,
+ 	.scr_read		= nv_scr_read,
+ 	.scr_write		= nv_scr_write,
+ };
+ 
++/* OSDL bz11195 reports that link doesn't come online after hardreset
++ * on generic nv's and there have been several other similar reports
++ * on linux-ide.  Disable hardreset for generic nv's.
++ */
++static struct ata_port_operations nv_generic_ops = {
++	.inherits		= &nv_common_ops,
++	.hardreset		= ATA_OP_NULL,
++};
++
++/* nf2 is ripe with hardreset related problems.
++ *
++ * kernel bz#3352 reports nf2/3 controllers can't determine device
++ * signature reliably.  The following thread reports detection failure
++ * on cold boot with the standard debouncing timing.
++ *
++ * http://thread.gmane.org/gmane.linux.ide/34098
++ *
++ * And bz#12176 reports that hardreset simply doesn't work on nf2.
++ * Give up on it and just don't do hardreset.
++ */
+ static struct ata_port_operations nv_nf2_ops = {
+ 	.inherits		= &nv_generic_ops,
+ 	.freeze			= nv_nf2_freeze,
+ 	.thaw			= nv_nf2_thaw,
+ };
+ 
++/* For initial probing after boot and hot plugging, hardreset mostly
++ * works fine on CK804 but curiously, reprobing on the initial port by
++ * rescanning or rmmod/insmod fails to acquire the initial D2H Reg FIS
++ * in somewhat undeterministic way.  Use noclassify hardreset.
++ */
+ static struct ata_port_operations nv_ck804_ops = {
+-	.inherits		= &nv_generic_ops,
++	.inherits		= &nv_common_ops,
+ 	.freeze			= nv_ck804_freeze,
+ 	.thaw			= nv_ck804_thaw,
++	.hardreset		= nv_noclassify_hardreset,
+ 	.host_stop		= nv_ck804_host_stop,
+ };
+ 
+ static struct ata_port_operations nv_adma_ops = {
+-	.inherits		= &nv_generic_ops,
++	.inherits		= &nv_ck804_ops,
+ 
+ 	.check_atapi_dma	= nv_adma_check_atapi_dma,
+ 	.sff_tf_read		= nv_adma_tf_read,
+@@ -449,8 +476,19 @@ static struct ata_port_operations nv_adma_ops = {
+ 	.host_stop		= nv_adma_host_stop,
+ };
+ 
++/* Kernel bz#12351 reports that when SWNCQ is enabled, for hotplug to
++ * work, hardreset should be used and hardreset can't report proper
++ * signature, which suggests that mcp5x is closer to nf2 as long as
++ * reset quirkiness is concerned.  Define separate ops for mcp5x with
++ * nv_noclassify_hardreset().
++ */
++static struct ata_port_operations nv_mcp5x_ops = {
++	.inherits		= &nv_common_ops,
++	.hardreset		= nv_noclassify_hardreset,
++};
++
+ static struct ata_port_operations nv_swncq_ops = {
+-	.inherits		= &nv_generic_ops,
++	.inherits		= &nv_mcp5x_ops,
+ 
+ 	.qc_defer		= ata_std_qc_defer,
+ 	.qc_prep		= nv_swncq_qc_prep,
+@@ -513,6 +551,15 @@ static const struct ata_port_info nv_port_info[] = {
+ 		.port_ops	= &nv_adma_ops,
+ 		.private_data	= NV_PI_PRIV(nv_adma_interrupt, &nv_adma_sht),
+ 	},
++	/* MCP5x */
++	{
++		.flags		= ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY,
++		.pio_mask	= NV_PIO_MASK,
++		.mwdma_mask	= NV_MWDMA_MASK,
++		.udma_mask	= NV_UDMA_MASK,
++		.port_ops	= &nv_mcp5x_ops,
++		.private_data	= NV_PI_PRIV(nv_generic_interrupt, &nv_sht),
++	},
+ 	/* SWNCQ */
+ 	{
+ 		.flags	        = ATA_FLAG_SATA | ATA_FLAG_NO_LEGACY |
+@@ -1512,6 +1559,17 @@
+ 	return 0;
+ }
+ 
++static int nv_noclassify_hardreset(struct ata_link *link, unsigned int *class,
++				   unsigned long deadline)
++{
++	bool online;
++	int rc;
++
++	rc = sata_link_hardreset(link, sata_deb_timing_hotplug, deadline,
++				 &online, NULL);
++	return online ? -EAGAIN : rc;
++}
++
+ static void nv_nf2_freeze(struct ata_port *ap)
+ {
+ 	void __iomem *scr_addr = ap->host->ports[0]->ioaddr.scr_addr;
+@@ -1588,21 +1646,6 @@ static void nv_mcp55_thaw(struct ata_port *ap)
+ 	ata_sff_thaw(ap);
+ }
+ 
+-static int nv_hardreset(struct ata_link *link, unsigned int *class,
+-			unsigned long deadline)
+-{
+-	int rc;
+-
+-	/* SATA hardreset fails to retrieve proper device signature on
+-	 * some controllers.  Request follow up SRST.  For more info,
+-	 * see http://bugzilla.kernel.org/show_bug.cgi?id=3352
+-	 */
+-	rc = sata_sff_hardreset(link, class, deadline);
+-	if (rc)
+-		return rc;
+-	return -EAGAIN;
+-}
+-
+ static void nv_adma_error_handler(struct ata_port *ap)
+ {
+ 	struct nv_adma_port_priv *pp = ap->private_data;
+@@ -2341,14 +2384,9 @@ static int nv_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
+ 	if (type == CK804 && adma_enabled) {
+ 		dev_printk(KERN_NOTICE, &pdev->dev, "Using ADMA mode\n");
+ 		type = ADMA;
+-	}
+-
+-	if (type == SWNCQ) {
+-		if (swncq_enabled)
+-			dev_printk(KERN_NOTICE, &pdev->dev,
+-				   "Using SWNCQ mode\n");
+-		else
+-			type = GENERIC;
++	} else if (type == MCP5x && swncq_enabled) {
++		dev_printk(KERN_NOTICE, &pdev->dev, "Using SWNCQ mode\n");
++		type = SWNCQ;
+ 	}
+ 
+ 	ppi[0] = &nv_port_info[type];

Added: dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-net-r8169-multicast-8101-8168.patch
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-net-r8169-multicast-8101-8168.patch	Tue Jun  9 01:05:44 2009	(r13742)
@@ -0,0 +1,28 @@
+Fix bug #514268.  This patch combines the following upstream changes:
+
+1087f4f r8169: multicast register update (sync with Realtek's 8.004.00 8168 driver)
+f887cce r8169: multicast register update
+
+--- b/drivers/net/r8169.c
++++ b/drivers/net/r8169.c
+@@ -3091,15 +3091,11 @@
+ 	tmp = rtl8169_rx_config | rx_mode |
+ 	      (RTL_R32(RxConfig) & rtl_chip_info[tp->chipset].RxConfigMask);
+ 
+-	if ((tp->mac_version == RTL_GIGA_MAC_VER_11) ||
+-	    (tp->mac_version == RTL_GIGA_MAC_VER_12) ||
+-	    (tp->mac_version == RTL_GIGA_MAC_VER_13) ||
+-	    (tp->mac_version == RTL_GIGA_MAC_VER_14) ||
+-	    (tp->mac_version == RTL_GIGA_MAC_VER_15) ||
+-	    (tp->mac_version == RTL_GIGA_MAC_VER_16) ||
+-	    (tp->mac_version == RTL_GIGA_MAC_VER_17)) {
+-		mc_filter[0] = 0xffffffff;
+-		mc_filter[1] = 0xffffffff;
++	if (tp->mac_version > RTL_GIGA_MAC_VER_06) {
++		u32 data = mc_filter[0];
++
++		mc_filter[0] = swab32(mc_filter[1]);
++		mc_filter[1] = swab32(data);
+ 	}
+ 
+ 	RTL_W32(MAR0 + 0, mc_filter[0]);

Added: dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-net-wireless-iwl4965-scan-cancel.patch
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ dists/lenny/linux-2.6/debian/patches/bugfix/all/drivers-net-wireless-iwl4965-scan-cancel.patch	Tue Jun  9 01:05:44 2009	(r13742)
@@ -0,0 +1,23 @@
+Fix bug #530884.  The upstream change was:
+
+commit 964d2777438bf7687324243d38ade538d9bbfe3c
+Author: John W. Linville <linville at tuxdriver.com>
+Date:   Thu Oct 30 14:12:21 2008 -0400
+
+    iwlagn: avoid sleep in softirq context
+
+--- a/drivers/net/wireless/iwlwifi/iwl4965-base.c
++++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c
+@@ -6791,7 +6791,11 @@ static void iwl4965_mac_update_tkip_key(struct ieee80211_hw *hw,
+ 		return;
+ 	}
+ 
+-	iwl4965_scan_cancel_timeout(priv, 100);
++	if (iwl4965_scan_cancel(priv)) {
++		/* cancel scan failed, just live w/ bad key and rely
++		   briefly on SW decryption */
++		return;
++	}
+ 
+ 	key_flags |= (STA_KEY_FLG_TKIP | STA_KEY_FLG_MAP_KEY_MSK);
+ 	key_flags |= cpu_to_le16(keyconf->keyidx << STA_KEY_FLG_KEYID_POS);

Modified: dists/lenny/linux-2.6/debian/patches/series/16
==============================================================================
--- dists/lenny/linux-2.6/debian/patches/series/16	Mon Jun  8 17:38:08 2009	(r13741)
+++ dists/lenny/linux-2.6/debian/patches/series/16	Tue Jun  9 01:05:44 2009	(r13742)
@@ -8,3 +8,7 @@
 + features/all/xen/xen-blkfront-make-blkif_ioctl-static.patch
 + features/all/ftdi_sio-sheevaplug.patch
 + bugfix/all/md-dont-wait-uninterruptible-for-other-resync-to-finish.patch
++ bugfix/all/drivers-ata-sata_nv-broken-hardreset.patch
++ bugfix/all/drivers-net-r8169-multicast-8101-8168.patch
++ bugfix/all/drivers-acpi-asus_acpi-unsupported-models.patch
++ bugfix/all/drivers-net-wireless-iwl4965-scan-cancel.patch



More information about the Kernel-svn-changes mailing list