From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-x231.google.com (mail-wm0-x231.google.com [IPv6:2a00:1450:400c:c09::231]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 6A3CE21A00AD5 for ; Thu, 29 Jun 2017 08:55:31 -0700 (PDT) Received: by mail-wm0-x231.google.com with SMTP id 62so86733164wmw.1 for ; Thu, 29 Jun 2017 08:57:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=Fj2qra1XqfmE6ioglaHzSE/joC3aXpq+JAt4NvpC5WE=; b=D1klM0pm7acpcvGYFd6BNVXcN3CcUERPRHuysBK8ocJ/Z9zSRKMXo1BLdEpowwNSNQ U/nbrcs23sn3sEUCnlNbrpUTuQaFwgOUiVv2fgM0JfIGEpaD3JX/E5WgNSd4bH/NZkNs vmvqG1dXY0lBDAbp2I/de10S7UWC1J9uGMacQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=Fj2qra1XqfmE6ioglaHzSE/joC3aXpq+JAt4NvpC5WE=; b=TwxoLwcj/vqN22ZpaZ8f+bfcj5QYHwJQrdxAvUTosARSYiUXb5UsUuAjqnTBkUPksN 4LtiUpOYtOUxd919a4OT+K1vnmo2aZ3gh7DGhjuGOjj25KGMzG8Nb0qeWeZO8PJAbkXN O1N1HwxfjihExHuLq8bLDieebxw6pspSptPS1iF9BXY0QlEsib8hERaSBcjopdYljOG3 jS+RjZdpBgvgUVj91cifVr1mwUoMbaE/x8F0o3Mt7fATz/nt9RTvdCAm+fN5HGjhZnW3 TSejidoPJuU0F9sAqaOpUrleLhg+qgxzHZgoEmznoA0Stfkgw1KObKyF7unjQ+4sl+qz pXDA== X-Gm-Message-State: AKS2vOzOiIMbjw6vU7asyB3tRKdEJ5Ohxmkc7CNRY44ppcYFOEmEzX2a pPWClJlU5kWgYYlE X-Received: by 10.28.153.81 with SMTP id b78mr1905149wme.85.1498751822647; Thu, 29 Jun 2017 08:57:02 -0700 (PDT) Received: from bivouac.eciton.net (bivouac.eciton.net. [2a00:1098:0:86:1000:23:0:2]) by smtp.gmail.com with ESMTPSA id w96sm4169523wrc.33.2017.06.29.08.57.01 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 29 Jun 2017 08:57:02 -0700 (PDT) Date: Thu, 29 Jun 2017 16:57:00 +0100 From: Leif Lindholm To: Jun Nie Cc: Ard Biesheuvel , Haojian Zhuang , edk2-devel@lists.01.org, Shawn Guo , Jason Liu Message-ID: <20170629155700.GU26676@bivouac.eciton.net> References: <1498726925-25860-1-git-send-email-jun.nie@linaro.org> <20170629120935.GS26676@bivouac.eciton.net> MIME-Version: 1.0 In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) Subject: Re: [PATCH] EmbeddedPkg/MmcDxe: Correct argument of ECSD read X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 29 Jun 2017 15:55:31 -0000 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, Jun 29, 2017 at 10:29:08PM +0800, Jun Nie wrote: > 2017-06-29 20:09 GMT+08:00 Leif Lindholm : > > On Thu, Jun 29, 2017 at 05:02:05PM +0800, Jun Nie wrote: > >> The argument of CMD8 should be stuff bits according to standard > >> JESD84-A44. > > > > OK, I realise that "stuff bits" is a term used by the spec, so that is > > probably sufficient explanation even though the term was known to me. > > And the MdeModulePkg driver seems to agree on the technical point. > > My question is why zeroes is the correct "stuff bits" value? > > Yes, it is defined in page 2 in spec. I guess 0 is best filling value > than other value when we do not need a real value. > stuff bit: filling 0 bits to ensure fixed length frames for commands > and responses. Yeah, fair enough. It literally is just "nothing". Reviewed-by: Leif Lindholm Pushed as 0ad564ffe7. (Oh, and "Add non-DDR timing mode support" which I had seen as a companion patch to the ECSD alignment fix also pushed, as 44f4ff6257.) / Leif > >> Contributed-under: TianoCore Contribution Agreement 1.0 > >> Signed-off-by: Jun Nie > >> --- > >> EmbeddedPkg/Universal/MmcDxe/MmcIdentification.c | 2 +- > >> 1 file changed, 1 insertion(+), 1 deletion(-) > >> > >> diff --git a/EmbeddedPkg/Universal/MmcDxe/MmcIdentification.c b/EmbeddedPkg/Universal/MmcDxe/MmcIdentification.c > >> index 4ce0ddd..c28207e 100644 > >> --- a/EmbeddedPkg/Universal/MmcDxe/MmcIdentification.c > >> +++ b/EmbeddedPkg/Universal/MmcDxe/MmcIdentification.c > >> @@ -210,7 +210,7 @@ EmmcIdentificationMode ( > >> } > >> > >> // Fetch ECSD > >> - Status = Host->SendCommand (Host, MMC_CMD8, RCA); > >> + Status = Host->SendCommand (Host, MMC_CMD8, 0); > >> if (EFI_ERROR (Status)) { > >> DEBUG ((EFI_D_ERROR, "EmmcIdentificationMode(): ECSD fetch error, Status=%r.\n", Status)); > >> } > >> -- > >> 1.9.1 > >>