From: Chris Ball <cjb@laptop.org>
To: Philippe De Swert <philippedeswert@gmail.com>
Cc: linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org,
john.calixto@modsystems.com, prakity@marvell.com
Subject: Re: [PATCH 2/2] mmc: Remove dead code
Date: Wed, 09 May 2012 20:55:33 -0400 [thread overview]
Message-ID: <87y5p0lure.fsf@laptop.org> (raw)
In-Reply-To: <1334176325-6221-1-git-send-email-philippedeswert@gmail.com> (Philippe De Swert's message of "Wed, 11 Apr 2012 23:32:05 +0300")
Hi,
On Wed, Apr 11 2012, Philippe De Swert wrote:
> bus_width is passed to the function and when 0 (MMC_BUS_WIDTH_1)
> will cause the function to return. So in in the second test it
> definitly is different from 0, and the third test is redundant.
>
> Signed-off-by: Philippe De Swert <philippedeswert@gmail.com>
> ---
> drivers/mmc/core/mmc.c | 6 +-----
> 1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/drivers/mmc/core/mmc.c b/drivers/mmc/core/mmc.c
> index 54df5ad..4a1bf8f 100644
> --- a/drivers/mmc/core/mmc.c
> +++ b/drivers/mmc/core/mmc.c
> @@ -556,14 +556,10 @@ static int mmc_compare_ext_csds(struct mmc_card *card, unsigned bus_width)
> err = mmc_get_ext_csd(card, &bw_ext_csd);
>
> if (err || bw_ext_csd == NULL) {
> - if (bus_width != MMC_BUS_WIDTH_1)
> - err = -EINVAL;
> + err = -EINVAL;
> goto out;
> }
>
> - if (bus_width == MMC_BUS_WIDTH_1)
> - goto out;
> -
> /* only compare read only fields */
> err = !((card->ext_csd.raw_partition_support ==
> bw_ext_csd[EXT_CSD_PARTITION_SUPPORT]) &&
Thanks, pushed for mmc-next for 3.5.
- Chris.
--
Chris Ball <cjb@laptop.org> <http://printf.net/>
One Laptop Per Child
prev parent reply other threads:[~2012-05-10 0:55 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-04-11 20:32 [PATCH 2/2] mmc: Remove dead code Philippe De Swert
2012-04-11 20:56 ` Philip Rakity
2012-04-12 1:39 ` Namjae Jeon
2012-05-10 0:48 ` Namjae Jeon
2012-05-10 0:55 ` Chris Ball [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87y5p0lure.fsf@laptop.org \
--to=cjb@laptop.org \
--cc=john.calixto@modsystems.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mmc@vger.kernel.org \
--cc=philippedeswert@gmail.com \
--cc=prakity@marvell.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.