MdeModulePkg/UfsPassThruDxe: Refactor private data to use UfsHcInfo
https://bugzilla.tianocore.org/show_bug.cgi?id=1343 Private data has been refactored to use EDKII_UFS_HC_INFO structure to store host controller capabilities and version information. Getting host controller data has been moved into single place and is done before host controller enable. Signed-off-by: Mateusz Albecki <mateusz.albecki@intel.com> Reviewed-by: Hao A Wu <hao.a.wu@intel.com>
This commit is contained in:
committed by
Hao A Wu
parent
90952ad733
commit
a71272ed7a
@@ -1,6 +1,6 @@
|
||||
/** @file
|
||||
|
||||
Copyright (c) 2014 - 2018, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2014 - 2019, Intel Corporation. All rights reserved.<BR>
|
||||
SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||
|
||||
**/
|
||||
@@ -35,7 +35,7 @@ UFS_PASS_THRU_PRIVATE_DATA gUfsPassThruTemplate = {
|
||||
},
|
||||
0, // UfsHostController
|
||||
0, // UfsHcBase
|
||||
0, // Capabilities
|
||||
{0, 0}, // UfsHcInfo
|
||||
0, // TaskTag
|
||||
0, // UtpTrlBase
|
||||
0, // Nutrs
|
||||
@@ -865,6 +865,11 @@ UfsPassThruDriverBindingStart (
|
||||
Private->UfsHostController = UfsHc;
|
||||
Private->UfsHcBase = UfsHcBase;
|
||||
InitializeListHead (&Private->Queue);
|
||||
Status = GetUfsHcInfo (Private);
|
||||
if (EFI_ERROR (Status)) {
|
||||
DEBUG ((DEBUG_ERROR, "Failed to initialize UfsHcInfo\n"));
|
||||
goto Error;
|
||||
}
|
||||
|
||||
//
|
||||
// Initialize UFS Host Controller H/W.
|
||||
|
Reference in New Issue
Block a user