audk/MdeModulePkg/Bus
Marcin Wojtas 6052a15f4a MdeModulePkg/AtaAtapiPassThru: Ensure GHC.AE bit is always set in Ahci
According to AHCI Spec 1.3 GHC.AE bit description:
"The implementation of this bit is dependent upon the value of the
CAP.SAM bit. If CAP.SAM is '0', then GHC.AE shall be read-write and shall
have a reset value of '0'. If CAP.SAM is '1', then AE shall be read-only
and shall have a reset value of '1'."

Being in AhciMode, for proper operation it is required, that GHC.AE bit
is always set, before any other AHCI registers are written to. Current
AhciMode implementation, both in AhciReset() and AhciModeInitialization()
functions, set GHC.AE bit only depending on 'CAP.SAM == 0' condition,
assuming (according to the AHCI spec), that otherwise it has to be set
anyway. It may however happen, that even if 'CAP.SAM == 1', GHC.AE
requires updating by software.

This patch enables in AhciMode setting GHC.AE in case its initial value
is '0'. It fixes AHCI support for Marvell Armada 70x0 and 80x0 SoC
families. The change is transparent to all other platforms.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Marcin Wojtas <mw@semihalf.com>
Signed-off-by: Jan Dabros <jsd@semihalf.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
2016-11-24 15:54:55 +00:00
..
Ata MdeModulePkg/AtaAtapiPassThru: Ensure GHC.AE bit is always set in Ahci 2016-11-24 15:54:55 +00:00
I2c/I2cDxe MdeModulePkg: Convert all .uni files to utf-8 2015-12-15 04:56:23 +00:00
Isa MdeModulePkg/Bus: Fix typos in comments 2016-10-27 09:11:16 +08:00
Pci MdeModulePkg/Xhci: Add 10ms delay before sending SendAddr cmd to dev 2016-11-24 12:44:50 +08:00
Scsi MdeModulePkg ScsiDiskDxe: Add Erase Block Protocol support for UFS devices 2016-05-20 13:42:51 +08:00
Sd MdeModulePkg: Fix typos in comments and variables 2016-07-11 10:29:48 +08:00
Ufs MdeModulePkg/Ufs: ensure the DBC field of UTP PRDT is dword-aligned 2016-11-09 15:30:10 +08:00
Usb MdeModulePkg/UsbMass: Revert changes of removing retry logic 2016-11-14 14:10:30 +08:00