From patchwork Wed May 11 03:34:33 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Ball X-Patchwork-Id: 775752 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p4B3VkBO015589 for ; Wed, 11 May 2011 03:32:06 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754151Ab1EKDcG (ORCPT ); Tue, 10 May 2011 23:32:06 -0400 Received: from void.printf.net ([89.145.121.20]:38194 "EHLO void.printf.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754134Ab1EKDcF (ORCPT ); Tue, 10 May 2011 23:32:05 -0400 Received: from pullcord.laptop.org ([18.85.46.20]) by void.printf.net with esmtp (Exim 4.69) (envelope-from ) id 1QK09b-0006HK-U3; Wed, 11 May 2011 04:32:04 +0100 From: Chris Ball To: Arindam Nath Cc: prakity@marvell.com, zhangfei.gao@gmail.com, subhashj@codeaurora.org, linux-mmc@vger.kernel.org, henry.su@amd.com, aaron.lu@amd.com, anath.amd@gmail.com Subject: Re: [PATCH v4 02/15] mmc: sd: query function modes for uhs cards References: <1304578151-1775-1-git-send-email-arindam.nath@amd.com> <1304578151-1775-3-git-send-email-arindam.nath@amd.com> Date: Tue, 10 May 2011 23:34:33 -0400 In-Reply-To: <1304578151-1775-3-git-send-email-arindam.nath@amd.com> (Arindam Nath's message of "Thu, 5 May 2011 12:18:58 +0530") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.90 (gnu/linux) MIME-Version: 1.0 Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Wed, 11 May 2011 03:32:07 +0000 (UTC) Hi, On Thu, May 05 2011, Arindam Nath wrote: > SD cards which conform to Physical Layer Spec v3.01 can support > additional Bus Speed Modes, Driver Strength, and Current Limit > other than the default values. We use CMD6 mode 0 to read these > additional card functions. The values read here will be used > during UHS-I initialization steps. > > Signed-off-by: Arindam Nath > Reviewed-by: Philip Rakity > Tested-by: Philip Rakity Thanks, pushed to mmc-next for .40 with the trivial changes below: - if ((err != -EINVAL) - && (err != -ENOSYS) - && (err != -EFAULT)) + if (err != -EINVAL && err != -ENOSYS && err != -EFAULT) goto out; printk(KERN_WARNING "%s: problem reading " @@ -332,14 +327,11 @@ static int mmc_read_switch(struct mmc_card *card) * If the host or the card can't do the switch, * fail more gracefully. */ - if ((err != -EINVAL) - && (err != -ENOSYS) - && (err != -EFAULT)) + if (err != -EINVAL && err != -ENOSYS && err != -EFAULT) goto out; printk(KERN_WARNING "%s: problem reading " - Chris. diff --git a/drivers/mmc/core/sd.c b/drivers/mmc/core/sd.c index d4410c9..027d7cb 100644 --- a/drivers/mmc/core/sd.c +++ b/drivers/mmc/core/sd.c @@ -190,7 +190,7 @@ static int mmc_decode_scr(struct mmc_card *card) scr->sda_vsn = UNSTUFF_BITS(resp, 56, 4); scr->bus_widths = UNSTUFF_BITS(resp, 48, 4); if (scr->sda_vsn == SCR_SPEC_VER_2) - /* Check if Physical Layer Spec v3.0 is supported*/ + /* Check if Physical Layer Spec v3.0 is supported */ scr->sda_spec3 = UNSTUFF_BITS(resp, 47, 1); if (UNSTUFF_BITS(resp, 55, 1)) @@ -288,13 +288,11 @@ static int mmc_read_switch(struct mmc_card *card) * If the host or the card can't do the switch, * fail more gracefully. */ - if ((err != -EINVAL) - && (err != -ENOSYS) - && (err != -EFAULT)) + if (err != -EINVAL && err != -ENOSYS && err != -EFAULT) goto out; printk(KERN_WARNING "%s: problem reading Bus Speed modes.\n", @@ -310,14 +308,11 @@ static int mmc_read_switch(struct mmc_card *card) * If the host or the card can't do the switch, * fail more gracefully. */