* Powerpc and ioremap
@ 2008-08-07 9:54 Sébastien Chrétien
2008-08-07 10:23 ` Juergen Beisert
0 siblings, 1 reply; 4+ messages in thread
From: Sébastien Chrétien @ 2008-08-07 9:54 UTC (permalink / raw)
To: linuxppc-dev
[-- Attachment #1: Type: text/plain, Size: 472 bytes --]
Hello,
I am trying to port linux on my Powerpc Board. I have used Linux 2.6.26 and
gcc 3.4.5.
I have used Uboot 1.2.
Linux seems running from _start to udbg_early_init(). That's why I
develloped a udbg_driver.
It must write in a register which is located at 0x2001b044. So I wrote :
void __iomem *p;
p=ioremap(0x2001b044,4);
iowrite32('O',p);
iowrite32('K',p);
But when he exectuted ioremap, he looped in the __delay function.
Can you help me to solve this probleme ?
[-- Attachment #2: Type: text/html, Size: 585 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Powerpc and ioremap
2008-08-07 9:54 Powerpc and ioremap Sébastien Chrétien
@ 2008-08-07 10:23 ` Juergen Beisert
2008-08-07 12:15 ` Sébastien Chrétien
0 siblings, 1 reply; 4+ messages in thread
From: Juergen Beisert @ 2008-08-07 10:23 UTC (permalink / raw)
To: linuxppc-dev; +Cc: Sébastien Chrétien
Am Donnerstag, 7. August 2008 11:54 schrieb S=E9bastien Chr=E9tien:
> Hello,
>
> I am trying to port linux on my Powerpc Board. I have used Linux 2.6.26 a=
nd
> gcc 3.4.5.
> I have used Uboot 1.2.
> Linux seems running from _start to udbg_early_init(). That's why I
> develloped a udbg_driver.
> It must write in a register which is located at 0x2001b044. So I wrote :
>
> void __iomem *p;
> p=3Dioremap(0x2001b044,4);
> iowrite32('O',p);
> iowrite32('K',p);
try
p=3Dioremap(0x2001b000, 0x1000);
iowrite32('O',p + 0x44);
iowrite32('K',p + 0x44);
instead.
jbe
=2D-=20
Dipl.-Ing. Juergen Beisert | http://www.pengutronix.de
Pengutronix - Linux Solutions for Science and Industry
Handelsregister: Amtsgericht Hildesheim, HRA 2686
Hannoversche Str. 2, 31134 Hildesheim, Germany
Phone: +49-5121-206917-7 | Fax: +49-5121-206917-9
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Powerpc and ioremap
2008-08-07 10:23 ` Juergen Beisert
@ 2008-08-07 12:15 ` Sébastien Chrétien
2008-08-07 12:56 ` Sébastien Chrétien
0 siblings, 1 reply; 4+ messages in thread
From: Sébastien Chrétien @ 2008-08-07 12:15 UTC (permalink / raw)
To: Juergen Beisert; +Cc: linuxppc-dev
[-- Attachment #1: Type: text/plain, Size: 1173 bytes --]
Thanks for your answer.
But it doesn't work.
I think ioremap create a kernel panic. But I can't see because i have no
UART ready.
Is there a way in order to trace the failure ?
2008/8/7, Juergen Beisert <j.beisert@pengutronix.de>:
>
> Am Donnerstag, 7. August 2008 11:54 schrieb Sébastien Chrétien:
>
> > Hello,
> >
> > I am trying to port linux on my Powerpc Board. I have used Linux 2.6.26
> and
> > gcc 3.4.5.
> > I have used Uboot 1.2.
> > Linux seems running from _start to udbg_early_init(). That's why I
> > develloped a udbg_driver.
> > It must write in a register which is located at 0x2001b044. So I wrote :
> >
> > void __iomem *p;
> > p=ioremap(0x2001b044,4);
> > iowrite32('O',p);
> > iowrite32('K',p);
>
>
> try
>
> p=ioremap(0x2001b000, 0x1000);
> iowrite32('O',p + 0x44);
> iowrite32('K',p + 0x44);
>
> instead.
>
> jbe
>
> --
> Dipl.-Ing. Juergen Beisert | http://www.pengutronix.de
> Pengutronix - Linux Solutions for Science and Industry
> Handelsregister: Amtsgericht Hildesheim, HRA 2686
> Hannoversche Str. 2, 31134 Hildesheim, Germany
> Phone: +49-5121-206917-7 | Fax: +49-5121-206917-9
>
[-- Attachment #2: Type: text/html, Size: 1695 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Powerpc and ioremap
2008-08-07 12:15 ` Sébastien Chrétien
@ 2008-08-07 12:56 ` Sébastien Chrétien
0 siblings, 0 replies; 4+ messages in thread
From: Sébastien Chrétien @ 2008-08-07 12:56 UTC (permalink / raw)
To: Juergen Beisert; +Cc: linuxppc-dev
[-- Attachment #1: Type: text/plain, Size: 1351 bytes --]
Can we call ioremap() during udbg_early_init ?
2008/8/7, Sébastien Chrétien <sebastien.chretien.enseirb@gmail.com>:
>
> Thanks for your answer.
> But it doesn't work.
> I think ioremap create a kernel panic. But I can't see because i have no
> UART ready.
> Is there a way in order to trace the failure ?
>
> 2008/8/7, Juergen Beisert <j.beisert@pengutronix.de>:
>>
>> Am Donnerstag, 7. August 2008 11:54 schrieb Sébastien Chrétien:
>>
>> > Hello,
>> >
>> > I am trying to port linux on my Powerpc Board. I have used Linux 2.6.26
>> and
>> > gcc 3.4.5.
>> > I have used Uboot 1.2.
>> > Linux seems running from _start to udbg_early_init(). That's why I
>> > develloped a udbg_driver.
>> > It must write in a register which is located at 0x2001b044. So I wrote :
>> >
>> > void __iomem *p;
>> > p=ioremap(0x2001b044,4);
>> > iowrite32('O',p);
>> > iowrite32('K',p);
>>
>>
>> try
>>
>> p=ioremap(0x2001b000, 0x1000);
>> iowrite32('O',p + 0x44);
>> iowrite32('K',p + 0x44);
>>
>> instead.
>>
>> jbe
>>
>> --
>> Dipl.-Ing. Juergen Beisert | http://www.pengutronix.de
>> Pengutronix - Linux Solutions for Science and Industry
>> Handelsregister: Amtsgericht Hildesheim, HRA 2686
>> Hannoversche Str. 2, 31134 Hildesheim, Germany
>> Phone: +49-5121-206917-7 | Fax: +49-5121-206917-9
>>
>
>
[-- Attachment #2: Type: text/html, Size: 2358 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2008-08-07 12:56 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-08-07 9:54 Powerpc and ioremap Sébastien Chrétien
2008-08-07 10:23 ` Juergen Beisert
2008-08-07 12:15 ` Sébastien Chrétien
2008-08-07 12:56 ` Sébastien Chrétien
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).