From: Minkyu Kang <mk7.kang@samsung.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] drivers:power:exynos-tmu: add support for Exynos5260
Date: Tue, 03 Dec 2013 11:11:27 +0900 [thread overview]
Message-ID: <529D3DCF.3070305@samsung.com> (raw)
In-Reply-To: <1385466997-18074-1-git-send-email-ch.naveen@samsung.com>
Dear Naveen Krishna Chatradhi,
On 26/11/13 20:56, Naveen Krishna Chatradhi wrote:
> This patch adds support for TMU on Exynos5260
> Register bit fields are little different from the previous
> versions.
>
> Change-Id: Ibe835abe9cb255d2f8375c8e9e32d32cff19c093
please remove it.
> Signed-off-by: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
> ---
> arch/arm/include/asm/arch-exynos/tmu.h | 11 +++++++++++
> drivers/power/exynos-tmu.c | 25 +++++++++++++++++++++++--
> 2 files changed, 34 insertions(+), 2 deletions(-)
>
> diff --git a/arch/arm/include/asm/arch-exynos/tmu.h b/arch/arm/include/asm/arch-exynos/tmu.h
> index cad3569..19b8f62 100644
> --- a/arch/arm/include/asm/arch-exynos/tmu.h
> +++ b/arch/arm/include/asm/arch-exynos/tmu.h
> @@ -26,7 +26,11 @@ struct exynos5_tmu_reg {
> u32 triminfo_control;
> u32 rsvd5[2];
> u32 tmu_control;
> +#ifdef CONFIG_EXYNOS5260
> + u32 tmu_control1;
> +#else
> u32 rsvd7;
> +#endif
> u32 tmu_status;
> u32 sampling_internal;
> u32 counter_value0;
> @@ -41,10 +45,17 @@ struct exynos5_tmu_reg {
> u32 past_temp7_4;
> u32 past_temp11_8;
> u32 past_temp15_12;
> +#ifdef CONFIG_EXYNOS5260
> + u32 rsvd15[16];
> +#endif
> u32 inten;
> u32 intstat;
> u32 intclear;
> +#ifdef CONFIG_EXYNOS5260
> + u32 rsvd31[17];
> +#else
> u32 rsvd15;
> +#endif
> u32 emul_con;
> };
> #endif /* __ASM_ARCH_TMU_H */
> diff --git a/drivers/power/exynos-tmu.c b/drivers/power/exynos-tmu.c
> index 9a093a5..de3ff82 100644
> --- a/drivers/power/exynos-tmu.c
> +++ b/drivers/power/exynos-tmu.c
> @@ -31,7 +31,13 @@
> #define INTEN_RISE0 1
> #define INTEN_RISE1 (1 << 4)
> #define INTEN_RISE2 (1 << 8)
> +
> +#ifdef CONFIG_EXYNOS5250
> +#define INTEN_FALL0 (1 << 12)
> +#else
> #define INTEN_FALL0 (1 << 16)
> +#endif
> +
> #define INTEN_FALL1 (1 << 20)
> #define INTEN_FALL2 (1 << 24)
>
> @@ -43,9 +49,24 @@
> #define INTCLEAR_FALL0 (1 << 16)
> #define INTCLEAR_FALL1 (1 << 20)
> #define INTCLEAR_FALL2 (1 << 24)
> +
> +#ifdef CONFIG_EXYNOS5260
> +#define INTEN_RISE3 (1 << 12)
> +#define INTEN_FALL3 (1 << 28)
> +#define INTCLEAR_RISE3 (1 << 12)
> +#define INTCLEAR_FALL3 (1 << 28)
> +#endif
> +
> +#if defined(INTCLEAR_RISE3) && defined(INTCLEAR_FALL3)
> #define INTCLEARALL (INTCLEAR_RISE0 | INTCLEAR_RISE1 | \
> - INTCLEAR_RISE2 | INTCLEAR_FALL0 | \
> - INTCLEAR_FALL1 | INTCLEAR_FALL2)
> + INTCLEAR_RISE2 | INTCLEAR_RISE3 | \
> + INTCLEAR_FALL0 | INTCLEAR_FALL1 | \
> + INTCLEAR_FALL2 | INTCLEAR_FALL3)
> +#else
> +#define INTCLEARALL (INTCLEAR_RISE0 | INTCLEAR_RISE1 | \
> + INTCLEAR_RISE2 | INTCLEAR_FALL0 | \
> + INTCLEAR_FALL1 | INTCLEAR_FALL2)
> +#endif
>
> /* Tmeperature threshold values for various thermal events */
> struct temperature_params {
>
I recommended that don't use ifdefs.
And if you want to support exynos5260 then please post full features and board file.
Thanks,
Minkyu Kang.
next prev parent reply other threads:[~2013-12-03 2:11 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-26 11:56 [U-Boot] [PATCH] drivers:power:exynos-tmu: add support for Exynos5260 Naveen Krishna Chatradhi
2013-12-03 2:11 ` Minkyu Kang [this message]
2013-12-05 5:23 ` Naveen Krishna Ch
2013-12-05 5:51 ` Minkyu Kang
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=529D3DCF.3070305@samsung.com \
--to=mk7.kang@samsung.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