From: York Sun <yorksun@freescale.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] mpc85xx/T104xRDB: Remove vbank check redundant code
Date: Mon, 27 Jul 2015 12:06:35 -0700 [thread overview]
Message-ID: <55B6813B.2070906@freescale.com> (raw)
In-Reply-To: <1431930663-6892-1-git-send-email-Priyanka.Jain@freescale.com>
On 05/17/2015 11:31 PM, Priyanka Jain wrote:
> sw variable in checkboard function is storing vbank value
> which can only take 4-bit value.
> So check of sw value for if greater than 7 is redundant.
>
> Signed-off-by: Priyanka Jain <Priyanka.Jain@freescale.com>
> ---
> board/freescale/t104xrdb/t104xrdb.c | 5 +----
> 1 files changed, 1 insertions(+), 4 deletions(-)
>
> diff --git a/board/freescale/t104xrdb/t104xrdb.c b/board/freescale/t104xrdb/t104xrdb.c
> index 9cd5e15..c34eea6 100644
> --- a/board/freescale/t104xrdb/t104xrdb.c
> +++ b/board/freescale/t104xrdb/t104xrdb.c
> @@ -35,10 +35,7 @@ int checkboard(void)
> sw = CPLD_READ(flash_ctl_status);
> sw = ((sw & CPLD_LBMAP_MASK) >> CPLD_LBMAP_SHIFT);
>
> - if (sw <= 7)
> - printf("vBank: %d\n", sw);
> - else
> - printf("Unsupported Bank=%x\n", sw);
> + printf("vBank: %d\n", sw);
>
> return 0;
> }
>
Priyanka,
4-bit variable can still have value bigger than 7. Is there other reason you
want to remove it?
York
next prev parent reply other threads:[~2015-07-27 19:06 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-18 6:31 [U-Boot] [PATCH] mpc85xx/T104xRDB: Remove vbank check redundant code Priyanka Jain
2015-07-27 19:06 ` York Sun [this message]
2015-07-29 8:31 ` Priyanka Jain
2015-07-29 16:56 ` York Sun
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=55B6813B.2070906@freescale.com \
--to=yorksun@freescale.com \
--cc=u-boot@lists.denx.de \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox