Re: [edk2] [PATCH] [edk2-platforms/devel-IntelAtomProcessorE3900] Fix Type-C video
Hi Kelly, Below comments should be removed. Other changes looks good to me. Reviewed-by: David Wei + +//KES:// +//KES:// Dump MUX I2C registers +//KES:// +//KES:MB3DumpMux (); + + // Thanks, David Wei Intel SSG/STO/UEFI BIOS From: Steele, Kelly Sent: Thursday, October 4, 2018 12:42 AM To: edk2-devel@lists.01.org Cc: Wei, David ; Guo, Mang Subject: [PATCH] [edk2-platforms/devel-IntelAtomProcessorE3900] Fix Type-C video >From a5d80c8322c30e09a92c0b88cdcec66ee612546f Mon Sep 17 00:00:00 2001 From: Kelly Steele mailto:kelly.ste...@intel.com>> Date: Wed, 3 Oct 2018 09:38:36 -0700 Subject: [PATCH] [edk2-platforms/devel-IntelAtomProcessorE3900] Fix Type-C video Enabled Type-C video thru the VBT. Corrected the Type-C debug code and removed the call to the Type-C debug code. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Kelly Steele mailto:kelly.ste...@intel.com>> --- .../BoardInitPostMem/BoardInitMiscs.c | 5 - .../MinnowBoard3Module/BoardInitPostMem/TypeC.c| 77 ++-- .../MinnowBoard3Module/BoardInitPostMem/TypeC.h| 133 ++--- .../Board/MinnowBoard3Module/Vbt/VbtBxtMipi.bin| Bin 5632 -> 5632 bytes 4 files changed, 130 insertions(+), 85 deletions(-) diff --git a/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/BoardInitMiscs.c b/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/BoardInitMiscs.c index 99e643f792..4e708e8793 100644 --- a/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/BoardInitMiscs.c +++ b/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/BoardInitMiscs.c @@ -128,11 +128,6 @@ Minnow3ModuleMultiPlatformInfoInit ( Status = Minnow3ModuleInitializeBoardOemId (PeiServices, PlatformInfoHob); Status = Minnow3ModuleInitializeBoardSsidSvid (PeiServices, PlatformInfoHob); - // - // TypeC MUX AUX mode - // - MB3SetupTypecMuxAux (); - return EFI_SUCCESS; } diff --git a/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/TypeC.c b/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/TypeC.c index 7b8d56ab48..12153ab6b0 100644 --- a/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/TypeC.c +++ b/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/TypeC.c @@ -16,18 +16,20 @@ #include "TypeC.h" static MUX_PROGRAMMING_TABLE mMB3MuxTable[] = { - // Address RegisterData String - // - {A_GENERAL, R_FIRMWARE_VERSION, MUX_TABLE_NULL, "Firmware Version Number"}, - {A_STATUS, R_CC_STATUS_1, MUX_TABLE_NULL, "CC_Status_1"}, - {A_STATUS, R_CC_STATUS_2, MUX_TABLE_NULL, "CC_Status_2"}, - {A_STATUS, R_CC_STATUS_3, MUX_TABLE_NULL, "CC_Status_3"}, - {A_STATUS, R_MUX_HPD_ASSERT, MUX_TABLE_NULL, "MUX_In_HPD_Assertion"}, - {A_STATUS, R_MUX_STATUS, MUX_TABLE_NULL, "MUX Status"}, - {A_STATUS, R_MUX_DP_TRAINING, MUX_TABLE_NULL, "MUX_DP_Training_Disable"}, - {A_STATUS, R_MUX_DP_AUX_INTERCEPT, MUX_TABLE_NULL, "MUX_DP_AUX_Interception_Disable"}, - {A_STATUS, R_MUX_DP_EQ_CONFIG, MUX_TABLE_NULL, "MUX_DP_EQ_Configuration"}, - {A_STATUS, R_MUX_DP_OUTPUT_CONFIG, MUX_TABLE_NULL, "MUX_DP_Output_Configuration"} + // Address RegisterDataOrgData String + //== + {A_STATUS, R_FIRMWARE_VERSION, MUX_TABLE_NULL, 0x00,"Firmware Version Number"}, // 0x00 + {A_STATUS, R_CC_STATUS,MUX_TABLE_NULL, 0x00,"CC_Status"}, // 0x01 + {A_MUX, R_CC_STATUS_1, MUX_TABLE_NULL, 0x00,"CC_Status 1"}, // 0x02 + {A_MUX, R_CC_STATUS_2, MUX_TABLE_NULL, 0x00,"CC_Status 2"}, // 0x03 + {A_MUX, R_CC_STATUS_3, MUX_TABLE_NULL, 0x00,"CC_Status 3"}, // 0x04 + {A_MUX, R_MUX_STATUS, MUX_TABLE_NULL, 0x00,"MUX_Status"}, // 0x05 + {A_MUX, R_MUX_USB_STATUS, MUX_TABLE_NULL, 0x00,"MUX USB Status"}, // 0x06 + {A_MUX, R_MUX_HPD_ASSERT, MUX_TABLE_NULL, 0x00, "MUX_In_HPD_Assertion"},// 0x07 + {A_MUX, R_MUX_DP_TRAINING, MUX_TABLE_NULL, 0x00, "MUX_DP_Training_Disable"}, // 0x08 + {A_MUX, R_MUX_DP_AUX_INTERCEPT, MUX_TABLE_NULL, 0x00, "MUX_DP_AUX_Interception_Disable"}, // 0x09 + {A_MUX, R_MUX_DP_EQ_CONFIG, MUX_TABLE_NULL, 0x00, "MUX_DP_EQ_Configuration"}, // 0x0A + {A_MUX, R_MUX_DP_OUTPUT_CONFIG, MUX_TABLE_NULL, 0x00, "MUX_DP_Output_Configuration"} // 0x0B }; VOID @@ -162,6 +164,7 @@ MB3ReadMux ( RetryCount = MUX_RETRY_COUNT; do { +
[edk2] [PATCH] [edk2-platforms/devel-IntelAtomProcessorE3900] Fix Type-C video
>From a5d80c8322c30e09a92c0b88cdcec66ee612546f Mon Sep 17 00:00:00 2001 From: Kelly Steele Date: Wed, 3 Oct 2018 09:38:36 -0700 Subject: [PATCH] [edk2-platforms/devel-IntelAtomProcessorE3900] Fix Type-C video Enabled Type-C video thru the VBT. Corrected the Type-C debug code and removed the call to the Type-C debug code. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Kelly Steele --- .../BoardInitPostMem/BoardInitMiscs.c | 5 - .../MinnowBoard3Module/BoardInitPostMem/TypeC.c| 77 ++-- .../MinnowBoard3Module/BoardInitPostMem/TypeC.h| 133 ++--- .../Board/MinnowBoard3Module/Vbt/VbtBxtMipi.bin| Bin 5632 -> 5632 bytes 4 files changed, 130 insertions(+), 85 deletions(-) diff --git a/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/BoardInitMiscs.c b/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/BoardInitMiscs.c index 99e643f792..4e708e8793 100644 --- a/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/BoardInitMiscs.c +++ b/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/BoardInitMiscs.c @@ -128,11 +128,6 @@ Minnow3ModuleMultiPlatformInfoInit ( Status = Minnow3ModuleInitializeBoardOemId (PeiServices, PlatformInfoHob); Status = Minnow3ModuleInitializeBoardSsidSvid (PeiServices, PlatformInfoHob); - // - // TypeC MUX AUX mode - // - MB3SetupTypecMuxAux (); - return EFI_SUCCESS; } diff --git a/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/TypeC.c b/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/TypeC.c index 7b8d56ab48..12153ab6b0 100644 --- a/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/TypeC.c +++ b/Platform/BroxtonPlatformPkg/Board/MinnowBoard3Module/BoardInitPostMem/TypeC.c @@ -16,18 +16,20 @@ #include "TypeC.h" static MUX_PROGRAMMING_TABLE mMB3MuxTable[] = { - // Address RegisterData String - // - {A_GENERAL, R_FIRMWARE_VERSION, MUX_TABLE_NULL, "Firmware Version Number"}, - {A_STATUS, R_CC_STATUS_1, MUX_TABLE_NULL, "CC_Status_1"}, - {A_STATUS, R_CC_STATUS_2, MUX_TABLE_NULL, "CC_Status_2"}, - {A_STATUS, R_CC_STATUS_3, MUX_TABLE_NULL, "CC_Status_3"}, - {A_STATUS, R_MUX_HPD_ASSERT, MUX_TABLE_NULL, "MUX_In_HPD_Assertion"}, - {A_STATUS, R_MUX_STATUS, MUX_TABLE_NULL, "MUX Status"}, - {A_STATUS, R_MUX_DP_TRAINING, MUX_TABLE_NULL, "MUX_DP_Training_Disable"}, - {A_STATUS, R_MUX_DP_AUX_INTERCEPT, MUX_TABLE_NULL, "MUX_DP_AUX_Interception_Disable"}, - {A_STATUS, R_MUX_DP_EQ_CONFIG, MUX_TABLE_NULL, "MUX_DP_EQ_Configuration"}, - {A_STATUS, R_MUX_DP_OUTPUT_CONFIG, MUX_TABLE_NULL, "MUX_DP_Output_Configuration"} + // Address RegisterDataOrgData String + //== + {A_STATUS, R_FIRMWARE_VERSION, MUX_TABLE_NULL, 0x00,"Firmware Version Number"}, // 0x00 + {A_STATUS, R_CC_STATUS,MUX_TABLE_NULL, 0x00,"CC_Status"}, // 0x01 + {A_MUX, R_CC_STATUS_1, MUX_TABLE_NULL, 0x00,"CC_Status 1"}, // 0x02 + {A_MUX, R_CC_STATUS_2, MUX_TABLE_NULL, 0x00,"CC_Status 2"}, // 0x03 + {A_MUX, R_CC_STATUS_3, MUX_TABLE_NULL, 0x00,"CC_Status 3"}, // 0x04 + {A_MUX, R_MUX_STATUS, MUX_TABLE_NULL, 0x00,"MUX_Status"}, // 0x05 + {A_MUX, R_MUX_USB_STATUS, MUX_TABLE_NULL, 0x00,"MUX USB Status"}, // 0x06 + {A_MUX, R_MUX_HPD_ASSERT, MUX_TABLE_NULL, 0x00, "MUX_In_HPD_Assertion"},// 0x07 + {A_MUX, R_MUX_DP_TRAINING, MUX_TABLE_NULL, 0x00, "MUX_DP_Training_Disable"}, // 0x08 + {A_MUX, R_MUX_DP_AUX_INTERCEPT, MUX_TABLE_NULL, 0x00, "MUX_DP_AUX_Interception_Disable"}, // 0x09 + {A_MUX, R_MUX_DP_EQ_CONFIG, MUX_TABLE_NULL, 0x00, "MUX_DP_EQ_Configuration"}, // 0x0A + {A_MUX, R_MUX_DP_OUTPUT_CONFIG, MUX_TABLE_NULL, 0x00, "MUX_DP_Output_Configuration"} // 0x0B }; VOID @@ -162,6 +164,7 @@ MB3ReadMux ( RetryCount = MUX_RETRY_COUNT; do { +MicroSecondDelay (MUX_I2C_DELAY); *Data = 0x00; Status = ByteReadI2C (PARADE_MUX_I2C_BUS, SlaveAddress, Offset, 1, Data); } while ((RetryCount-- > 0) && (EFI_ERROR (Status))); @@ -182,6 +185,7 @@ MB3WriteMux ( RetryCount = MUX_RETRY_COUNT; do { +MicroSecondDelay (MUX_I2C_DELAY); Status = ByteWriteI2C (PARADE_MUX_I2C_BUS, SlaveAddress, Offset, 1, Data); } while ((RetryCount-- > 0) && (EFI_ERROR (Status))); @@ -204,15 +208,19 @@ MB3DumpMux ( // Loop thru device and dump it all