* [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc
@ 2013-12-03 14:25 Roger Quadros
2013-12-03 14:25 ` [PATCH 1/3] ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module Roger Quadros
` (3 more replies)
0 siblings, 4 replies; 14+ messages in thread
From: Roger Quadros @ 2013-12-03 14:25 UTC (permalink / raw)
To: bcousson, paul, tony
Cc: michael, David.Laight, bigeasy, linux-usb, linux-kernel, balbi,
linux-omap, tomi.valkeinen, sr, linux-arm-kernel, Roger Quadros
Hi,
This is a follow up solution to the original series in [1]
The first patch fixes the OMAP4 Panda USB detection problems on 3.13-rc1
with u-boot v2013.10.
The remaining 2 patches are required if SOFTRESET needs to be done for the
USB Host module on OMAP3 platforms.
Patch 2 fixes the hwmod RESET logic to prevent multiple SOFTRESETs
being issued to the modules. This multiple SOFTRESET was causing problems
with OMAP3 USB Host module. On Beagleboard C4 this is seen as failure to
mount NFS root over external USB to Ethernet device.
This might be the reason why HWMOD_INIT_NO_RESET was used for the OMAP
USB host module in OMAP3 hwmod data and just carried forward in OMAP4
and OMAP5 hwmod data as well.
cheers,
-roger
[1] - http://thread.gmane.org/gmane.linux.kernel/1603931
Roger Quadros (3):
ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module
ARM: OMAP2+: hwmod: Fix RESET logic
ARM: OMAP3: hwmod data: Don't prevent RESET of USB Host module
arch/arm/mach-omap2/omap_hwmod.c | 43 +++++++++++++++++++++++++++++-
arch/arm/mach-omap2/omap_hwmod_3xxx_data.c | 13 +++------
arch/arm/mach-omap2/omap_hwmod_44xx_data.c | 12 ++-------
arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 13 +++------
4 files changed, 50 insertions(+), 31 deletions(-)
--
1.8.3.2
^ permalink raw reply [flat|nested] 14+ messages in thread
* [PATCH 1/3] ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module
2013-12-03 14:25 [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc Roger Quadros
@ 2013-12-03 14:25 ` Roger Quadros
[not found] ` <1386080748-17005-2-git-send-email-rogerq-l0cyMroinI0@public.gmane.org>
2013-12-03 14:25 ` [PATCH 2/3] ARM: OMAP2+: hwmod: Fix RESET logic Roger Quadros
` (2 subsequent siblings)
3 siblings, 1 reply; 14+ messages in thread
From: Roger Quadros @ 2013-12-03 14:25 UTC (permalink / raw)
To: bcousson, paul, tony
Cc: tomi.valkeinen, balbi, sr, David.Laight, michael, bigeasy,
linux-omap, linux-usb, linux-arm-kernel, linux-kernel,
Roger Quadros
Without this, the USB devices are sometimes not detected on OMAP4 Panda
with u-boot v2013.10.
Unlike what the comment states, errata i660 does not state that we
can't RESET the USB host module. Instead it states that RESET is the
only way to recover from a deadlock situation.
RESET ensures that the module is in a known good state irrespective
of what bootloader does with the module, so it must be done at boot.
Reported-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Signed-off-by: Roger Quadros <rogerq@ti.com>
---
arch/arm/mach-omap2/omap_hwmod_44xx_data.c | 12 ++----------
arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 13 +++----------
2 files changed, 5 insertions(+), 20 deletions(-)
diff --git a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
index 1e5b12c..3318cae9 100644
--- a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
@@ -2937,7 +2937,7 @@ static struct omap_hwmod_class_sysconfig omap44xx_usb_host_hs_sysc = {
.sysc_offs = 0x0010,
.syss_offs = 0x0014,
.sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
- SYSC_HAS_SOFTRESET),
+ SYSC_HAS_SOFTRESET | SYSC_HAS_RESET_STATUS),
.idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
@@ -3001,15 +3001,7 @@ static struct omap_hwmod omap44xx_usb_host_hs_hwmod = {
* hence HWMOD_SWSUP_MSTANDBY
*/
- /*
- * During system boot; If the hwmod framework resets the module
- * the module will have smart idle settings; which can lead to deadlock
- * (above Errata Id:i660); so, dont reset the module during boot;
- * Use HWMOD_INIT_NO_RESET.
- */
-
- .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
- HWMOD_INIT_NO_RESET,
+ .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
};
/*
diff --git a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
index 9e08d69..e297d62 100644
--- a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
@@ -1544,7 +1544,8 @@ static struct omap_hwmod_class_sysconfig omap54xx_usb_host_hs_sysc = {
.rev_offs = 0x0000,
.sysc_offs = 0x0010,
.sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS |
- SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
+ SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
+ SYSC_HAS_RESET_STATUS),
.idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
@@ -1598,15 +1599,7 @@ static struct omap_hwmod omap54xx_usb_host_hs_hwmod = {
* hence HWMOD_SWSUP_MSTANDBY
*/
- /*
- * During system boot; If the hwmod framework resets the module
- * the module will have smart idle settings; which can lead to deadlock
- * (above Errata Id:i660); so, dont reset the module during boot;
- * Use HWMOD_INIT_NO_RESET.
- */
-
- .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
- HWMOD_INIT_NO_RESET,
+ .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
.main_clk = "l3init_60m_fclk",
.prcm = {
.omap4 = {
--
1.8.3.2
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 2/3] ARM: OMAP2+: hwmod: Fix RESET logic
2013-12-03 14:25 [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc Roger Quadros
2013-12-03 14:25 ` [PATCH 1/3] ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module Roger Quadros
@ 2013-12-03 14:25 ` Roger Quadros
2013-12-09 1:32 ` Paul Walmsley
2013-12-03 14:25 ` [PATCH 3/3] ARM: OMAP3: hwmod data: Don't prevent RESET of USB Host module Roger Quadros
2013-12-04 10:00 ` [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc Tomi Valkeinen
3 siblings, 1 reply; 14+ messages in thread
From: Roger Quadros @ 2013-12-03 14:25 UTC (permalink / raw)
To: bcousson, paul, tony
Cc: tomi.valkeinen, balbi, sr, David.Laight, michael, bigeasy,
linux-omap, linux-usb, linux-arm-kernel, linux-kernel,
Roger Quadros
In _ocp_softreset(), after _set_softreset() + write_sysconfig(),
the hwmod's sysc_cache will always contain SOFTRESET bit set
so all further writes to sysconfig using this cache will initiate
a repeated SOFTRESET e.g. enable_sysc(). This is true for OMAP3 like
platforms that have RESET_DONE status in the SYSSTATUS register and
so the the SOFTRESET bit in SYSCONFIG is not automatically cleared.
It is not a problem for OMAP4 like platforms that indicate RESET
completion by clearing the SOFTRESET bit in the SYSCONFIG register.
This repeated SOFTRESET is undesired and was the root cause of
USB host issues on OMAP3 platforms when hwmod was allowed to do the
SOFTRESET for the USB Host module.
To fix this we clear the SOFTRESET bit and update the sysconfig
register + sysc_cache using write_sysconfig().
Signed-off-by: Roger Quadros <rogerq@ti.com>
---
arch/arm/mach-omap2/omap_hwmod.c | 43 +++++++++++++++++++++++++++++++++++++++-
1 file changed, 42 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2/omap_hwmod.c
index e3f0eca..615acec 100644
--- a/arch/arm/mach-omap2/omap_hwmod.c
+++ b/arch/arm/mach-omap2/omap_hwmod.c
@@ -399,7 +399,7 @@ static int _set_clockactivity(struct omap_hwmod *oh, u8 clockact, u32 *v)
}
/**
- * _set_softreset: set OCP_SYSCONFIG.CLOCKACTIVITY bits in @v
+ * _set_softreset: set OCP_SYSCONFIG.SOFTRESET bit in @v
* @oh: struct omap_hwmod *
* @v: pointer to register contents to modify
*
@@ -427,6 +427,36 @@ static int _set_softreset(struct omap_hwmod *oh, u32 *v)
}
/**
+ * _clr_softreset: clear OCP_SYSCONFIG.SOFTRESET bit in @v
+ * @oh: struct omap_hwmod *
+ * @v: pointer to register contents to modify
+ *
+ * Clear the SOFTRESET bit in @v for hwmod @oh. Returns -EINVAL upon
+ * error or 0 upon success.
+ */
+static int _clr_softreset(struct omap_hwmod *oh, u32 *v)
+{
+ u32 softrst_mask;
+
+ if (!oh->class->sysc ||
+ !(oh->class->sysc->sysc_flags & SYSC_HAS_SOFTRESET))
+ return -EINVAL;
+
+ if (!oh->class->sysc->sysc_fields) {
+ WARN(1,
+ "omap_hwmod: %s: sysc_fields absent for sysconfig class\n",
+ oh->name);
+ return -EINVAL;
+ }
+
+ softrst_mask = (0x1 << oh->class->sysc->sysc_fields->srst_shift);
+
+ *v &= ~softrst_mask;
+
+ return 0;
+}
+
+/**
* _wait_softreset_complete - wait for an OCP softreset to complete
* @oh: struct omap_hwmod * to wait on
*
@@ -1911,6 +1941,12 @@ static int _ocp_softreset(struct omap_hwmod *oh)
ret = _set_softreset(oh, &v);
if (ret)
goto dis_opt_clks;
+
+ _write_sysconfig(v, oh);
+ ret = _clr_softreset(oh, &v);
+ if (ret)
+ goto dis_opt_clks;
+
_write_sysconfig(v, oh);
if (oh->class->sysc->srst_udelay)
@@ -3169,6 +3205,11 @@ int omap_hwmod_softreset(struct omap_hwmod *oh)
goto error;
_write_sysconfig(v, oh);
+ ret = _clr_softreset(oh, &v);
+ if (ret)
+ goto error;
+ _write_sysconfig(v, oh);
+
error:
return ret;
}
--
1.8.3.2
^ permalink raw reply related [flat|nested] 14+ messages in thread
* [PATCH 3/3] ARM: OMAP3: hwmod data: Don't prevent RESET of USB Host module
2013-12-03 14:25 [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc Roger Quadros
2013-12-03 14:25 ` [PATCH 1/3] ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module Roger Quadros
2013-12-03 14:25 ` [PATCH 2/3] ARM: OMAP2+: hwmod: Fix RESET logic Roger Quadros
@ 2013-12-03 14:25 ` Roger Quadros
2013-12-09 1:34 ` Paul Walmsley
2013-12-04 10:00 ` [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc Tomi Valkeinen
3 siblings, 1 reply; 14+ messages in thread
From: Roger Quadros @ 2013-12-03 14:25 UTC (permalink / raw)
To: bcousson, paul, tony
Cc: tomi.valkeinen, balbi, sr, David.Laight, michael, bigeasy,
linux-omap, linux-usb, linux-arm-kernel, linux-kernel,
Roger Quadros
Unlike what the comment states, errata i660 does not state that we
can't RESET the USB host module. Instead it states that RESET is the
only way to recover from a deadlock situation.
RESET ensures that the module is in a known good state irrespective
of what bootloader does with the module, so it must be done at boot.
Signed-off-by: Roger Quadros <rogerq@ti.com>
---
arch/arm/mach-omap2/omap_hwmod_3xxx_data.c | 13 +++----------
1 file changed, 3 insertions(+), 10 deletions(-)
diff --git a/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c b/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c
index 9e56fab..d337429 100644
--- a/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_3xxx_data.c
@@ -1943,7 +1943,8 @@ static struct omap_hwmod_class_sysconfig omap3xxx_usb_host_hs_sysc = {
.syss_offs = 0x0014,
.sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_CLOCKACTIVITY |
SYSC_HAS_SIDLEMODE | SYSC_HAS_ENAWAKEUP |
- SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE),
+ SYSC_HAS_SOFTRESET | SYSC_HAS_AUTOIDLE |
+ SYSS_HAS_RESET_STATUS),
.idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
MSTANDBY_FORCE | MSTANDBY_NO | MSTANDBY_SMART),
.sysc_fields = &omap_hwmod_sysc_type1,
@@ -2021,15 +2022,7 @@ static struct omap_hwmod omap3xxx_usb_host_hs_hwmod = {
* hence HWMOD_SWSUP_MSTANDBY
*/
- /*
- * During system boot; If the hwmod framework resets the module
- * the module will have smart idle settings; which can lead to deadlock
- * (above Errata Id:i660); so, dont reset the module during boot;
- * Use HWMOD_INIT_NO_RESET.
- */
-
- .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
- HWMOD_INIT_NO_RESET,
+ .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
};
/*
--
1.8.3.2
^ permalink raw reply related [flat|nested] 14+ messages in thread
* Re: [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc
2013-12-03 14:25 [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc Roger Quadros
` (2 preceding siblings ...)
2013-12-03 14:25 ` [PATCH 3/3] ARM: OMAP3: hwmod data: Don't prevent RESET of USB Host module Roger Quadros
@ 2013-12-04 10:00 ` Tomi Valkeinen
2013-12-05 18:48 ` Tony Lindgren
[not found] ` <529EFD42.9070507-l0cyMroinI0@public.gmane.org>
3 siblings, 2 replies; 14+ messages in thread
From: Tomi Valkeinen @ 2013-12-04 10:00 UTC (permalink / raw)
To: Roger Quadros, bcousson, paul, tony
Cc: michael, bigeasy, linux-usb, linux-kernel, balbi, linux-omap,
David.Laight, sr, linux-arm-kernel
[-- Attachment #1.1: Type: text/plain, Size: 900 bytes --]
On 2013-12-03 16:25, Roger Quadros wrote:
> Hi,
>
> This is a follow up solution to the original series in [1]
>
> The first patch fixes the OMAP4 Panda USB detection problems on 3.13-rc1
> with u-boot v2013.10.
>
> The remaining 2 patches are required if SOFTRESET needs to be done for the
> USB Host module on OMAP3 platforms.
>
> Patch 2 fixes the hwmod RESET logic to prevent multiple SOFTRESETs
> being issued to the modules. This multiple SOFTRESET was causing problems
> with OMAP3 USB Host module. On Beagleboard C4 this is seen as failure to
> mount NFS root over external USB to Ethernet device.
>
> This might be the reason why HWMOD_INIT_NO_RESET was used for the OMAP
> USB host module in OMAP3 hwmod data and just carried forward in OMAP4
> and OMAP5 hwmod data as well.
>
> cheers,
> -roger
Tested on Panda and Beagle xM. Works fine for me.
Tomi
[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 901 bytes --]
[-- Attachment #2: Type: text/plain, Size: 176 bytes --]
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc
2013-12-04 10:00 ` [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc Tomi Valkeinen
@ 2013-12-05 18:48 ` Tony Lindgren
2013-12-06 9:14 ` Roger Quadros
[not found] ` <529EFD42.9070507-l0cyMroinI0@public.gmane.org>
1 sibling, 1 reply; 14+ messages in thread
From: Tony Lindgren @ 2013-12-05 18:48 UTC (permalink / raw)
To: Tomi Valkeinen
Cc: Roger Quadros, bcousson, paul, balbi, sr, David.Laight, michael,
bigeasy, linux-omap, linux-usb, linux-arm-kernel, linux-kernel
* Tomi Valkeinen <tomi.valkeinen@ti.com> [131204 02:01]:
> On 2013-12-03 16:25, Roger Quadros wrote:
> > Hi,
> >
> > This is a follow up solution to the original series in [1]
> >
> > The first patch fixes the OMAP4 Panda USB detection problems on 3.13-rc1
> > with u-boot v2013.10.
> >
> > The remaining 2 patches are required if SOFTRESET needs to be done for the
> > USB Host module on OMAP3 platforms.
> >
> > Patch 2 fixes the hwmod RESET logic to prevent multiple SOFTRESETs
> > being issued to the modules. This multiple SOFTRESET was causing problems
> > with OMAP3 USB Host module. On Beagleboard C4 this is seen as failure to
> > mount NFS root over external USB to Ethernet device.
> >
> > This might be the reason why HWMOD_INIT_NO_RESET was used for the OMAP
> > USB host module in OMAP3 hwmod data and just carried forward in OMAP4
> > and OMAP5 hwmod data as well.
> >
> > cheers,
> > -roger
>
> Tested on Panda and Beagle xM. Works fine for me.
Looks like we should merge these as regression fixes during the -rc
cycle. Paul should take a look at these first though.
Regards,
Tony
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc
2013-12-05 18:48 ` Tony Lindgren
@ 2013-12-06 9:14 ` Roger Quadros
0 siblings, 0 replies; 14+ messages in thread
From: Roger Quadros @ 2013-12-06 9:14 UTC (permalink / raw)
To: Tony Lindgren, Tomi Valkeinen
Cc: paul, sr, bigeasy, linux-usb, linux-kernel, balbi, linux-omap,
David.Laight, bcousson, michael, linux-arm-kernel
Tony,
On 12/05/2013 08:48 PM, Tony Lindgren wrote:
> * Tomi Valkeinen <tomi.valkeinen@ti.com> [131204 02:01]:
>> On 2013-12-03 16:25, Roger Quadros wrote:
>>> Hi,
>>>
>>> This is a follow up solution to the original series in [1]
>>>
>>> The first patch fixes the OMAP4 Panda USB detection problems on 3.13-rc1
>>> with u-boot v2013.10.
>>>
>>> The remaining 2 patches are required if SOFTRESET needs to be done for the
>>> USB Host module on OMAP3 platforms.
>>>
>>> Patch 2 fixes the hwmod RESET logic to prevent multiple SOFTRESETs
>>> being issued to the modules. This multiple SOFTRESET was causing problems
>>> with OMAP3 USB Host module. On Beagleboard C4 this is seen as failure to
>>> mount NFS root over external USB to Ethernet device.
>>>
>>> This might be the reason why HWMOD_INIT_NO_RESET was used for the OMAP
>>> USB host module in OMAP3 hwmod data and just carried forward in OMAP4
>>> and OMAP5 hwmod data as well.
>>>
>>> cheers,
>>> -roger
>>
>> Tested on Panda and Beagle xM. Works fine for me.
>
> Looks like we should merge these as regression fixes during the -rc
> cycle. Paul should take a look at these first though.
At least the first one must be taken ASAP. The other two would be nice to have though.
cheers,
-roger
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 1/3] ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module
[not found] ` <1386080748-17005-2-git-send-email-rogerq-l0cyMroinI0@public.gmane.org>
@ 2013-12-09 1:26 ` Paul Walmsley
2013-12-09 1:58 ` Tony Lindgren
2013-12-09 17:52 ` Benoit Cousson
0 siblings, 2 replies; 14+ messages in thread
From: Paul Walmsley @ 2013-12-09 1:26 UTC (permalink / raw)
To: bcousson-rdvid1DuHRBWk0Htik3J/w, Roger Quadros
Cc: tony-4v6yS6AI5VpBDgjK7y7TUQ, tomi.valkeinen-l0cyMroinI0,
balbi-l0cyMroinI0, sr-ynQEQJNshbs,
David.Laight-ZS65k/vG3HxXrIkS9f7CXA,
michael-dyjBcgdgk7Pe9wHmmfpqLFaTQe2KTcn/,
bigeasy-hfZtesqFncYOwBW4kG4KsQ, linux-omap-u79uwXL29TY76Z2rM5mHXA,
linux-usb-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-kernel-u79uwXL29TY76Z2rM5mHXA
[-- Attachment #1: Type: TEXT/PLAIN, Size: 3741 bytes --]
Hi Benoît,
On Tue, 3 Dec 2013, Roger Quadros wrote:
> Without this, the USB devices are sometimes not detected on OMAP4 Panda
> with u-boot v2013.10.
>
> Unlike what the comment states, errata i660 does not state that we
> can't RESET the USB host module. Instead it states that RESET is the
> only way to recover from a deadlock situation.
>
> RESET ensures that the module is in a known good state irrespective
> of what bootloader does with the module, so it must be done at boot.
>
> Reported-by: Tomi Valkeinen <tomi.valkeinen-l0cyMroinI0@public.gmane.org>
> Signed-off-by: Roger Quadros <rogerq-l0cyMroinI0@public.gmane.org>
Acked-by: Paul Walmsley <paul-DWxLp4Yu+b8AvxtiuMwx3w@public.gmane.org>
Will you pick this up for the -rc series, or do you want me or Tony to?
Roger writes that this one's pretty important.
- Paul
> ---
> arch/arm/mach-omap2/omap_hwmod_44xx_data.c | 12 ++----------
> arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 13 +++----------
> 2 files changed, 5 insertions(+), 20 deletions(-)
>
> diff --git a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
> index 1e5b12c..3318cae9 100644
> --- a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
> +++ b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
> @@ -2937,7 +2937,7 @@ static struct omap_hwmod_class_sysconfig omap44xx_usb_host_hs_sysc = {
> .sysc_offs = 0x0010,
> .syss_offs = 0x0014,
> .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
> - SYSC_HAS_SOFTRESET),
> + SYSC_HAS_SOFTRESET | SYSC_HAS_RESET_STATUS),
> .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
> SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
> MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
> @@ -3001,15 +3001,7 @@ static struct omap_hwmod omap44xx_usb_host_hs_hwmod = {
> * hence HWMOD_SWSUP_MSTANDBY
> */
>
> - /*
> - * During system boot; If the hwmod framework resets the module
> - * the module will have smart idle settings; which can lead to deadlock
> - * (above Errata Id:i660); so, dont reset the module during boot;
> - * Use HWMOD_INIT_NO_RESET.
> - */
> -
> - .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
> - HWMOD_INIT_NO_RESET,
> + .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
> };
>
> /*
> diff --git a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> index 9e08d69..e297d62 100644
> --- a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> +++ b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> @@ -1544,7 +1544,8 @@ static struct omap_hwmod_class_sysconfig omap54xx_usb_host_hs_sysc = {
> .rev_offs = 0x0000,
> .sysc_offs = 0x0010,
> .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS |
> - SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
> + SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
> + SYSC_HAS_RESET_STATUS),
> .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
> SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
> MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
> @@ -1598,15 +1599,7 @@ static struct omap_hwmod omap54xx_usb_host_hs_hwmod = {
> * hence HWMOD_SWSUP_MSTANDBY
> */
>
> - /*
> - * During system boot; If the hwmod framework resets the module
> - * the module will have smart idle settings; which can lead to deadlock
> - * (above Errata Id:i660); so, dont reset the module during boot;
> - * Use HWMOD_INIT_NO_RESET.
> - */
> -
> - .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
> - HWMOD_INIT_NO_RESET,
> + .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
> .main_clk = "l3init_60m_fclk",
> .prcm = {
> .omap4 = {
> --
> 1.8.3.2
>
- Paul
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 2/3] ARM: OMAP2+: hwmod: Fix RESET logic
2013-12-03 14:25 ` [PATCH 2/3] ARM: OMAP2+: hwmod: Fix RESET logic Roger Quadros
@ 2013-12-09 1:32 ` Paul Walmsley
0 siblings, 0 replies; 14+ messages in thread
From: Paul Walmsley @ 2013-12-09 1:32 UTC (permalink / raw)
To: Roger Quadros
Cc: sr, michael, tony, bigeasy, linux-usb, linux-kernel, balbi,
linux-omap, tomi.valkeinen, bcousson, David.Laight,
linux-arm-kernel
Hi Roger,
On Tue, 3 Dec 2013, Roger Quadros wrote:
> In _ocp_softreset(), after _set_softreset() + write_sysconfig(),
> the hwmod's sysc_cache will always contain SOFTRESET bit set
> so all further writes to sysconfig using this cache will initiate
> a repeated SOFTRESET e.g. enable_sysc(). This is true for OMAP3 like
> platforms that have RESET_DONE status in the SYSSTATUS register and
> so the the SOFTRESET bit in SYSCONFIG is not automatically cleared.
> It is not a problem for OMAP4 like platforms that indicate RESET
> completion by clearing the SOFTRESET bit in the SYSCONFIG register.
>
> This repeated SOFTRESET is undesired and was the root cause of
> USB host issues on OMAP3 platforms when hwmod was allowed to do the
> SOFTRESET for the USB Host module.
Doh :-(
Nice catch. Renamed _clr_softreset() to _clear_softreset() and queued
the following for v3.13-rc.
- Paul
From: Roger Quadros <rogerq@ti.com>
ARM: OMAP2+: hwmod: Fix SOFTRESET logic
In _ocp_softreset(), after _set_softreset() + write_sysconfig(),
the hwmod's sysc_cache will always contain SOFTRESET bit set
so all further writes to sysconfig using this cache will initiate
a repeated SOFTRESET e.g. enable_sysc(). This is true for OMAP3 like
platforms that have RESET_DONE status in the SYSSTATUS register and
so the the SOFTRESET bit in SYSCONFIG is not automatically cleared.
It is not a problem for OMAP4 like platforms that indicate RESET
completion by clearing the SOFTRESET bit in the SYSCONFIG register.
This repeated SOFTRESET is undesired and was the root cause of
USB host issues on OMAP3 platforms when hwmod was allowed to do the
SOFTRESET for the USB Host module.
To fix this we clear the SOFTRESET bit and update the sysconfig
register + sysc_cache using write_sysconfig().
Signed-off-by: Roger Quadros <rogerq@ti.com>
[paul@pwsan.com: renamed _clr_softreset() to _clear_softreset()]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
---
arch/arm/mach-omap2/omap_hwmod.c | 43 +++++++++++++++++++++++++++++++++++++++-
1 file changed, 42 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2/omap_hwmod.c
index e3f0ecaf87dd..cacc0c7e8634 100644
--- a/arch/arm/mach-omap2/omap_hwmod.c
+++ b/arch/arm/mach-omap2/omap_hwmod.c
@@ -399,7 +399,7 @@ static int _set_clockactivity(struct omap_hwmod *oh, u8 clockact, u32 *v)
}
/**
- * _set_softreset: set OCP_SYSCONFIG.CLOCKACTIVITY bits in @v
+ * _set_softreset: set OCP_SYSCONFIG.SOFTRESET bit in @v
* @oh: struct omap_hwmod *
* @v: pointer to register contents to modify
*
@@ -427,6 +427,36 @@ static int _set_softreset(struct omap_hwmod *oh, u32 *v)
}
/**
+ * _clear_softreset: clear OCP_SYSCONFIG.SOFTRESET bit in @v
+ * @oh: struct omap_hwmod *
+ * @v: pointer to register contents to modify
+ *
+ * Clear the SOFTRESET bit in @v for hwmod @oh. Returns -EINVAL upon
+ * error or 0 upon success.
+ */
+static int _clear_softreset(struct omap_hwmod *oh, u32 *v)
+{
+ u32 softrst_mask;
+
+ if (!oh->class->sysc ||
+ !(oh->class->sysc->sysc_flags & SYSC_HAS_SOFTRESET))
+ return -EINVAL;
+
+ if (!oh->class->sysc->sysc_fields) {
+ WARN(1,
+ "omap_hwmod: %s: sysc_fields absent for sysconfig class\n",
+ oh->name);
+ return -EINVAL;
+ }
+
+ softrst_mask = (0x1 << oh->class->sysc->sysc_fields->srst_shift);
+
+ *v &= ~softrst_mask;
+
+ return 0;
+}
+
+/**
* _wait_softreset_complete - wait for an OCP softreset to complete
* @oh: struct omap_hwmod * to wait on
*
@@ -1911,6 +1941,12 @@ static int _ocp_softreset(struct omap_hwmod *oh)
ret = _set_softreset(oh, &v);
if (ret)
goto dis_opt_clks;
+
+ _write_sysconfig(v, oh);
+ ret = _clear_softreset(oh, &v);
+ if (ret)
+ goto dis_opt_clks;
+
_write_sysconfig(v, oh);
if (oh->class->sysc->srst_udelay)
@@ -3169,6 +3205,11 @@ int omap_hwmod_softreset(struct omap_hwmod *oh)
goto error;
_write_sysconfig(v, oh);
+ ret = _clear_softreset(oh, &v);
+ if (ret)
+ goto error;
+ _write_sysconfig(v, oh);
+
error:
return ret;
}
--
1.8.4.4
^ permalink raw reply related [flat|nested] 14+ messages in thread
* Re: [PATCH 3/3] ARM: OMAP3: hwmod data: Don't prevent RESET of USB Host module
2013-12-03 14:25 ` [PATCH 3/3] ARM: OMAP3: hwmod data: Don't prevent RESET of USB Host module Roger Quadros
@ 2013-12-09 1:34 ` Paul Walmsley
0 siblings, 0 replies; 14+ messages in thread
From: Paul Walmsley @ 2013-12-09 1:34 UTC (permalink / raw)
To: Roger Quadros
Cc: bcousson, tony, tomi.valkeinen, balbi, sr, David.Laight, michael,
bigeasy, linux-omap, linux-usb, linux-arm-kernel, linux-kernel
On Tue, 3 Dec 2013, Roger Quadros wrote:
> Unlike what the comment states, errata i660 does not state that we
> can't RESET the USB host module. Instead it states that RESET is the
> only way to recover from a deadlock situation.
>
> RESET ensures that the module is in a known good state irrespective
> of what bootloader does with the module, so it must be done at boot.
>
> Signed-off-by: Roger Quadros <rogerq@ti.com>
Thanks, queued for v3.13-rc.
- Paul
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc
[not found] ` <529EFD42.9070507-l0cyMroinI0@public.gmane.org>
@ 2013-12-09 1:35 ` Paul Walmsley
0 siblings, 0 replies; 14+ messages in thread
From: Paul Walmsley @ 2013-12-09 1:35 UTC (permalink / raw)
To: Tomi Valkeinen
Cc: Roger Quadros, bcousson-rdvid1DuHRBWk0Htik3J/w,
tony-4v6yS6AI5VpBDgjK7y7TUQ, balbi-l0cyMroinI0, sr-ynQEQJNshbs,
David.Laight-ZS65k/vG3HxXrIkS9f7CXA,
michael-dyjBcgdgk7Pe9wHmmfpqLFaTQe2KTcn/,
bigeasy-hfZtesqFncYOwBW4kG4KsQ, linux-omap-u79uwXL29TY76Z2rM5mHXA,
linux-usb-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
linux-kernel-u79uwXL29TY76Z2rM5mHXA
On Wed, 4 Dec 2013, Tomi Valkeinen wrote:
> Tested on Panda and Beagle xM. Works fine for me.
Thanks, added your Tested-by's to both patches that I've queued.
- Paul
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 1/3] ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module
2013-12-09 1:26 ` Paul Walmsley
@ 2013-12-09 1:58 ` Tony Lindgren
2013-12-09 2:15 ` Paul Walmsley
2013-12-09 17:52 ` Benoit Cousson
1 sibling, 1 reply; 14+ messages in thread
From: Tony Lindgren @ 2013-12-09 1:58 UTC (permalink / raw)
To: Paul Walmsley
Cc: bcousson, Roger Quadros, tomi.valkeinen, balbi, sr, David.Laight,
michael, bigeasy, linux-omap, linux-usb, linux-arm-kernel,
linux-kernel
* Paul Walmsley <paul@pwsan.com> [131208 17:27]:
> Hi Benoît,
>
> On Tue, 3 Dec 2013, Roger Quadros wrote:
>
> > Without this, the USB devices are sometimes not detected on OMAP4 Panda
> > with u-boot v2013.10.
> >
> > Unlike what the comment states, errata i660 does not state that we
> > can't RESET the USB host module. Instead it states that RESET is the
> > only way to recover from a deadlock situation.
> >
> > RESET ensures that the module is in a known good state irrespective
> > of what bootloader does with the module, so it must be done at boot.
> >
> > Reported-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
> > Signed-off-by: Roger Quadros <rogerq@ti.com>
>
> Acked-by: Paul Walmsley <paul@pwsan.com>
>
> Will you pick this up for the -rc series, or do you want me or Tony to?
> Roger writes that this one's pretty important.
I suggest that you just queue this with your other fixes so we get
things working.
Regards,
Tony
> > arch/arm/mach-omap2/omap_hwmod_44xx_data.c | 12 ++----------
> > arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 13 +++----------
> > 2 files changed, 5 insertions(+), 20 deletions(-)
> >
> > diff --git a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
> > index 1e5b12c..3318cae9 100644
> > --- a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
> > +++ b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
> > @@ -2937,7 +2937,7 @@ static struct omap_hwmod_class_sysconfig omap44xx_usb_host_hs_sysc = {
> > .sysc_offs = 0x0010,
> > .syss_offs = 0x0014,
> > .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
> > - SYSC_HAS_SOFTRESET),
> > + SYSC_HAS_SOFTRESET | SYSC_HAS_RESET_STATUS),
> > .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
> > SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
> > MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
> > @@ -3001,15 +3001,7 @@ static struct omap_hwmod omap44xx_usb_host_hs_hwmod = {
> > * hence HWMOD_SWSUP_MSTANDBY
> > */
> >
> > - /*
> > - * During system boot; If the hwmod framework resets the module
> > - * the module will have smart idle settings; which can lead to deadlock
> > - * (above Errata Id:i660); so, dont reset the module during boot;
> > - * Use HWMOD_INIT_NO_RESET.
> > - */
> > -
> > - .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
> > - HWMOD_INIT_NO_RESET,
> > + .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
> > };
> >
> > /*
> > diff --git a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> > index 9e08d69..e297d62 100644
> > --- a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> > +++ b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
> > @@ -1544,7 +1544,8 @@ static struct omap_hwmod_class_sysconfig omap54xx_usb_host_hs_sysc = {
> > .rev_offs = 0x0000,
> > .sysc_offs = 0x0010,
> > .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS |
> > - SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
> > + SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
> > + SYSC_HAS_RESET_STATUS),
> > .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
> > SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
> > MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
> > @@ -1598,15 +1599,7 @@ static struct omap_hwmod omap54xx_usb_host_hs_hwmod = {
> > * hence HWMOD_SWSUP_MSTANDBY
> > */
> >
> > - /*
> > - * During system boot; If the hwmod framework resets the module
> > - * the module will have smart idle settings; which can lead to deadlock
> > - * (above Errata Id:i660); so, dont reset the module during boot;
> > - * Use HWMOD_INIT_NO_RESET.
> > - */
> > -
> > - .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
> > - HWMOD_INIT_NO_RESET,
> > + .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
> > .main_clk = "l3init_60m_fclk",
> > .prcm = {
> > .omap4 = {
> > --
> > 1.8.3.2
> >
>
>
> - Paul
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 1/3] ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module
2013-12-09 1:58 ` Tony Lindgren
@ 2013-12-09 2:15 ` Paul Walmsley
0 siblings, 0 replies; 14+ messages in thread
From: Paul Walmsley @ 2013-12-09 2:15 UTC (permalink / raw)
To: Tony Lindgren
Cc: bcousson, Roger Quadros, tomi.valkeinen, balbi, sr, David.Laight,
michael, bigeasy, linux-omap, linux-usb, linux-arm-kernel,
linux-kernel
[-- Attachment #1: Type: TEXT/PLAIN, Size: 1172 bytes --]
On Sun, 8 Dec 2013, Tony Lindgren wrote:
> * Paul Walmsley <paul@pwsan.com> [131208 17:27]:
> > On Tue, 3 Dec 2013, Roger Quadros wrote:
> >
> > > Without this, the USB devices are sometimes not detected on OMAP4 Panda
> > > with u-boot v2013.10.
> > >
> > > Unlike what the comment states, errata i660 does not state that we
> > > can't RESET the USB host module. Instead it states that RESET is the
> > > only way to recover from a deadlock situation.
> > >
> > > RESET ensures that the module is in a known good state irrespective
> > > of what bootloader does with the module, so it must be done at boot.
> > >
> > > Reported-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
> > > Signed-off-by: Roger Quadros <rogerq@ti.com>
> >
> > Acked-by: Paul Walmsley <paul@pwsan.com>
> >
> > Will you pick this up for the -rc series, or do you want me or Tony to?
> > Roger writes that this one's pretty important.
>
> I suggest that you just queue this with your other fixes so we get
> things working.
I'm going to wait until tomorrow anyway to see if Sathya responds to my
other E-mail, so maybe Benoît will let us know by then.
- Paul
^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH 1/3] ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module
2013-12-09 1:26 ` Paul Walmsley
2013-12-09 1:58 ` Tony Lindgren
@ 2013-12-09 17:52 ` Benoit Cousson
1 sibling, 0 replies; 14+ messages in thread
From: Benoit Cousson @ 2013-12-09 17:52 UTC (permalink / raw)
To: Paul Walmsley, Roger Quadros
Cc: tony, tomi.valkeinen, balbi, sr, David.Laight, michael, bigeasy,
linux-omap, linux-usb, linux-arm-kernel, linux-kernel
Salut Paul,
On 08/12/2013 17:26, Paul Walmsley wrote:
> Hi Benoît,
>
> On Tue, 3 Dec 2013, Roger Quadros wrote:
>
>> Without this, the USB devices are sometimes not detected on OMAP4 Panda
>> with u-boot v2013.10.
>>
>> Unlike what the comment states, errata i660 does not state that we
>> can't RESET the USB host module. Instead it states that RESET is the
>> only way to recover from a deadlock situation.
>>
>> RESET ensures that the module is in a known good state irrespective
>> of what bootloader does with the module, so it must be done at boot.
>>
>> Reported-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
>> Signed-off-by: Roger Quadros <rogerq@ti.com>
>
> Acked-by: Paul Walmsley <paul@pwsan.com>
>
> Will you pick this up for the -rc series, or do you want me or Tony to?
> Roger writes that this one's pretty important.
I guess, it is better for you to take it. I don't have anything queued
for -rc.
Acked-by: Benoit Cousson <bcousson@baylibre.com>
Thanks,
Benoit
>
>
> - Paul
>
>
>> ---
>> arch/arm/mach-omap2/omap_hwmod_44xx_data.c | 12 ++----------
>> arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 13 +++----------
>> 2 files changed, 5 insertions(+), 20 deletions(-)
>>
>> diff --git a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
>> index 1e5b12c..3318cae9 100644
>> --- a/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
>> +++ b/arch/arm/mach-omap2/omap_hwmod_44xx_data.c
>> @@ -2937,7 +2937,7 @@ static struct omap_hwmod_class_sysconfig omap44xx_usb_host_hs_sysc = {
>> .sysc_offs = 0x0010,
>> .syss_offs = 0x0014,
>> .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_SIDLEMODE |
>> - SYSC_HAS_SOFTRESET),
>> + SYSC_HAS_SOFTRESET | SYSC_HAS_RESET_STATUS),
>> .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
>> SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
>> MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
>> @@ -3001,15 +3001,7 @@ static struct omap_hwmod omap44xx_usb_host_hs_hwmod = {
>> * hence HWMOD_SWSUP_MSTANDBY
>> */
>>
>> - /*
>> - * During system boot; If the hwmod framework resets the module
>> - * the module will have smart idle settings; which can lead to deadlock
>> - * (above Errata Id:i660); so, dont reset the module during boot;
>> - * Use HWMOD_INIT_NO_RESET.
>> - */
>> -
>> - .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
>> - HWMOD_INIT_NO_RESET,
>> + .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
>> };
>>
>> /*
>> diff --git a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
>> index 9e08d69..e297d62 100644
>> --- a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
>> +++ b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
>> @@ -1544,7 +1544,8 @@ static struct omap_hwmod_class_sysconfig omap54xx_usb_host_hs_sysc = {
>> .rev_offs = 0x0000,
>> .sysc_offs = 0x0010,
>> .sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS |
>> - SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
>> + SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
>> + SYSC_HAS_RESET_STATUS),
>> .idlemodes = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
>> SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
>> MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
>> @@ -1598,15 +1599,7 @@ static struct omap_hwmod omap54xx_usb_host_hs_hwmod = {
>> * hence HWMOD_SWSUP_MSTANDBY
>> */
>>
>> - /*
>> - * During system boot; If the hwmod framework resets the module
>> - * the module will have smart idle settings; which can lead to deadlock
>> - * (above Errata Id:i660); so, dont reset the module during boot;
>> - * Use HWMOD_INIT_NO_RESET.
>> - */
>> -
>> - .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY |
>> - HWMOD_INIT_NO_RESET,
>> + .flags = HWMOD_SWSUP_SIDLE | HWMOD_SWSUP_MSTANDBY,
>> .main_clk = "l3init_60m_fclk",
>> .prcm = {
>> .omap4 = {
>> --
>> 1.8.3.2
>>
>
>
> - Paul
>
--
Benoît Cousson
BayLibre
Embedded Linux Technology Lab
www.baylibre.com
^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2013-12-09 17:52 UTC | newest]
Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-03 14:25 [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc Roger Quadros
2013-12-03 14:25 ` [PATCH 1/3] ARM: OMAP4+: hwmod data: Don't prevent RESET of USB Host module Roger Quadros
[not found] ` <1386080748-17005-2-git-send-email-rogerq-l0cyMroinI0@public.gmane.org>
2013-12-09 1:26 ` Paul Walmsley
2013-12-09 1:58 ` Tony Lindgren
2013-12-09 2:15 ` Paul Walmsley
2013-12-09 17:52 ` Benoit Cousson
2013-12-03 14:25 ` [PATCH 2/3] ARM: OMAP2+: hwmod: Fix RESET logic Roger Quadros
2013-12-09 1:32 ` Paul Walmsley
2013-12-03 14:25 ` [PATCH 3/3] ARM: OMAP3: hwmod data: Don't prevent RESET of USB Host module Roger Quadros
2013-12-09 1:34 ` Paul Walmsley
2013-12-04 10:00 ` [PATCH v2 0/3] ARM: OMAP2+: USB Host bug fixes for 3.13 rc Tomi Valkeinen
2013-12-05 18:48 ` Tony Lindgren
2013-12-06 9:14 ` Roger Quadros
[not found] ` <529EFD42.9070507-l0cyMroinI0@public.gmane.org>
2013-12-09 1:35 ` Paul Walmsley
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).