From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail03.groups.io (mail03.groups.io [45.79.227.220]) by spool.mail.gandi.net (Postfix) with ESMTPS id 5C0747803CF for ; Thu, 11 Apr 2024 08:21:23 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=1hxrIWToK7DqxvFYaVFeTEZ+5Jbaiwc46yqeqJHggOw=; c=relaxed/simple; d=groups.io; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Resent-Date:Resent-From:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Transfer-Encoding; s=20240206; t=1712823682; v=1; b=aqQFhlJ1l8Upp/pgeMFSXPlhLfWtfkKCA/SqFDFZimQZ1mvR8J+H/UH1dU06N2XuPuO/qlaB e9vjYdyTlKKG6UHZ8dZdWtWRtWrqqJaAnLU4ArH6pFGS/isJdbrgtKRHOIuqlEomI1chGnSitf3 8a5UKseCPXvZYjJoPkiFdxMnYcaEqGiM4jEbYyYW28AI9I+5girntLAcLinXpQ1+R0JKtWLiwL2 hsymlPIrGqwjI5x0yqiB9ff5tvh+OPE6hoH/yE6VhIR40eIhl2yDmXAybmyZcQgoh96WtZY56Ak 3cstdkVdc/ZFVrqZY7s4FRVXJO3lj4WxrDAKPNApmGi3w== X-Received: by 127.0.0.2 with SMTP id iZVRYY7687511xVdMZjfghAD; Thu, 11 Apr 2024 01:21:21 -0700 X-Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.20]) by mx.groups.io with SMTP id smtpd.web11.12473.1712823681310307899 for ; Thu, 11 Apr 2024 01:21:21 -0700 X-CSE-ConnectionGUID: 4Fgj7agwTz2y6kXr/tyIYQ== X-CSE-MsgGUID: aNn41ANZTyKPbTPeIuisgA== X-IronPort-AV: E=McAfee;i="6600,9927,11039"; a="8073256" X-IronPort-AV: E=Sophos;i="6.07,192,1708416000"; d="scan'208";a="8073256" X-Received: from orviesa010.jf.intel.com ([10.64.159.150]) by orvoesa112.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Apr 2024 01:21:20 -0700 X-CSE-ConnectionGUID: KCEGX/fbRpqWzmcF4T+q9Q== X-CSE-MsgGUID: o6APop1eQCaVMWX15Jnrhw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.07,192,1708416000"; d="scan'208";a="20732803" X-Received: from saiphani-mobl.gar.corp.intel.com ([10.247.18.58]) by orviesa010-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Apr 2024 01:21:18 -0700 From: "Sai Phanindra Gandikota" To: devel@edk2.groups.io Cc: Gandikota Sai Phanindra <102981786+saiphanindrag@users.noreply.github.com>, Ray Ni , Liming Gao , Sai Phanindra Gandikota Subject: [edk2-devel] [PATCH] MdeModulePkg/SdMmcPciHcDxe: Update switch to highspeed timing flow Date: Thu, 11 Apr 2024 13:51:01 +0530 Message-Id: <58a96b1dc10533468a0f6b1fbbb27336baac46f3.1712823511.git.sai.phanindra.gandikota@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Resent-Date: Thu, 11 Apr 2024 01:21:21 -0700 Resent-From: sai.phanindra.gandikota@intel.com Reply-To: devel@edk2.groups.io,sai.phanindra.gandikota@intel.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: TducQlnyIGkn60oqxQY5PSRFx7686176AA= Content-Transfer-Encoding: 8bit X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20240206 header.b=aqQFhlJ1; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=intel.com (policy=none); spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 45.79.227.220 as permitted sender) smtp.mailfrom=bounce@groups.io From: Gandikota Sai Phanindra <102981786+saiphanindrag@users.noreply.github.com> Switch to DDR50 speed mode is failing with the existing code flow. Exiting flow sets Bus width first then bus timing and clock frequency, with this flow switch to DDR50 speed mode is failing. After updating the flow to set the bus timing and clock frequency then bus width resolved the issue and switch to DDR50 is successful. Cc: Ray Ni Cc: Liming Gao Signed-off-by: Sai Phanindra Gandikota --- MdeModulePkg/Bus/Pci/SdMmcPciHcDxe/EmmcDevice.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MdeModulePkg/Bus/Pci/SdMmcPciHcDxe/EmmcDevice.c b/MdeModulePkg/Bus/Pci/SdMmcPciHcDxe/EmmcDevice.c index a392a4e31a..2bca6da3db 100644 --- a/MdeModulePkg/Bus/Pci/SdMmcPciHcDxe/EmmcDevice.c +++ b/MdeModulePkg/Bus/Pci/SdMmcPciHcDxe/EmmcDevice.c @@ -833,12 +833,12 @@ EmmcSwitchToHighSpeed ( IsDdr = FALSE; } - Status = EmmcSwitchBusWidth (PciIo, PassThru, Slot, Rca, IsDdr, BusMode->BusWidth); + Status = EmmcSwitchBusTiming (PciIo, PassThru, Slot, Rca, BusMode->DriverStrength, BusMode->BusTiming, BusMode->ClockFreq); if (EFI_ERROR (Status)) { return Status; } - return EmmcSwitchBusTiming (PciIo, PassThru, Slot, Rca, BusMode->DriverStrength, BusMode->BusTiming, BusMode->ClockFreq); + return EmmcSwitchBusWidth (PciIo, PassThru, Slot, Rca, IsDdr, BusMode->BusWidth); } /** -- 2.38.1.windows.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#117622): https://edk2.groups.io/g/devel/message/117622 Mute This Topic: https://groups.io/mt/105458662/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=-