* [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind
@ 2019-04-07 9:30 Baruch Siach
2019-04-09 15:18 ` Stefan Roese
2019-04-10 5:38 ` Heiko Schocher
0 siblings, 2 replies; 8+ messages in thread
From: Baruch Siach @ 2019-04-07 9:30 UTC (permalink / raw)
To: u-boot
The mvebu specific debug register is not accessible when the bind code
runs in SPL. Skip it.
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
---
drivers/i2c/mvtwsi.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/i2c/mvtwsi.c b/drivers/i2c/mvtwsi.c
index 74ac0a4aa789..05560e112729 100644
--- a/drivers/i2c/mvtwsi.c
+++ b/drivers/i2c/mvtwsi.c
@@ -801,6 +801,10 @@ static int mvtwsi_i2c_ofdata_to_platdata(struct udevice *bus)
static void twsi_disable_i2c_slave(struct mvtwsi_registers *twsi)
{
+ /* The debug register is not accessible in early boot */
+ if (IS_ENABLED(CONFIG_SPL_BUILD))
+ return;
+
clrbits_le32(&twsi->debug, BIT(18));
}
--
2.20.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind
2019-04-07 9:30 [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind Baruch Siach
@ 2019-04-09 15:18 ` Stefan Roese
2019-04-09 17:40 ` Baruch Siach
2019-04-10 5:38 ` Heiko Schocher
1 sibling, 1 reply; 8+ messages in thread
From: Stefan Roese @ 2019-04-09 15:18 UTC (permalink / raw)
To: u-boot
Hi Baruch,
On 07.04.19 11:30, Baruch Siach wrote:
> The mvebu specific debug register is not accessible when the bind code
> runs in SPL. Skip it.
The other I2C registers can be accessed but only the debug register
not? Do you know, why this is the case?
Thanks,
Stefan
> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
> ---
> drivers/i2c/mvtwsi.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/i2c/mvtwsi.c b/drivers/i2c/mvtwsi.c
> index 74ac0a4aa789..05560e112729 100644
> --- a/drivers/i2c/mvtwsi.c
> +++ b/drivers/i2c/mvtwsi.c
> @@ -801,6 +801,10 @@ static int mvtwsi_i2c_ofdata_to_platdata(struct udevice *bus)
>
> static void twsi_disable_i2c_slave(struct mvtwsi_registers *twsi)
> {
> + /* The debug register is not accessible in early boot */
> + if (IS_ENABLED(CONFIG_SPL_BUILD))
> + return;
> +
> clrbits_le32(&twsi->debug, BIT(18));
> }
>
>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind
2019-04-09 15:18 ` Stefan Roese
@ 2019-04-09 17:40 ` Baruch Siach
0 siblings, 0 replies; 8+ messages in thread
From: Baruch Siach @ 2019-04-09 17:40 UTC (permalink / raw)
To: u-boot
Hi Stefan,
On Tue, Apr 09 2019, Stefan Roese wrote:
> On 07.04.19 11:30, Baruch Siach wrote:
>> The mvebu specific debug register is not accessible when the bind code
>> runs in SPL. Skip it.
>
> The other I2C registers can be accessed but only the debug register
> not? Do you know, why this is the case?
Access to other registers might hang as well, I have not tested. The
debug register is the only one that the .bind callback touches. .bind
callbacks are called before board_early_init_f() that configures the
MPP.
baruch
>> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
>> ---
>> drivers/i2c/mvtwsi.c | 4 ++++
>> 1 file changed, 4 insertions(+)
>>
>> diff --git a/drivers/i2c/mvtwsi.c b/drivers/i2c/mvtwsi.c
>> index 74ac0a4aa789..05560e112729 100644
>> --- a/drivers/i2c/mvtwsi.c
>> +++ b/drivers/i2c/mvtwsi.c
>> @@ -801,6 +801,10 @@ static int mvtwsi_i2c_ofdata_to_platdata(struct udevice *bus)
>> static void twsi_disable_i2c_slave(struct mvtwsi_registers *twsi)
>> {
>> + /* The debug register is not accessible in early boot */
>> + if (IS_ENABLED(CONFIG_SPL_BUILD))
>> + return;
>> +
>> clrbits_le32(&twsi->debug, BIT(18));
>> }
--
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.52.368.4656, http://www.tkos.co.il -
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind
2019-04-07 9:30 [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind Baruch Siach
2019-04-09 15:18 ` Stefan Roese
@ 2019-04-10 5:38 ` Heiko Schocher
2019-04-11 9:31 ` Stefan Roese
1 sibling, 1 reply; 8+ messages in thread
From: Heiko Schocher @ 2019-04-10 5:38 UTC (permalink / raw)
To: u-boot
Hello Baruch,
Am 07.04.2019 um 11:30 schrieb Baruch Siach:
> The mvebu specific debug register is not accessible when the bind code
> runs in SPL. Skip it.
>
> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
> ---
> drivers/i2c/mvtwsi.c | 4 ++++
> 1 file changed, 4 insertions(+)
Applied to u-boot-i2c.git master
Thanks!
bye,
Heiko
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-52 Fax: +49-8142-66989-80 Email: hs at denx.de
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind
2019-04-10 5:38 ` Heiko Schocher
@ 2019-04-11 9:31 ` Stefan Roese
2019-04-11 9:49 ` Heiko Schocher
0 siblings, 1 reply; 8+ messages in thread
From: Stefan Roese @ 2019-04-11 9:31 UTC (permalink / raw)
To: u-boot
Hi Heiko,
On 10.04.19 07:38, Heiko Schocher wrote:
> Hello Baruch,
>
> Am 07.04.2019 um 11:30 schrieb Baruch Siach:
>> The mvebu specific debug register is not accessible when the bind code
>> runs in SPL. Skip it.
>>
>> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
>> ---
>> drivers/i2c/mvtwsi.c | 4 ++++
>> 1 file changed, 4 insertions(+)
>
> Applied to u-boot-i2c.git master
Could you please hold this patch a bit longer. I'm not 100% sure, if
this is the correct fix. Please see this thread for more details.
https://lists.denx.de/pipermail/u-boot/2019-April/364818.html
Thanks,
Stefan
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind
2019-04-11 9:31 ` Stefan Roese
@ 2019-04-11 9:49 ` Heiko Schocher
2019-04-11 12:01 ` Tom Rini
2019-04-11 13:27 ` Heiko Schocher
0 siblings, 2 replies; 8+ messages in thread
From: Heiko Schocher @ 2019-04-11 9:49 UTC (permalink / raw)
To: u-boot
Hello Stefan,
Am 11.04.2019 um 11:31 schrieb Stefan Roese:
> Hi Heiko,
>
> On 10.04.19 07:38, Heiko Schocher wrote:
>> Hello Baruch,
>>
>> Am 07.04.2019 um 11:30 schrieb Baruch Siach:
>>> The mvebu specific debug register is not accessible when the bind code
>>> runs in SPL. Skip it.
>>>
>>> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
>>> ---
>>> drivers/i2c/mvtwsi.c | 4 ++++
>>> 1 file changed, 4 insertions(+)
>>
>> Applied to u-boot-i2c.git master
>
> Could you please hold this patch a bit longer. I'm not 100% sure, if
> this is the correct fix. Please see this thread for more details.
>
> https://lists.denx.de/pipermail/u-boot/2019-April/364818.html
Oh, wasn;t aware of this ... Hmm.. pull request is already send
to Tom ... but Tom hasn;t merged it ...
@Tom: Should I remove this patch from u-boot-i2c.git and send a new
pull request or should we revert this commit, if a better solution
is found?
Tom
bye,
Heiko
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-52 Fax: +49-8142-66989-80 Email: hs at denx.de
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind
2019-04-11 9:49 ` Heiko Schocher
@ 2019-04-11 12:01 ` Tom Rini
2019-04-11 13:27 ` Heiko Schocher
1 sibling, 0 replies; 8+ messages in thread
From: Tom Rini @ 2019-04-11 12:01 UTC (permalink / raw)
To: u-boot
On Thu, Apr 11, 2019 at 11:49:44AM +0200, Heiko Schocher wrote:
> Hello Stefan,
>
> Am 11.04.2019 um 11:31 schrieb Stefan Roese:
> >Hi Heiko,
> >
> >On 10.04.19 07:38, Heiko Schocher wrote:
> >>Hello Baruch,
> >>
> >>Am 07.04.2019 um 11:30 schrieb Baruch Siach:
> >>>The mvebu specific debug register is not accessible when the bind code
> >>>runs in SPL. Skip it.
> >>>
> >>>Signed-off-by: Baruch Siach <baruch@tkos.co.il>
> >>>---
> >>> drivers/i2c/mvtwsi.c | 4 ++++
> >>> 1 file changed, 4 insertions(+)
> >>
> >>Applied to u-boot-i2c.git master
> >
> >Could you please hold this patch a bit longer. I'm not 100% sure, if
> >this is the correct fix. Please see this thread for more details.
> >
> >https://lists.denx.de/pipermail/u-boot/2019-April/364818.html
>
> Oh, wasn;t aware of this ... Hmm.. pull request is already send
> to Tom ... but Tom hasn;t merged it ...
>
> @Tom: Should I remove this patch from u-boot-i2c.git and send a new
> pull request or should we revert this commit, if a better solution
> is found?
Please re-send your PR, thanks!
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20190411/84f17b71/attachment.sig>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind
2019-04-11 9:49 ` Heiko Schocher
2019-04-11 12:01 ` Tom Rini
@ 2019-04-11 13:27 ` Heiko Schocher
1 sibling, 0 replies; 8+ messages in thread
From: Heiko Schocher @ 2019-04-11 13:27 UTC (permalink / raw)
To: u-boot
Hello Baruch
Am 11.04.2019 um 11:49 schrieb Heiko Schocher:
> Hello Stefan,
>
> Am 11.04.2019 um 11:31 schrieb Stefan Roese:
>> Hi Heiko,
>>
>> On 10.04.19 07:38, Heiko Schocher wrote:
>>> Hello Baruch,
>>>
>>> Am 07.04.2019 um 11:30 schrieb Baruch Siach:
>>>> The mvebu specific debug register is not accessible when the bind code
>>>> runs in SPL. Skip it.
>>>>
>>>> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
>>>> ---
>>>> drivers/i2c/mvtwsi.c | 4 ++++
>>>> 1 file changed, 4 insertions(+)
>>>
>>> Applied to u-boot-i2c.git master
>>
>> Could you please hold this patch a bit longer. I'm not 100% sure, if
>> this is the correct fix. Please see this thread for more details.
>>
>> https://lists.denx.de/pipermail/u-boot/2019-April/364818.html
>
> Oh, wasn;t aware of this ... Hmm.. pull request is already send
> to Tom ... but Tom hasn;t merged it ...
>
> @Tom: Should I remove this patch from u-boot-i2c.git and send a new
> pull request or should we revert this commit, if a better solution
> is found?
Removed from u-boot-i2c. I send a new PR to Tom if travis build
works.
We should wait of the result of discussion in thread:
https://lists.denx.de/pipermail/u-boot/2019-April/364818.html
bye,
Heiko
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-52 Fax: +49-8142-66989-80 Email: hs at denx.de
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2019-04-11 13:27 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-04-07 9:30 [U-Boot] [PATCH] i2c: mvtwsi: fix hang on SPL bind Baruch Siach
2019-04-09 15:18 ` Stefan Roese
2019-04-09 17:40 ` Baruch Siach
2019-04-10 5:38 ` Heiko Schocher
2019-04-11 9:31 ` Stefan Roese
2019-04-11 9:49 ` Heiko Schocher
2019-04-11 12:01 ` Tom Rini
2019-04-11 13:27 ` Heiko Schocher
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox