From: York Sun <yorksun@freescale.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] powerpc/b4860: Disable unused devices using DEVDISR register
Date: Thu, 8 Aug 2013 19:08:13 -0700 [thread overview]
Message-ID: <52044F0D.10802@freescale.com> (raw)
In-Reply-To: <1372763107-19942-1-git-send-email-Sandeep@freescale.com>
On 07/02/2013 04:05 AM, Sandeep Singh wrote:
> Explicitly disabling unused IPs/blocks. This will lower
> power consumption.
>
> Signed-off-by: Sandeep Singh <Sandeep@freescale.com>
>
<snip>
> +
> +void cpu_device_disable()
> +{
> + ccsr_gur_t *gur = (void *)CONFIG_SYS_MPC85xx_GUTS_ADDR;
> +
> + /* get devdisr */
> + u32 *devdisr1 = in_be32(&gur->devdisr);
> + u32 *devdisr2 = in_be32(&gur->devdisr2);
> + u32 *devdisr3 = in_be32(&gur->devdisr3);
> + u32 *devdisr4 = in_be32(&gur->devdisr4);
> + u32 *devdisr5 = in_be32(&gur->devdisr5);
> +
in_be32 returns u32, not u32 *. You will have compiling warnings here.
<snip>
> diff --git a/arch/powerpc/include/asm/processor.h b/arch/powerpc/include/asm/processor.h
> index 64a6f9c..143d561 100644
> --- a/arch/powerpc/include/asm/processor.h
> +++ b/arch/powerpc/include/asm/processor.h
> @@ -1125,6 +1125,7 @@
> #define SVR_B4860 0X868000
> #define SVR_G4860 0x868001
> #define SVR_G4060 0x868003
> +#define SVR_B4060 0x868002
> #define SVR_B4440 0x868100
> #define SVR_G4440 0x868101
> #define SVR_B4420 0x868102
> diff --git a/board/freescale/b4860qds/b4860qds.c b/board/freescale/b4860qds/b4860qds.c
> index b1b012c..5e2efd3 100644
> --- a/board/freescale/b4860qds/b4860qds.c
> +++ b/board/freescale/b4860qds/b4860qds.c
> @@ -575,6 +575,8 @@ int board_early_init_r(void)
> int ret;
> u32 svr = SVR_SOC_VER(get_svr());
>
> + cpu_device_disable();
You don't have prototype for this function.
> +
> /* Create law for MAPLE only for personalities having MAPLE */
> if ((svr == SVR_B4860) || (svr == SVR_B4440) ||
> (svr == SVR_B4420) || (svr == SVR_B4220)) {
>
This hunk doesn't apply. Please check your code base.
York
prev parent reply other threads:[~2013-08-09 2:08 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-02 11:05 [U-Boot] [PATCH] powerpc/b4860: Disable unused devices using DEVDISR register Sandeep Singh
2013-08-09 2:08 ` York Sun [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=52044F0D.10802@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