2.6.32.7-stable review
Subsystems (50)
cover 2.6.32.7-stable review
This is the start of the stable review cycle for the 2.6.32.7 release. There are 98 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let us know. If anyone is a maintainer of the proper subsystem, and wants to add a Signed-off-by: line to the patch, please respond with it.
Responses should be made by Thursday, January 28, 20:00:00 UTC. Anything received after that time might be too late.
The whole patch series can be found in one patch at:
kernel.org/pub/linux/kernel/v2.6/stable-review/patch-2.6.32.7-rc1.gz
and the diffstat can be found below.
I want to strongly thank Ben Hutchings, of the Debian Kernel team, for doing a lot of work on this release. He went through the Debian kernel and sent me a lot of patches. Same goes for the openSUSE and Gentoo kernel teams[1], they also did a great job digging patches out for this release as well.
thanks,
greg k-h
Documentation/DocBook/Makefile | 21 ++- Documentation/video4linux/CARDLIST.saa7134 | 1 + Makefile | 2 +- arch/arm/mach-davinci/dm646x.c | 9 +- arch/powerpc/sysdev/fsl_pci.c | 14 ++ arch/s390/kvm/intercept.c | 4 +- arch/x86/kernel/cpu/intel.c | 1 - arch/x86/kernel/tsc.c | 1 + arch/x86/kvm/lapic.c | 11 +- arch/x86/kvm/mmu.c | 6 +- arch/x86/kvm/paging_tmpl.h | 4 +- arch/x86/kvm/x86.c | 6 +- drivers/acpi/processor_idle.c | 21 ++- drivers/ata/ahci.c | 20 ++- drivers/ata/ata_piix.c | 8 +- drivers/base/devtmpfs.c | 3 +- drivers/firmware/dmi_scan.c | 15 ++- drivers/hid/usbhid/hid-core.c | 3 +- drivers/hid/usbhid/hid-quirks.c | 2 +- drivers/hwmon/fschmd.c | 7 +- drivers/infiniband/ulp/ipoib/ipoib_main.c | 1 + drivers/input/mouse/alps.c | 252 ++++++++++++++++++++++++--- drivers/input/mouse/alps.h | 1 + drivers/input/serio/i8042-x86ia64io.h | 158 +++++++++-------- drivers/md/md.c | 2 +- drivers/media/dvb/siano/smsusb.c | 10 + drivers/media/video/saa7134/saa7134-cards.c | 31 ++++ drivers/media/video/saa7134/saa7134-dvb.c | 1 + drivers/media/video/saa7134/saa7134.h | 1 + drivers/media/video/uvc/uvc_ctrl.c | 2 +- drivers/mtd/ubi/upd.c | 1 + drivers/mtd/ubi/vtbl.c | 1 + drivers/net/atl1c/atl1c.h | 6 +- drivers/net/atl1c/atl1c_main.c | 72 ++++---- drivers/net/atl1e/atl1e_main.c | 36 ---- drivers/net/benet/be.h | 15 ++- drivers/net/benet/be_main.c | 2 + drivers/net/qlge/qlge_main.c | 30 +--- drivers/net/qlge/qlge_mpi.c | 3 + drivers/net/sfc/tx.c | 4 +- drivers/net/wireless/ath/ar9170/usb.c | 4 +- drivers/net/wireless/iwlwifi/iwl-5000.c | 4 + drivers/pci/pcie/aer/aer_inject.c | 8 +- drivers/pci/setup-bus.c | 11 +- drivers/s390/cio/device.c | 11 +- drivers/s390/cio/device_fsm.c | 25 +-- drivers/s390/net/netiucv.c | 4 +- drivers/scsi/device_handler/scsi_dh.c | 11 +- drivers/scsi/fcoe/fcoe.c | 15 +- drivers/scsi/libfc/fc_disc.c | 2 +- drivers/scsi/libfc/fc_elsct.c | 4 +- drivers/scsi/libfc/fc_fcp.c | 35 ++-- drivers/scsi/libfc/fc_lport.c | 33 ++-- drivers/scsi/libfc/fc_rport.c | 81 ++++++--- drivers/scsi/lpfc/lpfc_init.c | 16 ++- drivers/scsi/mpt2sas/mpi/mpi2_cnfg.h | 8 + drivers/scsi/mpt2sas/mpt2sas_scsih.c | 18 ++ drivers/scsi/scsi_devinfo.c | 9 +- drivers/scsi/scsi_transport_fc.c | 70 +++++--- drivers/scsi/scsi_transport_iscsi.c | 9 +- drivers/usb/serial/ftdi_sio.c | 14 ++ drivers/usb/serial/ftdi_sio.h | 14 ++ drivers/usb/serial/mos7840.c | 24 +++- drivers/watchdog/iTCO_wdt.c | 115 ++++++++----- fs/nfs/super.c | 2 - fs/nfsd/nfs4acl.c | 2 +- fs/partitions/efi.c | 30 ++-- fs/partitions/efi.h | 8 +- include/acpi/platform/aclinux.h | 2 +- include/linux/clocksource.h | 2 + include/linux/hid.h | 1 + include/linux/pci_ids.h | 14 ++ include/linux/time.h | 1 + include/scsi/fc_frame.h | 3 + include/scsi/libfc.h | 1 + init/calibrate.c | 24 ++- ipc/msg.c | 1 + ipc/sem.c | 1 + ipc/shm.c | 1 + kernel/cpu.c | 5 +- kernel/sched.c | 34 ++-- kernel/sched_fair.c | 16 ++ kernel/time/clockevents.c | 5 +- kernel/time/clocksource.c | 44 +++++ kernel/time/tick-sched.c | 52 ++++-- kernel/time/timekeeping.c | 11 ++ net/mac80211/cfg.c | 3 + net/netfilter/xt_conntrack.c | 61 ++----- net/wireless/sme.c | 1 + sound/pci/hda/hda_intel.c | 3 + sound/pci/hda/patch_intelhdmi.c | 2 +- sound/pci/hda/patch_realtek.c | 10 +- sound/pci/ice1712/juli.c | 32 ++++ sound/soc/codecs/wm8903.c | 3 +- virt/kvm/eventfd.c | 15 ++- virt/kvm/irq_comm.c | 12 +- 96 files changed, 1175 insertions(+), 560 deletions(-)
[1] Ok, that would have been me, but I am on both of those teams, and if I don't thank myself, who does?
PATCH 1/98 clockevent: Dont remove broadcast device when cpu is dead
2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Xiaotian Feng <[email protected]>
commit ea9d8e3f45404d411c00ae67b45cc35c58265bb7 upstream.
Marc reported that the BUG_ON in clockevents_notify() triggers on his system. This happens because the kernel tries to remove an active clock event device (used for broadcasting) from the device list.
The handling of devices which can be used as per cpu device and as a global broadcast device is suboptimal.
The simplest solution for now (and for stable) is to check whether the device is used as global broadcast device, but this needs to be revisited.
[ tglx: restored the cpuweight check and massaged the changelog ]
LKML-Reference: <[email protected]>
--- kernel/time/clockevents.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
kernel/time/clockevents.c +2 -1
@@ -258,7 +258,8 @@ void clockevents_notify(unsigned long re cpu = *((int *)arg);list_for_each_entry_safe (dev, tmp, &clockevent_devices, list) {if (cpumask_test_cpu (cpu, dev->cpumask) && -cpumask_weight (dev->cpumask) ==1 ) { +cpumask_weight (dev->cpumask) ==1 && + !tick_is_broadcast_device (dev)) {BUG_ON (dev->mode !=CLOCK_EVT_MODE_UNUSED );list_del (&dev->list); }
PATCH 2/98 clockevents: Add missing include to pacify sparse
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: H Hartley Sweeten <[email protected]>
commit 8e1a928a2ed7e8d5cad97c8e985294b4caedd168 upstream.
Include "tick-internal.h" in order to pick up the extern function prototype for clockevents_shutdown(). This quiets the following sparse build noise:
warning: symbol 'clockevents_shutdown' was not declared. Should it be static?
LKML-Reference: <[email protected]>
--- kernel/time/clockevents.c | 2 ++ 1 file changed, 2 insertions(+)
kernel/time/clockevents.c +2 -0
@@ -20,6 +20,8 @@#include <linux/sysdev.h> #include <linux/tick.h> +#include "tick-internal.h" +/* The registered clock event devices */ static LIST_HEAD (clockevent_devices);static LIST_HEAD (clockevents_released);
PATCH 3/98 ACPI: dont cond_resched if irq is disabled
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Xiaotian Feng <[email protected]>
commit c084ca704a3661bf77690a05bc6bd2c305d87c34 upstream.
commit 8bd108d adds preemption point after each opcode parse, then a sleeping function called from invalid context bug was founded during suspend/resume stage. this was fixed in commit abe1dfa by don't cond_resched when irq_disabled. But recent commit 138d156 changes the behaviour to don't cond_resched when in_atomic. This makes the sleeping function called from invalid context bug happen again, which is reported in http://lkml.org/lkml/2009/12/1/371.
This patch also fixes http://bugzilla.kernel.org/show_bug.cgi?id=14483
--- include/acpi/platform/aclinux.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
include/acpi/platform/aclinux.h +1 -1
@@ -152,7 +152,7 @@ static inline void *acpi_os_acquire_obje#include <linux/hardirq.h> #define ACPI_PREEMPTION_POINT () \ do { \ - if (!in_atomic_preempt_off()) \ + if (!in_atomic_preempt_off() && !irqs_disabled()) \ cond_resched(); \ } while (0)
PATCH 4/98 sfc: Fix DMA mapping cleanup in case of an error in TSO
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Neil Turton <[email protected]>
commit a7ebd27a13757248863cd61e541af7fa9e7727ee upstream.
We need buffer->len to remain valid to work out the correct address to be unmapped. We therefore need to clear buffer->len after the unmap operation.
--- drivers/net/sfc/tx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/net/sfc/tx.c +2 -2
@@ -821,8 +821,6 @@ static void efx_enqueue_unwind(struct ef tx_queue->efx->type->txd_ring_mask];efx_tsoh_free (tx_queue, buffer);EFX_BUG_ON_PARANOID (buffer->skb); - buffer->len =0 ; - buffer->continuation = true;if (buffer->unmap_len) { unmap_addr = (buffer->dma_addr + buffer->len - buffer->unmap_len);
@@ -836,6 +834,8 @@ static void efx_enqueue_unwind(struct ef PCI_DMA_TODEVICE); buffer->unmap_len =0 ; } + buffer->len =0 ; + buffer->continuation = true; } }
PATCH 5/98 be2net: Add support for next generation of BladeEngine device.
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ajit Khaparde <[email protected]>
commit 12d7ea2c5a5c87834daf9fcd920aab80ff6248b1 upstream.
Add new PCI ids to support next generation of BladeEngine device.
--- drivers/net/benet/be.h | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-)
drivers/net/benet/be.h +13 -2
@@ -35,20 +35,31 @@#define DRV_VER "2.101.205"#define DRV_NAME "be2net"#define BE_NAME "ServerEngines BladeEngine2 10Gbps NIC" +#define BE3_NAME "ServerEngines BladeEngine3 10Gbps NIC"#define OC_NAME "Emulex OneConnect 10Gbps NIC" +#define OC_NAME1 "Emulex OneConnect 10Gbps NIC (be3)"#define DRV_DESC BE_NAME "Driver"#define BE_VENDOR_ID 0x19a2#define BE_DEVICE_ID1 0x211 +#define BE_DEVICE_ID2 0x221#define OC_DEVICE_ID1 0x700#define OC_DEVICE_ID2 0x701 +#define OC_DEVICE_ID3 0x710static inline char *nic_name (struct pci_dev *pdev) { -if (pdev->device ==OC_DEVICE_ID1 || pdev->device ==OC_DEVICE_ID2 ) +switch (pdev->device) { +case OC_DEVICE_ID1 : +case OC_DEVICE_ID2 :return OC_NAME ; -else +case OC_DEVICE_ID3 : +return OC_NAME1 ; +case BE_DEVICE_ID2 : +return BE3_NAME ; +default :return BE_NAME ; + } }/* Number of bytes of an RX frame that are copied to skb->data */
PATCH 6/98 be2net: Add the new PCI IDs to PCI_DEVICE_TABLE.
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ajit Khaparde <[email protected]>
commit 59fd5d87a4243a992f3a3e69f3627cf4c509608e upstream.
This patch adds the PCI IDs for the next generation chip to the PCI_DEVICE_ID table.
--- drivers/net/benet/be_main.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/net/benet/be_main.c +2 -0
@@ -31,8 +31,10 @@ MODULE_PARM_DESC(rx_frag_size, "Size ofstatic DEFINE_PCI_DEVICE_TABLE (be_dev_ids) = { {PCI_DEVICE (BE_VENDOR_ID ,BE_DEVICE_ID1 ) }, + {PCI_DEVICE (BE_VENDOR_ID ,BE_DEVICE_ID2 ) }, {PCI_DEVICE (BE_VENDOR_ID ,OC_DEVICE_ID1 ) }, {PCI_DEVICE (BE_VENDOR_ID ,OC_DEVICE_ID2 ) }, + {PCI_DEVICE (BE_VENDOR_ID ,OC_DEVICE_ID3 ) }, {0 } };MODULE_DEVICE_TABLE (pci, be_dev_ids);
PATCH 7/98 mpt2sas: New device SAS2208 support is added
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Kashyap, Desai <[email protected]>
commit db27136a89d061bf9dceb28953a61a8ef862ca7f upstream.
Added device ids range for { 0x80 - 87 } , modified mpi/mpi2_cnfg.h containing MPI2_MFGPAGE_DEVID_SAS2208_X.
--- drivers/scsi/mpt2sas/mpi/mpi2_cnfg.h | 8 ++++++++ drivers/scsi/mpt2sas/mpt2sas_scsih.c | 18 ++++++++++++++++++ 2 files changed, 26 insertions(+)
drivers/scsi/mpt2sas/mpi/mpi2_cnfg.h +8 -0
@@ -348,6 +348,14 @@ typedef struct _MPI2_CONFIG_REPLY#define MPI2_MFGPAGE_DEVID_SAS2108_3 (0x0077)#define MPI2_MFGPAGE_DEVID_SAS2116_1 (0x0064)#define MPI2_MFGPAGE_DEVID_SAS2116_2 (0x0065) +#define MPI2_MFGPAGE_DEVID_SAS2208_1 (0x0080) +#define MPI2_MFGPAGE_DEVID_SAS2208_2 (0x0081) +#define MPI2_MFGPAGE_DEVID_SAS2208_3 (0x0082) +#define MPI2_MFGPAGE_DEVID_SAS2208_4 (0x0083) +#define MPI2_MFGPAGE_DEVID_SAS2208_5 (0x0084) +#define MPI2_MFGPAGE_DEVID_SAS2208_6 (0x0085) +#define MPI2_MFGPAGE_DEVID_SAS2208_7 (0x0086) +#define MPI2_MFGPAGE_DEVID_SAS2208_8 (0x0087)/* Manufacturing Page 0 */
drivers/scsi/mpt2sas/mpt2sas_scsih.c +18 -0
@@ -196,10 +196,28 @@ static struct pci_device_id scsih_pci_ta PCI_ANY_ID, PCI_ANY_ID }, { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2108_3, PCI_ANY_ID, PCI_ANY_ID }, +/* Meteor ~ 2116 */ { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2116_1, PCI_ANY_ID, PCI_ANY_ID }, { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2116_2, PCI_ANY_ID, PCI_ANY_ID }, +/* Thunderbolt ~ 2208 */ + { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2208_1, + PCI_ANY_ID, PCI_ANY_ID }, + { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2208_2, + PCI_ANY_ID, PCI_ANY_ID }, + { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2208_3, + PCI_ANY_ID, PCI_ANY_ID }, + { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2208_4, + PCI_ANY_ID, PCI_ANY_ID }, + { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2208_5, + PCI_ANY_ID, PCI_ANY_ID }, + { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2208_6, + PCI_ANY_ID, PCI_ANY_ID }, + { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2208_7, + PCI_ANY_ID, PCI_ANY_ID }, + { MPI2_MFGPAGE_VENDORID_LSI, MPI2_MFGPAGE_DEVID_SAS2208_8, + PCI_ANY_ID, PCI_ANY_ID }, {0} /* Terminating entry */ };MODULE_DEVICE_TABLE (pci, scsih_pci_table);
PATCH 8/98 ar9170: Add support for D-Link DWA 160 A2
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Thomas Klute <[email protected]>
commit 15295380f45aa0d35665f6e5596ac98c081d95b9 upstream.
At least two revisions of the D-Link DWA 160 exist, called A1 and A2. A1 (USB-ID 07d1:3c10) is already listed in usb.c as D-Link DWA 160A. A2 (USB-ID 07d1:3a09) works if added to ar9170_usb_ids. I didn't do much testing until now, but I was able to connect to APs using WPA or WEP and transmit data.
Summary:
* Add model revision number to the comment for D-Link DWA 160 A1 (07d1:3c10)
* Add support for D-Link DWA 160 A2 (07d1:3a09)
--- drivers/net/wireless/ath/ar9170/usb.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/net/wireless/ath/ar9170/usb.c +3 -1
@@ -68,8 +68,10 @@ static struct usb_device_id ar9170_usb_i { USB_DEVICE(0x0cf3, 0x1002) },/* Cace Airpcap NX */ { USB_DEVICE(0xcace, 0x0300) }, -/* D-Link DWA 160A */ +/* D-Link DWA 160 A1 */ { USB_DEVICE(0x07d1, 0x3c10) }, +/* D-Link DWA 160 A2 */ + { USB_DEVICE(0x07d1, 0x3a09) },/* Netgear WNDA3100 */ { USB_DEVICE(0x0846, 0x9010) },/* Netgear WN111 v2 */
PATCH 9/98 powerpc/fsl: Add PCI device ids for new QoirQ chips
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ben Hutchings <[email protected]>
commit a3f62bd2b20c769ddc989b242ddd274179e19ee6 upstream by Kumar Gala <[email protected]>. I have adjusted the patch context for 2.6.32.
--- arch/powerpc/sysdev/fsl_pci.c | 14 ++++++++++++++ include/linux/pci_ids.h | 14 ++++++++++++++ 2 files changed, 28 insertions(+)
arch/powerpc/sysdev/fsl_pci.c +14 -0
@@ -392,8 +392,22 @@ DECLARE_PCI_FIXUP_HEADER(0x1957, PCI_DEVDECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_MPC8641 , quirk_fsl_pcie_header);DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_MPC8641D , quirk_fsl_pcie_header);DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_MPC8610 , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P1011E , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P1011 , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P1013E , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P1013 , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P1020E , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P1020 , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P1022E , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P1022 , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P2010E , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P2010 , quirk_fsl_pcie_header);DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P2020E , quirk_fsl_pcie_header);DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P2020 , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P4040E , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P4040 , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P4080E , quirk_fsl_pcie_header); +DECLARE_PCI_FIXUP_HEADER (0x1957 ,PCI_DEVICE_ID_P4080 , quirk_fsl_pcie_header);#endif /* CONFIG_PPC_85xx || CONFIG_PPC_86xx */ #if defined(CONFIG_PPC_83xx) || defined(CONFIG_PPC_MPC512x)
include/linux/pci_ids.h +14 -0
@@ -2290,6 +2290,20 @@#define PCI_DEVICE_ID_MPC8536 0x0051#define PCI_DEVICE_ID_P2020E 0x0070#define PCI_DEVICE_ID_P2020 0x0071 +#define PCI_DEVICE_ID_P2010E 0x0078 +#define PCI_DEVICE_ID_P2010 0x0079 +#define PCI_DEVICE_ID_P1020E 0x0100 +#define PCI_DEVICE_ID_P1020 0x0101 +#define PCI_DEVICE_ID_P1011E 0x0108 +#define PCI_DEVICE_ID_P1011 0x0109 +#define PCI_DEVICE_ID_P1022E 0x0110 +#define PCI_DEVICE_ID_P1022 0x0111 +#define PCI_DEVICE_ID_P1013E 0x0118 +#define PCI_DEVICE_ID_P1013 0x0119 +#define PCI_DEVICE_ID_P4080E 0x0400 +#define PCI_DEVICE_ID_P4080 0x0401 +#define PCI_DEVICE_ID_P4040E 0x0408 +#define PCI_DEVICE_ID_P4040 0x0409#define PCI_DEVICE_ID_MPC8641 0x7010#define PCI_DEVICE_ID_MPC8641D 0x7011#define PCI_DEVICE_ID_MPC8610 0x7018
PATCH 10/98 davinci: dm646x: Add support for 3.x silicon revision
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Hemant Pedanekar <[email protected]>
commit f63dd12da29f47c37bbc093abec098538e04357c upstream.
DM6467 silicon revisions 3.x have variant field in JTAGID register as '1'. This path adds entry for the same in dm646x_ids to be able to boot on boards with 3.x revision chips.
Also modifies name for 'variant=0' (revisions 1.0, 1.1).
--- arch/arm/mach-davinci/dm646x.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-)
arch/arm/mach-davinci/dm646x.c +8 -1
@@ -789,7 +789,14 @@ static struct davinci_id dm646x_ids[] = .part_no = 0xb770, .manufacturer = 0x017, .cpu_id = DAVINCI_CPU_ID_DM6467, - .name = "dm6467", + .name = "dm6467_rev1.x", + }, + { + .variant = 0x1, + .part_no = 0xb770, + .manufacturer = 0x017, + .cpu_id = DAVINCI_CPU_ID_DM6467, + .name = "dm6467_rev3.x", }, };
PATCH 11/98 Input: ALPS - add interleaved protocol support (Dell E6x00 series)
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Sebastian Kapfer <[email protected]>
commit 1d9f26262aef6d63ff65eba0fd5f1583f342b69b upstream
Properly handle version of the protocol where standard PS/2 packets from trackpoint are stuffed into middle (byte 3-6) of the standard ALPS packets when both the touchpad and trackpoint are used together.
The patch is based on work done by Matthew Chapman and additional research done by David Kubicek and Erik Osterholm:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/296610
Many thanks to David Kubicek for his efforts in researching fine points of this new version of the protocol, especially interaction between pad and stick in these models.
--- drivers/input/mouse/alps.c | 252 ++++++++++++++++++++++++++++++++++++++++----- drivers/input/mouse/alps.h | 1 2 files changed, 228 insertions(+), 25 deletions(-)
drivers/input/mouse/alps.c +227 -25
@@ -5,6 +5,7 @@* Copyright (c) 2003-2005 Peter Osterlund <[email protected]> * Copyright (c) 2004 Dmitry Torokhov <[email protected]> * Copyright (c) 2005 Vojtech Pavlik <[email protected]> +* Copyright (c) 2009 Sebastian Kapfer <[email protected]> * * ALPS detection, tap switching and status querying info is taken from * tpconfig utility (by C. Scott Ananian and Bruce Kall).
@@ -35,6 +36,8 @@#define ALPS_OLDPROTO 0x10#define ALPS_PASS 0x20#define ALPS_FW_BK_2 0x40 +#define ALPS_PS2_INTERLEAVED 0x80/* 3-byte PS/2 packet interleaved with +6-byte ALPS packet */ static const struct alps_model_info alps_model_data[] = { { {0x32 ,0x02 ,0x14 },0xf8 ,0xf8 ,ALPS_PASS |ALPS_DUALPOINT },/* Toshiba Salellite Pro M10 */
@@ -55,7 +58,9 @@ static const struct alps_model_info alps { { 0x20, 0x02, 0x0e }, 0xf8, 0xf8, ALPS_PASS | ALPS_DUALPOINT }, /* XXX */ { { 0x22, 0x02, 0x0a }, 0xf8, 0xf8, ALPS_PASS | ALPS_DUALPOINT }, { { 0x22, 0x02, 0x14 }, 0xff, 0xff, ALPS_PASS | ALPS_DUALPOINT }, /* Dell Latitude D600 */ - { { 0x62, 0x02, 0x14 }, 0xcf, 0xcf, ALPS_PASS | ALPS_DUALPOINT }, /* Dell Latitude E6500 */ + /* Dell Latitude E5500, E6400, E6500, Precision M4400 */ + { { 0x62, 0x02, 0x14 }, 0xcf, 0xcf, + ALPS_PASS | ALPS_DUALPOINT | ALPS_PS2_INTERLEAVED }, { { 0x73, 0x02, 0x50 }, 0xcf, 0xcf, ALPS_FW_BK_1 }, /* Dell Vostro 1400 */ };
@@ -66,20 +71,88 @@ static const struct alps_model_info alps*/ /* -* ALPS abolute Mode - new format +* PS/2 packet format +* +* byte 0: 0 0 YSGN XSGN 1 M R L +* byte 1: X7 X6 X5 X4 X3 X2 X1 X0 +* byte 2: Y7 Y6 Y5 Y4 Y3 Y2 Y1 Y0 +* +* Note that the device never signals overflow condition. +* +* ALPS absolute Mode - new format * * byte 0: 1 ? ? ? 1 ? ? ? * byte 1: 0 x6 x5 x4 x3 x2 x1 x0 -* byte 2: 0 x10 x9 x8 x7 ? fin ges +* byte 2: 0 x10 x9 x8 x7 ? fin ges * byte 3: 0 y9 y8 y7 1 M R L * byte 4: 0 y6 y5 y4 y3 y2 y1 y0 * byte 5: 0 z6 z5 z4 z3 z2 z1 z0 * +* Dualpoint device -- interleaved packet format +* +* byte 0: 1 1 0 0 1 1 1 1 +* byte 1: 0 x6 x5 x4 x3 x2 x1 x0 +* byte 2: 0 x10 x9 x8 x7 0 fin ges +* byte 3: 0 0 YSGN XSGN 1 1 1 1 +* byte 4: X7 X6 X5 X4 X3 X2 X1 X0 +* byte 5: Y7 Y6 Y5 Y4 Y3 Y2 Y1 Y0 +* byte 6: 0 y9 y8 y7 1 m r l +* byte 7: 0 y6 y5 y4 y3 y2 y1 y0 +* byte 8: 0 z6 z5 z4 z3 z2 z1 z0 +* +* CAPITALS = stick, miniscules = touchpad +* * ?'s can have different meanings on different models, * such as wheel rotation, extra buttons, stick buttons * on a dualpoint, etc. */ +static bool alps_is_valid_first_byte (const struct alps_model_info *model, +unsigned char data) +{ +return (data & model->mask0) == model->byte0; +} + +static void alps_report_buttons (struct psmouse *psmouse, +struct input_dev *dev1,struct input_dev *dev2, +int left,int right,int middle) +{ +struct alps_data *priv = psmouse->private; +const struct alps_model_info *model = priv->i; + +if (model->flags &ALPS_PS2_INTERLEAVED ) { +struct input_dev *dev; + +/* +* If shared button has already been reported on the +* other device (dev2) then this event should be also +* sent through that device. +*/ + dev =test_bit (BTN_LEFT , dev2->key) ? dev2 : dev1; +input_report_key (dev,BTN_LEFT , left); + + dev =test_bit (BTN_RIGHT , dev2->key) ? dev2 : dev1; +input_report_key (dev,BTN_RIGHT , right); + + dev =test_bit (BTN_MIDDLE , dev2->key) ? dev2 : dev1; +input_report_key (dev,BTN_MIDDLE , middle); + +/* +* Sync the _other_ device now, we'll do the first +* device later once we report the rest of the events. +*/ +input_sync (dev2); + }else { +/* +* For devices with non-interleaved packets we know what +* device buttons belong to so we can simply report them. +*/ +input_report_key (dev1,BTN_LEFT , left); +input_report_key (dev1,BTN_RIGHT , right); +input_report_key (dev1,BTN_MIDDLE , middle); + } +} +static void alps_process_packet (struct psmouse *psmouse) {struct alps_data *priv = psmouse->private;
@@ -89,18 +162,6 @@ static void alps_process_packet(struct pint x, y, z, ges, fin, left, right, middle;int back =0 , forward =0 ; -if ((packet[0 ] &0xc8 ) ==0x08 ) {/* 3-byte PS/2 packet */ -input_report_key (dev2,BTN_LEFT , packet[0 ] &1 ); -input_report_key (dev2,BTN_RIGHT , packet[0 ] &2 ); -input_report_key (dev2,BTN_MIDDLE , packet[0 ] &4 ); -input_report_rel (dev2,REL_X , - packet[1 ] ? packet[1 ] - ((packet[0 ] <<4 ) &0x100 ) :0 ); -input_report_rel (dev2,REL_Y , - packet[2 ] ? ((packet[0 ] <<3 ) &0x100 ) - packet[2 ] :0 ); -input_sync (dev2); -return ; - } -if (priv->i->flags &ALPS_OLDPROTO ) { left = packet[2 ] &0x10 ; right = packet[2 ] &0x08 ;
@@ -136,18 +197,13 @@ static void alps_process_packet(struct pinput_report_rel (dev2,REL_X , (x >383 ? (x -768 ) : x));input_report_rel (dev2,REL_Y , -(y >255 ? (y -512 ) : y)); -input_report_key (dev2,BTN_LEFT , left); -input_report_key (dev2,BTN_RIGHT , right); -input_report_key (dev2,BTN_MIDDLE , middle); +alps_report_buttons (psmouse, dev2, dev, left, right, middle); -input_sync (dev);input_sync (dev2);return ; } -input_report_key (dev,BTN_LEFT , left); -input_report_key (dev,BTN_RIGHT , right); -input_report_key (dev,BTN_MIDDLE , middle); +alps_report_buttons (psmouse, dev, dev2, left, right, middle);/* Convert hardware tap to a reasonable Z value */ if (ges && !fin) z =40 ;
@@ -188,25 +244,168 @@ static void alps_process_packet(struct pinput_sync (dev); } +static void alps_report_bare_ps2_packet (struct psmouse *psmouse, +unsigned char packet[], +bool report_buttons) +{ +struct alps_data *priv = psmouse->private; +struct input_dev *dev2 = priv->dev2; + +if (report_buttons) +alps_report_buttons (psmouse, dev2, psmouse->dev, + packet[0 ] &1 , packet[0 ] &2 , packet[0 ] &4 ); + +input_report_rel (dev2,REL_X , + packet[1 ] ? packet[1 ] - ((packet[0 ] <<4 ) &0x100 ) :0 ); +input_report_rel (dev2,REL_Y , + packet[2 ] ? ((packet[0 ] <<3 ) &0x100 ) - packet[2 ] :0 ); + +input_sync (dev2); +} + +static psmouse_ret_t alps_handle_interleaved_ps2 (struct psmouse *psmouse) +{ +struct alps_data *priv = psmouse->private; + +if (psmouse->pktcnt <6 ) +return PSMOUSE_GOOD_DATA ; + +if (psmouse->pktcnt ==6 ) { +/* +* Start a timer to flush the packet if it ends up last +* 6-byte packet in the stream. Timer needs to fire +* psmouse core times out itself. 20 ms should be enough +* to decide if we are getting more data or not. +*/ +mod_timer (&priv->timer, jiffies +msecs_to_jiffies (20 )); +return PSMOUSE_GOOD_DATA ; + } + +del_timer (&priv->timer); + +if (psmouse->packet[6 ] &0x80 ) { + +/* +* Highest bit is set - that means we either had +* complete ALPS packet and this is start of the +* next packet or we got garbage. +*/ + +if (((psmouse->packet[3 ] | + psmouse->packet[4 ] | + psmouse->packet[5 ]) &0x80 ) || + (!alps_is_valid_first_byte (priv->i, psmouse->packet[6 ]))) { +dbg ("refusing packet %x %x %x %x " +"(suspected interleaved ps/2)\n" , + psmouse->packet[3 ], psmouse->packet[4 ], + psmouse->packet[5 ], psmouse->packet[6 ]); +return PSMOUSE_BAD_DATA ; + } + +alps_process_packet (psmouse); + +/* Continue with the next packet */ + psmouse->packet[0 ] = psmouse->packet[6 ]; + psmouse->pktcnt =1 ; + + }else { + +/* +* High bit is 0 - that means that we indeed got a PS/2 +* packet in the middle of ALPS packet. +* +* There is also possibility that we got 6-byte ALPS +* packet followed by 3-byte packet from trackpoint. We +* can not distinguish between these 2 scenarios but +* becase the latter is unlikely to happen in course of +* normal operation (user would need to press all +* buttons on the pad and start moving trackpoint +* without touching the pad surface) we assume former. +* Even if we are wrong the wost thing that would happen +* the cursor would jump but we should not get protocol +* desynchronization. +*/ + +alps_report_bare_ps2_packet (psmouse, &psmouse->packet[3 ], + false); + +/* +* Continue with the standard ALPS protocol handling, +* but make sure we won't process it as an interleaved +* packet again, which may happen if all buttons are +* pressed. To avoid this let's reset the 4th bit which +* is normally 1. +*/ + psmouse->packet[3 ] = psmouse->packet[6 ] &0xf7 ; + psmouse->pktcnt =4 ; + } + +return PSMOUSE_GOOD_DATA ; +} + +static void alps_flush_packet (unsigned long data) +{ +struct psmouse *psmouse = (struct psmouse *)data; + +serio_pause_rx (psmouse->ps2dev.serio); + +if (psmouse->pktcnt ==6 ) { + +/* +* We did not any more data in reasonable amount of time. +* Validate the last 3 bytes and process as a standard +* ALPS packet. +*/ +if ((psmouse->packet[3 ] | + psmouse->packet[4 ] | + psmouse->packet[5 ]) &0x80 ) { +dbg ("refusing packet %x %x %x " +"(suspected interleaved ps/2)\n" , + psmouse->packet[3 ], psmouse->packet[4 ], + psmouse->packet[5 ]); + }else { +alps_process_packet (psmouse); + } + psmouse->pktcnt =0 ; + } + +serio_continue_rx (psmouse->ps2dev.serio); +} +static psmouse_ret_t alps_process_byte (struct psmouse *psmouse) {struct alps_data *priv = psmouse->private; +const struct alps_model_info *model = priv->i;if ((psmouse->packet[0 ] &0xc8 ) ==0x08 ) {/* PS/2 packet */ if (psmouse->pktcnt ==3 ) { -alps_process_packet (psmouse); +alps_report_bare_ps2_packet (psmouse, psmouse->packet, + true);return PSMOUSE_FULL_PACKET ; }return PSMOUSE_GOOD_DATA ; } -if ((psmouse->packet[0 ] & priv->i->mask0) != priv->i->byte0) +/* Check for PS/2 packet stuffed in the middle of ALPS packet. */ + +if ((model->flags &ALPS_PS2_INTERLEAVED ) && + psmouse->pktcnt >=4 && (psmouse->packet[3 ] &0x0f ) ==0x0f ) { +return alps_handle_interleaved_ps2 (psmouse); + } + +if (!alps_is_valid_first_byte (model, psmouse->packet[0 ])) { +dbg ("refusing packet[0] = %x (mask0 = %x, byte0 = %x)\n" , + psmouse->packet[0 ], model->mask0, model->byte0);return PSMOUSE_BAD_DATA ; + }/* Bytes 2 - 6 should have 0 in the highest bit */ if (psmouse->pktcnt >=2 && psmouse->pktcnt <=6 && - (psmouse->packet[psmouse->pktcnt -1 ] &0x80 )) + (psmouse->packet[psmouse->pktcnt -1 ] &0x80 )) { +dbg ("refusing packet[%i] = %x\n" , + psmouse->pktcnt -1 , psmouse->packet[psmouse->pktcnt -1 ]);return PSMOUSE_BAD_DATA ; + }if (psmouse->pktcnt ==6 ) {alps_process_packet (psmouse);
@@ -445,6 +644,7 @@ static void alps_disconnect(struct psmoustruct alps_data *priv = psmouse->private;psmouse_reset (psmouse); +del_timer_sync (&priv->timer);input_unregister_device (priv->dev2);kfree (priv); }
@@ -461,6 +661,8 @@ int alps_init(struct psmouse *psmouse) goto init_fail; priv->dev2 = dev2; +setup_timer (&priv->timer, alps_flush_packet, (unsigned long )psmouse); + psmouse->private = priv;if (alps_hw_init (psmouse, &version))
drivers/input/mouse/alps.h +1 -0
@@ -23,6 +23,7 @@ struct alps_data {char phys[32 ];/* Phys */ const struct alps_model_info *i;/* Info */ int prev_fin;/* Finger bit from previous packet */ +struct timer_list timer; };#ifdef CONFIG_MOUSE_PS2_ALPS
PATCH 12/98 Driver-Core: devtmpfs - set root directory mode to 0755
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Kay Sievers <[email protected]>
commit 03d673e6af6490371aaf64dfe1f84c658c48b71d upstream.
--- drivers/base/devtmpfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/base/devtmpfs.c +1 -1
@@ -361,7 +361,7 @@ int __init devtmpfs_init(void)return err; } - mnt =kern_mount (&dev_fs_type); + mnt =kern_mount_data (&dev_fs_type,"mode=0755" );if (IS_ERR (mnt)) { err =PTR_ERR (mnt);printk (KERN_ERR "devtmpfs: unable to create devtmpfs %i\n" , err);
Re: [12/98] Driver-Core: devtmpfs - set root directory mode to 0755
Quoted 7 lines · Greg KH
2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Kay Sievers <[email protected]>
commit
03d673e6af6490371aaf64dfe1f84c658c48b71dupstream.
Hey Greg,
to silent a warning this change causes, this might also be good to have:
vfs: get_sb_single() - do not pass options twice
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=9329d1beaeed1a94f030c784dcec5ff973f402c4
Thanks,
Kay
Re: [12/98] Driver-Core: devtmpfs - set root directory mode to 0755
Quoted 5 lines · Kay Sievers
Quoted 4 lines · Greg KH
2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
Quoted 8 lines
Quoted 3 lines
From: Kay Sievers <[email protected]>
commit
03d673e6af6490371aaf64dfe1f84c658c48b71dupstream.Hey Greg,
to silent a warning this change causes, this might also be good to have:
vfs:get_sb_single()- do not pass options twice
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=9329d1beaeed1a94f030c784dcec5ff973f402c4
You are right, thanks for pointing that out, I've queued it up as well.
thanks,
greg k-h
PATCH 13/98 driver-core: fix devtmpfs crash on s390
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Heiko Carstens <[email protected]>
commit f776c5ec4690b21b3668ad5956774a22c86f541a upstream.
Quoted 37 lines · Sachin Sant
Hello Heiko,
Today while trying to boot next-20100118 i came across the following Oops :
Brought up 4 CPUs
Unable to handle kernel pointer dereference at virtual kernel address 0000000000 543000 Oops: 0004 #1 SMP Modules linked in: CPU: 0 Not tainted 2.6.33-rc4-autotest-next-20100118-5-default #1 Process swapper (pid: 1, task: 00000000fd792038, ksp: 00000000fd797a30) Krnl PSW : 0704200180000000 00000000001eb0b8 (shmem_parse_options+0xc0/0x328) R:0 T:1 IO:1 EX:1 Key:0 M:1 W:0 P:0 AS:0 CC:2 PM:0 EA:3 Krnl GPRS: 000000000054388a 000000000000003d 0000000000543836 000000000000003d 0000000000000000 0000000000483f28 0000000000536112 00000000fd797d00 00000000fd4ba100 0000000000000100 0000000000483978 0000000000543832 0000000000000000 0000000000465958 00000000001eb0b0 00000000fd797c58 Krnl Code: 00000000001eb0aa: c0e5000994f1 brasl %r14,31da8c 00000000001eb0b0: b9020022 ltgr %r2,%r2 00000000001eb0b4: a784010b brc 8,1eb2ca >00000000001eb0b8: 92002000 mvi 0(%r2),0 00000000001eb0bc: a7080000 lhi %r0,0 00000000001eb0c0: 41902001 la %r9,1(%r2) 00000000001eb0c4: b9040016 lgr %r1,%r6 00000000001eb0c8: b904002b lgr %r2,%r11 Call Trace:(<
00000000fd797c50>0xfd797c50)
<00000000001eb5da>shmem_fill_super+0x13a/0x25c
<0000000000228cfa>get_sb_single+0xbe/0xdc
<000000000034ffc0>dev_get_sb+0x2c/0x38
<000000000066c602>devtmpfs_init+0x46/0xc0
<000000000066c53e>driver_init+0x22/0x60
<000000000064d40a>kernel_init+0x24e/0x3d0
<000000000010a7ea>kernel_thread_starter+0x6/0xc
<000000000010a7e4>kernel_thread_starter+0x0/0xc
Quoted 3 lines
I never tried to boot a kernel with DEVTMPFS enabled on a s390 box. So am wondering if this is supported or not ? If you think this is supported i will send a mail to community on this.
There is nothing arch specific to devtmpfs. This part crashes because the kernel tries to modify the data read-only section which is write protected on s390.
--- drivers/base/devtmpfs.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/base/devtmpfs.c +2 -1
@@ -353,6 +353,7 @@ int __init devtmpfs_init(void) {int err;struct vfsmount *mnt; +char options[] ="mode=0755" ; err =register_filesystem (&dev_fs_type);if (err) {
@@ -361,7 +362,7 @@ int __init devtmpfs_init(void)return err; } - mnt =kern_mount_data (&dev_fs_type,"mode=0755" ); + mnt =kern_mount_data (&dev_fs_type, options);if (IS_ERR (mnt)) { err =PTR_ERR (mnt);printk (KERN_ERR "devtmpfs: unable to create devtmpfs %i\n" , err);
PATCH 14/98 ALSA: hda - Add PCI IDs for Nvidia G2xx-series
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Stefan Ringel <[email protected]>
commit 6dd7dc767e35cfbb38f8c63a50b1c27acad25920 upstream.
--- sound/pci/hda/hda_intel.c | 3 +++ 1 file changed, 3 insertions(+)
sound/pci/hda/hda_intel.c +3 -0
@@ -2694,6 +2694,9 @@ static struct pci_device_id azx_ids[] = { PCI_DEVICE(0x10de, 0x0ac1), .driver_data = AZX_DRIVER_NVIDIA }, { PCI_DEVICE(0x10de, 0x0ac2), .driver_data = AZX_DRIVER_NVIDIA }, { PCI_DEVICE(0x10de, 0x0ac3), .driver_data = AZX_DRIVER_NVIDIA }, + { PCI_DEVICE(0x10de, 0x0be2), .driver_data = AZX_DRIVER_NVIDIA }, + { PCI_DEVICE(0x10de, 0x0be3), .driver_data = AZX_DRIVER_NVIDIA }, + { PCI_DEVICE(0x10de, 0x0be4), .driver_data = AZX_DRIVER_NVIDIA }, { PCI_DEVICE(0x10de, 0x0d94), .driver_data = AZX_DRIVER_NVIDIA }, { PCI_DEVICE(0x10de, 0x0d95), .driver_data = AZX_DRIVER_NVIDIA }, { PCI_DEVICE(0x10de, 0x0d96), .driver_data = AZX_DRIVER_NVIDIA },
PATCH 15/98 V4L/DVB (13569): smsusb: add autodetection support for five additional Hauppauge USB IDs
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Michael Krufky <[email protected]>
commit 20d15a200d34cfb7141fb4558895d7d5233db84b upstream.
Add support for five new Hauppauge Device USB IDs:
2040:b980
2040:b990
2040:c010
2040:c080
2040:c090
--- drivers/media/dvb/siano/smsusb.c | 10 ++++++++++ 1 file changed, 10 insertions(+)
drivers/media/dvb/siano/smsusb.c +10 -0
@@ -533,8 +533,18 @@ struct usb_device_id smsusb_id_table[] = .driver_info = SMS1XXX_BOARD_HAUPPAUGE_WINDHAM }, { USB_DEVICE(0x2040, 0xb910), .driver_info = SMS1XXX_BOARD_HAUPPAUGE_WINDHAM }, + { USB_DEVICE(0x2040, 0xb980), + .driver_info = SMS1XXX_BOARD_HAUPPAUGE_WINDHAM }, + { USB_DEVICE(0x2040, 0xb990), + .driver_info = SMS1XXX_BOARD_HAUPPAUGE_WINDHAM }, { USB_DEVICE(0x2040, 0xc000), .driver_info = SMS1XXX_BOARD_HAUPPAUGE_WINDHAM }, + { USB_DEVICE(0x2040, 0xc010), + .driver_info = SMS1XXX_BOARD_HAUPPAUGE_WINDHAM }, + { USB_DEVICE(0x2040, 0xc080), + .driver_info = SMS1XXX_BOARD_HAUPPAUGE_WINDHAM }, + { USB_DEVICE(0x2040, 0xc090), + .driver_info = SMS1XXX_BOARD_HAUPPAUGE_WINDHAM }, { } /* Terminating entry */ };
PATCH 16/98 USB: mos7840: add device IDs for B&B electronics devices
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Cliff Brake <[email protected]>
commit acf509ae28301d78b022c534c26b1e4765c18f2b upstream.
--- drivers/usb/serial/mos7840.c | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-)
drivers/usb/serial/mos7840.c +21 -3
@@ -121,8 +121,14 @@* moschip_id_table_combined */ #define USB_VENDOR_ID_BANDB 0x0856 -#define BANDB_DEVICE_ID_USOPTL4_4 0xAC44 +#define BANDB_DEVICE_ID_USO9ML2_2 0xAC22 +#define BANDB_DEVICE_ID_USO9ML2_4 0xAC24 +#define BANDB_DEVICE_ID_US9ML2_2 0xAC29 +#define BANDB_DEVICE_ID_US9ML2_4 0xAC30 +#define BANDB_DEVICE_ID_USPTL4_2 0xAC31 +#define BANDB_DEVICE_ID_USPTL4_4 0xAC32#define BANDB_DEVICE_ID_USOPTL4_2 0xAC42 +#define BANDB_DEVICE_ID_USOPTL4_4 0xAC44/* This driver also supports * ATEN UC2324 device using Moschip MCS7840
@@ -177,8 +183,14 @@static struct usb_device_id moschip_port_id_table[] = { {USB_DEVICE (USB_VENDOR_ID_MOSCHIP ,MOSCHIP_DEVICE_ID_7840 )}, {USB_DEVICE (USB_VENDOR_ID_MOSCHIP ,MOSCHIP_DEVICE_ID_7820 )}, - {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USOPTL4_4 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USO9ML2_2 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USO9ML2_4 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_US9ML2_2 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_US9ML2_4 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USPTL4_2 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USPTL4_4 )}, {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USOPTL4_2 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USOPTL4_4 )}, {USB_DEVICE (USB_VENDOR_ID_ATENINTL ,ATENINTL_DEVICE_ID_UC2324 )}, {USB_DEVICE (USB_VENDOR_ID_ATENINTL ,ATENINTL_DEVICE_ID_UC2322 )}, {}/* terminating entry */
@@ -187,8 +199,14 @@ static struct usb_device_id moschip_portstatic __devinitdata struct usb_device_id moschip_id_table_combined[] = { {USB_DEVICE (USB_VENDOR_ID_MOSCHIP ,MOSCHIP_DEVICE_ID_7840 )}, {USB_DEVICE (USB_VENDOR_ID_MOSCHIP ,MOSCHIP_DEVICE_ID_7820 )}, - {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USOPTL4_4 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USO9ML2_2 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USO9ML2_4 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_US9ML2_2 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_US9ML2_4 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USPTL4_2 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USPTL4_4 )}, {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USOPTL4_2 )}, + {USB_DEVICE (USB_VENDOR_ID_BANDB ,BANDB_DEVICE_ID_USOPTL4_4 )}, {USB_DEVICE (USB_VENDOR_ID_ATENINTL ,ATENINTL_DEVICE_ID_UC2324 )}, {USB_DEVICE (USB_VENDOR_ID_ATENINTL ,ATENINTL_DEVICE_ID_UC2322 )}, {}/* terminating entry */
PATCH 17/98 USB: ftdi_sio: add USB device IDs for B&B Electronics line
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Cliff Brake <[email protected]>
commit a8cbd90a0410096e152f68a4e114a8b5c7abb49b upstream.
--- drivers/usb/serial/ftdi_sio.c | 14 ++++++++++++++ drivers/usb/serial/ftdi_sio.h | 14 ++++++++++++++ 2 files changed, 28 insertions(+)
drivers/usb/serial/ftdi_sio.c +14 -0
@@ -598,6 +598,20 @@ static struct usb_device_id id_table_com { USB_DEVICE(BANDB_VID, BANDB_USOTL4_PID) }, { USB_DEVICE(BANDB_VID, BANDB_USTL4_PID) }, { USB_DEVICE(BANDB_VID, BANDB_USO9ML2_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_USOPTL4_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_USPTL4_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_USO9ML2DR_2_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_USO9ML2DR_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_USOPTL4DR2_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_USOPTL4DR_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_485USB9F_2W_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_485USB9F_4W_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_232USB9M_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_485USBTB_2W_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_485USBTB_4W_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_TTL5USB9M_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_TTL3USB9M_PID) }, + { USB_DEVICE(BANDB_VID, BANDB_ZZ_PROG1_USB_PID) }, { USB_DEVICE(FTDI_VID, EVER_ECO_PRO_CDS) }, { USB_DEVICE(FTDI_VID, FTDI_4N_GALAXY_DE_1_PID) }, { USB_DEVICE(FTDI_VID, FTDI_4N_GALAXY_DE_2_PID) },
drivers/usb/serial/ftdi_sio.h +14 -0
@@ -662,6 +662,20 @@#define BANDB_USOTL4_PID 0xAC01/* USOTL4 Isolated RS-485 Converter */ #define BANDB_USTL4_PID 0xAC02/* USTL4 RS-485 Converter */ #define BANDB_USO9ML2_PID 0xAC03/* USO9ML2 Isolated RS-232 Converter */ +#define BANDB_USOPTL4_PID 0xAC11 +#define BANDB_USPTL4_PID 0xAC12 +#define BANDB_USO9ML2DR_2_PID 0xAC16 +#define BANDB_USO9ML2DR_PID 0xAC17 +#define BANDB_USOPTL4DR2_PID 0xAC18/* USOPTL4R-2 2-port Isolated RS-232 Converter */ +#define BANDB_USOPTL4DR_PID 0xAC19 +#define BANDB_485USB9F_2W_PID 0xAC25 +#define BANDB_485USB9F_4W_PID 0xAC26 +#define BANDB_232USB9M_PID 0xAC27 +#define BANDB_485USBTB_2W_PID 0xAC33 +#define BANDB_485USBTB_4W_PID 0xAC34 +#define BANDB_TTL5USB9M_PID 0xAC49 +#define BANDB_TTL3USB9M_PID 0xAC50 +#define BANDB_ZZ_PROG1_USB_PID 0xBA02/* * RM Michaelides CANview USB (http://www.rmcan.com)
PATCH 18/98 V4L/DVB (13168): Add support for Asus Europa Hybrid DVB-T card (SAA7134 SubVendor ID: 0x1043 Device ID: 0x4847)
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Danny Wood <[email protected]>
commit e3c6e1aaa5db7822524f5b1355960fd732910068 upstream.
Adds the device IDs and driver linking to allow the Asus Europa DVB-T card to operate with these drivers.
The device has a SAA7134 chipset with a TD1316 Hybrid Tuner. All inputs work on the card including switching between DVB-T and Analogue TV, there is also no IR with this card.
[[email protected]: CodingStyle fixes]
--- Documentation/video4linux/CARDLIST.saa7134 | 1 drivers/media/video/saa7134/saa7134-cards.c | 31 ++++++++++++++++++++++++++++ drivers/media/video/saa7134/saa7134-dvb.c | 1 drivers/media/video/saa7134/saa7134.h | 1 4 files changed, 34 insertions(+)
Documentation/video4linux/CARDLIST.saa7134 +1 -0
@@ -172,3 +172,4 @@ 171 -> Beholder BeholdTV X7 [5ace:7595] 172 -> RoverMedia TV Link Pro FM [19d1:0138] 173 -> Zolid Hybrid TV Tuner PCI [1131:2004] +174 -> Asus Europa Hybrid OEM [1043:4847]
drivers/media/video/saa7134/saa7134-cards.c +31 -0
@@ -5279,6 +5279,30 @@ struct saa7134_board saa7134_boards[] = .amux = TV, }, }, + [SAA7134_BOARD_ASUS_EUROPA_HYBRID ] = { + .name ="Asus Europa Hybrid OEM" , + .audio_clock =0x00187de7 , + .tuner_type =TUNER_PHILIPS_TD1316 , + .radio_type =UNSET , + .tuner_addr =0x61 , + .radio_addr =ADDR_UNSET , + .tda9887_conf =TDA9887_PRESENT |TDA9887_PORT1_ACTIVE , + .mpeg =SAA7134_MPEG_DVB , + .inputs = { { + .name = name_tv, + .vmux =3 , + .amux =TV , + .tv =1 , + }, { + .name = name_comp1, + .vmux =4 , + .amux =LINE2 , + }, { + .name = name_svideo, + .vmux =8 , + .amux =LINE2 , + } }, + }, };
@@ -6418,6 +6442,12 @@ struct pci_device_id saa7134_pci_tbl[] = .subdevice = 0x2004, .driver_data = SAA7134_BOARD_ZOLID_HYBRID_PCI, }, { + .vendor = PCI_VENDOR_ID_PHILIPS, + .device = PCI_DEVICE_ID_PHILIPS_SAA7134, + .subvendor = 0x1043, + .subdevice = 0x4847, + .driver_data = SAA7134_BOARD_ASUS_EUROPA_HYBRID, + }, {/* --- boards without eeprom + subsystem ID --- */ .vendor = PCI_VENDOR_ID_PHILIPS, .device = PCI_DEVICE_ID_PHILIPS_SAA7134,
@@ -7079,6 +7109,7 @@ int saa7134_board_init2(struct saa7134_d/* break intentionally omitted */ case SAA7134_BOARD_VIDEOMATE_DVBT_300 :case SAA7134_BOARD_ASUS_EUROPA2_HYBRID : +case SAA7134_BOARD_ASUS_EUROPA_HYBRID : {/* The Philips EUROPA based hybrid boards have the tuner
drivers/media/video/saa7134/saa7134-dvb.c +1 -0
@@ -1116,6 +1116,7 @@ static int dvb_init(struct saa7134_dev *break ;case SAA7134_BOARD_PHILIPS_EUROPA :case SAA7134_BOARD_VIDEOMATE_DVBT_300 : +case SAA7134_BOARD_ASUS_EUROPA_HYBRID : fe0->dvb.frontend =dvb_attach (tda10046_attach, &philips_europa_config, &dev->i2c_adap);
drivers/media/video/saa7134/saa7134.h +1 -0
@@ -297,6 +297,7 @@ struct saa7134_format {#define SAA7134_BOARD_BEHOLD_X7 171#define SAA7134_BOARD_ROVERMEDIA_LINK_PRO_FM 172#define SAA7134_BOARD_ZOLID_HYBRID_PCI 173 +#define SAA7134_BOARD_ASUS_EUROPA_HYBRID 174#define SAA7134_MAXBOARDS 32#define SAA7134_INPUT_MAX 8
PATCH 19/98 iTCO_wdt: Add support for Intel Ibex Peak
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Seth Heasley <[email protected]>
commit 79e8941dda254505bb8af37b3a009165dfb7e98a upstream.
Add the Intel Ibex Peak (PCH) Device IDs to iTCO_wdt.c.
--- drivers/watchdog/iTCO_wdt.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-)
drivers/watchdog/iTCO_wdt.c +12 -1
@@ -54,7 +54,9 @@* 82801JIB (ICH10) : document number 319973-002, 319974-002, * 82801JIR (ICH10R) : document number 319973-002, 319974-002, * 82801JD (ICH10D) : document number 319973-002, 319974-002, -* 82801JDO (ICH10DO) : document number 319973-002, 319974-002 +* 82801JDO (ICH10DO) : document number 319973-002, 319974-002, +* 5 Series (PCH) : document number 322169-001, 322170-001, +* 3400 Series (PCH) : document number 322169-001, 322170-001 */ /*
@@ -122,6 +124,9 @@ enum iTCO_chipsets {TCO_ICH10R ,/* ICH10R */ TCO_ICH10D ,/* ICH10D */ TCO_ICH10DO ,/* ICH10DO */ +TCO_PCH ,/* PCH Desktop Full Featured */ +TCO_PCHM ,/* PCH Mobile Full Featured */ + TCO_PCHMSFF, /* PCH Mobile SFF Full Featured */ }; static struct {
@@ -162,6 +167,9 @@ static struct { {"ICH10R", 2}, {"ICH10D", 2}, {"ICH10DO", 2}, + {"PCH Desktop Full Featured", 2}, + {"PCH Mobile Full Featured", 2}, + {"PCH Mobile SFF Full Featured", 2}, {NULL, 0} };
@@ -230,6 +238,9 @@ static struct pci_device_id iTCO_wdt_pci { ITCO_PCI_DEVICE(0x3a16, TCO_ICH10R)}, { ITCO_PCI_DEVICE(0x3a1a, TCO_ICH10D)}, { ITCO_PCI_DEVICE(0x3a14, TCO_ICH10DO)}, + { ITCO_PCI_DEVICE(0x3b00, TCO_PCH)}, + { ITCO_PCI_DEVICE(0x3b01, TCO_PCHM)}, + { ITCO_PCI_DEVICE(0x3b0d, TCO_PCHMSFF)}, { 0, }, /* End of list */ };MODULE_DEVICE_TABLE (pci, iTCO_wdt_pci_tbl);
PATCH 20/98 atl1c:use common_task instead of reset_task and link_chg_task
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Jie Yang <[email protected]>
commit cb19054697e92a793f336380fd72c588521178ff upstream.
use common_task instead of reset_task and link_chg_task, so it fix "call cancel_work_sync from the work itself".
--- drivers/net/atl1c/atl1c.h | 6 ++- drivers/net/atl1c/atl1c_main.c | 72 ++++++++++++++++++----------------------- 2 files changed, 37 insertions(+), 41 deletions(-)
drivers/net/atl1c/atl1c.h +4 -2
@@ -534,6 +534,9 @@ struct atl1c_adapter {#define __AT_TESTING 0x0001#define __AT_RESETTING 0x0002#define __AT_DOWN 0x0003 +u8 work_event; +#define ATL1C_WORK_EVENT_RESET 0x01 +#define ATL1C_WORK_EVENT_LINK_CHANGE 0x02u32 msg_enable;bool have_msi;
@@ -545,8 +548,7 @@ struct atl1c_adapter {spinlock_t tx_lock;atomic_t irq_sem; -struct work_struct reset_task; -struct work_struct link_chg_task; +struct work_struct common_task;struct timer_list watchdog_timer;struct timer_list phy_config_timer;
drivers/net/atl1c/atl1c_main.c +33 -39
128 lines not on this page · raw message
Re: [Stable-review] [20/98] atl1c:use common_task instead of reset_task and link_chg_task
Quoted 11 lines · Greg KH
From: Jie Yang <[email protected]>
commit
cb19054697e92a793f336380fd72c588521178ffupstream.use
common_taskinstead ofreset_taskandlink_chg_task, so it fix "callcancel_work_syncfrom the work itself".Signed-off-by Jie Yang <[email protected]>Signed-off-by David S. Miller <[email protected]>Cc Ben Hutchings <[email protected]>Signed-off-by Greg Kroah-Hartman <[email protected]>
I'm going to test this one. I'm randomly seeing my ASUS 1005HA hanging after I replug the network cable. I noticed that the driver from the Atheros site doesn't have the issue at all. I spent a week-end trying to eliminate almost all of the diffs between the two drivers to try to spot the faulty code chunk, until I realized that I went past the failure point without noticing in time because the issue was too much random :-(
Clearly a non-bisectable issue. But with just this fix, I'll be able to tell if the problem is definitely over.
Regards,
Willy
Re: [Stable-review] [20/98] atl1c:use common_task instead of reset_task and link_chg_task
Quoted 13 lines · Willy Tarreau
Quoted 11 lines · Greg KH
From: Jie Yang <[email protected]>
commit
cb19054697e92a793f336380fd72c588521178ffupstream.use
common_taskinstead ofreset_taskandlink_chg_task, so it fix "callcancel_work_syncfrom the work itself".Signed-off-by Jie Yang <[email protected]>Signed-off-by David S. Miller <[email protected]>Cc Ben Hutchings <[email protected]>Signed-off-by Greg Kroah-Hartman <[email protected]>
Quoted 7 lines
I'm going to test this one. I'm randomly seeing my ASUS 1005HA hanging after I replug the network cable. I noticed that the driver from the Atheros site doesn't have the issue at all. I spent a week-end trying to eliminate almost all of the diffs between the two drivers to try to spot the faulty code chunk, until I realized that I went past the failure point without noticing in time because the issue was too much random :-(
Not sure how much this is true or helps. While looking over that patch I was wondering whether there could be a problem of not having an explicit cancel_work_sync on the way down. It just seems to disable actions by setting the flags to 0 but I somehow it felt like it still could be scheduled to run doing nothing...
-Stefan
Quoted 10 lines
Clearly a non-bisectable issue. But with just this fix, I'll be able to tell if the problem is definitely over.
Regards,
Willy_______________________________________________
Stable-review mailing list
[email protected]
http://linux.kernel.org/mailman/listinfo/stable-review
Re: [Stable-review] [20/98] atl1c:use common_task instead of reset_task and link_chg_task
In reply to Willy TarreauQuoted 21 lines · Willy Tarreau
Quoted 11 lines · Greg KH
From: Jie Yang <[email protected]>
commit
cb19054697e92a793f336380fd72c588521178ffupstream.use
common_taskinstead ofreset_taskandlink_chg_task, so it fix "callcancel_work_syncfrom the work itself".Signed-off-by Jie Yang <[email protected]>Signed-off-by David S. Miller <[email protected]>Cc Ben Hutchings <[email protected]>Signed-off-by Greg Kroah-Hartman <[email protected]>I'm going to test this one. I'm randomly seeing my ASUS 1005HA hanging after I replug the network cable. I noticed that the driver from the Atheros site doesn't have the issue at all. I spent a week-end trying to eliminate almost all of the diffs between the two drivers to try to spot the faulty code chunk, until I realized that I went past the failure point without noticing in time because the issue was too much random :-(
Quoted 2 lines
Clearly a non-bisectable issue. But with just this fix, I'll be able to tell if the problem is definitely over.
For the record, this patch has fixed my issue, the machine no longer hangs when I plug the cable. However, now when I unplug then replug the link, it normally takes 1 second to get back up, until I suspend. After the first suspend/resume cycle, it always takes 16 seconds to get the link up every time I unplug/replug it. If I wait before replugging, it gets up later (by the amount of time spent unplugged). Same if I unplug, wait a bit, then replug/unplug then replug. It still takes 16 seconds after the moment I last plugged the wire to get the link up. The link on the switch goes up at the same time as the message appears.
It makes no difference whether I use S2R or S2D.
It's not dramatical, but I suspect it's a bug in the suspend/ resume code which maybe does not reinitialize a hardware timer, though I have no idea where to look for.
Anyway, the most important is that it does not freeze anymore !
Thanks,
Willy
PATCH 21/98 atl1e:disable NETIF_F_TSO6 for hardware limit
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Jie Yang <[email protected]>
commit 7c7afb083675b3d4d012a2aacec3a958ba484ab0 upstream.
For hardware limit to support TSOV6, just disable this feature
--- drivers/net/atl1e/atl1e_main.c | 36 ------------------------------------ 1 file changed, 36 deletions(-)
drivers/net/atl1e/atl1e_main.c +0 -36
@@ -1666,41 +1666,6 @@ static int atl1e_tso_csum(struct atl1e_a }return 0 ; } - -if (offload_type &SKB_GSO_TCPV6 ) { - real_len = (((unsigned char *)ipv6_hdr (skb) - skb->data) - +ntohs (ipv6_hdr (skb)->payload_len)); -if (real_len < skb->len) -pskb_trim (skb, real_len); - -/* check payload == 0 byte ? */ - hdr_len = (skb_transport_offset (skb) +tcp_hdrlen (skb)); -if (unlikely (skb->len == hdr_len)) { -/* only xsum need */ -dev_warn (&pdev->dev, -"IPV6 tso with zero data??\n" ); - goto check_sum; - }else { -tcp_hdr (skb)->check = ~csum_ipv6_magic ( - &ipv6_hdr (skb)->saddr, - &ipv6_hdr (skb)->daddr, -0 ,IPPROTO_TCP ,0 ); - tpd->word3 |=1 <<TPD_IP_VERSION_SHIFT ; - hdr_len >>=1 ; - tpd->word3 |= (hdr_len &TPD_V6_IPHLLO_MASK ) << -TPD_V6_IPHLLO_SHIFT ; - tpd->word3 |= ((hdr_len >>3 ) & -TPD_V6_IPHLHI_MASK ) << -TPD_V6_IPHLHI_SHIFT ; - tpd->word3 |= (tcp_hdrlen (skb) >>2 & -TPD_TCPHDRLEN_MASK ) << -TPD_TCPHDRLEN_SHIFT ; - tpd->word3 |= ((skb_shinfo (skb)->gso_size) & -TPD_MSS_MASK ) <<TPD_MSS_SHIFT ; - tpd->word3 |=1 <<TPD_SEGMENT_EN_SHIFT ; - } - } -return 0 ; } check_sum:
@@ -2289,7 +2254,6 @@ static int atl1e_init_netdev(struct net_NETIF_F_HW_VLAN_TX |NETIF_F_HW_VLAN_RX ; netdev->features |=NETIF_F_LLTX ; netdev->features |=NETIF_F_TSO ; - netdev->features |=NETIF_F_TSO6 ;return 0 ; }
PATCH 22/98 V4L/DVB (13680a): DocBook/media: copy images after building HTML
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ben Hutchings <[email protected]>
commit 49b14650ba5bf80234cb1984fd8396aff03430ce upstream.
The rule for %.html removes the output directory, so there is no point in copying images before building HTML.
Documentation/DocBook/Makefile | 10 +++++-----
--- Documentation/DocBook/Makefile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)
Documentation/DocBook/Makefile +5 -5
@@ -32,7 +32,7 @@ PS_METHOD = $(prefer-db2x) ### # The targets that may be used. -PHONY += xmldocs sgmldocs psdocs pdfdocs htmldocs mandocs installmandocs cleandocs media +PHONY += xmldocs sgmldocs psdocs pdfdocs htmldocs mandocs installmandocs cleandocs BOOKS := $(addprefix $(obj)/,$(DOCBOOKS)) xmldocs: $(BOOKS)
@@ -45,15 +45,15 @@ PDF := $(patsubst %.xml, %.pdf, $(BOOKS) pdfdocs: $(PDF) HTML := $(sort $(patsubst %.xml, %.html, $(BOOKS))) -htmldocs: media $(HTML) +htmldocs: $(HTML) $(call build_main_index) + $(call build_images) MAN := $(patsubst %.xml, %.9, $(BOOKS)) mandocs: $(MAN) -media: - mkdir -p $(srctree)/Documentation/DocBook/media/ - cp $(srctree)/Documentation/DocBook/dvb/*.png $(srctree)/Documentation/DocBook/v4l/*.gif $(srctree)/Documentation/DocBook/media/ +build_images = mkdir -p $(objtree)/Documentation/DocBook/media/ && \ + cp $(srctree)/Documentation/DocBook/dvb/*.png $(srctree)/Documentation/DocBook/v4l/*.gif $(objtree)/Documentation/DocBook/media/ installmandocs: mandocs mkdir -p /usr/local/man/man9/
PATCH 23/98 V4L/DVB (13680b): DocBook/media: create links for included sources
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ben Hutchings <[email protected]>
commit 5bf583473813530c1bf82051a35fac8d5045f4f7 upstream.
If docs are being built in a separate directory, xmlto and xsltproc can't find included sources. Make links back to the source directory.
I would much prefer to have xmlto and xsltproc look in the source directory for included entities but couldn't see how to do that. This needs to be solved in some way for 2.6.32, even if this patch isn't the right way to do it.
--- Documentation/DocBook/Makefile | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-)
Documentation/DocBook/Makefile +11 -2
@@ -32,10 +32,10 @@ PS_METHOD = $(prefer-db2x) ### # The targets that may be used. -PHONY += xmldocs sgmldocs psdocs pdfdocs htmldocs mandocs installmandocs cleandocs +PHONY += xmldocs sgmldocs psdocs pdfdocs htmldocs mandocs installmandocs cleandocs xmldoclinks BOOKS := $(addprefix $(obj)/,$(DOCBOOKS)) -xmldocs: $(BOOKS) +xmldocs: $(BOOKS) xmldoclinks sgmldocs: xmldocs PS := $(patsubst %.xml, %.ps, $(BOOKS))
@@ -55,6 +55,15 @@ mandocs: $(MAN) build_images = mkdir -p $(objtree)/Documentation/DocBook/media/ && \ cp $(srctree)/Documentation/DocBook/dvb/*.png $(srctree)/Documentation/DocBook/v4l/*.gif $(objtree)/Documentation/DocBook/media/ +xmldoclinks: +ifneq ($(objtree),$(srctree)) + for dep in dvb media-entities.tmpl media-indices.tmpl v4l; do \ + rm -f $(objtree)/Documentation/DocBook/$$dep \ + && ln -s $(srctree)/Documentation/DocBook/$$dep $(objtree)/Documentation/DocBook/ \ + || exit; \ + done +endif + installmandocs: mandocs mkdir -p /usr/local/man/man9/ install Documentation/DocBook/man/*.9.gz /usr/local/man/man9/
PATCH 24/98 netfilter: xtables: fix conntrack match v1 ipt-save output
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Florian Westphal <[email protected]>
commit 3a0429292daa0e1ec848bd26479f5e48b0d54a42 upstream.
commit d6d3f08b0fd998b647a05540cedd11a067b72867 (netfilter: xtables: conntrack match revision 2) does break the v1 conntrack match iptables-save output in a subtle way.
Problem is as follows:
up = kmalloc(sizeof(*up), GFP_KERNEL);
[..]
/*
* The strategy here is to minimize the overhead of v1 matching,
* by prebuilding a v2 struct and putting the pointer into the
* v1 dataspace.
*/
memcpy(up, info, offsetof(typeof(*info), state_mask));
[..]
*(void **)info = up;
As the v2 struct pointer is saved in the match data space, it clobbers the first structure member (->origsrc_addr).
Because the _v1 match function grabs this pointer and does not actually look at the v1 origsrc, run time functionality does not break. But iptables -nvL (or iptables-save) cannot know that v1 origsrc_addr has been overloaded in this way:
$ iptables -p tcp -A OUTPUT -m conntrack --ctorigsrc 10.0.0.1 -j ACCEPT $ iptables-save -A OUTPUT -p tcp -m conntrack --ctorigsrc 128.173.134.206 -j ACCEPT
(128.173... is the address to the v2 match structure).
To fix this, we take advantage of the fact that the v1 and v2 structures are identical with exception of the last two structure members (u8 in v1, u16 in v2).
We extract them as early as possible and prevent the v2 matching function from looking at those two members directly.
Previously reported by Michel Messerschmidt via Ben Hutchings, also see Debian Bug tracker #556587.
--- net/netfilter/xt_conntrack.c | 61 +++++++++++-------------------------------- 1 file changed, 17 insertions(+), 44 deletions(-)
net/netfilter/xt_conntrack.c +17 -44
@@ -113,7 +113,8 @@ ct_proto_port_check(const struct xt_conn }static bool -conntrack_mt (const struct sk_buff *skb,const struct xt_match_param *par) +conntrack_mt (const struct sk_buff *skb,const struct xt_match_param *par, +u16 state_mask,u16 status_mask) {const struct xt_conntrack_mtinfo2 *info = par->matchinfo;enum ip_conntrack_info ctinfo;
@@ -136,7 +137,7 @@ conntrack_mt(const struct sk_buff *skb,if (test_bit (IPS_DST_NAT_BIT , &ct->status)) statebit |=XT_CONNTRACK_STATE_DNAT ; } -if (!!(info->state_mask & statebit) ^ +if (!!(state_mask & statebit) ^ !(info->invert_flags &XT_CONNTRACK_STATE ))return false; }
@@ -172,7 +173,7 @@ conntrack_mt(const struct sk_buff *skb,return false;if ((info->match_flags &XT_CONNTRACK_STATUS ) && - (!!(info->status_mask & ct->status) ^ + (!!(status_mask & ct->status) ^ !(info->invert_flags &XT_CONNTRACK_STATUS )))return false;
@@ -192,11 +193,17 @@ conntrack_mt(const struct sk_buff *skb,static bool conntrack_mt_v1 (const struct sk_buff *skb,const struct xt_match_param *par) { -const struct xt_conntrack_mtinfo2 *const *info = par->matchinfo; -struct xt_match_param newpar = *par; +const struct xt_conntrack_mtinfo1 *info = par->matchinfo; - newpar.matchinfo = *info; -return conntrack_mt (skb, &newpar); +return conntrack_mt (skb, par, info->state_mask, info->status_mask); +} + +static bool +conntrack_mt_v2 (const struct sk_buff *skb,const struct xt_match_param *par) +{ +const struct xt_conntrack_mtinfo2 *info = par->matchinfo; + +return conntrack_mt (skb, par, info->state_mask, info->status_mask); }static bool conntrack_mt_check (const struct xt_mtchk_param *par)
@@ -209,45 +216,11 @@ static bool conntrack_mt_check(const strreturn true; } -static bool conntrack_mt_check_v1 (const struct xt_mtchk_param *par) -{ -struct xt_conntrack_mtinfo1 *info = par->matchinfo; -struct xt_conntrack_mtinfo2 *up; -int ret =conntrack_mt_check (par); - -if (ret <0 ) -return ret; - - up =kmalloc (sizeof (*up),GFP_KERNEL ); -if (up ==NULL ) { -nf_ct_l3proto_module_put (par->family); -return -ENOMEM ; - } - -/* -* The strategy here is to minimize the overhead of v1 matching, -* by prebuilding a v2 struct and putting the pointer into the -* v1 dataspace. -*/ - memcpy(up, info, offsetof(typeof(*info), state_mask)); - up->state_mask = info->state_mask; - up->status_mask = info->status_mask; - *(void **)info = up; -return true; -} -static void conntrack_mt_destroy (const struct xt_mtdtor_param *par) {nf_ct_l3proto_module_put (par->family); } -static void conntrack_mt_destroy_v1 (const struct xt_mtdtor_param *par) -{ -struct xt_conntrack_mtinfo2 **info = par->matchinfo; -kfree (*info); -conntrack_mt_destroy (par); -} -static struct xt_match conntrack_mt_reg[]__read_mostly = { { .name ="conntrack" ,
@@ -255,8 +228,8 @@ static struct xt_match conntrack_mt_reg[ .family = NFPROTO_UNSPEC, .matchsize = sizeof(struct xt_conntrack_mtinfo1), .match = conntrack_mt_v1, - .checkentry = conntrack_mt_check_v1, - .destroy = conntrack_mt_destroy_v1, + .checkentry = conntrack_mt_check, + .destroy = conntrack_mt_destroy, .me = THIS_MODULE, }, {
@@ -264,7 +237,7 @@ static struct xt_match conntrack_mt_reg[ .revision = 2, .family = NFPROTO_UNSPEC, .matchsize = sizeof(struct xt_conntrack_mtinfo2), - .match = conntrack_mt, + .match = conntrack_mt_v2, .checkentry = conntrack_mt_check, .destroy = conntrack_mt_destroy, .me = THIS_MODULE,
PATCH 25/98 partitions: read whole sector with EFI GPT header
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Karel Zak <[email protected]>
commit 87038c2d5bda2418fda8b1456a0ae81cc3ff5bd8 upstream.
The size of EFI GPT header is not static, but whole sector is allocated for the header. The HeaderSize field must be greater than 92 (= sizeof(struct gpt_header) and must be less than or equal to the logical block size.
It means we have to read whole sector with the header, because the header crc32 checksum is calculated according to HeaderSize.
For more details see UEFI standard (version 2.3, May 2009):
- 5.3.1 GUID Format overview, page 93
- Table 13. GUID Partition Table Header, page 96
--- fs/partitions/efi.c | 7 ++++--- fs/partitions/efi.h | 8 ++++++-- 2 files changed, 10 insertions(+), 5 deletions(-)
fs/partitions/efi.c +4 -3
@@ -257,15 +257,16 @@ static gpt_header * alloc_read_gpt_header(struct block_device *bdev, u64 lba) {gpt_header *gpt; +unsigned ssz =bdev_logical_block_size (bdev); +if (!bdev)return NULL ; - gpt =kzalloc (sizeof (gpt_header),GFP_KERNEL ); + gpt =kzalloc (ssz,GFP_KERNEL );if (!gpt)return NULL ; -if (read_lba (bdev, lba, (u8 *) gpt, -sizeof (gpt_header)) <sizeof (gpt_header)) { +if (read_lba (bdev, lba, (u8 *) gpt, ssz) < ssz) {kfree (gpt); gpt=NULL ;return NULL ;
fs/partitions/efi.h +6 -2
@@ -37,7 +37,6 @@#define EFI_PMBR_OSTYPE_EFI 0xEF#define EFI_PMBR_OSTYPE_EFI_GPT 0xEE -#define GPT_BLOCK_SIZE 512#define GPT_HEADER_SIGNATURE 0x5452415020494645ULL#define GPT_HEADER_REVISION_V1 0x00010000#define GPT_PRIMARY_PARTITION_TABLE_LBA 1
@@ -79,7 +78,12 @@ typedef struct _gpt_header {__le32 num_partition_entries;__le32 sizeof_partition_entry;__le32 partition_entry_array_crc32; -u8 reserved2[GPT_BLOCK_SIZE -92 ]; + +/* The rest of the logical block is reserved by UEFI and must be zero. +* EFI standard handles this by: +* +* uint8_t reserved2[ BlockSize - 92 ]; +*/ } __attribute__ ((packed)) gpt_header; typedef struct _gpt_entry_attributes {
PATCH 26/98 partitions: use sector size for EFI GPT
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Karel Zak <[email protected]>
commit 7d13af3279985f554784a45cc961f706dbcdbdd1 upstream.
Currently, kernel uses strictly 512-byte sectors for EFI GPT parsing. That's wrong.
UEFI standard (version 2.3, May 2009, 5.3.1 GUID Format overview, page
95) defines that LBA is always based on the logical block size. It means bdev_logical_block_size() (aka BLKSSZGET) for Linux.
This patch removes static sector size from EFI GPT parser.
The problem is reproducible with the latest GNU Parted:
# modprobe scsi_debug dev_size_mb=50 sector_size=4096
# ./parted /dev/sdb print Model: Linux scsi_debug (scsi) Disk /dev/sdb: 52.4MB Sector size (logical/physical): 4096B/4096B Partition Table: gpt
Number Start End Size File system Name Flags 1 24.6kB 3002kB 2978kB primary 2 3002kB 6001kB 2998kB primary 3 6001kB 9003kB 3002kB primary
# blockdev --rereadpt /dev/sdb # dmesg | tail -1 sdb: unknown partition table <---- !!!
with this patch:
# blockdev --rereadpt /dev/sdb # dmesg | tail -1 sdb: sdb1 sdb2 sdb3
--- fs/partitions/efi.c | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-)
fs/partitions/efi.c +15 -8
@@ -1,7 +1,9 @@/************************************************************ * EFI GUID Partition Table handling -* Per Intel EFI Specification v1.02 -* http://developer.intel.com/technology/efi/efi.htm +* +* http://www.uefi.org/specs/ +* http://www.intel.com/technology/efi/ +* * efi.[ch] by Matt Domsch <[email protected]> * Copyright 2000,2001,2002,2004 Dell Inc. *
@@ -92,6 +94,7 @@* ************************************************************/ #include <linux/crc32.h> +#include <linux/math64.h> #include "check.h" #include "efi.h"
@@ -141,7 +144,8 @@ last_lba(struct block_device *bdev) {if (!bdev || !bdev->bd_inode)return 0 ; -return (bdev->bd_inode->i_size >>9 ) -1ULL ; +return div_u64 (bdev->bd_inode->i_size, +bdev_logical_block_size (bdev)) -1ULL ; } static inline int
@@ -188,6 +192,7 @@ static size_t read_lba(struct block_device *bdev, u64 lba, u8 * buffer, size_t count) { size_t totalreadcount = 0; +sector_t n = lba * (bdev_logical_block_size (bdev) /512 );if (!bdev || !buffer || lba >last_lba (bdev))return 0 ;
@@ -195,7 +200,7 @@ read_lba(struct block_device *bdev, u64while (count) {int copied =512 ;Sector sect; -unsigned char *data =read_dev_sector (bdev, lba++, §); +unsigned char *data =read_dev_sector (bdev, n++, §);if (!data)break ;if (copied > count)
@@ -602,6 +607,7 @@ efi_partition(struct parsed_partitions *gpt_header *gpt =NULL ;gpt_entry *ptes =NULL ;u32 i; +unsigned ssz =bdev_logical_block_size (bdev) /512 ;if (!find_valid_gpt (bdev, &gpt, &ptes) || !gpt || !ptes) {kfree (gpt);
@@ -612,13 +618,14 @@ efi_partition(struct parsed_partitions *pr_debug ("GUID Partition Table is valid! Yea!\n" ); for (i = 0; i < le32_to_cpu(gpt->num_partition_entries) && i < state->limit-1; i++) { + u64 start = le64_to_cpu(ptes[i].starting_lba); + u64 size = le64_to_cpu(ptes[i].ending_lba) - + le64_to_cpu(ptes[i].starting_lba) + 1ULL; + if (!is_pte_valid(&ptes[i], last_lba(bdev))) continue; - put_partition(state, i+1, le64_to_cpu(ptes[i].starting_lba), - (le64_to_cpu(ptes[i].ending_lba) - - le64_to_cpu(ptes[i].starting_lba) + - 1ULL)); + put_partition(state, i+1, start * ssz, size * ssz); /* If this is a RAID volume, tell md */ if (!efi_guidcmp(ptes[i].partition_type_guid,
PATCH 27/98 ALSA: ice1724 - Patch for suspend/resume for ESI Juli@
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Aleksey Kunitskiy <[email protected]>
commit 50d40f187f9182ee8caa1b83f80a0e11e2226baa upstream.
Add proper suspend/resume code for Juli@ cards. Based on ice1724 suspend/resume work of Igor Chernyshev.
Fixes bug https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4413
Tested on linux-2.6.31.6
--- sound/pci/ice1712/juli.c | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+)
sound/pci/ice1712/juli.c +32 -0
@@ -504,6 +504,31 @@ static int __devinit juli_add_controls(s }/* +* suspend/resume +* */ + +#ifdef CONFIG_PM +static int juli_resume (struct snd_ice1712 *ice) +{ +struct snd_akm4xxx *ak = ice->akm; +struct juli_spec *spec = ice->spec; +/* akm4358 un-reset, un-mute */ +snd_akm4xxx_reset (ak,0 ); +/* reinit ak4114 */ +snd_ak4114_reinit (spec->ak4114); +return 0 ; +} + +static int juli_suspend (struct snd_ice1712 *ice) +{ +struct snd_akm4xxx *ak = ice->akm; +/* akm4358 reset and soft-mute */ +snd_akm4xxx_reset (ak,1 ); +return 0 ; +} +#endif + +/* * initialize the chip */
@@ -646,6 +671,13 @@ static int __devinit juli_init(struct sn ice->set_spdif_clock = juli_set_spdif_clock; ice->spdif.ops.open = juli_spdif_in_open; + +#ifdef CONFIG_PM + ice->pm_resume = juli_resume; + ice->pm_suspend = juli_suspend; + ice->pm_suspend_enabled =1 ; +#endif +return 0 ; }
PATCH 28/98 sched: Fix isolcpus boot option
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Rusty Russell <[email protected]>
commit bdddd2963c0264c56f18043f6fa829d3c1d3d1c0 upstream.
Quoted 4 lines · Anton Blanchard
We allocate and zero
cpu_isolated_mapafter the isolcpus__setupoption has run. This meanscpu_isolated_mapalways ends up empty and ifCPUMASK_OFFSTACKis enabled we write to a cpumask that hasn't been allocated.
I introduced this regression in 49557e620339cb13 (sched: Fix boot crash by zalloc()ing most of the cpu masks).
Use the bootmem allocator if they set isolcpus=, otherwise allocate and zero like normal.
LKML-Reference: <[email protected]>
--- kernel/sched.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
kernel/sched.c +4 -1
@@ -8061,6 +8061,7 @@ static cpumask_var_t cpu_isolated_map;/* Setup the mask of cpus configured for isolated domains */ static int __init isolated_cpu_setup (char *str) { +alloc_bootmem_cpumask_var (&cpu_isolated_map);cpulist_parse (str, cpu_isolated_map);return 1 ; }
@@ -9591,7 +9592,9 @@ void __init sched_init(void)zalloc_cpumask_var (&nohz.cpu_mask,GFP_NOWAIT );alloc_cpumask_var (&nohz.ilb_grp_nohz_mask,GFP_NOWAIT );#endif -zalloc_cpumask_var (&cpu_isolated_map,GFP_NOWAIT ); +/* May be allocated at isolcpus cmdline parse time */ +if (cpu_isolated_map ==NULL ) +zalloc_cpumask_var (&cpu_isolated_map,GFP_NOWAIT );#endif /* SMP */ perf_event_init ();
PATCH 29/98 sched: Fix missing sched tunable recalculation on cpu add/remove
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Christian Ehrhardt <[email protected]>
commit 0bcdcf28c979869f44e05121b96ff2cfb05bd8e6 upstream.
Based on Peter Zijlstras patch suggestion this enables recalculation of the scheduler tunables in response of a change in the number of cpus. It also adds a max of eight cpus that are considered in that scaling.
LKML-Reference: <[email protected]>
--- kernel/sched.c | 29 ++++++++++++++++------------- kernel/sched_fair.c | 16 ++++++++++++++++ 2 files changed, 32 insertions(+), 13 deletions(-)
kernel/sched.c +16 -13
@@ -816,6 +816,7 @@ const_debug unsigned int sysctl_sched_nr* default: 0.25ms */ unsigned int sysctl_sched_shares_ratelimit =250000 ; +unsigned int normalized_sysctl_sched_shares_ratelimit =250000 ;/* * Inject some fuzzyness into changing the per-cpu group shares
@@ -1812,6 +1813,7 @@ static void cfs_rq_set_shares(struct cfs#endif static void calc_load_account_active (struct rq *this_rq); +static void update_sysctl (void );#include "sched_stats.h" #include "sched_idletask.c"
@@ -7018,22 +7020,23 @@ cpumask_var_t nohz_cpu_mask;* * This idea comes from the SD scheduler of Con Kolivas: */ -static inline void sched_init_granularity (void ) +static void update_sysctl (void ) { -unsigned int factor =1 +ilog2 (num_online_cpus ()); -const unsigned long limit =200000000 ; - - sysctl_sched_min_granularity *= factor; -if (sysctl_sched_min_granularity > limit) - sysctl_sched_min_granularity = limit; - - sysctl_sched_latency *= factor; -if (sysctl_sched_latency > limit) - sysctl_sched_latency = limit; +unsigned int cpus =min (num_online_cpus (),8U ); +unsigned int factor =1 +ilog2 (cpus); - sysctl_sched_wakeup_granularity *= factor; +#define SET_SYSCTL (name) \ + (sysctl_##name = (factor) * normalized_sysctl_##name) +SET_SYSCTL (sched_min_granularity); +SET_SYSCTL (sched_latency); +SET_SYSCTL (sched_wakeup_granularity); +SET_SYSCTL (sched_shares_ratelimit); +#undef SET_SYSCTL +} - sysctl_sched_shares_ratelimit *= factor; +static inline void sched_init_granularity (void ) +{ +update_sysctl (); }#ifdef CONFIG_SMP
kernel/sched_fair.c +16 -0
@@ -35,12 +35,14 @@* run vmstat and monitor the context-switches (cs) field) */ unsigned int sysctl_sched_latency =5000000ULL ; +unsigned int normalized_sysctl_sched_latency =5000000ULL ;/* * Minimal preemption granularity for CPU-bound tasks: * (default: 1 msec * (1 + ilog(ncpus)), units: nanoseconds) */ unsigned int sysctl_sched_min_granularity =1000000ULL ; +unsigned int normalized_sysctl_sched_min_granularity =1000000ULL ;/* * is kept at sysctl_sched_latency / sysctl_sched_min_granularity
@@ -70,6 +72,7 @@ unsigned int __read_mostly sysctl_sched_* have immediate wakeup/sleep latencies. */ unsigned int sysctl_sched_wakeup_granularity =1000000UL ; +unsigned int normalized_sysctl_sched_wakeup_granularity =1000000UL ; const_debug unsigned int sysctl_sched_migration_cost = 500000UL;
@@ -1880,6 +1883,17 @@ move_one_task_fair(struct rq *this_rq, i return 0; } + +static void rq_online_fair (struct rq *rq) +{ +update_sysctl (); +} + +static void rq_offline_fair (struct rq *rq) +{ +update_sysctl (); +} +#endif /* CONFIG_SMP */ /*
@@ -2027,6 +2041,8 @@ static const struct sched_class fair_sch .load_balance = load_balance_fair, .move_one_task = move_one_task_fair, + .rq_online = rq_online_fair, + .rq_offline = rq_offline_fair, #endif .set_curr_task = set_curr_task_fair,
PATCH 30/98 nohz: Prevent clocksource wrapping during idle
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Jon Hunter <[email protected]>
commit 98962465ed9e6ea99c38e0af63fe1dcb5a79dc25 upstream.
The dynamic tick allows the kernel to sleep for periods longer than a single tick, but it does not limit the sleep time currently. In the worst case the kernel could sleep longer than the wrap around time of the time keeping clock source which would result in losing track of time.
Prevent this by limiting it to the safe maximum sleep time of the current time keeping clock source. The value is calculated when the clock source is registered.
[ tglx: simplified the code a bit and massaged the commit msg ]
LKML-Reference: <[email protected]>
--- include/linux/clocksource.h | 2 + include/linux/time.h | 1 kernel/time/clocksource.c | 44 +++++++++++++++++++++++++++++++++++++ kernel/time/tick-sched.c | 52 ++++++++++++++++++++++++++++++++------------ kernel/time/timekeeping.c | 11 +++++++++ 5 files changed, 96 insertions(+), 14 deletions(-)
include/linux/clocksource.h +2 -0
@@ -151,6 +151,7 @@ extern u64 timecounter_cyc2time(struct t* subtraction of non 64 bit counters * @mult: cycle to nanosecond multiplier * @shift: cycle to nanosecond divisor (power of two) +* @max_idle_ns: max idle time permitted by the clocksource (nsecs) * @flags: flags describing special properties * @vread: vsyscall based read * @resume: resume function for the clocksource, if necessary
@@ -168,6 +169,7 @@ struct clocksource {cycle_t mask;u32 mult;u32 shift; +u64 max_idle_ns;unsigned long flags;cycle_t (*vread)(void);void (*resume)(void );
include/linux/time.h +1 -0
@@ -148,6 +148,7 @@ extern void monotonic_to_bootbased(strucextern struct timespec timespec_trunc (struct timespec t,unsigned gran);extern int timekeeping_valid_for_hres (void ); +extern u64 timekeeping_max_deferment (void );extern void update_wall_time (void );extern void update_xtime_cache (u64 nsec);extern void timekeeping_leap_insert (int leapsecond);
kernel/time/clocksource.c +44 -0
56 lines not on this page · raw message
kernel/time/tick-sched.c +38 -14
83 lines not on this page · raw message
kernel/time/timekeeping.c +11 -0
@@ -488,6 +488,17 @@ int timekeeping_valid_for_hres(void) }/** +* timekeeping_max_deferment - Returns max time the clocksource can be deferred +* +* Caller must observe xtime_lock via read_seqbegin/read_seqretry to +* ensure that the clocksource does not change! +*/ +u64 timekeeping_max_deferment (void ) +{ +return timekeeper.clock->max_idle_ns; +} + +/** * read_persistent_clock - Return time from the persistent clock. * * Weak dummy function for arches that do not yet support it.
PATCH 31/98 nfsd: Fix sort_pacl in fs/nfsd/nf4acl.c to actually sort groups
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Frank Filz <[email protected]>
commit aba24d71580180dfdf6a1a83a5858a1c048fd785 upstream.
We have been doing some extensive testing of Linux support for ACLs on NFDS v4. We have noticed that the server rejects ACLs where the groups are out of order, for example, the following ACL is rejected:
A::OWNER@:rwaxtTcCy
A::user101@domain:rwaxtcy
A::GROUP@:rwaxtcy
A:g:group102@domain:rwaxtcy
A:g:group101@domain:rwaxtcy
A::EVERYONE@:rwaxtcy
Examining the server code, I found that after converting an NFS v4 ACL to POSIX, sort_pacl is called to sort the user ACEs and group ACEs. Unfortunately, a minor bug causes the group sort to be skipped.
--- fs/nfsd/nfs4acl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/nfsd/nfs4acl.c +1 -1
@@ -389,7 +389,7 @@ sort_pacl(struct posix_acl *pacl)sort_pacl_range (pacl,1 , i-1 );BUG_ON (pacl->a_entries[i].e_tag !=ACL_GROUP_OBJ ); - j = i++; + j = ++i;while (pacl->a_entries[j].e_tag ==ACL_GROUP ) j++;sort_pacl_range (pacl, i, j-1 );
PATCH 32/98 timers, init: Limit the number of per cpu calibration bootup messages
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Mike Travis <[email protected]>
commit feae3203d711db0a9965300ee6d592257fdaae4f upstream.
Limit the number of per cpu calibration messages by only printing out results for the first cpu to boot.
Also, don't print "CPUx is down" as this is expected, and we don't need 4096 reminders... ;-)
LKML-Reference: <[email protected]>
--- init/calibrate.c | 24 +++++++++++++++--------- kernel/cpu.c | 5 ++--- 2 files changed, 17 insertions(+), 12 deletions(-)
init/calibrate.c +15 -9
@@ -123,23 +123,26 @@ void __cpuinit calibrate_delay(void) {unsigned long ticks, loopbit;int lps_precision =LPS_PREC ; +static bool printed;if (preset_lpj) { loops_per_jiffy = preset_lpj; -printk (KERN_INFO -"Calibrating delay loop (skipped) preset value.. " ); - }else if ((smp_processor_id () ==0 ) && lpj_fine) { +if (!printed) +pr_info ("Calibrating delay loop (skipped) " +"preset value.. " ); + }else if ((!printed) && lpj_fine) { loops_per_jiffy = lpj_fine; -printk (KERN_INFO -"Calibrating delay loop (skipped), " +pr_info ("Calibrating delay loop (skipped), " "value calculated using timer frequency.. " ); }else if ((loops_per_jiffy =calibrate_delay_direct ()) !=0 ) { -printk (KERN_INFO -"Calibrating delay using timer specific routine.. " ); +if (!printed) +pr_info ("Calibrating delay using timer " +"specific routine.. " ); }else { loops_per_jiffy = (1 <<12 ); -printk (KERN_INFO "Calibrating delay loop... " ); +if (!printed) +pr_info ("Calibrating delay loop... " );while ((loops_per_jiffy <<=1 ) !=0 ) {/* wait for "start of" clock tick */ ticks = jiffies;
@@ -170,7 +173,10 @@ void __cpuinit calibrate_delay(void) loops_per_jiffy &= ~loopbit; } } -printk (KERN_CONT "%lu.%02lu BogoMIPS (lpj=%lu)\n" , +if (!printed) +pr_cont ("%lu.%02lu BogoMIPS (lpj=%lu)\n" , loops_per_jiffy/(500000 /HZ ), (loops_per_jiffy/(5000 /HZ )) %100 , loops_per_jiffy); + + printed = true; }
kernel/cpu.c +2 -3
@@ -400,10 +400,9 @@ int disable_nonboot_cpus(void)if (cpu == first_cpu)continue ; error =_cpu_down (cpu,1 ); -if (!error) { +if (!error)cpumask_set_cpu (cpu, frozen_cpus); -printk ("CPU%d is down\n" , cpu); - }else { +else {printk (KERN_ERR "Error taking CPU%d down: %d\n" , cpu, error);break ;
PATCH 33/98 PCI: Always set prefetchable base/limit upper32 registers
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Alex Williamson <[email protected]>
commit 59353ea30e65ab3ae181d6175e3212e1361c3787 upstream.
Prior to 1f82de10 we always initialized the upper 32bits of the prefetchable memory window, regardless of the address range used. Now we only touch it for a >32bit address, which means the upper32 registers remain whatever the BIOS initialized them too.
It's valid for the BIOS to set the upper32 base/limit to 0xffffffff/0x00000000, which makes us program prefetchable ranges like 0xffffffffabc00000 - 0x00000000abc00000
Revert the chunk of 1f82de10 that made this conditional so we always write the upper32 registers and remove now unused pref_mem64 variable.
--- drivers/pci/setup-bus.c | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-)
drivers/pci/setup-bus.c +3 -8
@@ -142,7 +142,6 @@ static void pci_setup_bridge(struct pci_struct pci_dev *bridge = bus->self;struct pci_bus_region region;u32 l, bu, lu, io_upper16; -int pref_mem64;if (pci_is_enabled (bridge))return ;
@@ -198,7 +197,6 @@ static void pci_setup_bridge(struct pci_pci_write_config_dword (bridge,PCI_PREF_LIMIT_UPPER32 ,0 );/* Set up PREF base/limit. */ - pref_mem64 =0 ; bu = lu =0 ;pcibios_resource_to_bus (bridge, ®ion, bus->resource[2 ]);if (bus->resource[2 ]->flags &IORESOURCE_PREFETCH ) {
@@ -206,7 +204,6 @@ static void pci_setup_bridge(struct pci_ l = (region.start >>16 ) &0xfff0 ; l |= region.end &0xfff00000 ;if (bus->resource[2 ]->flags &IORESOURCE_MEM_64 ) { - pref_mem64 =1 ; bu =upper_32_bits (region.start); lu =upper_32_bits (region.end); width =16 ;
@@ -221,11 +218,9 @@ static void pci_setup_bridge(struct pci_ }pci_write_config_dword (bridge,PCI_PREF_MEMORY_BASE , l); -if (pref_mem64) { -/* Set the upper 32 bits of PREF base & limit. */ -pci_write_config_dword (bridge,PCI_PREF_BASE_UPPER32 , bu); -pci_write_config_dword (bridge,PCI_PREF_LIMIT_UPPER32 , lu); - } +/* Set the upper 32 bits of PREF base & limit. */ +pci_write_config_dword (bridge,PCI_PREF_BASE_UPPER32 , bu); +pci_write_config_dword (bridge,PCI_PREF_LIMIT_UPPER32 , lu);pci_write_config_word (bridge,PCI_BRIDGE_CONTROL , bus->bridge_ctl); }
PATCH 34/98 iscsi class: modify handling of replacement timeout
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Mike Christie <[email protected]>
commit fdd46dcbe4468a1f47a2cc9be442d11c3d21dd68 upstream.
This patch modifies the replacement/recovery_timeout so it works more like the fc fast io fail tmo.
If userspace tries to set the replacement/recovery_timeout to less than zero, we will turn off the forced recovery cleanup.
If userspace sets the value to 0 then we will force the recovery cleanup immediately.
--- drivers/scsi/scsi_transport_iscsi.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/scsi/scsi_transport_iscsi.c +5 -4
@@ -627,8 +627,10 @@ static void __iscsi_block_session(structspin_unlock_irqrestore (&session->lock, flags);scsi_target_block (&session->dev);ISCSI_DBG_TRANS_SESSION (session,"Completed SCSI target blocking\n" ); -queue_delayed_work (iscsi_eh_timer_workq, &session->recovery_work, - session->recovery_tmo *HZ ); +if (session->recovery_tmo >=0 ) +queue_delayed_work (iscsi_eh_timer_workq, + &session->recovery_work, + session->recovery_tmo *HZ ); }void iscsi_block_session (struct iscsi_cls_session *session)
@@ -1348,8 +1350,7 @@ iscsi_set_param(struct iscsi_transport *switch (ev->u.set_param.param) {case ISCSI_PARAM_SESS_RECOVERY_TMO :sscanf (data,"%d" , &value); -if (value !=0 ) - session->recovery_tmo = value; + session->recovery_tmo = value;break ;default : err = transport->set_param(conn, ev->u.set_param.param,
PATCH 35/98 NFS: Revert default r/wsize behavior
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Chuck Lever <[email protected]>
commit dd47f96c077b4516727e497e4b6fd47a06778c0a upstream.
When the "rsize=" or "wsize=" mount options are not specified, text-based mounts have slightly different behavior than legacy binary mounts. Text-based mounts use the smaller of the server's maximum and the client's maximum, but binary mounts use the smaller of the server's _preferred_ size and the client's maximum.
This difference is actually pretty subtle. Most servers advertise the same value as their maximum and their preferred transfer size, so the end result is the same in most cases.
The reason for this difference is that for text-based mounts, if r/wsize are not specified, they are set to the largest value supported by the client. For legacy mounts, the values are set to zero if these options are not specified.
nfs_server_set_fsinfo() can negotiate the transfer size defaults correctly in any case. There's no need to specify any particular value as default in the text-based option parsing logic.
Note that nfs4 doesn't use nfs_server_set_fsinfo(), but the mount.nfs4 command does set rsize and wsize to 0 if the user didn't specify these options. So, make the same change for text-based NFSv4 mounts.
Thanks to James Pearson <[email protected]> for reporting and diagnosing the problem.
--- fs/nfs/super.c | 2 -- 1 file changed, 2 deletions(-)
fs/nfs/super.c +0 -2
@@ -734,8 +734,6 @@ static struct nfs_parsed_mount_data *nfs data =kzalloc (sizeof (*data),GFP_KERNEL );if (data) { - data->rsize =NFS_MAX_FILE_IO_SIZE ; - data->wsize =NFS_MAX_FILE_IO_SIZE ; data->acregmin =NFS_DEF_ACREGMIN ; data->acregmax =NFS_DEF_ACREGMAX ; data->acdirmin =NFS_DEF_ACDIRMIN ;
PATCH 36/98 HID: fixup quirk for NCR devices
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Jiri Kosina <[email protected]>
commit 5b915d9e6dc3d22fedde91dfef1cb1a8fa9a1870 upstream.
NCR devices are terminally broken by design -- they claim themselves to contain proper input applications in their HID report descriptor, but behave very badly if treated in standard way.
According to NCR developers, the devices get confused when queried for reports in a standard way, rendering them unusable.
NCR is shipping application called "RPSL" that can be used to drive these devices through hiddev, under the assumption that in-kernel driver doesn't perform initial report query.
If it does, neither in-kernel nor hiddev-based driver can operate with these devices any more.
Introduce a quirk that skips the report query for all NCR devices. The previous NOGET quirk was wrong and had been introduced because I misunderstood the nature of brokenness of these devices.
--- drivers/hid/usbhid/hid-core.c | 3 ++- drivers/hid/usbhid/hid-quirks.c | 2 +- include/linux/hid.h | 1 + 3 files changed, 4 insertions(+), 2 deletions(-)
drivers/hid/usbhid/hid-core.c +2 -1
@@ -998,7 +998,8 @@ static int usbhid_start(struct hid_devic usbhid->urbctrl->transfer_dma = usbhid->ctrlbuf_dma; usbhid->urbctrl->transfer_flags |= (URB_NO_TRANSFER_DMA_MAP |URB_NO_SETUP_DMA_MAP ); -usbhid_init_reports (hid); +if (!(hid->quirks &HID_QUIRK_NO_INIT_REPORTS )) +usbhid_init_reports (hid);set_bit (HID_STARTED , &usbhid->iofl);
drivers/hid/usbhid/hid-quirks.c +1 -1
@@ -280,7 +280,7 @@ u32 usbhid_lookup_quirk(const u16 idVendif (idVendor ==USB_VENDOR_ID_NCR && idProduct >=USB_DEVICE_ID_NCR_FIRST && idProduct <=USB_DEVICE_ID_NCR_LAST ) -return HID_QUIRK_NOGET ; +return HID_QUIRK_NO_INIT_REPORTS ;down_read (&dquirks_rwsem); bl_entry =usbhid_exists_dquirk (idVendor, idProduct);
include/linux/hid.h +1 -0
@@ -312,6 +312,7 @@ struct hid_item {#define HID_QUIRK_MULTI_INPUT 0x00000040#define HID_QUIRK_SKIP_OUTPUT_REPORTS 0x00010000#define HID_QUIRK_FULLSPEED_INTERVAL 0x10000000 +#define HID_QUIRK_NO_INIT_REPORTS 0x20000000/* * This is the global environment of the parser. This information is
PATCH 37/98 scsi_devinfo: update Hitachi entries (v2)
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Takahiro Yasui <[email protected]>
commit 627511e3e67553b04f6917c03e39b797df210e04 upstream.
Four models, OPEN-/DF400/DF500/DISK-SUBSYSTEM, can handle REPORT_LUN, and the BLIST_REPORTLUN2 flag needs to be set. And DF600 doesn't require any flags because it returns ANSI 03h (SPC).
--- drivers/scsi/scsi_devinfo.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-)
drivers/scsi/scsi_devinfo.c +4 -5
@@ -168,11 +168,10 @@ static struct { {"Generic", "USB SD Reader", "1.00", BLIST_FORCELUN | BLIST_INQUIRY_36}, {"Generic", "USB Storage-SMC", "0180", BLIST_FORCELUN | BLIST_INQUIRY_36}, {"Generic", "USB Storage-SMC", "0207", BLIST_FORCELUN | BLIST_INQUIRY_36}, - {"HITACHI", "DF400", "*", BLIST_SPARSELUN}, - {"HITACHI", "DF500", "*", BLIST_SPARSELUN}, - {"HITACHI", "DF600", "*", BLIST_SPARSELUN}, - {"HITACHI", "DISK-SUBSYSTEM", "*", BLIST_ATTACH_PQ3 | BLIST_SPARSELUN | BLIST_LARGELUN}, - {"HITACHI", "OPEN-E", "*", BLIST_ATTACH_PQ3 | BLIST_SPARSELUN | BLIST_LARGELUN}, + {"HITACHI", "DF400", "*", BLIST_REPORTLUN2}, + {"HITACHI", "DF500", "*", BLIST_REPORTLUN2}, + {"HITACHI", "DISK-SUBSYSTEM", "*", BLIST_REPORTLUN2}, + {"HITACHI", "OPEN-", "*", BLIST_REPORTLUN2}, {"HITACHI", "OP-C-", "*", BLIST_SPARSELUN | BLIST_LARGELUN}, {"HITACHI", "3380-", "*", BLIST_SPARSELUN | BLIST_LARGELUN}, {"HITACHI", "3390-", "*", BLIST_SPARSELUN | BLIST_LARGELUN},
PATCH 38/98 scsi_dh: create sysfs file, dh_state for all SCSI disk devices
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Chandra Seetharaman <[email protected]>
commit 5917290ce9b376866b165d02a5ed88d5ecdb32d0 upstream.
Create the sysfs file, dh_state even if the new SCSI device is not in the any of the device handler's internal lists.
--- drivers/scsi/device_handler/scsi_dh.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-)
drivers/scsi/device_handler/scsi_dh.c +4 -7
@@ -304,18 +304,15 @@ static int scsi_dh_notifier(struct notif sdev =to_scsi_device (dev);if (action ==BUS_NOTIFY_ADD_DEVICE ) { + err =device_create_file (dev, &scsi_dh_state_attr); +/* don't care about err */ devinfo =device_handler_match (NULL , sdev); -if (!devinfo) - goto out; - - err =scsi_dh_handler_attach (sdev, devinfo); -if (!err) - err =device_create_file (dev, &scsi_dh_state_attr); +if (devinfo) + err =scsi_dh_handler_attach (sdev, devinfo); }else if (action ==BUS_NOTIFY_DEL_DEVICE ) {device_remove_file (dev, &scsi_dh_state_attr);scsi_dh_handler_detach (sdev,NULL ); } -out:return err; }
PATCH 39/98 scsi_transport_fc: remove invalid BUG_ON
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Michael Reed <[email protected]>
commit 8798a694da59486e4a3ff0abeec183202fb34c20 upstream.
I was doing some large lun count testing with 2.6.31 and hit a BUG_ON() in fc_timeout_deleted_rport(), and it seems like it should have been just a matter of time before someone did.
It seems invalid to set port_state under lock, then expect it to remain set after releasing the lock. Another thread called fc_remote_port_add() when the lock was released, changing the port_state.
This patch removes the BUG_ON and moves the test of the port_state to inside the host_lock. It's been running for several weeks now with no ill effect.
--- drivers/scsi/scsi_transport_fc.c | 68 ++++++++++++++++++++++++--------------- 1 file changed, 42 insertions(+), 26 deletions(-)
drivers/scsi/scsi_transport_fc.c +42 -26
@@ -2395,6 +2395,7 @@ fc_rport_final_delete(struct work_structstruct Scsi_Host *shost =rport_to_shost (rport);struct fc_internal *i =to_fc_internal (shost->transportt);unsigned long flags; +int do_callback =0 ;/* * if a scan is pending, flush the SCSI Host work_q so that
@@ -2433,8 +2434,15 @@ fc_rport_final_delete(struct work_struct* Avoid this call if we already called it when we preserved the * rport for the binding. */ +spin_lock_irqsave (shost->host_lock, flags);if (!(rport->flags &FC_RPORT_DEVLOSS_CALLBK_DONE ) && - (i->f->dev_loss_tmo_callbk)) + (i->f->dev_loss_tmo_callbk)) { + rport->flags |=FC_RPORT_DEVLOSS_CALLBK_DONE ; + do_callback =1 ; + } +spin_unlock_irqrestore (shost->host_lock, flags); + +if (do_callback) i->f->dev_loss_tmo_callbk (rport);fc_bsg_remove (rport->rqst_q);
@@ -2981,6 +2989,7 @@ fc_timeout_deleted_rport(struct work_strstruct fc_internal *i =to_fc_internal (shost->transportt);struct fc_host_attrs *fc_host =shost_to_fc_host (shost);unsigned long flags; +int do_callback =0 ;spin_lock_irqsave (shost->host_lock, flags);
@@ -3046,7 +3055,6 @@ fc_timeout_deleted_rport(struct work_str rport->roles =FC_PORT_ROLE_UNKNOWN ; rport->port_state =FC_PORTSTATE_NOTPRESENT ; rport->flags &= ~FC_RPORT_FAST_FAIL_TIMEDOUT ; - rport->flags |=FC_RPORT_DEVLOSS_CALLBK_DONE ;/* * Pre-emptively kill I/O rather than waiting for the work queue
@@ -3056,32 +3064,40 @@ fc_timeout_deleted_rport(struct work_strspin_unlock_irqrestore (shost->host_lock, flags);fc_terminate_rport_io (rport); -BUG_ON (rport->port_state !=FC_PORTSTATE_NOTPRESENT ); +spin_lock_irqsave (shost->host_lock, flags); -/* remove the identifiers that aren't used in the consisting binding */ -switch (fc_host->tgtid_bind_type) { -case FC_TGTID_BIND_BY_WWPN : - rport->node_name =-1 ; - rport->port_id =-1 ; -break ; -case FC_TGTID_BIND_BY_WWNN : - rport->port_name =-1 ; - rport->port_id =-1 ; -break ; -case FC_TGTID_BIND_BY_ID : - rport->node_name =-1 ; - rport->port_name =-1 ; -break ; -case FC_TGTID_BIND_NONE :/* to keep compiler happy */ -break ; +if (rport->port_state ==FC_PORTSTATE_NOTPRESENT ) {/* still missing */ + +/* remove the identifiers that aren't used in the consisting binding */ +switch (fc_host->tgtid_bind_type) { +case FC_TGTID_BIND_BY_WWPN : + rport->node_name =-1 ; + rport->port_id =-1 ; +break ; +case FC_TGTID_BIND_BY_WWNN : + rport->port_name =-1 ; + rport->port_id =-1 ; +break ; +case FC_TGTID_BIND_BY_ID : + rport->node_name =-1 ; + rport->port_name =-1 ; +break ; +case FC_TGTID_BIND_NONE :/* to keep compiler happy */ +break ; + } + +/* +* As this only occurs if the remote port (scsi target) +* went away and didn't come back - we'll remove +* all attached scsi devices. +*/ + rport->flags |=FC_RPORT_DEVLOSS_CALLBK_DONE ; +fc_queue_work (shost, &rport->stgt_delete_work); + + do_callback =1 ; } -/* -* As this only occurs if the remote port (scsi target) -* went away and didn't come back - we'll remove -* all attached scsi devices. -*/ -fc_queue_work (shost, &rport->stgt_delete_work); +spin_unlock_irqrestore (shost->host_lock, flags);/* * Notify the driver that the rport is now dead. The LLDD will
@@ -3089,7 +3105,7 @@ fc_timeout_deleted_rport(struct work_str* * Note: we set the CALLBK_DONE flag above to correspond */ -if (i->f->dev_loss_tmo_callbk) +if (do_callback && i->f->dev_loss_tmo_callbk) i->f->dev_loss_tmo_callbk (rport); }
PATCH 40/98 lpfc: fix hang on SGI ia64 platform
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Michael Reed <[email protected]>
commit 8e68597d087977d3e4fd3e735d290ab45fd0b5ea upstream.
In testing 2.6.31 on one of our ia64 platforms I've encountered a hang due to the driver using hardware ATEs which are a limited resource. This is because the driver does not set the dma consistent mask to 64 bits.
--- drivers/scsi/lpfc/lpfc_init.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-)
drivers/scsi/lpfc/lpfc_init.c +12 -4
@@ -4384,9 +4384,13 @@ lpfc_sli_pci_mem_setup(struct lpfc_hba * pdev = phba->pcidev;/* Set the device DMA mask size */ -if (pci_set_dma_mask (pdev,DMA_BIT_MASK (64 )) !=0 ) -if (pci_set_dma_mask (pdev,DMA_BIT_MASK (32 )) !=0 ) +if (pci_set_dma_mask (pdev,DMA_BIT_MASK (64 )) !=0 + ||pci_set_consistent_dma_mask (pdev,DMA_BIT_MASK (64 )) !=0 ) { +if (pci_set_dma_mask (pdev,DMA_BIT_MASK (32 )) !=0 + ||pci_set_consistent_dma_mask (pdev,DMA_BIT_MASK (32 )) !=0 ) {return error; + } + }/* Get the bus address of Bar0 and Bar2 and the number of bytes * required by each mapping.
@@ -5940,9 +5944,13 @@ lpfc_sli4_pci_mem_setup(struct lpfc_hba pdev = phba->pcidev;/* Set the device DMA mask size */ -if (pci_set_dma_mask (pdev,DMA_BIT_MASK (64 )) !=0 ) -if (pci_set_dma_mask (pdev,DMA_BIT_MASK (32 )) !=0 ) +if (pci_set_dma_mask (pdev,DMA_BIT_MASK (64 )) !=0 + ||pci_set_consistent_dma_mask (pdev,DMA_BIT_MASK (64 )) !=0 ) { +if (pci_set_dma_mask (pdev,DMA_BIT_MASK (32 )) !=0 + ||pci_set_consistent_dma_mask (pdev,DMA_BIT_MASK (32 )) !=0 ) {return error; + } + }/* Get the bus address of SLI4 device Bar0, Bar1, and Bar2 and the * number of bytes required by each mapping. They are actually
PATCH 41/98 libfc: fix typo in retry check on received PRLI
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Joe Eykholt <[email protected]>
commit 85b5893ca97c69e409ecbb5ee90a5d99882369c4 upstream.
A received Fibre Channel ELS PRLI request contains a bit that indicates whether the remote port supports certain retry processing sequences. The test for this bit was somehow coded to use multiply instead of AND!
This case would apply only for target mode operation, and it is unlikely to be noticed as an initiator.
--- drivers/scsi/libfc/fc_rport.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/scsi/libfc/fc_rport.c +1 -1
@@ -1402,7 +1402,7 @@ static void fc_rport_recv_prli_req(strucbreak ;case FC_TYPE_FCP : fcp_parm =ntohl (rspp->spp_params); -if (fcp_parm *FCP_SPPF_RETRY ) +if (fcp_parm &FCP_SPPF_RETRY ) rdata->flags |=FC_RP_FLAGS_RETRY ; rdata->supported_classes =FC_COS_CLASS3 ;if (fcp_parm &FCP_SPPF_INIT_FCN )
PATCH 42/98 libfc: fix ddp in fc_fcp for 0 xid
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Yi Zou <[email protected]>
commit 5e472d077f45de4f37365171bd742f18b3ef20de upstream.
xid 0 was used as an indication of invalid xid before but now xid 0 can be used as a valid exchange i. This patch fixes the ddp completion in fcp layer, i.e., in fc_fcp.c:fc_fcp_ddp_done() function, to make sure it does not use xid 0 for indication of an invalid xid, instead, it now uses use FC_XID_UNKNOWN for such indication.
--- drivers/scsi/libfc/fc_fcp.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-)
drivers/scsi/libfc/fc_fcp.c +6 -2
@@ -302,10 +302,13 @@ static void fc_fcp_ddp_done(struct fc_fcif (!fsp)return ; +if (fsp->xfer_ddp ==FC_XID_UNKNOWN ) +return ; + lp = fsp->lp; -if (fsp->xfer_ddp && lp->tt.ddp_done) { +if (lp->tt.ddp_done) { fsp->xfer_len = lp->tt.ddp_done (lp, fsp->xfer_ddp); - fsp->xfer_ddp =0 ; + fsp->xfer_ddp =FC_XID_UNKNOWN ; } }
@@ -1708,6 +1711,7 @@ int fc_queuecommand(struct scsi_cmnd *sc fsp->cmd = sc_cmd;/* save the cmd */ fsp->lp = lp;/* save the softc ptr */ fsp->rport = rport;/* set the remote port ptr */ + fsp->xfer_ddp =FC_XID_UNKNOWN ; sc_cmd->scsi_done = done;/*
PATCH 43/98 fcoe: remove redundant checking of netdev->netdev_ops
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Yi Zou <[email protected]>
commit b04d023cf5b7f4113cc4a09405c2fe8003bfe37d upstream.
Remove the redundant checking of netdev->netdev_ops as it will never be NULL.
--- drivers/scsi/fcoe/fcoe.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/scsi/fcoe/fcoe.c +2 -2
@@ -664,7 +664,7 @@ static int fcoe_ddp_setup(struct fc_lpor {struct net_device *n =fcoe_netdev (lp); -if (n->netdev_ops && n->netdev_ops->ndo_fcoe_ddp_setup) +if (n->netdev_ops->ndo_fcoe_ddp_setup)return n->netdev_ops->ndo_fcoe_ddp_setup (n, xid, sgl, sgc);return 0 ;
@@ -681,7 +681,7 @@ static int fcoe_ddp_done(struct fc_lport {struct net_device *n =fcoe_netdev (lp); -if (n->netdev_ops && n->netdev_ops->ndo_fcoe_ddp_done) +if (n->netdev_ops->ndo_fcoe_ddp_done)return n->netdev_ops->ndo_fcoe_ddp_done (n, xid);return 0 ; }
PATCH 44/98 libfc: Fix wrong scsi return status under FC_DATA_UNDRUN
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Yi Zou <[email protected]>
commit 4347fa66878e079766258bc0d077c350cb31a799 upstream.
This bug is exposed when there is a link flap in LLD. Particularly, when it happens right after a SCSI write command is sent out, no FCP_DATA is sent, causing fsp->status_code to be set as FC_DATA_UNDRUN in fc_fcp_complete_locked even no SCSI status is received. Consequently, fc_io_compl treats this as DID_OK. This results in SCSI returning successful to the initial I/O request even there is no DATA actually sent. Particularly, if you run an I/O tool w/ data verification on, the read back for verification is gonna fail.
This is fixed here by checking when FC_DATA_UNDRUN happens, SCSI status is received w/ FC_SRB_RCV_STATUS set in fsp->state.
--- drivers/scsi/libfc/fc_fcp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/scsi/libfc/fc_fcp.c +2 -1
@@ -1850,7 +1850,8 @@ static void fc_io_compl(struct fc_fcp_pk* scsi status is good but transport level * underrun. */ - sc_cmd->result =DID_OK <<16 ; + sc_cmd->result = (fsp->state &FC_SRB_RCV_STATUS ? +DID_OK :DID_ERROR ) <<16 ; }else {/* * scsi got underrun, this is an error
PATCH 45/98 libfc: lport: fix minor documentation errors
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Joe Eykholt <[email protected]>
commit 1b69bc062c2a4c8f3e15ac69f487afec3aa8d774 upstream.
Fix minor errors.
A debug message said an RLIR was received instead of ECHO. "Expected" was misspelled in several places.
Fix a type cast from u32 to __be32.
Rob, Some of these may have been also taken care of in your other doc cleanup patch. Feel free to fold them in.
--- drivers/scsi/libfc/fc_lport.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-)
drivers/scsi/libfc/fc_lport.c +10 -10
@@ -329,7 +329,7 @@ static void fc_lport_add_fc4_type(struct* @sp: current sequence in the RLIR exchange * @fp: RLIR request frame * -* Locking Note: The lport lock is exected to be held before calling +* Locking Note: The lport lock is expected to be held before calling * this function. */ static void fc_lport_recv_rlir_req(struct fc_seq *sp, struct fc_frame *fp,
@@ -348,7 +348,7 @@ static void fc_lport_recv_rlir_req(struc* @sp: current sequence in the ECHO exchange * @fp: ECHO request frame * -* Locking Note: The lport lock is exected to be held before calling +* Locking Note: The lport lock is expected to be held before calling * this function. */ static void fc_lport_recv_echo_req(struct fc_seq *sp, struct fc_frame *in_fp,
@@ -361,7 +361,7 @@ static void fc_lport_recv_echo_req(strucvoid *dp;u32 f_ctl; -FC_LPORT_DBG (lport,"Received RLIR request while in state %s\n" , +FC_LPORT_DBG (lport,"Received ECHO request while in state %s\n" ,fc_lport_state (lport)); len =fr_len (in_fp) -sizeof (struct fc_frame_header );
@@ -374,7 +374,7 @@ static void fc_lport_recv_echo_req(strucif (fp) { dp =fc_frame_payload_get (fp, len);memcpy (dp, pp, len); - *((u32 *)dp) =htonl (ELS_LS_ACC <<24 ); + *((__be32 *)dp) =htonl (ELS_LS_ACC <<24 ); sp = lport->tt.seq_start_next (sp); f_ctl =FC_FC_EX_CTX |FC_FC_LAST_SEQ |FC_FC_END_SEQ ; fc_fill_fc_hdr(fp, FC_RCTL_ELS_REP, ep->did, ep->sid,
@@ -385,12 +385,12 @@ static void fc_lport_recv_echo_req(struc }/** -* fc_lport_recv_echo_req() - Handle received Request Node ID data request -* @lport: Fibre Channel local port recieving the RNID -* @sp: current sequence in the RNID exchange -* @fp: RNID request frame +* fc_lport_recv_rnid_req() - Handle received Request Node ID data request +* @sp: The sequence in the RNID exchange +* @fp: The RNID request frame +* @lport: The local port recieving the RNID * -* Locking Note: The lport lock is exected to be held before calling +* Locking Note: The lport lock is expected to be held before calling * this function. */ static void fc_lport_recv_rnid_req(struct fc_seq *sp, struct fc_frame *in_fp,
@@ -667,7 +667,7 @@ static void fc_lport_enter_ready(struct* Accept it with the common service parameters indicating our N port. * Set up to do a PLOGI if we have the higher-number WWPN. * -* Locking Note: The lport lock is exected to be held before calling +* Locking Note: The lport lock is expected to be held before calling * this function. */ static void fc_lport_recv_flogi_req(struct fc_seq *sp_in,
PATCH 46/98 libfc: dont WARN_ON in lport_timeout for RESET state
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Joe Eykholt <[email protected]>
commit 22655ac22289d7b7def8ef2d72eafe5024bd57fe upstream.
It's possible and harmless to get FLOGI timeouts while in RESET state. Don't do a WARN_ON in that case.
Also, split out the other WARN_ONs in fc_lport_timeout, so we can tell which one is hit by its line number.
--- drivers/scsi/libfc/fc_lport.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/scsi/libfc/fc_lport.c +4 -1
@@ -1237,10 +1237,13 @@ static void fc_lport_timeout(struct workswitch (lport->state) {case LPORT_ST_DISABLED : +WARN_ON (1 ); +break ;case LPORT_ST_READY : -case LPORT_ST_RESET :WARN_ON (1 );break ; +case LPORT_ST_RESET : +break ;case LPORT_ST_FLOGI :fc_lport_enter_flogi (lport);break ;
PATCH 47/98 fcoe: initialize return value in fcoe_destroy
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Mike Christie <[email protected]>
commit 8eca355fa8af660557fbdd5506bde1392eee9bfe upstream.
When doing echo ethX > /sys..../destroy I am getting errors when the tear down succeeds. It looks like the reason for this is because the rc var is not getting set when the destruction works. This just sets it to zero.
--- drivers/scsi/fcoe/fcoe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/scsi/fcoe/fcoe.c +1 -1
@@ -1631,7 +1631,7 @@ static int fcoe_destroy(const char *buff {struct fcoe_interface *fcoe;struct net_device *netdev; -int rc; +int rc =0 ;mutex_lock (&fcoe_config_mutex);#ifdef CONFIG_FCOE_MODULE
PATCH 48/98 libfc: Fix frags in frame exceeding SKB_MAX_FRAGS in fc_fcp_send_data
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Yi Zou <[email protected]>
commit d37322a43ebac79eef417149f5696390cf8872db upstream.
In case of sequence offload, in fc_fcp_send_data(), the skb_fill_page_info() called may end up adding more frags to the skb_shinfo(fp_skb(fp))->frags[], exceeding SKB_MAX_FRAGS, this eventually corrupts the memory. I am adding the FR_FRAME_SG_LEN back, but as SKB_MAX_FRAGS -1, leaving 1 for our fcoe_eof_crc page. And send will be broken into multiple large sends if the frame already contains more frags than skb handle.
--- drivers/scsi/libfc/fc_fcp.c | 3 ++- include/scsi/fc_frame.h | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-)
drivers/scsi/libfc/fc_fcp.c +2 -1
@@ -575,7 +575,8 @@ static int fc_fcp_send_data(struct fc_fc tlen -= sg_bytes; remaining -= sg_bytes; -if (tlen) +if ((skb_shinfo (fp_skb (fp))->nr_frags <FC_FRAME_SG_LEN ) && + (tlen))continue ;/*
include/scsi/fc_frame.h +3 -0
@@ -37,6 +37,9 @@#define FC_FRAME_HEADROOM 32/* headroom for VLAN + FCoE headers */ #define FC_FRAME_TAILROOM 8/* trailer space for FCoE */ +/* Max number of skb frags allowed, reserving one for fcoe_crc_eof page */ +#define FC_FRAME_SG_LEN (MAX_SKB_FRAGS - 1) +#define fp_skb (fp) (&((fp)->skb))#define fr_hdr (fp) ((fp)->skb.data)#define fr_len (fp) ((fp)->skb.len)
PATCH 49/98 libfc: fix memory corruption caused by double frees and bad error handling
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Chris Leech <[email protected]>
commit 8f550f937e9fdafa5c37e348e214aecec851ef3f upstream.
I was running into several different panics under stress, which I traced down to a few different possible slab corruption issues in error handling paths. I have not yet looked into why these exchange sends fail, but with these fixes my test system is much more stable under stress than before.
fc_elsct_send() could fail and either leave the passed in frame intact (failure in fc_ct/els_fill) or the frame could have been freed if the failure was is fc_exch_seq_send(). The caller had no way of knowing, and there was a potential double free in the error handling in fc_fcp_rec().
Make fc_elsct_send() always free the frame before returning, and remove the fc_frame_free() call in fc_fcp_rec().
While fc_exch_seq_send() did always consume the frame, there were double free bugs in the error handling of fc_fcp_cmd_send() and fc_fcp_srr() as well.
Numerous calls to error handling routines (fc_disc_error(), fc_lport_error(), fc_rport_error_retry() ) were passing in a frame pointer that had already been freed in the case of an error. I have changed the call sites to pass in a NULL pointer, but there may be more appropriate error codes to use.
Question: Why do these error routines take a frame pointer anyway? I understand passing in a pointer encoded error to the response handlers, but the error routines take no action on a valid pointer and should never be called that way.
--- drivers/scsi/libfc/fc_disc.c | 2 +- drivers/scsi/libfc/fc_elsct.c | 4 +++- drivers/scsi/libfc/fc_fcp.c | 7 ++----- drivers/scsi/libfc/fc_lport.c | 8 ++++---- drivers/scsi/libfc/fc_rport.c | 10 +++++----- 5 files changed, 15 insertions(+), 16 deletions(-)
drivers/scsi/libfc/fc_disc.c +1 -1
@@ -371,7 +371,7 @@ static void fc_disc_gpn_ft_req(struct fc disc, lport->e_d_tov))return ; err: -fc_disc_error (disc, fp); +fc_disc_error (disc,NULL ); }/**
drivers/scsi/libfc/fc_elsct.c +3 -1
@@ -53,8 +53,10 @@ static struct fc_seq *fc_elsct_send(stru did =FC_FID_DIR_SERV ; } -if (rc) +if (rc) { +fc_frame_free (fp);return NULL ; + }fc_fill_fc_hdr (fp, r_ctl, did,fc_host_port_id (lport->host), fh_type,FC_FC_FIRST_SEQ |FC_FC_END_SEQ |FC_FC_SEQ_INIT ,0 );
drivers/scsi/libfc/fc_fcp.c +2 -5
@@ -1052,7 +1052,6 @@ static int fc_fcp_cmd_send(struct fc_lpo seq = lp->tt.exch_seq_send (lp, fp, resp, fc_fcp_pkt_destroy, fsp,0 );if (!seq) { -fc_frame_free (fp); rc =-1 ; goto unlock; }
@@ -1317,7 +1316,6 @@ static void fc_fcp_rec(struct fc_fcp_pktfc_fcp_pkt_hold (fsp);/* hold while REC outstanding */ return ; } -fc_frame_free (fp); retry:if (fsp->recov_retry++ <FC_MAX_RECOV_RETRY )fc_fcp_timer_set (fsp,FC_SCSI_REC_TOV );
@@ -1565,10 +1563,9 @@ static void fc_fcp_srr(struct fc_fcp_pkt seq = lp->tt.exch_seq_send (lp, fp, fc_fcp_srr_resp,NULL , fsp,jiffies_to_msecs (FC_SCSI_REC_TOV )); -if (!seq) { -fc_frame_free (fp); +if (!seq) goto retry; - } + fsp->recov_seq = seq; fsp->xfer_len = offset; fsp->xfer_contig_end = offset;
drivers/scsi/libfc/fc_lport.c +4 -4
@@ -1115,7 +1115,7 @@ static void fc_lport_enter_scr(struct fcif (!lport->tt.elsct_send (lport,FC_FID_FCTRL , fp,ELS_SCR , fc_lport_scr_resp, lport, lport->e_d_tov)) -fc_lport_error (lport, fp); +fc_lport_error (lport,NULL ); }/**
@@ -1186,7 +1186,7 @@ static void fc_lport_enter_rpn_id(structif (!lport->tt.elsct_send (lport,FC_FID_DIR_SERV , fp,FC_NS_RPN_ID , fc_lport_rpn_id_resp, lport, lport->e_d_tov)) -fc_lport_error (lport, fp); +fc_lport_error (lport,NULL ); }static struct fc_rport_operations fc_lport_rport_ops = {
@@ -1340,7 +1340,7 @@ static void fc_lport_enter_logo(struct fif (!lport->tt.elsct_send (lport,FC_FID_FLOGI , fp,ELS_LOGO , fc_lport_logo_resp, lport, lport->e_d_tov)) -fc_lport_error (lport, fp); +fc_lport_error (lport,NULL ); }/**
@@ -1456,7 +1456,7 @@ void fc_lport_enter_flogi(struct fc_lporif (!lport->tt.elsct_send (lport,FC_FID_FLOGI , fp,ELS_FLOGI , fc_lport_flogi_resp, lport, lport->e_d_tov)) -fc_lport_error (lport, fp); +fc_lport_error (lport,NULL ); }/* Configure a fc_lport */
drivers/scsi/libfc/fc_rport.c +5 -5
@@ -632,7 +632,7 @@ static void fc_rport_enter_plogi(structif (!lport->tt.elsct_send (lport, rdata->ids.port_id, fp,ELS_PLOGI , fc_rport_plogi_resp, rdata, lport->e_d_tov)) -fc_rport_error_retry (rdata, fp); +fc_rport_error_retry (rdata,NULL );else kref_get (&rdata->kref); }
@@ -793,7 +793,7 @@ static void fc_rport_enter_prli(struct fif (!lport->tt.elsct_send (lport, rdata->ids.port_id, fp,ELS_PRLI , fc_rport_prli_resp, rdata, lport->e_d_tov)) -fc_rport_error_retry (rdata, fp); +fc_rport_error_retry (rdata,NULL );else kref_get (&rdata->kref); }
@@ -889,7 +889,7 @@ static void fc_rport_enter_rtv(struct fcif (!lport->tt.elsct_send (lport, rdata->ids.port_id, fp,ELS_RTV , fc_rport_rtv_resp, rdata, lport->e_d_tov)) -fc_rport_error_retry (rdata, fp); +fc_rport_error_retry (rdata,NULL );else kref_get (&rdata->kref); }
@@ -919,7 +919,7 @@ static void fc_rport_enter_logo(struct fif (!lport->tt.elsct_send (lport, rdata->ids.port_id, fp,ELS_LOGO , fc_rport_logo_resp, rdata, lport->e_d_tov)) -fc_rport_error_retry (rdata, fp); +fc_rport_error_retry (rdata,NULL );else kref_get (&rdata->kref); }
@@ -1006,7 +1006,7 @@ static void fc_rport_enter_adisc(struct }if (!lport->tt.elsct_send (lport, rdata->ids.port_id, fp,ELS_ADISC , fc_rport_adisc_resp, rdata, lport->e_d_tov)) -fc_rport_error_retry (rdata, fp); +fc_rport_error_retry (rdata,NULL );else kref_get (&rdata->kref); }
PATCH 50/98 libfc: fix free of fc_rport_priv with timer pending
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Joe Eykholt <[email protected]>
commit b4a9c7ede96e90f7b1ec009ce7256059295e76df upstream.
Timer crashes were caused by freeing a struct fc_rport_priv with a timer pending, causing the timer facility list to be corrupted. This was during FC uplink flap tests with a lot of targets.
After discovery, we were doing an PLOGI on an rdata that was in DELETE state but not yet removed from the lookup list. This moved the rdata from DELETE state to PLOGI state. If the PLOGI exchange allocation failed and needed to be retried, the timer scheduling could race with the free being done by fc_rport_work().
When fc_rport_login() is called on a rport in DELETE state, move it to a new state RESTART. In fc_rport_work, when handling a LOGO, STOPPED or FAILED event, look for restart state. In the RESTART case, don't take the rdata off the list and after the transport remote port is deleted and exchanges are reset, re-login to the remote port.
Note that the new RESTART state also corrects a problem we had when re-discovering a port that had moved to DELETE state. In that case, a new rdata was created, but the old rdata would do an exchange manager reset affecting the FC_ID for both the new rdata and old rdata. With the new state, the new port isn't logged into until after any old exchanges are reset.
--- drivers/scsi/libfc/fc_rport.c | 69 ++++++++++++++++++++++++++++++------------ include/scsi/libfc.h | 1 2 files changed, 51 insertions(+), 19 deletions(-)
drivers/scsi/libfc/fc_rport.c +50 -19
@@ -86,6 +86,7 @@ static const char *fc_rport_state_names[ [RPORT_ST_LOGO] = "LOGO", [RPORT_ST_ADISC] = "ADISC", [RPORT_ST_DELETE] = "Delete", + [RPORT_ST_RESTART] = "Restart", };/**
@@ -99,8 +100,7 @@ static struct fc_rport_priv *fc_rport_lostruct fc_rport_priv *rdata;list_for_each_entry (rdata, &lport->disc.rports, peers) -if (rdata->ids.port_id == port_id && - rdata->rp_state !=RPORT_ST_DELETE ) +if (rdata->ids.port_id == port_id)return rdata;return NULL ; }
@@ -235,6 +235,7 @@ static void fc_rport_work(struct work_ststruct fc_rport_operations *rport_ops;struct fc_rport_identifiers ids;struct fc_rport *rport; +int restart =0 ;mutex_lock (&rdata->rp_mutex); event = rdata->event;
@@ -287,8 +288,19 @@ static void fc_rport_work(struct work_stmutex_unlock (&rdata->rp_mutex);if (port_id !=FC_FID_DIR_SERV ) { +/* +* We must drop rp_mutex before taking disc_mutex. +* Re-evaluate state to allow for restart. +* A transition to RESTART state must only happen +* while disc_mutex is held and rdata is on the list. +*/ mutex_lock (&lport->disc.disc_mutex); -list_del (&rdata->peers); +mutex_lock (&rdata->rp_mutex); +if (rdata->rp_state ==RPORT_ST_RESTART ) + restart =1 ; +else +list_del (&rdata->peers); +mutex_unlock (&rdata->rp_mutex);mutex_unlock (&lport->disc.disc_mutex); }
@@ -312,7 +324,13 @@ static void fc_rport_work(struct work_stmutex_unlock (&rdata->rp_mutex);fc_remote_port_delete (rport); } -kref_put (&rdata->kref, lport->tt.rport_destroy); +if (restart) { +mutex_lock (&rdata->rp_mutex); +FC_RPORT_DBG (rdata,"work restart\n" ); +fc_rport_enter_plogi (rdata); +mutex_unlock (&rdata->rp_mutex); + }else +kref_put (&rdata->kref, lport->tt.rport_destroy);break ;default :
@@ -342,6 +360,12 @@ int fc_rport_login(struct fc_rport_privFC_RPORT_DBG (rdata,"ADISC port\n" );fc_rport_enter_adisc (rdata);break ; +case RPORT_ST_RESTART : +break ; +case RPORT_ST_DELETE : +FC_RPORT_DBG (rdata,"Restart deleted port\n" ); +fc_rport_state_enter (rdata,RPORT_ST_RESTART ); +break ;default :FC_RPORT_DBG (rdata,"Login to port\n" );fc_rport_enter_plogi (rdata);
@@ -397,20 +421,21 @@ int fc_rport_logoff(struct fc_rport_privif (rdata->rp_state ==RPORT_ST_DELETE ) {FC_RPORT_DBG (rdata,"Port in Delete state, not removing\n" ); -mutex_unlock (&rdata->rp_mutex); goto out; } -fc_rport_enter_logo (rdata); +if (rdata->rp_state ==RPORT_ST_RESTART ) +FC_RPORT_DBG (rdata,"Port in Restart state, deleting\n" ); +else +fc_rport_enter_logo (rdata);/* * Change the state to Delete so that we discard * the response. */ fc_rport_enter_delete (rdata,RPORT_EV_STOP ); -mutex_unlock (&rdata->rp_mutex); - out: +mutex_unlock (&rdata->rp_mutex);return 0 ; }
@@ -466,6 +491,7 @@ static void fc_rport_timeout(struct workcase RPORT_ST_READY :case RPORT_ST_INIT :case RPORT_ST_DELETE : +case RPORT_ST_RESTART :break ; }
@@ -499,6 +525,7 @@ static void fc_rport_error(struct fc_rpofc_rport_enter_logo (rdata);break ;case RPORT_ST_DELETE : +case RPORT_ST_RESTART :case RPORT_ST_READY :case RPORT_ST_INIT :break ;
@@ -1248,6 +1275,7 @@ static void fc_rport_recv_plogi_req(stru }break ;case RPORT_ST_PRLI : +case RPORT_ST_RTV :case RPORT_ST_READY :case RPORT_ST_ADISC : FC_RPORT_DBG(rdata, "Received PLOGI in logged-in state %d "
@@ -1255,11 +1283,14 @@ static void fc_rport_recv_plogi_req(stru/* XXX TBD - should reset */ break ;case RPORT_ST_DELETE : -default : -FC_RPORT_DBG (rdata,"Received PLOGI in unexpected state %d\n" , - rdata->rp_state); -fc_frame_free (rx_fp); - goto out; +case RPORT_ST_LOGO : +case RPORT_ST_RESTART : +FC_RPORT_DBG (rdata,"Received PLOGI in state %s - send busy\n" , +fc_rport_state (rdata)); +mutex_unlock (&rdata->rp_mutex); + rjt_data.reason =ELS_RJT_BUSY ; + rjt_data.explan =ELS_EXPL_NONE ; + goto reject; }/*
@@ -1510,14 +1541,14 @@ static void fc_rport_recv_logo_req(strucFC_RPORT_DBG (rdata,"Received LOGO request while in state %s\n" ,fc_rport_state (rdata)); +fc_rport_enter_delete (rdata,RPORT_EV_LOGO ); +/* -* If the remote port was created due to discovery, -* log back in. It may have seen a stale RSCN about us. +* If the remote port was created due to discovery, set state +* to log back in. It may have seen a stale RSCN about us. */ -if (rdata->rp_state !=RPORT_ST_DELETE && rdata->disc_id) -fc_rport_enter_plogi (rdata); -else -fc_rport_enter_delete (rdata,RPORT_EV_LOGO ); +if (rdata->disc_id) +fc_rport_state_enter (rdata,RPORT_ST_RESTART );mutex_unlock (&rdata->rp_mutex); }else FC_RPORT_ID_DBG(lport, sid,
include/scsi/libfc.h +1 -0
@@ -145,6 +145,7 @@ enum fc_rport_state {RPORT_ST_LOGO ,/* port logout sent */ RPORT_ST_ADISC ,/* Discover Address sent */ RPORT_ST_DELETE ,/* port being deleted */ + RPORT_ST_RESTART, /* remote port being deleted and will restart */ };/**
Re: [50/98] [SCSI] libfc: fix free of fc_rport_priv with timer pending
Quoted 80 lines · Greg KH
2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Joe Eykholt <[email protected]>
commit
b4a9c7ede96e90f7b1ec009ce7256059295e76dfupstream.Timer crashes were caused by freeing a struct
fc_rport_privwith a timer pending, causing the timer facility list to be corrupted. This was during FC uplink flap tests with a lot of targets.After discovery, we were doing an PLOGI on an rdata that was in DELETE state but not yet removed from the lookup list. This moved the rdata from DELETE state to PLOGI state. If the PLOGI exchange allocation failed and needed to be retried, the timer scheduling could race with the free being done by
fc_rport_work().When
fc_rport_login()is called on a rport in DELETE state, move it to a new state RESTART. Infc_rport_work, when handling a LOGO, STOPPED or FAILED event, look for restart state. In the RESTART case, don't take the rdata off the list and after the transport remote port is deleted and exchanges are reset, re-login to the remote port.Note that the new RESTART state also corrects a problem we had when re-discovering a port that had moved to DELETE state. In that case, a new rdata was created, but the old rdata would do an exchange manager reset affecting the
FC_IDfor both the new rdata and old rdata. With the new state, the new port isn't logged into until after any old exchanges are reset.Signed-off-by Joe Eykholt <[email protected]>Signed-off-by Robert Love <[email protected]>Signed-off-by James Bottomley <[email protected]>Signed-off-by Greg Kroah-Hartman <[email protected]>--- drivers/scsi/libfc/fc_rport.c | 69 ++++++++++++++++++++++++++++++------------ include/scsi/libfc.h | 1 2 files changed, 51 insertions(+), 19 deletions(-)drivers/scsi/libfc/fc_rport.c +6
-2@@ -86,6 +86,7 @@ static const char *fc_rport_state_names[ [RPORT_ST_LOGO] = "LOGO", [RPORT_ST_ADISC] = "ADISC", [RPORT_ST_DELETE] = "Delete", + [RPORT_ST_RESTART] = "Restart", };/** @@ -99,8 +100,7 @@ static struct fc_rport_priv *fc_rport_lostruct fc_rport_priv *rdata;list_for_each_entry (rdata, &lport->disc.rports, peers) -if (rdata->ids.port_id == port_id && - rdata->rp_state !=RPORT_ST_DELETE ) +if (rdata->ids.port_id == port_id)return rdata;return NULL ; }@@ -235,6 +235,7 @@ static void fc_rport_work(struct work_ststruct fc_rport_operations *rport_ops;struct fc_rport_identifiers ids;struct fc_rport *rport; +int restart =0 ;mutex_lock (&rdata->rp_mutex); event = rdata->event;@@ -287,8 +288,19 @@ static void fc_rport_work(struct work_stmutex_unlock (&rdata->rp_mutex);if (port_id !=FC_FID_DIR_SERV ) { +/* +* We must drop rp_mutex before taking disc_mutex. +* Re-evaluate state to allow for restart.
drivers/scsi/libfc/fc_rport.c static void fc_rport_work(struct work_st · line 302
Quoted 10 lines
drivers/scsi/libfc/fc_rport.c +8
-1+* A transition to RESTART state must only happen +* while disc_mutex is held and rdata is on the list. +*/ mutex_lock (&lport->disc.disc_mutex); -list_del (&rdata->peers); +mutex_lock (&rdata->rp_mutex); +if (rdata->rp_state ==RPORT_ST_RESTART ) + restart =1 ; +else +list_del (&rdata->peers);
There is a follow-up patch that adds this line at this point:
rdata->event = RPORT_EV_NONE;
If this patch is integrated, that one should be integrated as well. That patch is:
commit 5543c72e2bbb30e5ba5938b18ec26617b8b3fb04
Author: Abhijeet Joglekar <[email protected]> Date: Thu Dec 10 09:59:20 2009 -0800
[SCSI] libfc: remote port gets stuck in restart state without really restarting
Joe
Quoted 135 lines
drivers/scsi/libfc/fc_rport.c +36
-16+mutex_unlock (&rdata->rp_mutex);mutex_unlock (&lport->disc.disc_mutex); }@@ -312,7 +324,13 @@ static void fc_rport_work(struct work_stmutex_unlock (&rdata->rp_mutex);fc_remote_port_delete (rport); } -kref_put (&rdata->kref, lport->tt.rport_destroy); +if (restart) { +mutex_lock (&rdata->rp_mutex); +FC_RPORT_DBG (rdata,"work restart\n" ); +fc_rport_enter_plogi (rdata); +mutex_unlock (&rdata->rp_mutex); + }else +kref_put (&rdata->kref, lport->tt.rport_destroy);break ;default :@@ -342,6 +360,12 @@ int fc_rport_login(struct fc_rport_privFC_RPORT_DBG (rdata,"ADISC port\n" );fc_rport_enter_adisc (rdata);break ; +case RPORT_ST_RESTART : +break ; +case RPORT_ST_DELETE : +FC_RPORT_DBG (rdata,"Restart deleted port\n" ); +fc_rport_state_enter (rdata,RPORT_ST_RESTART ); +break ;default :FC_RPORT_DBG (rdata,"Login to port\n" );fc_rport_enter_plogi (rdata);@@ -397,20 +421,21 @@ int fc_rport_logoff(struct fc_rport_privif (rdata->rp_state ==RPORT_ST_DELETE ) {FC_RPORT_DBG (rdata,"Port in Delete state, not removing\n" ); -mutex_unlock (&rdata->rp_mutex); goto out; } -fc_rport_enter_logo (rdata); +if (rdata->rp_state ==RPORT_ST_RESTART ) +FC_RPORT_DBG (rdata,"Port in Restart state, deleting\n" ); +else +fc_rport_enter_logo (rdata);/* * Change the state to Delete so that we discard * the response. */ fc_rport_enter_delete (rdata,RPORT_EV_STOP ); -mutex_unlock (&rdata->rp_mutex); - out: +mutex_unlock (&rdata->rp_mutex);return 0 ; }@@ -466,6 +491,7 @@ static void fc_rport_timeout(struct workcase RPORT_ST_READY :case RPORT_ST_INIT :case RPORT_ST_DELETE : +case RPORT_ST_RESTART :break ; }@@ -499,6 +525,7 @@ static void fc_rport_error(struct fc_rpofc_rport_enter_logo (rdata);break ;case RPORT_ST_DELETE : +case RPORT_ST_RESTART :case RPORT_ST_READY :case RPORT_ST_INIT :break ;@@ -1248,6 +1275,7 @@ static void fc_rport_recv_plogi_req(stru }break ;case RPORT_ST_PRLI : +case RPORT_ST_RTV :case RPORT_ST_READY :case RPORT_ST_ADISC : FC_RPORT_DBG(rdata, "Received PLOGI in logged-in state %d "@@ -1255,11 +1283,14 @@ static void fc_rport_recv_plogi_req(stru/* XXX TBD - should reset */ break ;case RPORT_ST_DELETE : -default : -FC_RPORT_DBG (rdata,"Received PLOGI in unexpected state %d\n" , - rdata->rp_state); -fc_frame_free (rx_fp); - goto out; +case RPORT_ST_LOGO : +case RPORT_ST_RESTART : +FC_RPORT_DBG (rdata,"Received PLOGI in state %s - send busy\n" , +fc_rport_state (rdata)); +mutex_unlock (&rdata->rp_mutex); + rjt_data.reason =ELS_RJT_BUSY ; + rjt_data.explan =ELS_EXPL_NONE ; + goto reject; }/* @@ -1510,14 +1541,14 @@ static void fc_rport_recv_logo_req(strucFC_RPORT_DBG (rdata,"Received LOGO request while in state %s\n" ,fc_rport_state (rdata)); +fc_rport_enter_delete (rdata,RPORT_EV_LOGO ); +/* -* If the remote port was created due to discovery, -* log back in. It may have seen a stale RSCN about us. +* If the remote port was created due to discovery, set state +* to log back in. It may have seen a stale RSCN about us. */ -if (rdata->rp_state !=RPORT_ST_DELETE && rdata->disc_id) -fc_rport_enter_plogi (rdata); -else -fc_rport_enter_delete (rdata,RPORT_EV_LOGO ); +if (rdata->disc_id) +fc_rport_state_enter (rdata,RPORT_ST_RESTART );mutex_unlock (&rdata->rp_mutex); }else FC_RPORT_ID_DBG(lport, sid,include/scsi/libfc.h +1
-0@@ -145,6 +145,7 @@ enum fc_rport_state {RPORT_ST_LOGO ,/* port logout sent */ RPORT_ST_ADISC ,/* Discover Address sent */ RPORT_ST_DELETE ,/* port being deleted */ + RPORT_ST_RESTART, /* remote port being deleted and will restart */ };/**
Re: [50/98] [SCSI] libfc: fix free of fc_rport_priv with timer pending
Quoted 96 lines · Joe Eykholt
Quoted 80 lines · Greg KH
2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Joe Eykholt <[email protected]>
commit
b4a9c7ede96e90f7b1ec009ce7256059295e76dfupstream.Timer crashes were caused by freeing a struct
fc_rport_privwith a timer pending, causing the timer facility list to be corrupted. This was during FC uplink flap tests with a lot of targets.After discovery, we were doing an PLOGI on an rdata that was in DELETE state but not yet removed from the lookup list. This moved the rdata from DELETE state to PLOGI state. If the PLOGI exchange allocation failed and needed to be retried, the timer scheduling could race with the free being done by
fc_rport_work().When
fc_rport_login()is called on a rport in DELETE state, move it to a new state RESTART. Infc_rport_work, when handling a LOGO, STOPPED or FAILED event, look for restart state. In the RESTART case, don't take the rdata off the list and after the transport remote port is deleted and exchanges are reset, re-login to the remote port.Note that the new RESTART state also corrects a problem we had when re-discovering a port that had moved to DELETE state. In that case, a new rdata was created, but the old rdata would do an exchange manager reset affecting the
FC_IDfor both the new rdata and old rdata. With the new state, the new port isn't logged into until after any old exchanges are reset.Signed-off-by Joe Eykholt <[email protected]>Signed-off-by Robert Love <[email protected]>Signed-off-by James Bottomley <[email protected]>Signed-off-by Greg Kroah-Hartman <[email protected]>--- drivers/scsi/libfc/fc_rport.c | 69 ++++++++++++++++++++++++++++++------------ include/scsi/libfc.h | 1 2 files changed, 51 insertions(+), 19 deletions(-)drivers/scsi/libfc/fc_rport.c +6
-2@@ -86,6 +86,7 @@ static const char *fc_rport_state_names[ [RPORT_ST_LOGO] = "LOGO", [RPORT_ST_ADISC] = "ADISC", [RPORT_ST_DELETE] = "Delete", + [RPORT_ST_RESTART] = "Restart", };/** @@ -99,8 +100,7 @@ static struct fc_rport_priv *fc_rport_lostruct fc_rport_priv *rdata;list_for_each_entry (rdata, &lport->disc.rports, peers) -if (rdata->ids.port_id == port_id && - rdata->rp_state !=RPORT_ST_DELETE ) +if (rdata->ids.port_id == port_id)return rdata;return NULL ; }@@ -235,6 +235,7 @@ static void fc_rport_work(struct work_ststruct fc_rport_operations *rport_ops;struct fc_rport_identifiers ids;struct fc_rport *rport; +int restart =0 ;mutex_lock (&rdata->rp_mutex); event = rdata->event;@@ -287,8 +288,19 @@ static void fc_rport_work(struct work_stmutex_unlock (&rdata->rp_mutex);if (port_id !=FC_FID_DIR_SERV ) { +/* +* We must drop rp_mutex before taking disc_mutex. +* Re-evaluate state to allow for restart. drivers/scsi/libfc/fc_rport.c static void fc_rport_work(struct work_st · line 302
Quoted 10 lines
drivers/scsi/libfc/fc_rport.c +8
-1+* A transition to RESTART state must only happen +* while disc_mutex is held and rdata is on the list. +*/ mutex_lock (&lport->disc.disc_mutex); -list_del (&rdata->peers); +mutex_lock (&rdata->rp_mutex); +if (rdata->rp_state ==RPORT_ST_RESTART ) + restart =1 ; +else +list_del (&rdata->peers);There is a follow-up patch that adds this line at this point:
rdata->event = RPORT_EV_NONE;
Quoted 8 lines
If this patch is integrated, that one should be integrated as well. That patch is:
commit
5543c72e2bbb30e5ba5938b18ec26617b8b3fb04Author: Abhijeet Joglekar <[email protected]> Date: Thu Dec 10 09:59:20 2009 -0800[SCSI] libfc: remote port gets stuck in restart state without really restarting
Thank you so much for the information, I have queued up this patch as well for the .32 tree.
thanks for the review,
greg k-h
PATCH 51/98 fcoe, libfc: fix an libfc issue with queue ramp down in libfc
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Vasu Dev <[email protected]>
commit 14caf44c69184ed72d46a2f883311daf27a4192f upstream.
The cmd_per_lun value is used by scsi-ml as fall back lowest queue_depth value but in case of libfc cmd_per_lun is set to same value as max queue_depth = 32.
So this patch reduces cmd_per_lun value to 3 and configures each lun with default max queue_depth 32 in fc_slave_alloc.
--- drivers/scsi/fcoe/fcoe.c | 2 +- drivers/scsi/libfc/fc_fcp.c | 14 ++++++-------- 2 files changed, 7 insertions(+), 9 deletions(-)
drivers/scsi/fcoe/fcoe.c +1 -1
@@ -137,7 +137,7 @@ static struct scsi_host_template fcoe_sh .change_queue_depth = fc_change_queue_depth, .change_queue_type = fc_change_queue_type, .this_id = -1, - .cmd_per_lun = 32, + .cmd_per_lun = 3, .can_queue = FCOE_MAX_OUTSTANDING_COMMANDS, .use_clustering = ENABLE_CLUSTERING, .sg_tablesize = SG_ALL,
drivers/scsi/libfc/fc_fcp.c +6 -8
@@ -2049,18 +2049,16 @@ EXPORT_SYMBOL(fc_eh_host_reset);int fc_slave_alloc (struct scsi_device *sdev) {struct fc_rport *rport =starget_to_rport (scsi_target (sdev)); -int queue_depth;if (!rport ||fc_remote_port_chkready (rport))return -ENXIO ; -if (sdev->tagged_supported) { -if (sdev->host->hostt->cmd_per_lun) - queue_depth = sdev->host->hostt->cmd_per_lun; -else - queue_depth =FC_FCP_DFLT_QUEUE_DEPTH ; -scsi_activate_tcq (sdev, queue_depth); - } +if (sdev->tagged_supported) +scsi_activate_tcq (sdev,FC_FCP_DFLT_QUEUE_DEPTH ); +else +scsi_adjust_queue_depth (sdev,scsi_get_tag_type (sdev), +FC_FCP_DFLT_QUEUE_DEPTH ); +return 0 ; }EXPORT_SYMBOL (fc_slave_alloc);
PATCH 52/98 fcoe: Fix checking san mac address
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Yi Zou <[email protected]>
commit bf361707c81f8e8e43e332bfc8838bae76ae021a upstream.
This was fixed before in 7a7f0c7 but it's introduced again recently.
--- drivers/scsi/fcoe/fcoe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/scsi/fcoe/fcoe.c +1 -1
@@ -176,7 +176,7 @@ static int fcoe_interface_setup(struct frcu_read_lock ();for_each_dev_addr (netdev, ha) {if ((ha->type ==NETDEV_HW_ADDR_T_SAN ) && - (is_valid_ether_addr (fip->ctl_src_addr))) { + (is_valid_ether_addr (ha->addr))) {memcpy (fip->ctl_src_addr, ha->addr,ETH_ALEN ); fip->spma =1 ;break ;
PATCH 53/98 fcoe: Fix getting san mac for VLAN interface
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Yi Zou <[email protected]>
commit 5bab87e6d465d54a2b5899e0f583d42f00dbee2e upstream.
Make sure we are get the SAN MAC address from the real netdev if the input netdev is a VLAN device.
--- drivers/scsi/fcoe/fcoe.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/scsi/fcoe/fcoe.c +4 -1
@@ -160,6 +160,7 @@ static int fcoe_interface_setup(struct f {struct fcoe_ctlr *fip = &fcoe->ctlr;struct netdev_hw_addr *ha; +struct net_device *real_dev;u8 flogi_maddr[ETH_ALEN ]; fcoe->netdev = netdev;
@@ -173,8 +174,10 @@ static int fcoe_interface_setup(struct f/* look for SAN MAC address, if multiple SAN MACs exist, only * use the first one for SPMA */ + real_dev = (netdev->priv_flags &IFF_802_1Q_VLAN ) ? +vlan_dev_real_dev (netdev) : netdev;rcu_read_lock (); -for_each_dev_addr (netdev, ha) { +for_each_dev_addr (real_dev, ha) {if ((ha->type ==NETDEV_HW_ADDR_T_SAN ) && (is_valid_ether_addr (ha->addr))) {memcpy (fip->ctl_src_addr, ha->addr,ETH_ALEN );
PATCH 54/98 qlge: Remove explicit setting of PCI Dev CTL reg.
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ron Mercer <[email protected]>
commit 1d1023d039d8295070b8dbb92c4d972237235304 upstream.
Remove explicit setting of error reporting bits.
--- drivers/net/qlge/qlge_main.c | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-)
drivers/net/qlge/qlge_main.c +1 -15
@@ -3868,8 +3868,7 @@ static int __devinit ql_init_device(stru struct net_device *ndev, int cards_found) {struct ql_adapter *qdev =netdev_priv (ndev); -int pos, err =0 ; -u16 val16; +int err =0 ;memset ((void *)qdev,0 ,sizeof (*qdev)); err =pci_enable_device (pdev);
@@ -3881,19 +3880,6 @@ static int __devinit ql_init_device(stru qdev->ndev = ndev; qdev->pdev = pdev;pci_set_drvdata (pdev, ndev); - pos =pci_find_capability (pdev,PCI_CAP_ID_EXP ); -if (pos <=0 ) { -dev_err (&pdev->dev,PFX "Cannot find PCI Express capability, " -"aborting.\n" ); -return pos; - }else { -pci_read_config_word (pdev, pos +PCI_EXP_DEVCTL , &val16); - val16 &= ~PCI_EXP_DEVCTL_NOSNOOP_EN ; - val16 |= (PCI_EXP_DEVCTL_CERE | -PCI_EXP_DEVCTL_NFERE | -PCI_EXP_DEVCTL_FERE |PCI_EXP_DEVCTL_URRE ); -pci_write_config_word (pdev, pos +PCI_EXP_DEVCTL , val16); - } err =pci_request_regions (pdev,DRV_NAME );if (err) {
PATCH 55/98 qlge: Set PCIE max read request size.
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ron Mercer <[email protected]>
commit bc9167f39ff8cd428e8577eb72751a653008edb2 upstream.
--- drivers/net/qlge/qlge_main.c | 7 +++++++ 1 file changed, 7 insertions(+)
drivers/net/qlge/qlge_main.c +7 -0
@@ -3881,6 +3881,13 @@ static int __devinit ql_init_device(stru qdev->pdev = pdev;pci_set_drvdata (pdev, ndev); +/* Set PCIe read request size */ + err =pcie_set_readrq (pdev,4096 ); +if (err) { +dev_err (&pdev->dev,"Set readrq failed.\n" ); + goto err_out; + } + err =pci_request_regions (pdev,DRV_NAME );if (err) {dev_err (&pdev->dev,"PCI region request failed.\n" );
PATCH 56/98 qlge: Dont fail open when port is not initialized.
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ron Mercer <[email protected]>
commit 80928860941023bb37e9c61927395d0eb753bc3b upstream.
--- drivers/net/qlge/qlge_main.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/net/qlge/qlge_main.c +2 -4
@@ -3310,10 +3310,8 @@ static int ql_adapter_initialize(struct/* Initialize the port and set the max framesize. */ status = qdev->nic_ops->port_initialize (qdev); -if (status) { -QPRINTK (qdev,IFUP ,ERR ,"Failed to start port.\n" ); -return status; - } +if (status) +QPRINTK (qdev,IFUP ,ERR ,"Failed to start port.\n" );/* Set up the MAC address and frame routing filter. */ status =ql_cam_route_initialize (qdev);
PATCH 57/98 qlge: Add handler for DCBX firmware event.
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ron Mercer <[email protected]>
commit 91ced682f9de17ebab5fcb2a70b48e372eb43281 upstream.
The driver has nothing to do, but this marker prevents the event from showing up 'not handled'.
--- drivers/net/qlge/qlge_mpi.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/net/qlge/qlge_mpi.c +3 -0
@@ -446,6 +446,9 @@ static int ql_mpi_handler(struct ql_adapql_aen_lost (qdev, mbcp);break ; +case AEN_DCBX_CHG : +/* Need to support AEN 8110 */ +break ;default :QPRINTK (qdev,DRV ,ERR ,"Unsupported AE %.08x.\n" , mbcp->mbox_out[0 ]);
PATCH 58/98 qlge: Bonding fix for mode 6.
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ron Mercer <[email protected]>
commit 63ae93a19094d88c8ca62543586b20e3a7ff7637 upstream.
Allow MAC address to be changed even if device is not up.
--- drivers/net/qlge/qlge_main.c | 3 --- 1 file changed, 3 deletions(-)
drivers/net/qlge/qlge_main.c +0 -3
@@ -3712,9 +3712,6 @@ static int qlge_set_mac_address(struct nstruct sockaddr *addr = p;int status; -if (netif_running (ndev)) -return -EBUSY ; -if (!is_valid_ether_addr (addr->sa_data))return -EADDRNOTAVAIL ;memcpy (ndev->dev_addr, addr->sa_data, ndev->addr_len);
PATCH 59/98 PCI: AER: fix aer inject result in kernel oops
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Song Youquan <[email protected]>
commit 46256f83d0d066f99ffde547f27473dfd2a78009 upstream.
If the BIOS does not export _OSC to allow OS take over the PCIe AER, the pcie aer driver will not initialize the aer service. However, the aer_inject driver does not check this scenario, which results in a kernel oops when injecting an aer error into OS. For example:
BUG: unable to handle kernel NULL pointer dereference at 0000000000000350 IP: [<ffffffff812e08f7>] _spin_lock_irqsave+0xc/0x23 PGD 155c41067 PUD 157fe0067 PMD 0 Oops: 0002 [#1] SMP Pid: 5119, comm: aer-inject Not tainted 2.6.32-rc8-mce #2 RIP: 0010:[<ffffffff812e08f7>] [<ffffffff812e08f7>] _spin_lock_irqsave+0xc/0x23 RSP: 0018:ffff880157f81e28 EFLAGS: 00010096 RAX: 0000000000000296 RBX: 0000000000000000 RCX: 0000000000000100 RDX: 0000000000010000 RSI: 0000000000000246 RDI: 0000000000000350 RBP: ffff880157f81e28 R08: 0000000000000004 R09: ffff880157f81dac R10: ffff88015a666f60 R11: ffff88015a666f40 R12: ffff88015758cc00 R13: 0000000000000350 R14: 0000000000000000 R15: 0000000000000100 FS: 00007f4d4a66e6f0(0000) GS:ffff8800282e0000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 000000008005003b CR2: 0000000000000350 CR3: 000000015661a000 CR4: 00000000000006e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400 Process aer-inject (pid: 5119, threadinfo ffff880157f80000, task ffff8801585f4340) Stack: ffff880157f81e78 ffffffff811b1615 ffff880157f81e78 ffffffff81222823 Call Trace: [<ffffffff811b1615>] aer_irq+0x38/0x117 [<ffffffff81222823>] ? device_for_each_child+0x5f/0x6f [<ffffffffa00967bf>] aer_inject_write+0x409/0x45e [aer_inject] [<ffffffff810eb80e>] vfs_write+0xae/0x16a [<ffffffff810eb98e>] sys_write+0x47/0x6e [<ffffffff8100ba2b>] system_call_fastpath+0x16/0x1b RIP [<ffffffff812e08f7>] _spin_lock_irqsave+0xc/0x23 RSP <ffff880157f81e28>
CR2: 0000000000000350
So check the _OSC before assuming that AER is available to the OS.
--- drivers/pci/pcie/aer/aer_inject.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
drivers/pci/pcie/aer/aer_inject.c +7 -1
@@ -392,8 +392,14 @@ static int aer_inject(struct aer_error_iif (ret) goto out_put; -if (find_aer_device (rpdev, &edev)) +if (find_aer_device (rpdev, &edev)) { +if (!get_service_data (edev)) { +printk (KERN_WARNING "AER service is not initialized\n" ); + ret = -EINVAL ; + goto out_put; + }aer_irq (-1 , edev); + }else ret = -EINVAL ; out_put:
PATCH 60/98 DMI: allow omitting ident strings in DMI tables
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Dmitry Torokhov <[email protected]>
commit 75757507e014fa074d25d2883c4ab604999584bd upstream.
The purpose of dmi->ident is twofold - it may be used by DMI callback functions when composing log messages; it is also used to determine end of DMI table in dmi_check_system() and dmi_first_match(). However, in case when callbacks are not interested in using ident at all it just wastes memory. Let's make entries with empty first match slot serve as end-of-table markers instead.
[needed for DMI table changes that need to be done by later patches - gkh]
--- drivers/firmware/dmi_scan.c | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-)
drivers/firmware/dmi_scan.c +12 -3
@@ -429,7 +429,7 @@ static bool dmi_matches(const struct dmifor (i =0 ; i <ARRAY_SIZE (dmi->matches); i++) {int s = dmi->matches[i].slot;if (s ==DMI_NONE ) -continue ; +break ;if (dmi_ident[s] &&strstr (dmi_ident[s], dmi->matches[i].substr))continue ;
@@ -440,6 +440,15 @@ static bool dmi_matches(const struct dmi }/** +* dmi_is_end_of_table - check for end-of-table marker +* @dmi: pointer to the dmi_system_id structure to check +*/ +static bool dmi_is_end_of_table (const struct dmi_system_id *dmi) +{ +return dmi->matches[0 ].slot ==DMI_NONE ; +} + +/** * dmi_check_system - check system DMI data * @list: array of dmi_system_id structures to match against * All non-null elements of the list must match
@@ -457,7 +466,7 @@ int dmi_check_system(const struct dmi_syint count =0 ;const struct dmi_system_id *d; -for (d = list; d->ident; d++) +for (d = list; !dmi_is_end_of_table (d); d++)if (dmi_matches (d)) { count++;if (d->callback && d->callback (d))
@@ -484,7 +493,7 @@ const struct dmi_system_id *dmi_first_ma {const struct dmi_system_id *d; -for (d = list; d->ident; d++) +for (d = list; !dmi_is_end_of_table (d); d++)if (dmi_matches (d))return d;
PATCH 61/98 Input: i8042 - remove identification strings from DMI tables
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Dmitry Torokhov <[email protected]>
commit f909b1df0a068f30e252d8dc3e9d45ca25bf266f upstream.
The driver does not reference identification strings in DMI tables and since these strings are no longer required by DMI core we can safely remove them and save some memory.
--- drivers/input/serio/i8042-x86ia64io.h | 143 +++++++++++++++------------------- 1 file changed, 66 insertions(+), 77 deletions(-)
drivers/input/serio/i8042-x86ia64io.h +66 -77
@@ -67,10 +67,12 @@ static inline void i8042_write_command(i#include <linux/dmi.h> -static struct dmi_system_id __initdata i8042_dmi_noloop_table[] = { +static const struct dmi_system_id __initconst i8042_dmi_noloop_table[] = { { -/* AUX LOOP command does not raise AUX IRQ */ - .ident ="Arima-Rioworks HDAMB" , +/* +* Arima-Rioworks HDAMB - +* AUX LOOP command does not raise AUX IRQ +*/ .matches = {DMI_MATCH (DMI_BOARD_VENDOR ,"RIOWORKS" ),DMI_MATCH (DMI_BOARD_NAME ,"HDAMB" ),
@@ -78,7 +80,7 @@ static struct dmi_system_id __initdata i }, }, { - .ident = "ASUS G1S", +/* ASUS G1S */ .matches = {DMI_MATCH (DMI_BOARD_VENDOR ,"ASUSTeK Computer Inc." ), DMI_MATCH(DMI_BOARD_NAME, "G1S"),
@@ -86,8 +88,7 @@ static struct dmi_system_id __initdata i }, }, { -/* AUX LOOP command does not raise AUX IRQ */ - .ident = "ASUS P65UP5", +/* ASUS P65UP5 - AUX LOOP command does not raise AUX IRQ */ .matches = {DMI_MATCH (DMI_BOARD_VENDOR ,"ASUSTeK Computer INC." ), DMI_MATCH(DMI_BOARD_NAME, "P/I-P65UP5"),
@@ -95,7 +96,6 @@ static struct dmi_system_id __initdata i }, }, { - .ident = "Compaq Proliant 8500", .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Compaq" ), DMI_MATCH(DMI_PRODUCT_NAME , "ProLiant"),
@@ -103,7 +103,6 @@ static struct dmi_system_id __initdata i }, }, { - .ident = "Compaq Proliant DL760", .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Compaq" ), DMI_MATCH(DMI_PRODUCT_NAME , "ProLiant"),
@@ -111,7 +110,7 @@ static struct dmi_system_id __initdata i }, }, { - .ident = "OQO Model 01", +/* OQO Model 01 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"OQO" ), DMI_MATCH(DMI_PRODUCT_NAME, "ZEPTO"),
@@ -119,8 +118,7 @@ static struct dmi_system_id __initdata i }, }, { -/* AUX LOOP does not work properly */ - .ident = "ULI EV4873", +/* ULI EV4873 - AUX LOOP does not work properly */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"ULI" ), DMI_MATCH(DMI_PRODUCT_NAME, "EV4873"),
@@ -128,7 +126,7 @@ static struct dmi_system_id __initdata i }, }, { - .ident = "Microsoft Virtual Machine", +/* Microsoft Virtual Machine */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Microsoft Corporation" ), DMI_MATCH(DMI_PRODUCT_NAME, "Virtual Machine"),
@@ -136,7 +134,7 @@ static struct dmi_system_id __initdata i }, }, { - .ident = "Medion MAM 2070", +/* Medion MAM 2070 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Notebook" ), DMI_MATCH(DMI_PRODUCT_NAME, "MAM 2070"),
@@ -144,7 +142,7 @@ static struct dmi_system_id __initdata i }, }, { - .ident = "Blue FB5601", +/* Blue FB5601 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"blue" ), DMI_MATCH(DMI_PRODUCT_NAME, "FB5601"),
@@ -152,7 +150,7 @@ static struct dmi_system_id __initdata i }, }, { - .ident = "Gigabyte M912", +/* Gigabyte M912 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"GIGABYTE" ), DMI_MATCH(DMI_PRODUCT_NAME, "M912"),
@@ -160,7 +158,6 @@ static struct dmi_system_id __initdata i }, }, { - .ident = "HP DV9700", .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Hewlett-Packard" ), DMI_MATCH(DMI_PRODUCT_NAME, "HP Pavilion dv9700"),
@@ -177,72 +174,72 @@ static struct dmi_system_id __initdata i* ... apparently some Toshibas don't like MUX mode either and * die horrible death on reboot. */ -static struct dmi_system_id __initdata i8042_dmi_nomux_table[] = { +static const struct dmi_system_id __initconst i8042_dmi_nomux_table[] = { { - .ident ="Fujitsu Lifebook P7010/P7010D" , +/* Fujitsu Lifebook P7010/P7010D */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"FUJITSU" ),DMI_MATCH (DMI_PRODUCT_NAME ,"P7010" ), }, }, { - .ident ="Fujitsu Lifebook P7010" , +/* Fujitsu Lifebook P7010 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"FUJITSU SIEMENS" ),DMI_MATCH (DMI_PRODUCT_NAME ,"0000000000" ), }, }, { - .ident ="Fujitsu Lifebook P5020D" , +/* Fujitsu Lifebook P5020D */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"FUJITSU" ),DMI_MATCH (DMI_PRODUCT_NAME ,"LifeBook P Series" ), }, }, { - .ident ="Fujitsu Lifebook S2000" , +/* Fujitsu Lifebook S2000 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"FUJITSU" ),DMI_MATCH (DMI_PRODUCT_NAME ,"LifeBook S Series" ), }, }, { - .ident ="Fujitsu Lifebook S6230" , +/* Fujitsu Lifebook S6230 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"FUJITSU" ),DMI_MATCH (DMI_PRODUCT_NAME ,"LifeBook S6230" ), }, }, { - .ident ="Fujitsu T70H" , +/* Fujitsu T70H */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"FUJITSU" ),DMI_MATCH (DMI_PRODUCT_NAME ,"FMVLT70H" ), }, }, { - .ident ="Fujitsu-Siemens Lifebook T3010" , +/* Fujitsu-Siemens Lifebook T3010 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"FUJITSU SIEMENS" ),DMI_MATCH (DMI_PRODUCT_NAME ,"LIFEBOOK T3010" ), }, }, { - .ident ="Fujitsu-Siemens Lifebook E4010" , +/* Fujitsu-Siemens Lifebook E4010 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"FUJITSU SIEMENS" ),DMI_MATCH (DMI_PRODUCT_NAME ,"LIFEBOOK E4010" ), }, }, { - .ident ="Fujitsu-Siemens Amilo Pro 2010" , +/* Fujitsu-Siemens Amilo Pro 2010 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"FUJITSU SIEMENS" ),DMI_MATCH (DMI_PRODUCT_NAME ,"AMILO Pro V2010" ), }, }, { - .ident ="Fujitsu-Siemens Amilo Pro 2030" , +/* Fujitsu-Siemens Amilo Pro 2030 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"FUJITSU SIEMENS" ),DMI_MATCH (DMI_PRODUCT_NAME ,"AMILO PRO V2030" ),
@@ -253,7 +250,7 @@ static struct dmi_system_id __initdata i* No data is coming from the touchscreen unless KBC * is in legacy mode. */ - .ident = "Panasonic CF-29", +/* Panasonic CF-29 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Matsushita" ), DMI_MATCH(DMI_PRODUCT_NAME, "CF-29"),
@@ -261,10 +258,10 @@ static struct dmi_system_id __initdata i }, {/* -* Errors on MUX ports are reported without raising AUXDATA +* HP Pavilion DV4017EA - +* errors on MUX ports are reported without raising AUXDATA * causing "spurious NAK" messages. */ - .ident = "HP Pavilion DV4017EA", .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Hewlett-Packard" ), DMI_MATCH(DMI_PRODUCT_NAME, "Pavilion dv4000 (EA032EA#ABF)"),
@@ -272,9 +269,9 @@ static struct dmi_system_id __initdata i }, {/* -* Like DV4017EA does not raise AUXERR for errors on MUX ports. +* HP Pavilion ZT1000 - +* like DV4017EA does not raise AUXERR for errors on MUX ports. */ - .ident = "HP Pavilion ZT1000", .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Hewlett-Packard" ), DMI_MATCH(DMI_PRODUCT_NAME, "HP Pavilion Notebook PC"),
@@ -283,44 +280,41 @@ static struct dmi_system_id __initdata i }, {/* -* Like DV4017EA does not raise AUXERR for errors on MUX ports. +* HP Pavilion DV4270ca - +* like DV4017EA does not raise AUXERR for errors on MUX ports. */ - .ident = "HP Pavilion DV4270ca", .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Hewlett-Packard" ), DMI_MATCH(DMI_PRODUCT_NAME, "Pavilion dv4000 (EH476UA#ABL)"), }, }, { - .ident ="Toshiba P10" , .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"TOSHIBA" ), DMI_MATCH(DMI_PRODUCT_NAME, "Satellite P10"), }, }, { - .ident ="Toshiba Equium A110" , .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"TOSHIBA" ), DMI_MATCH(DMI_PRODUCT_NAME, "EQUIUM A110"), }, }, { - .ident ="Alienware Sentia" , .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"ALIENWARE" ), DMI_MATCH(DMI_PRODUCT_NAME, "Sentia"), }, }, { - .ident ="Sharp Actius MM20" , +/* Sharp Actius MM20 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"SHARP" ), DMI_MATCH(DMI_PRODUCT_NAME, "PC-MM20 Series"), }, }, { - .ident ="Sony Vaio FS-115b" , +/* Sony Vaio FS-115b */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Sony Corporation" ), DMI_MATCH(DMI_PRODUCT_NAME, "VGN-FS115B"),
@@ -328,73 +322,72 @@ static struct dmi_system_id __initdata i }, {/* -* Reset and GET ID commands issued via KBD port are +* Sony Vaio FZ-240E - +* reset and GET ID commands issued via KBD port are * sometimes being delivered to AUX3. */ - .ident = "Sony Vaio FZ-240E", .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Sony Corporation" ), DMI_MATCH(DMI_PRODUCT_NAME, "VGN-FZ240E"), }, }, { - .ident ="Amoi M636/A737" , +/* Amoi M636/A737 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Amoi Electronics CO.,LTD." ), DMI_MATCH(DMI_PRODUCT_NAME, "M636/A737 platform"), }, }, { - .ident ="Lenovo 3000 n100" , +/* Lenovo 3000 n100 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"LENOVO" ), DMI_MATCH(DMI_PRODUCT_NAME, "076804U"), }, }, { - .ident ="Acer Aspire 1360" , .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ), DMI_MATCH(DMI_PRODUCT_NAME, "Aspire 1360"), }, }, { - .ident ="Gericom Bellagio" , +/* Gericom Bellagio */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Gericom" ), DMI_MATCH(DMI_PRODUCT_NAME, "N34AS6"), }, }, { - .ident ="IBM 2656" , +/* IBM 2656 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"IBM" ), DMI_MATCH(DMI_PRODUCT_NAME, "2656"), }, }, { - .ident ="Dell XPS M1530" , +/* Dell XPS M1530 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), DMI_MATCH(DMI_PRODUCT_NAME, "XPS M1530"), }, }, { - .ident ="Compal HEL80I" , +/* Compal HEL80I */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"COMPAL" ), DMI_MATCH(DMI_PRODUCT_NAME, "HEL80I"), }, }, { - .ident ="Dell Vostro 1510" , +/* Dell Vostro 1510 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), DMI_MATCH(DMI_PRODUCT_NAME, "Vostro1510"), }, }, { - .ident ="Acer Aspire 5536" , +/* Acer Aspire 5536 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ), DMI_MATCH(DMI_PRODUCT_NAME, "Aspire 5536"),
@@ -404,65 +397,65 @@ static struct dmi_system_id __initdata i { } }; -static struct dmi_system_id __initdata i8042_dmi_reset_table[] = { +static const struct dmi_system_id __initconst i8042_dmi_reset_table[] = { { - .ident ="MSI Wind U-100" , +/* MSI Wind U-100 */ .matches = {DMI_MATCH (DMI_BOARD_NAME ,"U-100" ),DMI_MATCH (DMI_BOARD_VENDOR ,"MICRO-STAR INTERNATIONAL CO., LTD" ), }, }, { - .ident ="LG Electronics X110" , +/* LG Electronics X110 */ .matches = {DMI_MATCH (DMI_BOARD_NAME ,"X110" ),DMI_MATCH (DMI_BOARD_VENDOR ,"LG Electronics Inc." ), }, }, { - .ident ="Acer Aspire One 150" , +/* Acer Aspire One 150 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ),DMI_MATCH (DMI_PRODUCT_NAME ,"AOA150" ), }, }, { - .ident ="Advent 4211" , +/* Advent 4211 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"DIXONSXP" ),DMI_MATCH (DMI_PRODUCT_NAME ,"Advent 4211" ), }, }, { - .ident ="Medion Akoya Mini E1210" , +/* Medion Akoya Mini E1210 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"MEDION" ),DMI_MATCH (DMI_PRODUCT_NAME ,"E1210" ), }, }, { - .ident ="Mivvy M310" , +/* Mivvy M310 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"VIOOO" ),DMI_MATCH (DMI_PRODUCT_NAME ,"N10" ), }, }, { - .ident ="Dell Vostro 1320" , +/* Dell Vostro 1320 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ),DMI_MATCH (DMI_PRODUCT_NAME ,"Vostro 1320" ), }, }, { - .ident ="Dell Vostro 1520" , +/* Dell Vostro 1520 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ),DMI_MATCH (DMI_PRODUCT_NAME ,"Vostro 1520" ), }, }, { - .ident ="Dell Vostro 1720" , +/* Dell Vostro 1720 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ),DMI_MATCH (DMI_PRODUCT_NAME ,"Vostro 1720" ),
@@ -472,16 +465,16 @@ static struct dmi_system_id __initdata i }; #ifdef CONFIG_PNP -static struct dmi_system_id __initdata i8042_dmi_nopnp_table[] = { +static const struct dmi_system_id __initconst i8042_dmi_nopnp_table[] = { { - .ident = "Intel MBO Desktop D845PESV", + /* Intel MBO Desktop D845PESV */ .matches = { DMI_MATCH(DMI_BOARD_NAME, "D845PESV"), DMI_MATCH(DMI_BOARD_VENDOR, "Intel Corporation"), }, }, { - .ident = "MSI Wind U-100", + /* MSI Wind U-100 */ .matches = { DMI_MATCH(DMI_BOARD_NAME, "U-100"), DMI_MATCH(DMI_BOARD_VENDOR, "MICRO-STAR INTERNATIONAL CO., LTD"),
@@ -490,27 +483,23 @@ static struct dmi_system_id __initdata i { } }; -static struct dmi_system_id __initdata i8042_dmi_laptop_table[] = { +static const struct dmi_system_id __initconst i8042_dmi_laptop_table[] = { { - .ident ="Portable" , .matches = {DMI_MATCH (DMI_CHASSIS_TYPE ,"8" ),/* Portable */ }, }, { - .ident ="Laptop" , .matches = {DMI_MATCH (DMI_CHASSIS_TYPE ,"9" ),/* Laptop */ }, }, { - .ident ="Notebook" , .matches = {DMI_MATCH (DMI_CHASSIS_TYPE ,"10" ),/* Notebook */ }, }, { - .ident ="Sub-Notebook" , .matches = {DMI_MATCH (DMI_CHASSIS_TYPE ,"14" ),/* Sub-Notebook */ },
@@ -525,58 +514,58 @@ static struct dmi_system_id __initdata i* Originally, this was just confined to older laptops, but a few Acer laptops * have turned up in 2007 that also need this again. */ -static struct dmi_system_id __initdata i8042_dmi_dritek_table[] = { +static const struct dmi_system_id __initconst i8042_dmi_dritek_table[] = { { - .ident ="Acer Aspire 5630" , +/* Acer Aspire 5630 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ),DMI_MATCH (DMI_PRODUCT_NAME ,"Aspire 5630" ), }, }, { - .ident ="Acer Aspire 5650" , +/* Acer Aspire 5650 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ),DMI_MATCH (DMI_PRODUCT_NAME ,"Aspire 5650" ), }, }, { - .ident ="Acer Aspire 5680" , +/* Acer Aspire 5680 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ),DMI_MATCH (DMI_PRODUCT_NAME ,"Aspire 5680" ), }, }, { - .ident ="Acer Aspire 5720" , +/* Acer Aspire 5720 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ),DMI_MATCH (DMI_PRODUCT_NAME ,"Aspire 5720" ), }, }, { - .ident ="Acer Aspire 9110" , +/* Acer Aspire 9110 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ),DMI_MATCH (DMI_PRODUCT_NAME ,"Aspire 9110" ), }, }, { - .ident ="Acer TravelMate 660" , +/* Acer TravelMate 660 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ),DMI_MATCH (DMI_PRODUCT_NAME ,"TravelMate 660" ), }, }, { - .ident ="Acer TravelMate 2490" , +/* Acer TravelMate 2490 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ),DMI_MATCH (DMI_PRODUCT_NAME ,"TravelMate 2490" ), }, }, { - .ident ="Acer TravelMate 4280" , +/* Acer TravelMate 4280 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ),DMI_MATCH (DMI_PRODUCT_NAME ,"TravelMate 4280" ),
Re: [61/98] Input: i8042 - remove identification strings from DMI tables
Quoted 7 lines · Greg KH
2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Dmitry Torokhov <[email protected]>
Quoted 7 lines
commit
f909b1df0a068f30e252d8dc3e9d45ca25bf266fupstream.The driver does not reference identification strings in DMI tables and since these strings are no longer required by DMI core we can safely remove them and save some memory.
Signed-off-by Dmitry Torokhov <[email protected]>
This seems to have lost your sign-off?
Linus
Re: [61/98] Input: i8042 - remove identification strings from DMI tables
Quoted 12 lines · Linus Torvalds
Quoted 9 lines · Greg KH
2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Dmitry Torokhov <[email protected]>
commit
f909b1df0a068f30e252d8dc3e9d45ca25bf266fupstream.
Quoted 7 lines
Quoted 5 lines
The driver does not reference identification strings in DMI tables and since these strings are no longer required by DMI core we can safely remove them and save some memory.
Signed-off-by Dmitry Torokhov <[email protected]>This seems to have lost your sign-off?
Argh, good catch, I've now added it.
thanks,
greg k-h
PATCH 62/98 Input: i8042 - add Gigabyte M1022M to the noloop list
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Dmitry Torokhov <[email protected]>
commit a61cd03827eceefcec19eefc6e1173703fdc5e5d upstream.
Gigabyte netbook model M1022M requires i8042.noloop, otherwise AUX port will not detected and the touchpad will not work. Unfortunately chassis type in DMI set to "Other" and thus generic laptop entry does not fire on it.
--- drivers/input/serio/i8042-x86ia64io.h | 8 ++++++++ 1 file changed, 8 insertions(+)
drivers/input/serio/i8042-x86ia64io.h +8 -0
@@ -158,6 +158,14 @@ static const struct dmi_system_id __init }, }, { +/* Gigabyte M1022M netbook */ + .matches = { +DMI_MATCH (DMI_BOARD_VENDOR ,"Gigabyte Technology Co.,Ltd." ), +DMI_MATCH (DMI_BOARD_NAME ,"M1022E" ), + DMI_MATCH(DMI_BOARD_VERSION, "1.02"), + }, + }, + { .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Hewlett-Packard" ), DMI_MATCH(DMI_PRODUCT_NAME, "HP Pavilion dv9700"),
PATCH 63/98 Input: i8042 - add Dritek quirk for Acer Aspire 5610.
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Elliott Sales de Andrade <[email protected]>
commit e6edbdc52bc0755cbfe0721ca91d4fd87649bc13 upstream.
--- drivers/input/serio/i8042-x86ia64io.h | 7 +++++++ 1 file changed, 7 insertions(+)
drivers/input/serio/i8042-x86ia64io.h +7 -0
@@ -524,6 +524,13 @@ static const struct dmi_system_id __init*/ static const struct dmi_system_id __initconst i8042_dmi_dritek_table[] = { { +/* Acer Aspire 5610 */ + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ), +DMI_MATCH (DMI_PRODUCT_NAME ,"Aspire 5610" ), + }, + }, + {/* Acer Aspire 5630 */ .matches = {DMI_MATCH (DMI_SYS_VENDOR ,"Acer" ),
PATCH 64/98 ALSA: hda - select IbexPeak handler for Calpella
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Wu Fengguang <[email protected]>
commit 739b47f1e5aa3b36eadd7906cc6b41f0175c6ed1 upstream.
An earlier patch merely adds id for 0x80862804.
It has 2/3 cvt/pin nodes and shall be tied to the IbexPeak handler.
--- sound/pci/hda/patch_intelhdmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/pci/hda/patch_intelhdmi.c +1 -1
@@ -684,7 +684,7 @@ static struct hda_codec_preset snd_hda_p { .id = 0x80862801, .name = "G45 DEVBLC", .patch = patch_intel_hdmi }, { .id = 0x80862802, .name = "G45 DEVCTG", .patch = patch_intel_hdmi }, { .id = 0x80862803, .name = "G45 DEVELK", .patch = patch_intel_hdmi }, - { .id = 0x80862804, .name = "G45 DEVIBX", .patch = patch_intel_hdmi }, + { .id = 0x80862804, .name = "G45 DEVIBX", .patch = patch_intel_hdmi_ibexpeak }, { .id = 0x80860054, .name = "Q57 DEVIBX", .patch = patch_intel_hdmi_ibexpeak }, { .id = 0x10951392, .name = "SiI1392 HDMI", .patch = patch_intel_hdmi }, {} /* terminator */
PATCH 65/98 ALSA: hda - Fix quirk for Maxdata obook4-1
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Takashi Iwai <[email protected]>
commit 2fef62c825f09e29d2f52dc187ddf6f99e28c7f1 upstream.
Works fine with the auto-parser.
Reference: Novell bnc#564940
https://bugzilla.novell.com/show_bug.cgi?id=564940
--- sound/pci/hda/patch_realtek.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
sound/pci/hda/patch_realtek.c +1 -1
@@ -8839,7 +8839,7 @@ static struct snd_pci_quirk alc882_cfg_tSND_PCI_QUIRK (0x1462 ,0x040d ,"MSI" , ALC883_TARGA_2ch_DIG),SND_PCI_QUIRK (0x1462 ,0x0579 ,"MSI" , ALC883_TARGA_2ch_DIG),SND_PCI_QUIRK (0x1462 ,0x28fb ,"Targa T8" ,ALC882_TARGA ),/* MSI-1049 T8 */ -SND_PCI_QUIRK (0x1462 ,0x2fb3 ,"MSI" , ALC883_TARGA_2ch_DIG), +SND_PCI_QUIRK (0x1462 ,0x2fb3 ,"MSI" ,ALC882_AUTO ),SND_PCI_QUIRK (0x1462 ,0x6668 ,"MSI" ,ALC882_6ST_DIG ),SND_PCI_QUIRK (0x1462 ,0x3729 ,"MSI S420" ,ALC883_TARGA_DIG ), SND_PCI_QUIRK(0x1462, 0x3783, "NEC S970", ALC883_TARGA_DIG),
PATCH 66/98 ALSA: hda - Add missing Line-Out and PCM switches as slave
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Takashi Iwai <[email protected]>
commit 23033b2bce4361f2859ee0331f97c9056dae7091 upstream.
Realtek codecs may have "PCM" and "Line-Out" playback switches, and they can be slaves for vmaster.
--- sound/pci/hda/patch_realtek.c | 2 ++ 1 file changed, 2 insertions(+)
sound/pci/hda/patch_realtek.c +2 -0
@@ -2401,6 +2401,8 @@ static const char *alc_slave_sws[] = {"Speaker Playback Switch" ,"Mono Playback Switch" ,"IEC958 Playback Switch" , +"Line-Out Playback Switch" , +"PCM Playback Switch" , NULL, };
PATCH 67/98 iTCO_wdt.c - cleanup chipset documentation
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Wim Van Sebroeck <[email protected]>
commit cb711a1931363b8ad4dc98df4a92c262ced8eeb4 upstream.
Cleanup the documentation about the supported chipsets.
[needed for further device ids to add to this driver - gkh]
--- drivers/watchdog/iTCO_wdt.c | 61 ++++++++++++-------------------------------- 1 file changed, 17 insertions(+), 44 deletions(-)
drivers/watchdog/iTCO_wdt.c +17 -44
@@ -1,5 +1,5 @@/* -* intel TCO Watchdog Driver (Used in i82801 and i63xxESB chipsets) +* intel TCO Watchdog Driver * * (c) Copyright 2006-2009 Wim Van Sebroeck <[email protected]>. *
@@ -14,49 +14,22 @@* * The TCO watchdog is implemented in the following I/O controller hubs: * (See the intel documentation on http://developer.intel.com.) -* 82801AA (ICH) : document number 290655-003, 290677-014, -* 82801AB (ICHO) : document number 290655-003, 290677-014, -* 82801BA (ICH2) : document number 290687-002, 298242-027, -* 82801BAM (ICH2-M) : document number 290687-002, 298242-027, -* 82801CA (ICH3-S) : document number 290733-003, 290739-013, -* 82801CAM (ICH3-M) : document number 290716-001, 290718-007, -* 82801DB (ICH4) : document number 290744-001, 290745-025, -* 82801DBM (ICH4-M) : document number 252337-001, 252663-008, -* 82801E (C-ICH) : document number 273599-001, 273645-002, -* 82801EB (ICH5) : document number 252516-001, 252517-028, -* 82801ER (ICH5R) : document number 252516-001, 252517-028, -* 6300ESB (6300ESB) : document number 300641-004, 300884-013, -* 82801FB (ICH6) : document number 301473-002, 301474-026, -* 82801FR (ICH6R) : document number 301473-002, 301474-026, -* 82801FBM (ICH6-M) : document number 301473-002, 301474-026, -* 82801FW (ICH6W) : document number 301473-001, 301474-026, -* 82801FRW (ICH6RW) : document number 301473-001, 301474-026, -* 631xESB (631xESB) : document number 313082-001, 313075-006, -* 632xESB (632xESB) : document number 313082-001, 313075-006, -* 82801GB (ICH7) : document number 307013-003, 307014-024, -* 82801GR (ICH7R) : document number 307013-003, 307014-024, -* 82801GDH (ICH7DH) : document number 307013-003, 307014-024, -* 82801GBM (ICH7-M) : document number 307013-003, 307014-024, -* 82801GHM (ICH7-M DH) : document number 307013-003, 307014-024, -* 82801GU (ICH7-U) : document number 307013-003, 307014-024, -* 82801HB (ICH8) : document number 313056-003, 313057-017, -* 82801HR (ICH8R) : document number 313056-003, 313057-017, -* 82801HBM (ICH8M) : document number 313056-003, 313057-017, -* 82801HH (ICH8DH) : document number 313056-003, 313057-017, -* 82801HO (ICH8DO) : document number 313056-003, 313057-017, -* 82801HEM (ICH8M-E) : document number 313056-003, 313057-017, -* 82801IB (ICH9) : document number 316972-004, 316973-012, -* 82801IR (ICH9R) : document number 316972-004, 316973-012, -* 82801IH (ICH9DH) : document number 316972-004, 316973-012, -* 82801IO (ICH9DO) : document number 316972-004, 316973-012, -* 82801IBM (ICH9M) : document number 316972-004, 316973-012, -* 82801IEM (ICH9M-E) : document number 316972-004, 316973-012, -* 82801JIB (ICH10) : document number 319973-002, 319974-002, -* 82801JIR (ICH10R) : document number 319973-002, 319974-002, -* 82801JD (ICH10D) : document number 319973-002, 319974-002, -* 82801JDO (ICH10DO) : document number 319973-002, 319974-002, -* 5 Series (PCH) : document number 322169-001, 322170-001, -* 3400 Series (PCH) : document number 322169-001, 322170-001 +* document number 290655-003, 290677-014: 82801AA (ICH), 82801AB (ICHO) +* document number 290687-002, 298242-027: 82801BA (ICH2) +* document number 290733-003, 290739-013: 82801CA (ICH3-S) +* document number 290716-001, 290718-007: 82801CAM (ICH3-M) +* document number 290744-001, 290745-025: 82801DB (ICH4) +* document number 252337-001, 252663-008: 82801DBM (ICH4-M) +* document number 273599-001, 273645-002: 82801E (C-ICH) +* document number 252516-001, 252517-028: 82801EB (ICH5), 82801ER (ICH5R) +* document number 300641-004, 300884-013: 6300ESB +* document number 301473-002, 301474-026: 82801F (ICH6) +* document number 313082-001, 313075-006: 631xESB, 632xESB +* document number 307013-003, 307014-024: 82801G (ICH7) +* document number 313056-003, 313057-017: 82801H (ICH8) +* document number 316972-004, 316973-012: 82801I (ICH9) +* document number 319973-002, 319974-002: 82801J (ICH10) +* document number 322169-001, 322170-001: 5 Series, 3400 Series (PCH) */ /*
PATCH 68/98 iTCO_wdt: add PCI ID for the Intel EP80579 (Tolapai) SoC
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Imre Kaloz <[email protected]>
commit 4946f8353da9d3038e2a9d0295d5dfeee4cee5c5 upstream.
add PCI ID for the Intel EP80579 (Tolapai) SoC
--- drivers/watchdog/iTCO_wdt.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/watchdog/iTCO_wdt.c +4 -0
@@ -30,6 +30,7 @@* document number 316972-004, 316973-012: 82801I (ICH9) * document number 319973-002, 319974-002: 82801J (ICH10) * document number 322169-001, 322170-001: 5 Series, 3400 Series (PCH) +* document number 320066-003, 320257-008: EP80597 (IICH) */ /*
@@ -100,6 +101,7 @@ enum iTCO_chipsets {TCO_PCH ,/* PCH Desktop Full Featured */ TCO_PCHM ,/* PCH Mobile Full Featured */ TCO_PCHMSFF ,/* PCH Mobile SFF Full Featured */ + TCO_EP80579, /* EP80579 */ }; static struct {
@@ -143,6 +145,7 @@ static struct { {"PCH Desktop Full Featured", 2}, {"PCH Mobile Full Featured", 2}, {"PCH Mobile SFF Full Featured", 2}, + {"EP80579", 2}, {NULL, 0} };
@@ -214,6 +217,7 @@ static struct pci_device_id iTCO_wdt_pci { ITCO_PCI_DEVICE(0x3b00, TCO_PCH)}, { ITCO_PCI_DEVICE(0x3b01, TCO_PCHM)}, { ITCO_PCI_DEVICE(0x3b0d, TCO_PCHMSFF)}, + { ITCO_PCI_DEVICE(0x5031, TCO_EP80579)}, { 0, }, /* End of list */ };MODULE_DEVICE_TABLE (pci, iTCO_wdt_pci_tbl);
PATCH 69/98 iTCO_wdt: Add Intel Cougar Point and PCH DeviceIDs
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Seth Heasley <[email protected]>
commit 3c9d8eccd8687f0e770e4d89fd0d73d4f81a985a upstream.
This patch adds the Intel Cougar Point and PCH DeviceIDs for iTCO Watchdog.
--- drivers/watchdog/iTCO_wdt.c | 45 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 44 insertions(+), 1 deletion(-)
drivers/watchdog/iTCO_wdt.c +44 -1
@@ -29,8 +29,9 @@* document number 313056-003, 313057-017: 82801H (ICH8) * document number 316972-004, 316973-012: 82801I (ICH9) * document number 319973-002, 319974-002: 82801J (ICH10) -* document number 322169-001, 322170-001: 5 Series, 3400 Series (PCH) +* document number 322169-001, 322170-003: 5 Series, 3400 Series (PCH) * document number 320066-003, 320257-008: EP80597 (IICH) +* document number TBD : Cougar Point (CPT) */ /*
@@ -100,8 +101,22 @@ enum iTCO_chipsets {TCO_ICH10DO ,/* ICH10DO */ TCO_PCH ,/* PCH Desktop Full Featured */ TCO_PCHM ,/* PCH Mobile Full Featured */ +TCO_P55 ,/* P55 */ +TCO_PM55 ,/* PM55 */ +TCO_H55 ,/* H55 */ +TCO_QM57 ,/* QM57 */ +TCO_H57 ,/* H57 */ +TCO_HM55 ,/* HM55 */ +TCO_Q57 ,/* Q57 */ +TCO_HM57 ,/* HM57 */ TCO_PCHMSFF ,/* PCH Mobile SFF Full Featured */ +TCO_QS57 ,/* QS57 */ +TCO_3400 ,/* 3400 */ +TCO_3420 ,/* 3420 */ +TCO_3450 ,/* 3450 */ TCO_EP80579 ,/* EP80579 */ +TCO_CPTD ,/* CPT Desktop */ + TCO_CPTM, /* CPT Mobile */ }; static struct {
@@ -144,8 +159,22 @@ static struct { {"ICH10DO", 2}, {"PCH Desktop Full Featured", 2}, {"PCH Mobile Full Featured", 2}, + {"P55", 2}, + {"PM55", 2}, + {"H55", 2}, + {"QM57", 2}, + {"H57", 2}, + {"HM55", 2}, + {"Q57", 2}, + {"HM57", 2}, {"PCH Mobile SFF Full Featured", 2}, + {"QS57", 2}, + {"3400", 2}, + {"3420", 2}, + {"3450", 2}, {"EP80579", 2}, + {"CPT Desktop", 2}, + {"CPT Mobile", 2}, {NULL, 0} };
@@ -216,8 +245,22 @@ static struct pci_device_id iTCO_wdt_pci { ITCO_PCI_DEVICE(0x3a14, TCO_ICH10DO)}, { ITCO_PCI_DEVICE(0x3b00, TCO_PCH)}, { ITCO_PCI_DEVICE(0x3b01, TCO_PCHM)}, + { ITCO_PCI_DEVICE(0x3b02, TCO_P55)}, + { ITCO_PCI_DEVICE(0x3b03, TCO_PM55)}, + { ITCO_PCI_DEVICE(0x3b06, TCO_H55)}, + { ITCO_PCI_DEVICE(0x3b07, TCO_QM57)}, + { ITCO_PCI_DEVICE(0x3b08, TCO_H57)}, + { ITCO_PCI_DEVICE(0x3b09, TCO_HM55)}, + { ITCO_PCI_DEVICE(0x3b0a, TCO_Q57)}, + { ITCO_PCI_DEVICE(0x3b0b, TCO_HM57)}, { ITCO_PCI_DEVICE(0x3b0d, TCO_PCHMSFF)}, + { ITCO_PCI_DEVICE(0x3b0f, TCO_QS57)}, + { ITCO_PCI_DEVICE(0x3b12, TCO_3400)}, + { ITCO_PCI_DEVICE(0x3b14, TCO_3420)}, + { ITCO_PCI_DEVICE(0x3b16, TCO_3450)}, { ITCO_PCI_DEVICE(0x5031, TCO_EP80579)}, + { ITCO_PCI_DEVICE(0x1c42, TCO_CPTD)}, + { ITCO_PCI_DEVICE(0x1c43, TCO_CPTM)}, { 0, }, /* End of list */ };MODULE_DEVICE_TABLE (pci, iTCO_wdt_pci_tbl);
PATCH 70/98 ahci: disable SNotification capability for ich8
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Shaohua Li <[email protected]>
commit 1b677afda44f7882b7e257d6f025d006ec5d14f9 upstream.
I obseved there is a sata_async_notification() for every ahci interrupt. But the async notification does nothing (this is hard disk drive and no pmp). This cause cpu wastes some time on sntf register access.
It appears ICH AHCI doesn't support SNotification register, but the controller reports it does. After quirking it, the async notification disappears.
PS. it appears all ICH don't support SNotification register from ICH manual, don't know if we need quirk all ICH. I don't have machines with all kinds of ICH.
--- drivers/ata/ahci.c | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-)
drivers/ata/ahci.c +18 -2
@@ -113,6 +113,7 @@ enum { board_ahci_mcp65 =6 , board_ahci_nopmp =7 , board_ahci_yesncq =8 , + board_ahci_nosntf =9 ,/* global controller registers */ HOST_CAP = 0x00, /* host capabilities */
@@ -235,6 +236,7 @@ enum {AHCI_HFLAG_NO_SUSPEND = (1 <<10 ),/* don't suspend */ AHCI_HFLAG_SRST_TOUT_IS_OFFLINE = (1 <<11 ),/* treat SRST timeout as link offline */ + AHCI_HFLAG_NO_SNTF = (1 << 12), /* no sntf *//* ap->flags bits */
@@ -508,7 +510,7 @@ static const struct ata_port_info ahci_p .udma_mask = ATA_UDMA6, .port_ops = &ahci_ops, }, -/* board_ahci_yesncq */ + [board_ahci_yesncq] = { AHCI_HFLAGS (AHCI_HFLAG_YES_NCQ), .flags = AHCI_FLAG_COMMON,
@@ -516,6 +518,14 @@ static const struct ata_port_info ahci_p .udma_mask = ATA_UDMA6, .port_ops = &ahci_ops, }, + [board_ahci_nosntf] = + { + AHCI_HFLAGS (AHCI_HFLAG_NO_SNTF), + .flags = AHCI_FLAG_COMMON, + .pio_mask = ATA_PIO4, + .udma_mask = ATA_UDMA6, + .port_ops = &ahci_ops, + }, }; static const struct pci_device_id ahci_pci_tbl[] = {
@@ -531,7 +541,7 @@ static const struct pci_device_id ahci_p { PCI_VDEVICE(INTEL, 0x2683), board_ahci }, /* ESB2 */ { PCI_VDEVICE(INTEL, 0x27c6), board_ahci }, /* ICH7-M DH */ { PCI_VDEVICE(INTEL, 0x2821), board_ahci }, /* ICH8 */ - { PCI_VDEVICE(INTEL, 0x2822), board_ahci }, /* ICH8 */ + { PCI_VDEVICE(INTEL, 0x2822), board_ahci_nosntf }, /* ICH8 */ { PCI_VDEVICE(INTEL, 0x2824), board_ahci }, /* ICH8 */ { PCI_VDEVICE(INTEL, 0x2829), board_ahci }, /* ICH8M */ { PCI_VDEVICE(INTEL, 0x282a), board_ahci }, /* ICH8M */
@@ -849,6 +859,12 @@ static void ahci_save_initial_config(str cap &= ~HOST_CAP_PMP ; } +if ((cap &HOST_CAP_SNTF ) && (hpriv->flags &AHCI_HFLAG_NO_SNTF )) { +dev_printk (KERN_INFO , &pdev->dev, +"controller can't do SNTF, turning off CAP_SNTF\n" ); + cap &= ~HOST_CAP_SNTF ; + } +if (pdev->vendor ==PCI_VENDOR_ID_JMICRON && pdev->device ==0x2361 && port_map !=1 ) { dev_printk(KERN_INFO, &pdev->dev,
PATCH 71/98 ata_piix: fix MWDMA handling on PIIX3
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Bartlomiej Zolnierkiewicz <[email protected]>
commit 6938594374ee506e91a4c03117a034ea0ed66783 upstream.
Fix erroneous check for ap->udma_mask in do_pata_set_dmamode() resulting in controller not being programmed properly for MWDMA.
--- drivers/ata/ata_piix.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/ata/ata_piix.c +3 -3
@@ -869,10 +869,10 @@ static void do_pata_set_dmamode(struct a (timings[pio][1 ] <<8 ); } -if (ap->udma_mask) { +if (ap->udma_mask) udma_enable &= ~(1 << devid); -pci_write_config_word (dev, master_port, master_data); - } + +pci_write_config_word (dev, master_port, master_data); }/* Don't scribble on 0x48 if the controller does not support UDMA */ if (ap->udma_mask)
PATCH 72/98 ata_piix: enable 32bit PIO on SATA piix
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Tejun Heo <[email protected]>
commit 0b67c7439fe2a5d76602de36854c88e2beab00b0 upstream.
Commit 871af1210f13966ab911ed2166e4ab2ce775b99d enabled 32bit PIO for PATA piix but didn't for SATA. There's no reason not to use 32bit PIO on SATA piix. Enable it.
--- drivers/ata/ata_piix.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/ata/ata_piix.c +1 -1
@@ -329,7 +329,7 @@ static struct ata_port_operations ich_pa };static struct ata_port_operations piix_sata_ops = { - .inherits = &ata_bmdma_port_ops, + .inherits = &ata_bmdma32_port_ops, };static struct ata_port_operations piix_sidpr_sata_ops = {
Re: [72/98] ata_piix: enable 32bit PIO on SATA piix
Quoted 8 lines · Greg KH
2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Tejun Heo <[email protected]>
commit
0b67c7439fe2a5d76602de36854c88e2beab00b0upstream.
Quoted 8 lines
Commit
871af1210f13966ab911ed2166e4ab2ce775b99denabled 32bit PIO for PATA piix but didn't for SATA. There's no reason not to use 32bit PIO on SATA piix. Enable it.Signed-off-by Tejun Heo <[email protected]>Cc Alan Cox <[email protected]>Signed-off-by Jeff Garzik <[email protected]>Signed-off-by Greg Kroah-Hartman <[email protected]>
Umm... I don't really think this would be necessary for -stable. It probably won't break anything but at the same time this doesn't really fix any critical problem.
Thanks.
Signature · 1 line
tejun
Re: [72/98] ata_piix: enable 32bit PIO on SATA piix
Quoted 13 lines · Tejun Heo
Quoted 12 lines · Greg KH
2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Tejun Heo <[email protected]>
commit
0b67c7439fe2a5d76602de36854c88e2beab00b0upstream.Commit
871af1210f13966ab911ed2166e4ab2ce775b99denabled 32bit PIO for PATA piix but didn't for SATA. There's no reason not to use 32bit PIO on SATA piix. Enable it.
Quoted 8 lines
Quoted 4 lines
Signed-off-by Tejun Heo <[email protected]>Cc Alan Cox <[email protected]>Signed-off-by Jeff Garzik <[email protected]>Signed-off-by Greg Kroah-Hartman <[email protected]>Umm... I don't really think this would be necessary for -stable. It probably won't break anything but at the same time this doesn't really fix any critical problem.
Ok, thanks for letting me know, I'll go drop it. I found it when I was looking for other changes in this area.
thanks,
greg k-h
PATCH 73/98 md: fix small irregularity with start_ro module parameter
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: NeilBrown <[email protected]>
commit 0f9552b5dc4fe10da37fa3f4a4ca185d90fa41c9 upstream.
The start_ro modules parameter can be used to force arrays to be started in 'auto-readonly' in which they are read-only until the first write. This ensures that no resync/recovery happens until something else writes to the device. This is important for resume-from-disk off an md array.
However if an array is started 'readonly' (by writing 'readonly' to the 'array_state' sysfs attribute) we want it to be really 'readonly', not 'auto-readonly'.
So strengthen the condition to only set auto-readonly if the array is not already read-only.
--- drivers/md/md.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/md/md.c +1 -1
@@ -4173,7 +4173,7 @@ static int do_md_run(mddev_t * mddev) mddev->barriers_work =1 ; mddev->ok_start_degraded = start_dirty_degraded; -if (start_readonly) +if (start_readonly && mddev->ro ==0 ) mddev->ro =2 ;/* read-only, but switch on first write */ err = mddev->pers->run (mddev);
PATCH 74/98 V4L/DVB (13826): uvcvideo: Fix controls blacklisting
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Laurent Pinchart <[email protected]>
commit 385097e08b9c24655626ed760bc67eb7e50115a0 upstream.
The control blacklisting code erroneously used usb_match_id() by passing a pointer to a usb_device_id structure instead of an array of such structures.
Replace the usb_match_id() call by usb_match_id_one().
Thanks to Paulo Assis for diagnosing the bug and providing an initial fix.
--- drivers/media/video/uvc/uvc_ctrl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/video/uvc/uvc_ctrl.c +1 -1
@@ -1405,7 +1405,7 @@ uvc_ctrl_prune_entity(struct uvc_device size = entity->processing.bControlSize;for (i =0 ; i <ARRAY_SIZE (blacklist); ++i) { -if (!usb_match_id (dev->intf, &blacklist[i].id)) +if (!usb_match_one_id (dev->intf, &blacklist[i].id))continue ; if (blacklist[i].index >= 8 * size ||
PATCH 75/98 cio: fix double free in case of probe failure
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Peter Oberparleiter <[email protected]>
commit 48e4c385c5f54626651cca027afe242439281899 upstream.
io_subchannel_probe() frees memory for sch->private which is later freed again when io_subchannel_remove() is called. Fix this problem by removing the cleanup in io_subchannel_probe().
--- drivers/s390/cio/device.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-)
drivers/s390/cio/device.c +5 -6
@@ -1292,7 +1292,7 @@ static int io_subchannel_probe(struct su sch->private =kzalloc (sizeof (struct io_subchannel_private ),GFP_KERNEL |GFP_DMA );if (!sch->private) - goto out_err; + goto out_schedule;/* * First check if a fitting device may be found amongst the * disconnected devices or in the orphanage.
@@ -1317,7 +1317,7 @@ static int io_subchannel_probe(struct su } cdev =io_subchannel_create_ccwdev (sch);if (IS_ERR (cdev)) - goto out_err; + goto out_schedule; rc =io_subchannel_recog (cdev, sch);if (rc) {spin_lock_irqsave (sch->lock, flags);
@@ -1325,9 +1325,7 @@ static int io_subchannel_probe(struct suspin_unlock_irqrestore (sch->lock, flags); }return 0 ; -out_err: -kfree (sch->private); -sysfs_remove_group (&sch->dev.kobj, &io_subchannel_attr_group); + out_schedule:io_subchannel_schedule_removal (sch);return 0 ;
@@ -1341,13 +1339,14 @@ io_subchannel_remove (struct subchannel cdev =sch_get_cdev (sch);if (!cdev) -return 0 ; + goto out_free;/* Set ccw device to not operational and drop reference. */ spin_lock_irqsave (cdev->ccwlock, flags);sch_set_cdev (sch,NULL ); cdev->private->state =DEV_STATE_NOT_OPER ;spin_unlock_irqrestore (cdev->ccwlock, flags);ccw_device_unregister (cdev); +out_free:kfree (sch->private);sysfs_remove_group (&sch->dev.kobj, &io_subchannel_attr_group);return 0 ;
PATCH 76/98 cio: dont panic in non-fatal conditions
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Peter Oberparleiter <[email protected]>
commit 16b9a0571da4ee5cd15ca75e871722b0b5aee64d upstream.
Remove the call to BUG() for situations which are unexpected but do not cause actual problems.
--- drivers/s390/cio/device_fsm.c | 25 ++++++------------------- 1 file changed, 6 insertions(+), 19 deletions(-)
drivers/s390/cio/device_fsm.c +6 -19
@@ -1080,14 +1080,14 @@ void ccw_device_trigger_reprobe(struct cccw_device_start_id (cdev,0 ); } -static void -ccw_device_offline_irq (struct ccw_device *cdev,enum dev_event dev_event) +static void ccw_device_disabled_irq (struct ccw_device *cdev, +enum dev_event dev_event) {struct subchannel *sch; sch =to_subchannel (cdev->dev.parent);/* -* An interrupt in state offline means a previous disable was not +* An interrupt in a disabled state means a previous disable was not * successful - should not happen, but we try to disable again. */ cio_disable_subchannel (sch);
@@ -1150,25 +1150,12 @@ ccw_device_nop(struct ccw_device *cdev, }/* -* Bug operation action. -*/ -static void -ccw_device_bug (struct ccw_device *cdev,enum dev_event dev_event) -{ -CIO_MSG_EVENT (0 ,"Internal state [%i][%i] not handled for device " -"0.%x.%04x\n" , cdev->private->state, dev_event, - cdev->private->dev_id.ssid, - cdev->private->dev_id.devno); -BUG (); -} - -/* * device statemachine */ fsm_func_t *dev_jumptable[NR_DEV_STATES ][NR_DEV_EVENTS ] = { [DEV_STATE_NOT_OPER ] = { [DEV_EVENT_NOTOPER ] = ccw_device_nop, - [DEV_EVENT_INTERRUPT ] = ccw_device_bug, + [DEV_EVENT_INTERRUPT ] = ccw_device_disabled_irq, [DEV_EVENT_TIMEOUT ] = ccw_device_nop, [DEV_EVENT_VERIFY ] = ccw_device_nop, },
@@ -1186,7 +1173,7 @@ fsm_func_t *dev_jumptable[NR_DEV_STATES] }, [DEV_STATE_OFFLINE] = { [DEV_EVENT_NOTOPER] = ccw_device_generic_notoper, - [DEV_EVENT_INTERRUPT] = ccw_device_offline_irq, + [DEV_EVENT_INTERRUPT] = ccw_device_disabled_irq, [DEV_EVENT_TIMEOUT] = ccw_device_nop, [DEV_EVENT_VERIFY] = ccw_device_offline_verify, },
@@ -1243,7 +1230,7 @@ fsm_func_t *dev_jumptable[NR_DEV_STATES] [DEV_STATE_DISCONNECTED] = { [DEV_EVENT_NOTOPER] = ccw_device_nop, [DEV_EVENT_INTERRUPT] = ccw_device_start_id, - [DEV_EVENT_TIMEOUT] = ccw_device_bug, + [DEV_EVENT_TIMEOUT] = ccw_device_nop, [DEV_EVENT_VERIFY] = ccw_device_start_id, }, [DEV_STATE_DISCONNECTED_SENSE_ID] = {
PATCH 77/98 netiucv: displayed TX bytes value much too high
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Ursula Braun <[email protected]>
commit 998221c26b86a7edd621e66b437628c5ec0f8e9b upstream.
tx_bytes value must be updated by skb length before skb is freed.
--- drivers/s390/net/netiucv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/s390/net/netiucv.c +2 -2
@@ -741,13 +741,13 @@ static void conn_action_txdone(fsm_instaif (single_flag) {if ((skb =skb_dequeue (&conn->commit_queue))) {atomic_dec (&skb->users); -dev_kfree_skb_any (skb);if (privptr) { privptr->stats.tx_packets++; privptr->stats.tx_bytes += (skb->len -NETIUCV_HDRLEN - -NETIUCV_HDRLEN ); + -NETIUCV_HDRLEN ); } +dev_kfree_skb_any (skb); } } conn->tx_buff->data = conn->tx_buff->head;
PATCH 78/98 ipc ns: fix memory leak (idr)
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Serge E. Hallyn <[email protected]>
commit 7d6feeb287c61aafa88f06345387b1188edf4b86 upstream.
We have apparently had a memory leak since 7ca7e564e049d8b350ec9d958ff25eaa24226352 "ipc: store ipcs into IDRs" in 2007. The idr of which 3 exist for each ipc namespace is never freed.
This patch simply frees them when the ipcns is freed. I don't believe any idr_remove() are done from rcu (and could therefore be delayed until after this idr_destroy()), so the patch should be safe. Some quick testing showed no harm, and the memory leak fixed.
Caught by kmemleak.
--- ipc/msg.c | 1 + ipc/sem.c | 1 + ipc/shm.c | 1 + 3 files changed, 3 insertions(+)
ipc/msg.c +1 -0
@@ -125,6 +125,7 @@ void msg_init_ns(struct ipc_namespace *nvoid msg_exit_ns (struct ipc_namespace *ns) {free_ipcs (ns, &msg_ids (ns), freeque); +idr_destroy (&ns->ids[IPC_MSG_IDS ].ipcs_idr); }#endif
ipc/sem.c +1 -0
@@ -129,6 +129,7 @@ void sem_init_ns(struct ipc_namespace *nvoid sem_exit_ns (struct ipc_namespace *ns) {free_ipcs (ns, &sem_ids (ns), freeary); +idr_destroy (&ns->ids[IPC_SEM_IDS ].ipcs_idr); }#endif
ipc/shm.c +1 -0
@@ -101,6 +101,7 @@ static void do_shm_rmid(struct ipc_namesvoid shm_exit_ns (struct ipc_namespace *ns) {free_ipcs (ns, &shm_ids (ns), do_shm_rmid); +idr_destroy (&ns->ids[IPC_SHM_IDS ].ipcs_idr); }#endif
PATCH 79/98 ALSA: hda - Fix HP T5735 automute
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Takashi Iwai <[email protected]>
commit dc99be47667c56046555e89e62f1ac17fa06329a upstream.
This patch fixes the aut-mute setup on HP T5735 with ALC262 codec. Instead of wrong amp, use pin control toggling for muting the speaker now.
--- sound/pci/hda/patch_realtek.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
sound/pci/hda/patch_realtek.c +3 -3
@@ -10154,7 +10154,7 @@ static void alc262_hp_t5735_setup(structstruct alc_spec *spec = codec->spec; spec->autocfg.hp_pins[0 ] =0x15 ; - spec->autocfg.speaker_pins[0 ] =0x0c ;/* HACK: not actually a pin */ + spec->autocfg.speaker_pins[0 ] =0x14 ; }static struct snd_kcontrol_new alc262_hp_t5735_mixer[] = {
@@ -11588,9 +11588,9 @@ static struct alc_config_preset alc262_p .num_channel_mode = ARRAY_SIZE(alc262_modes), .channel_mode = alc262_modes, .input_mux = &alc262_capture_source, - .unsol_event = alc_automute_amp_unsol_event, + .unsol_event = alc_sku_unsol_event, .setup = alc262_hp_t5735_setup, - .init_hook = alc_automute_amp, + .init_hook = alc_inithook, }, [ALC262_HP_RP5700] = { .mixers = { alc262_hp_rp5700_mixer },
PATCH 80/98 hwmon: (fschmd) Fix a memleak on multiple opens of /dev/watchdog
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Hans de Goede <[email protected]>
commit c453615f77aa51593c1c9c9031b4278797d3fd19 upstream.
When /dev/watchdog gets opened a second time we return -EBUSY, but we already have got a kref then, so we end up leaking our data struct.
--- drivers/hwmon/fschmd.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
drivers/hwmon/fschmd.c +5 -2
@@ -767,6 +767,7 @@ leave:static int watchdog_open (struct inode *inode,struct file *filp) {struct fschmd_data *pos, *data =NULL ; +int watchdog_is_open;/* We get called from drivers/char/misc.c with misc_mtx hold, and we call misc_register() from fschmd_probe() with watchdog_data_mutex
@@ -781,10 +782,12 @@ static int watchdog_open(struct inode *i } }/* Note we can never not have found data, so we don't check for this */ -kref_get (&data->kref); + watchdog_is_open =test_and_set_bit (0 , &data->watchdog_is_open); +if (!watchdog_is_open) +kref_get (&data->kref);mutex_unlock (&watchdog_data_mutex); -if (test_and_set_bit (0 , &data->watchdog_is_open)) +if (watchdog_is_open)return -EBUSY ;/* Start the watchdog */
PATCH 81/98 UBI: fix memory leak in update path
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Artem Bityutskiy <[email protected]>
commit ebddd63b74dcf1cb676d14328d5852f1fee19a8a upstream.
When truncating an UBI volume, UBI should allocates a PEB-sized buffer but does not release it, which leads to memory leaks. This patch fixes the issue.
--- drivers/mtd/ubi/upd.c | 1 + 1 file changed, 1 insertion(+)
drivers/mtd/ubi/upd.c +1 -0
@@ -155,6 +155,7 @@ int ubi_start_update(struct ubi_device *if (err)return err; vol->updating =0 ; +return 0 ; } vol->upd_buf =vmalloc (ubi->leb_size);
PATCH 82/98 UBI: initialise update marker
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Peter Horton <[email protected]>
commit ff998793288b49a3b22d929bf8e56362320905ff upstream.
The in kernel copy of a volume's update marker is not initialised from the volume table. This means that volumes where an update was unfinnished will not be treated as "forbidden to use". This is basically that the update functionality was broken.
--- drivers/mtd/ubi/vtbl.c | 1 + 1 file changed, 1 insertion(+)
drivers/mtd/ubi/vtbl.c +1 -0
@@ -566,6 +566,7 @@ static int init_volumes(struct ubi_devic vol->reserved_pebs =be32_to_cpu (vtbl[i].reserved_pebs); vol->alignment =be32_to_cpu (vtbl[i].alignment); vol->data_pad =be32_to_cpu (vtbl[i].data_pad); + vol->upd_marker = vtbl[i].upd_marker; vol->vol_type = vtbl[i].vol_type ==UBI_VID_DYNAMIC ?UBI_DYNAMIC_VOLUME :UBI_STATIC_VOLUME ; vol->name_len =be16_to_cpu (vtbl[i].name_len);
PATCH 83/98 ASoC: fix a memory-leak in wm8903
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Guennadi Liakhovetski <[email protected]>
commit 40aa7030e5213a43e9e0554fd7f95534ea310bf3 upstream.
Remember to free the temporary register-cache.
--- sound/soc/codecs/wm8903.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
sound/soc/codecs/wm8903.c +2 -1
@@ -1506,7 +1506,7 @@ static int wm8903_resume(struct platformstruct i2c_client *i2c = codec->control_data;int i;u16 *reg_cache = codec->reg_cache; -u16 *tmp_cache =kmemdup (codec->reg_cache,sizeof (wm8903_reg_defaults), +u16 *tmp_cache =kmemdup (reg_cache,sizeof (wm8903_reg_defaults),GFP_KERNEL );/* Bring the codec back up to standby first to minimise pop/clicks */
@@ -1518,6 +1518,7 @@ static int wm8903_resume(struct platformfor (i =2 ; i <ARRAY_SIZE (wm8903_reg_defaults); i++)if (tmp_cache[i] != reg_cache[i])snd_soc_write (codec, i, tmp_cache[i]); +kfree (tmp_cache); }else {dev_err (&i2c->dev,"Failed to allocate temporary cache\n" ); }
PATCH 84/98 mac80211: check that ieee80211_set_power_mgmt only handles STA interfaces.
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Benoit Papillault <[email protected]>
commit e5de30c9bf4a39db9f54c4a373470ce65881ade0 upstream.
ieee80211_set_power_mgmt is meant for STA interfaces only. Moreover, since sdata->u.mgd.mtx is only initialized for STA interfaces, using this code for any other type of interface (like creating a monitor interface) will result in a oops.
--- net/mac80211/cfg.c | 3 +++ 1 file changed, 3 insertions(+)
net/mac80211/cfg.c +3 -0
@@ -1306,6 +1306,9 @@ static int ieee80211_set_power_mgmt(strustruct ieee80211_local *local =wdev_priv (dev->ieee80211_ptr);struct ieee80211_conf *conf = &local->hw.conf; +if (sdata->vif.type !=NL80211_IFTYPE_STATION ) +return -EOPNOTSUPP ; +if (!(local->hw.flags &IEEE80211_HW_SUPPORTS_PS ))return -EOPNOTSUPP ;
PATCH 85/98 cfg80211: fix channel setting for wext
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Abhijeet Kolekar <[email protected]>
commit 5f6120335c701ba07d5151206071f4d6ccaa684f upstream.
Patch fixes the bug at
http://bugzilla.intellinuxwireless.org/show_bug.cgi?id=2139
Currently we cannot set the channel using wext extension if we have already associated and disconnected. As cfg80211_mgd_wext_siwfreq will not switch the channel if ssid is set. This fixes it by clearing the ssid.
Following is the sequence which it tries to fix.
modprobe iwlagn
iwconfig wlan0 essid ""
ifconfig wlan0 down
iwconfig wlan0 chan X
wext is marked as deprecate.If we use nl80211 we can easily play with setting the channel.
--- net/wireless/sme.c | 1 + 1 file changed, 1 insertion(+)
net/wireless/sme.c +1 -0
@@ -655,6 +655,7 @@ void __cfg80211_disconnected(struct net_memset (&wrqu,0 ,sizeof (wrqu)); wrqu.ap_addr.sa_family =ARPHRD_ETHER ;wireless_send_event (dev,SIOCGIWAP , &wrqu,NULL ); + wdev->wext.connect.ssid_len =0 ;#endif }
PATCH 86/98 KVM: S390: fix potential array overrun in intercept handling
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Christian Borntraeger <[email protected]>
commit 062d5e9b0d714f449b261bb522eadaaf6f00f438 upstream.
kvm_handle_sie_intercept uses a jump table to get the intercept handler for a SIE intercept. Static code analysis revealed a potential problem:
the intercept_funcs jump table was defined to contain (0x48 >> 2) entries, but we only checked for code > 0x48 which would cause an off-by-one array overflow if code == 0x48.
Use the compiler and ARRAY_SIZE to automatically set the limits.
--- arch/s390/kvm/intercept.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/s390/kvm/intercept.c +2 -2
@@ -213,7 +213,7 @@ static int handle_instruction_and_prog(sreturn rc2; } -static const intercept_handler_t intercept_funcs[0x48 >>2 ] = { +static const intercept_handler_t intercept_funcs[] = { [0x00 >>2 ] = handle_noop, [0x04 >>2 ] = handle_instruction, [0x08 >>2 ] = handle_prog,
@@ -230,7 +230,7 @@ int kvm_handle_sie_intercept(struct kvm_intercept_handler_t func;u8 code = vcpu->arch.sie_block->icptcode; -if (code &3 || code >0x48 ) +if (code &3 || (code >>2 ) >=ARRAY_SIZE (intercept_funcs))return -ENOTSUPP ; func = intercept_funcs[code >>2 ];if (func)
PATCH 87/98 KVM: only allow one gsi per fd
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Michael S. Tsirkin <[email protected]>
commit f1d1c309f35e9b0fb961cffd70fbd04f450ec47c upstream.
Looks like repeatedly binding same fd to multiple gsi's with irqfd can use up a ton of kernel memory for irqfd structures.
A simple fix is to allow each fd to only trigger one gsi: triggering a storm of interrupts in guest is likely useless anyway, and we can do it by binding a single gsi to many interrupts if we really want to.
--- virt/kvm/eventfd.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-)
virt/kvm/eventfd.c +13 -2
@@ -168,7 +168,7 @@ irqfd_ptable_queue_proc(struct file *filstatic int kvm_irqfd_assign (struct kvm *kvm,int fd,int gsi) { -struct _irqfd *irqfd; +struct _irqfd *irqfd, *tmp;struct file *file =NULL ;struct eventfd_ctx *eventfd =NULL ;int ret;
@@ -205,9 +205,20 @@ kvm_irqfd_assign(struct kvm *kvm, int fdinit_waitqueue_func_entry (&irqfd->wait, irqfd_wakeup);init_poll_funcptr (&irqfd->pt, irqfd_ptable_queue_proc); +spin_lock_irq (&kvm->irqfds.lock); + + ret =0 ; +list_for_each_entry (tmp, &kvm->irqfds.items, list) { +if (irqfd->eventfd != tmp->eventfd) +continue ; +/* This fd is used for another irq already. */ + ret = -EBUSY ; +spin_unlock_irq (&kvm->irqfds.lock); + goto fail; + } + events = file->f_op->poll (file, &irqfd->pt); -spin_lock_irq (&kvm->irqfds.lock);list_add_tail (&irqfd->list, &kvm->irqfds.items);spin_unlock_irq (&kvm->irqfds.lock);
PATCH 88/98 KVM: Fix race between APIC TMR and IRR
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Avi Kivity <[email protected]>
commit a5d36f82c4f3e852b61fdf1fee13463c8aa91b90 upstream.
When we queue an interrupt to the local apic, we set the IRR before the TMR. The vcpu can pick up the IRR and inject the interrupt before setting the TMR, and perhaps even EOI it, causing incorrect behaviour.
The race is really insignificant since it can only occur on the first interrupt (usually following interrupts will not change TMR), but it's better closed than open.
Fixed by reordering setting the TMR vs IRR.
--- arch/x86/kvm/lapic.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-)
arch/x86/kvm/lapic.c +6 -5
@@ -374,6 +374,12 @@ static int __apic_accept_irq(struct kvm_if (unlikely (!apic_enabled (apic)))break ; +if (trig_mode) { +apic_debug ("level trig mode for vector %d" , vector); +apic_set_vector (vector, apic->regs +APIC_TMR ); + }else +apic_clear_vector (vector, apic->regs +APIC_TMR ); + result = !apic_test_and_set_irr (vector, apic);trace_kvm_apic_accept_irq (vcpu->vcpu_id, delivery_mode, trig_mode, vector, !result);
@@ -384,11 +390,6 @@ static int __apic_accept_irq(struct kvm_break ; } -if (trig_mode) { -apic_debug ("level trig mode for vector %d" , vector); -apic_set_vector (vector, apic->regs +APIC_TMR ); - }else -apic_clear_vector (vector, apic->regs +APIC_TMR );kvm_vcpu_kick (vcpu);break ;
PATCH 89/98 KVM: MMU: bail out pagewalk on kvm_read_guest error
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Marcelo Tosatti <[email protected]>
commit a6085fbaf65ab09bfb5ec8d902d6d21680fe1895 upstream.
Exit the guest pagetable walk loop if reading gpte failed. Otherwise its possible to enter an endless loop processing the previous present pte.
--- arch/x86/kvm/paging_tmpl.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
arch/x86/kvm/paging_tmpl.h +3 -1
@@ -150,7 +150,9 @@ walk: walker->table_gfn[walker->level -1 ] = table_gfn; walker->pte_gpa[walker->level -1 ] = pte_gpa; -kvm_read_guest (vcpu->kvm, pte_gpa, &pte,sizeof (pte)); +if (kvm_read_guest (vcpu->kvm, pte_gpa, &pte,sizeof (pte))) + goto not_present; +trace_kvm_mmu_paging_element (pte, walker->level);if (!is_present_gpte (pte))
PATCH 90/98 KVM: x86: Fix host_mapping_level()
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Sheng Yang <[email protected]>
commit 82b7005f0e72d8d1a8226e4c192cbb0850d10b3f upstream.
When found a error hva, should not return PAGE_SIZE but the level...
Also clean up the coding style of the following loop.
--- arch/x86/kvm/mmu.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
arch/x86/kvm/mmu.c +2 -4
@@ -477,7 +477,7 @@ static int host_mapping_level(struct kvm addr =gfn_to_hva (kvm, gfn);if (kvm_is_error_hva (addr)) -return page_size; +return PT_PAGE_TABLE_LEVEL ;down_read (¤t->mm->mmap_sem); vma =find_vma (current->mm, addr);
@@ -515,11 +515,9 @@ static int mapping_level(struct kvm_vcpuif (host_level ==PT_PAGE_TABLE_LEVEL )return host_level; -for (level =PT_DIRECTORY_LEVEL ; level <= host_level; ++level) { - +for (level =PT_DIRECTORY_LEVEL ; level <= host_level; ++level)if (has_wrprotected_page (vcpu->kvm, large_gfn, level))break ; - }return level -1 ; }
PATCH 91/98 KVM: x86: Fix probable memory leak of vcpu->arch.mce_banks
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Wei Yongjun <[email protected]>
commit 36cb93fd6b6bf7e9163a69a8bf20207aed5fea44 upstream.
vcpu->arch.mce_banks is malloc in kvm_arch_vcpu_init(), but never free in any place, this may cause memory leak. So this patch fixed to free it in kvm_arch_vcpu_uninit().
--- arch/x86/kvm/x86.c | 1 + 1 file changed, 1 insertion(+)
arch/x86/kvm/x86.c +1 -0
@@ -4782,6 +4782,7 @@ fail:void kvm_arch_vcpu_uninit (struct kvm_vcpu *vcpu) { +kfree (vcpu->arch.mce_banks);kvm_free_lapic (vcpu);down_read (&vcpu->kvm->slots_lock);kvm_mmu_destroy (vcpu);
PATCH 92/98 KVM: x86: Fix leak of free lapic date in kvm_arch_vcpu_init()
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Wei Yongjun <[email protected]>
commit 443c39bc9ef7d8f648408d74c97e943f3bb3f48a upstream.
In function kvm_arch_vcpu_init(), if the memory malloc for vcpu->arch.mce_banks is fail, it does not free the memory of lapic date. This patch fixed it.
--- arch/x86/kvm/x86.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
arch/x86/kvm/x86.c +3 -2
@@ -4766,12 +4766,13 @@ int kvm_arch_vcpu_init(struct kvm_vcpu * GFP_KERNEL);if (!vcpu->arch.mce_banks) { r = -ENOMEM ; - goto fail_mmu_destroy; + goto fail_free_lapic; } vcpu->arch.mcg_cap =KVM_MAX_MCE_BANKS ;return 0 ; - +fail_free_lapic: +kvm_free_lapic (vcpu); fail_mmu_destroy:kvm_mmu_destroy (vcpu); fail_free_pio_data:
PATCH 93/98 KVM: fix lock imbalance in kvm_*_irq_source_id()
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Jiri Slaby <[email protected]>
commit 0c6ddcebd8303ada6faefa6f72ac18b6230320c4 upstream.
Stanse found 2 lock imbalances in kvm_request_irq_source_id and kvm_free_irq_source_id. They omit to unlock kvm->irq_lock on fail paths.
Fix that by adding unlock labels at the end of the functions and jump there from the fail paths.
--- virt/kvm/irq_comm.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
virt/kvm/irq_comm.c +5 -2
@@ -209,11 +209,13 @@ int kvm_request_irq_source_id(struct kvmif (irq_source_id >=BITS_PER_LONG ) {printk (KERN_WARNING "kvm: exhaust allocatable IRQ sources!\n" ); -return -EFAULT ; + irq_source_id = -EFAULT ; + goto unlock; }ASSERT (irq_source_id !=KVM_USERSPACE_IRQ_SOURCE_ID );set_bit (irq_source_id, bitmap); +unlock:mutex_unlock (&kvm->irq_lock);return irq_source_id;
@@ -229,11 +231,12 @@ void kvm_free_irq_source_id(struct kvm *if (irq_source_id <0 || irq_source_id >=BITS_PER_LONG ) {printk (KERN_ERR "kvm: IRQ source ID out of range!\n" ); -return ; + goto unlock; }for (i =0 ; i <KVM_IOAPIC_NUM_PINS ; i++)clear_bit (irq_source_id, &kvm->arch.irq_states[i]);clear_bit (irq_source_id, &kvm->arch.irq_sources_bitmap); +unlock:mutex_unlock (&kvm->irq_lock); }
PATCH 94/98 KVM: only clear irq_source_id if irqchip is present
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Marcelo Tosatti <[email protected]>
commit e50212bb51356f0df48d6cce0aae5acf41df336d upstream.
Otherwise kvm might attempt to dereference a NULL pointer.
--- virt/kvm/irq_comm.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
virt/kvm/irq_comm.c +4 -1
@@ -233,9 +233,12 @@ void kvm_free_irq_source_id(struct kvm *printk (KERN_ERR "kvm: IRQ source ID out of range!\n" ); goto unlock; } +clear_bit (irq_source_id, &kvm->arch.irq_sources_bitmap); +if (!irqchip_in_kernel (kvm)) + goto unlock; +for (i =0 ; i <KVM_IOAPIC_NUM_PINS ; i++)clear_bit (irq_source_id, &kvm->arch.irq_states[i]); -clear_bit (irq_source_id, &kvm->arch.irq_sources_bitmap); unlock:mutex_unlock (&kvm->irq_lock); }
PATCH 95/98 IPoIB: Clear ipoib_neigh.dgid in ipoib_neigh_alloc()
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: David J. Wilder <[email protected]>
commit 0cd4d0fd9b0a4e10c091fc6316d1bf92885dcd9c upstream.
IPoIB can miss a change in destination GID under some conditions. The problem is caused when ipoib_neigh->dgid contains a stale address. The fix is to set ipoib_neigh->dgid to zero in ipoib_neigh_alloc().
This can happen when a system using bonding on its IPoIB interfaces has switched its active interface from interface A to B and back to A. The system that fails over will not correctly processes the 2nd address change, as described below.
When an address has changed neighbor->ha is updated with the new address. Each neighbor has an associated ipoib_neigh. ipoib_neigh->dgid also holds a copy of the remote node's hardware address. When an address changes neighbor->ha is updated by the network layer (arp code) with the new address. IPoIB detects this change in ipoib_start_xmit() by comparing neighbor->ha with ipoib_neigh->dgid. The bug is that ipoib_neigh->dgid may already contain the new address (A) thus the change from B to A is missed by ipoib. Here is the sequence of events:
ipoib_neigh->dgid = A and neighbor->ha = A
The address is switched to B (the first switch)
neighbor->ha = B
The change is seen in ipoib_start_xmit() -- neighbor->ha != ipoib_neigh->dgid so ipoib_neigh is released, and a new one is allocated.
The allocator may return the same chunk of memory that was just released, therefore ipoib_neigh->dgid still contains A at this point.
ipoib_neigh->dgid should be updated in neigh_add_path(), but if the following conditions are true dgid is not updated:
1) __path_find() returns a path
2) path->ah is NULL
The remote system now switches from address B to A, neighbor->ha is updated to A.
Now we have again : ipoib_neigh->dgid = A and neighbor->ha = A
Since the addresses are the same ipoib won't process the change in address. Fix this by zeroing out the dgid field when allocating a new struct ipoib_neigh.
--- drivers/infiniband/ulp/ipoib/ipoib_main.c | 1 + 1 file changed, 1 insertion(+)
drivers/infiniband/ulp/ipoib/ipoib_main.c +1 -0
@@ -884,6 +884,7 @@ struct ipoib_neigh *ipoib_neigh_alloc(st neigh->neighbour = neighbour; neigh->dev = dev; +memset (&neigh->dgid.raw,0 ,sizeof (union ib_gid )); *to_ipoib_neigh (neighbour) = neigh;skb_queue_head_init (&neigh->queue);ipoib_cm_set (neigh,NULL );
PATCH 96/98 x86: Reenable TSC sync check at boot, even with NONSTOP_TSC
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Pallipadi, Venkatesh <[email protected]>
commit 6c56ccecf05fafe100ab4ea94f6fccbf5ff00db7 upstream.
Commit 83ce4009 did the following change
If the TSC is constant and non-stop, also set it reliable.
But, there seems to be few systems that will end up with TSC warp across sockets, depending on how the cpus come out of reset. Skipping TSC sync test on such systems may result in time inconsistency later.
So, reenable TSC sync test even on constant and non-stop TSC systems. Set, sched_clock_stable to 1 by default and reset it in mark_tsc_unstable, if TSC sync fails.
This change still gives perf benefit mentioned in 83ce4009 for systems where TSC is reliable.
LKML-Reference: <[email protected]>
--- arch/x86/kernel/cpu/intel.c | 1 - arch/x86/kernel/tsc.c | 1 + 2 files changed, 1 insertion(+), 1 deletion(-)
arch/x86/kernel/cpu/intel.c +0 -1
@@ -70,7 +70,6 @@ static void __cpuinit early_init_intel(sif (c->x86_power & (1 <<8 )) {set_cpu_cap (c,X86_FEATURE_CONSTANT_TSC );set_cpu_cap (c,X86_FEATURE_NONSTOP_TSC ); -set_cpu_cap (c,X86_FEATURE_TSC_RELIABLE ); sched_clock_stable =1 ; }
arch/x86/kernel/tsc.c +1 -0
@@ -763,6 +763,7 @@ void mark_tsc_unstable(char *reason) {if (!tsc_unstable) { tsc_unstable =1 ; + sched_clock_stable =0 ;printk (KERN_INFO "Marking TSC unstable due to %s\n" , reason);/* Change only the rating, when not registered */ if (clocksource_tsc.mult)
PATCH 97/98 ACPI: enable C2 and Turbo-mode on Nehalem notebooks on A/C
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Len Brown <[email protected]>
upstream in 2.6.33-rc: 5d76b6f6c17572e662f5c99c2023adae92100855
Refreshed here for 2.6.32.y, applies w/ offset back to 2.6.29.y.
Linux has always ignored ACPI BIOS C2 with exit latency > 100 usec, and the ACPI spec is clear that is correct FADT-supplied C2.
However, the ACPI spec explicitly states that _CST-supplied C-states have no latency limits.
So move the 100usec C2 test out of the code shared by FADT and _CST code-paths, and into the FADT-specific path.
This bug has not been visible until Nehalem, which advertises a CPU-C2 worst case exit latency on servers of 205usec. That (incorrect) figure is being used by BIOS writers on mobile Nehalem systems for the AC configuration. Thus, Linux ignores C2 leaving just C1, which is saves less power, and also impacts performance
by preventing the use of turbo mode.
http://bugzilla.kernel.org/show_bug.cgi?id=15064
--- drivers/acpi/processor_idle.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-)
drivers/acpi/processor_idle.c +11 -10
@@ -299,6 +299,17 @@ static int acpi_processor_get_power_info pr->power.states[ACPI_STATE_C2 ].latency = acpi_gbl_FADT.C2latency; pr->power.states[ACPI_STATE_C3 ].latency = acpi_gbl_FADT.C3latency; +/* +* FADT specified C2 latency must be less than or equal to +* 100 microseconds. +*/ +if (acpi_gbl_FADT.C2latency >ACPI_PROCESSOR_MAX_C2_LATENCY ) { +ACPI_DEBUG_PRINT ((ACPI_DB_INFO , +"C2 latency too large [%d]\n" , acpi_gbl_FADT.C2latency)); +/* invalidate C2 */ + pr->power.states[ACPI_STATE_C2 ].address =0 ; + } + ACPI_DEBUG_PRINT((ACPI_DB_INFO, "lvl2[0x%08x] lvl3[0x%08x]\n", pr->power.states[ACPI_STATE_C2].address,
@@ -495,16 +506,6 @@ static void acpi_processor_power_verify_return ;/* -* C2 latency must be less than or equal to 100 -* microseconds. -*/ - else if (cx->latency > ACPI_PROCESSOR_MAX_C2_LATENCY) { -ACPI_DEBUG_PRINT ((ACPI_DB_INFO , -"latency too large [%d]\n" , cx->latency)); -return ; - } - -/* * Otherwise we've met all of our C2 requirements. * Normalize the C2 latency to expidite policy */
PATCH 98/98 iwlwifi: Fix throughput stall issue in HT mode for 5000
In reply to Greg KH2.6.32-stable review patch. If anyone has any objections, please let us know.
------------------
From: Wey-Yi Guy <[email protected]>
commit 1152dcc28c66a74b5b3f1a3ede0aa6729bfd48e4 upstream
Similar to 6000 and 1000 series, RTS/CTS is the recommended protection mechanism for 5000 series in HT mode based on the HW design.
Using RTS/CTS will better protect the inner exchange from interference, especially in highly-congested environment, it also prevent uCode encounter TX FIFO underrun and other HT mode related performance issues.
--- drivers/net/wireless/iwlwifi/iwl-5000.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/net/wireless/iwlwifi/iwl-5000.c +4 -0
@@ -1666,6 +1666,7 @@ struct iwl_cfg iwl5300_agn_cfg = { .valid_rx_ant = ANT_ABC, .need_pll_cfg = true, .ht_greenfield_support = true, + .use_rts_for_ht = true, /* use rts/cts protection */ };struct iwl_cfg iwl5100_bg_cfg = {
@@ -1717,6 +1718,7 @@ struct iwl_cfg iwl5100_agn_cfg = { .valid_rx_ant = ANT_AB, .need_pll_cfg = true, .ht_greenfield_support = true, + .use_rts_for_ht = true, /* use rts/cts protection */ };struct iwl_cfg iwl5350_agn_cfg = {
@@ -1734,6 +1736,7 @@ struct iwl_cfg iwl5350_agn_cfg = { .valid_rx_ant = ANT_ABC, .need_pll_cfg = true, .ht_greenfield_support = true, + .use_rts_for_ht = true, /* use rts/cts protection */ };struct iwl_cfg iwl5150_agn_cfg = {
@@ -1751,6 +1754,7 @@ struct iwl_cfg iwl5150_agn_cfg = { .valid_rx_ant = ANT_AB, .need_pll_cfg = true, .ht_greenfield_support = true, + .use_rts_for_ht = true, /* use rts/cts protection */ };MODULE_FIRMWARE (IWL5000_MODULE_FIRMWARE (IWL5000_UCODE_API_MAX ));