Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1337048 > unrolled thread
| Started by | Keerthy <j-keerthy@ti.com> |
|---|---|
| First post | 2016-02-18 06:40 +0100 |
| Last post | 2016-02-18 08:50 +0100 |
| Articles | 3 — 3 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH 2/2] ARM: AM43XX: HWMOD: Add rtc hwmod Keerthy <j-keerthy@ti.com> - 2016-02-18 06:40 +0100
Re: [PATCH 2/2] ARM: AM43XX: HWMOD: Add rtc hwmod Paul Walmsley <paul@pwsan.com> - 2016-02-18 07:50 +0100
Re: [PATCH 2/2] ARM: AM43XX: HWMOD: Add rtc hwmod Keerthy <a0393675@ti.com> - 2016-02-18 08:50 +0100
| From | Keerthy <j-keerthy@ti.com> |
|---|---|
| Date | 2016-02-18 06:40 +0100 |
| Subject | [PATCH 2/2] ARM: AM43XX: HWMOD: Add rtc hwmod |
| Message-ID | <r3ptL-Rw-1@gated-at.bofh.it> |
The patch adds rtc hwmod. RTC module The RTC module is physically
present on the AM438x SoC used on AM43X-EPOS-EVM, but it is permanently
disabled. A secure RTC is used instead on these devices, where needed.
. Hence adding it selectively using a seprate list to get RTC Module
functional on the other am43x SoCs used on am437x-gp-evm and
am437x-sk-evm.
Signed-off-by: Keerthy <j-keerthy@ti.com>
---
No Public TRM is available for AM438x SoC as of now.
arch/arm/mach-omap2/omap_hwmod_43xx_data.c | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-omap2/omap_hwmod_43xx_data.c b/arch/arm/mach-omap2/omap_hwmod_43xx_data.c
index e97a894..fcffaf8 100644
--- a/arch/arm/mach-omap2/omap_hwmod_43xx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_43xx_data.c
@@ -1020,9 +1020,21 @@ static struct omap_hwmod_ocp_if *am43xx_hwmod_ocp_ifs[] __initdata = {
NULL,
};
+static struct omap_hwmod_ocp_if *am43xx_rtc_hwmod_ocp_ifs[] __initdata = {
+ &am33xx_l4_wkup__rtc,
+ NULL,
+};
+
int __init am43xx_hwmod_init(void)
{
+ int ret;
+
omap_hwmod_am43xx_reg();
omap_hwmod_init();
- return omap_hwmod_register_links(am43xx_hwmod_ocp_ifs);
+ ret = omap_hwmod_register_links(am43xx_hwmod_ocp_ifs);
+
+ if (!(of_machine_is_compatible("ti,am438x")))
+ ret = omap_hwmod_register_links(am43xx_rtc_hwmod_ocp_ifs);
+
+ return ret;
}
--
1.9.1
[toc] | [next] | [standalone]
| From | Paul Walmsley <paul@pwsan.com> |
|---|---|
| Date | 2016-02-18 07:50 +0100 |
| Message-ID | <r3qzv-1BA-11@gated-at.bofh.it> |
| In reply to | #1337048 |
Hi Keerthy
On Thu, 18 Feb 2016, Keerthy wrote:
> The patch adds rtc hwmod. RTC module The RTC module is physically
> present on the AM438x SoC used on AM43X-EPOS-EVM, but it is permanently
> disabled. A secure RTC is used instead on these devices, where needed.
> . Hence adding it selectively using a seprate list to get RTC Module
> functional on the other am43x SoCs used on am437x-gp-evm and
> am437x-sk-evm.
>
> Signed-off-by: Keerthy <j-keerthy@ti.com>
> ---
>
> No Public TRM is available for AM438x SoC as of now.
>
> arch/arm/mach-omap2/omap_hwmod_43xx_data.c | 14 +++++++++++++-
> 1 file changed, 13 insertions(+), 1 deletion(-)
>
> diff --git a/arch/arm/mach-omap2/omap_hwmod_43xx_data.c b/arch/arm/mach-omap2/omap_hwmod_43xx_data.c
> index e97a894..fcffaf8 100644
> --- a/arch/arm/mach-omap2/omap_hwmod_43xx_data.c
> +++ b/arch/arm/mach-omap2/omap_hwmod_43xx_data.c
> @@ -1020,9 +1020,21 @@ static struct omap_hwmod_ocp_if *am43xx_hwmod_ocp_ifs[] __initdata = {
> NULL,
> };
>
> +static struct omap_hwmod_ocp_if *am43xx_rtc_hwmod_ocp_ifs[] __initdata = {
> + &am33xx_l4_wkup__rtc,
> + NULL,
> +};
> +
> int __init am43xx_hwmod_init(void)
> {
> + int ret;
> +
> omap_hwmod_am43xx_reg();
> omap_hwmod_init();
> - return omap_hwmod_register_links(am43xx_hwmod_ocp_ifs);
> + ret = omap_hwmod_register_links(am43xx_hwmod_ocp_ifs);
> +
> + if (!(of_machine_is_compatible("ti,am438x")))
> + ret = omap_hwmod_register_links(am43xx_rtc_hwmod_ocp_ifs);
> +
> + return ret;
> }
Could you please invert the test of this case such that the RTC hwmod is
only registered on AM43xx SoCs where it is specifically known to be
enabled?
That way, if another AM43xx SoC comes out that doesn't have the RTC
module, it won't inadvertently be registered. This seems like a safer
approach.
- Paul
[toc] | [prev] | [next] | [standalone]
| From | Keerthy <a0393675@ti.com> |
|---|---|
| Date | 2016-02-18 08:50 +0100 |
| Message-ID | <r3rvA-2gQ-13@gated-at.bofh.it> |
| In reply to | #1337085 |
Hi Paul,
On Thursday 18 February 2016 12:12 PM, Paul Walmsley wrote:
> Hi Keerthy
>
> On Thu, 18 Feb 2016, Keerthy wrote:
>
>> The patch adds rtc hwmod. RTC module The RTC module is physically
>> present on the AM438x SoC used on AM43X-EPOS-EVM, but it is permanently
>> disabled. A secure RTC is used instead on these devices, where needed.
>> . Hence adding it selectively using a seprate list to get RTC Module
>> functional on the other am43x SoCs used on am437x-gp-evm and
>> am437x-sk-evm.
>>
>> Signed-off-by: Keerthy <j-keerthy@ti.com>
>> ---
>>
>> No Public TRM is available for AM438x SoC as of now.
>>
>> arch/arm/mach-omap2/omap_hwmod_43xx_data.c | 14 +++++++++++++-
>> 1 file changed, 13 insertions(+), 1 deletion(-)
>>
>> diff --git a/arch/arm/mach-omap2/omap_hwmod_43xx_data.c b/arch/arm/mach-omap2/omap_hwmod_43xx_data.c
>> index e97a894..fcffaf8 100644
>> --- a/arch/arm/mach-omap2/omap_hwmod_43xx_data.c
>> +++ b/arch/arm/mach-omap2/omap_hwmod_43xx_data.c
>> @@ -1020,9 +1020,21 @@ static struct omap_hwmod_ocp_if *am43xx_hwmod_ocp_ifs[] __initdata = {
>> NULL,
>> };
>>
>> +static struct omap_hwmod_ocp_if *am43xx_rtc_hwmod_ocp_ifs[] __initdata = {
>> + &am33xx_l4_wkup__rtc,
>> + NULL,
>> +};
>> +
>> int __init am43xx_hwmod_init(void)
>> {
>> + int ret;
>> +
>> omap_hwmod_am43xx_reg();
>> omap_hwmod_init();
>> - return omap_hwmod_register_links(am43xx_hwmod_ocp_ifs);
>> + ret = omap_hwmod_register_links(am43xx_hwmod_ocp_ifs);
>> +
>> + if (!(of_machine_is_compatible("ti,am438x")))
>> + ret = omap_hwmod_register_links(am43xx_rtc_hwmod_ocp_ifs);
>> +
>> + return ret;
>> }
>
> Could you please invert the test of this case such that the RTC hwmod is
> only registered on AM43xx SoCs where it is specifically known to be
> enabled?
>
> That way, if another AM43xx SoC comes out that doesn't have the RTC
> module, it won't inadvertently be registered. This seems like a safer
> approach.
I get your point but currently only am438x SoC has RTC disabled forever.
So i checked negating am438x. I can add a check with am4372 here and
register for only those SoCs.
I will resend a v2 in a while.
Thanks for the quick response.
Best Regards,
Keerthy
>
> - Paul
>
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web