mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-16 00:34:20 +08:00
89dafa20f3
Tested with Marvell 88se9125, attached with one port mulitplier(5 ports) and one disk, we will get following boot log messages if using current code: ata8: SATA link up 6.0 Gbps (SStatus 133 SControl 330) ata8.15: Port Multiplier 1.2, 0x1b4b:0x9715 r160, 5 ports, feat 0x1/0x1f ahci 0000:03:00.0: FBS is enabled ata8.00: hard resetting link ata8.00: SATA link down (SStatus 0 SControl 330) ata8.01: hard resetting link ata8.01: SATA link down (SStatus 0 SControl 330) ata8.02: hard resetting link ata8.02: SATA link down (SStatus 0 SControl 330) ata8.03: hard resetting link ata8.03: SATA link up 6.0 Gbps (SStatus 133 SControl 133) ata8.04: hard resetting link ata8.04: failed to resume link (SControl 133) ata8.04: failed to read SCR 0 (Emask=0x40) ata8.04: failed to read SCR 0 (Emask=0x40) ata8.04: failed to read SCR 1 (Emask=0x40) ata8.04: failed to read SCR 0 (Emask=0x40) ata8.03: native sectors (2) is smaller than sectors (976773168) ata8.03: ATA-8: ST3500413AS, JC4B, max UDMA/133 ata8.03: 976773168 sectors, multi 0: LBA48 NCQ (depth 31/32) ata8.03: configured for UDMA/133 ata8.04: failed to IDENTIFY (I/O error, err_mask=0x100) ata8.15: hard resetting link ata8.15: SATA link up 6.0 Gbps (SStatus 133 SControl 330) ata8.15: Port Multiplier vendor mismatch '0x1b4b' != '0x133' ata8.15: PMP revalidation failed (errno=-19) ata8.15: hard resetting link ata8.15: SATA link up 6.0 Gbps (SStatus 133 SControl 330) ata8.15: Port Multiplier vendor mismatch '0x1b4b' != '0x133' ata8.15: PMP revalidation failed (errno=-19) ata8.15: limiting SATA link speed to 3.0 Gbps ata8.15: hard resetting link ata8.15: SATA link up 3.0 Gbps (SStatus 123 SControl 320) ata8.15: Port Multiplier vendor mismatch '0x1b4b' != '0x133' ata8.15: PMP revalidation failed (errno=-19) ata8.15: failed to recover PMP after 5 tries, giving up ata8.15: Port Multiplier detaching ata8.03: disabled ata8.00: disabled ata8: EH complete The reason is that current detection code doesn't follow AHCI spec: First,the port multiplier detection process look like this: ahci_hardreset(link, class, deadline) if (class == ATA_DEV_PMP) { sata_pmp_attach(dev) /* will enable FBS */ sata_pmp_init_links(ap, nr_ports); ata_for_each_link(link, ap, EDGE) { sata_std_hardreset(link, class, deadline); if (link_is_online) /* do soft reset */ ahci_softreset(link, class, deadline); } } But, according to chapter 9.3.9 in AHCI spec: Prior to issuing software reset, software shall clear PxCMD.ST to '0' and then clear PxFBS.EN to '0'. The patch test ok with kernel 3.11.1. tj: Patch white space contaminated, applied manually with trivial updates. Signed-off-by: Xiangliang Yu <yuxiangl@marvell.com> Signed-off-by: Tejun Heo <tj@kernel.org> Cc: stable@vger.kernel.org |
||
---|---|---|
.. | ||
acard-ahci.c | ||
ahci_imx.c | ||
ahci_platform.c | ||
ahci.c | ||
ahci.h | ||
ata_generic.c | ||
ata_piix.c | ||
Kconfig | ||
libahci.c | ||
libata-acpi.c | ||
libata-core.c | ||
libata-eh.c | ||
libata-pmp.c | ||
libata-scsi.c | ||
libata-sff.c | ||
libata-transport.c | ||
libata-transport.h | ||
libata-zpodd.c | ||
libata.h | ||
Makefile | ||
pata_acpi.c | ||
pata_ali.c | ||
pata_amd.c | ||
pata_arasan_cf.c | ||
pata_artop.c | ||
pata_at32.c | ||
pata_at91.c | ||
pata_atiixp.c | ||
pata_atp867x.c | ||
pata_bf54x.c | ||
pata_cmd64x.c | ||
pata_cmd640.c | ||
pata_cs5520.c | ||
pata_cs5530.c | ||
pata_cs5535.c | ||
pata_cs5536.c | ||
pata_cypress.c | ||
pata_efar.c | ||
pata_ep93xx.c | ||
pata_hpt3x2n.c | ||
pata_hpt3x3.c | ||
pata_hpt37x.c | ||
pata_hpt366.c | ||
pata_icside.c | ||
pata_imx.c | ||
pata_isapnp.c | ||
pata_it821x.c | ||
pata_it8213.c | ||
pata_ixp4xx_cf.c | ||
pata_jmicron.c | ||
pata_legacy.c | ||
pata_macio.c | ||
pata_marvell.c | ||
pata_mpc52xx.c | ||
pata_mpiix.c | ||
pata_netcell.c | ||
pata_ninja32.c | ||
pata_ns87410.c | ||
pata_ns87415.c | ||
pata_octeon_cf.c | ||
pata_of_platform.c | ||
pata_oldpiix.c | ||
pata_opti.c | ||
pata_optidma.c | ||
pata_palmld.c | ||
pata_pcmcia.c | ||
pata_pdc202xx_old.c | ||
pata_pdc2027x.c | ||
pata_piccolo.c | ||
pata_platform.c | ||
pata_pxa.c | ||
pata_radisys.c | ||
pata_rb532_cf.c | ||
pata_rdc.c | ||
pata_rz1000.c | ||
pata_samsung_cf.c | ||
pata_sc1200.c | ||
pata_scc.c | ||
pata_sch.c | ||
pata_serverworks.c | ||
pata_sil680.c | ||
pata_sis.c | ||
pata_sl82c105.c | ||
pata_triflex.c | ||
pata_via.c | ||
pdc_adma.c | ||
sata_dwc_460ex.c | ||
sata_fsl.c | ||
sata_highbank.c | ||
sata_inic162x.c | ||
sata_mv.c | ||
sata_nv.c | ||
sata_promise.c | ||
sata_promise.h | ||
sata_qstor.c | ||
sata_rcar.c | ||
sata_sil24.c | ||
sata_sil.c | ||
sata_sis.c | ||
sata_svw.c | ||
sata_sx4.c | ||
sata_uli.c | ||
sata_via.c | ||
sata_vsc.c | ||
sis.h |