OpenQNX :: The QNX Community Portal

Jul 25, 2008 - 04:19 PM
Google
  Web openqnx.com   
     Create an account Home · Submit News · QNX Forums · QNX Download · Search   
_
Main Menu
Who's Online
There are 19 unlogged users and 2 registered users online.

You can log-in or register for a user account here.

Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
Jan Raddatz
Post subject: Porting QNX on DNP9200 Problem  PostPosted: May 08, 2006 - 02:23 PM
Guest





Hello,
actually I am trying to port QNX onto the DNP9200 Board.

My problem is that I got stuck when writing Callout routines for the Startup
programm for the DNP9200 Board.

As reference implementation I am using the Integrator BSP and the problem is
as follows:


The Integrator Callout function calls some Patch code at first.
CALLOUT_START(interrupt_mask_integrator, 0, interrupt_patch)


This Patch code is using a constant which is used in other implementations
for other boards as well.
It is called #INTEGRATOR_INTR_SIZE:

.....
mov r0, #INTEGRATOR_INTR_SIZE
ldr r1, Lpaddr
bl callout_io_map

....
Lpaddr: .word INTEGRATOR_INTR_BASE



For the Integrator Board this constant is 0xf0 for another board the ixp2400
it is 0x210.

I dont't get the meaning of this constant and its function. I would be glad
if you could help me out.

Thanks a lot in advance!!

Jan
 
   
Reply with quote Back to top
Sunil Kittur
Post subject: Re: Porting QNX on DNP9200 Problem  PostPosted: May 08, 2006 - 02:50 PM
Guest





The callout_io_map function is used to map the registers
for use by the callout once the kernel is running.

The 1st parameter (r0) is size of the registers to map.
The 2nd parameter (r1) is the physical address of the registers.
It returns a virtual address, and the CALLOUT_PATCH macro is
used to modify the callout code to use this virtual address.

Since virtual address mappings are always 4K page size multiples,
the actual size mapped is rounded up to a 4K boundary.

The start of most callout routines consist of a sequence of
instructions that put a 32-bit value into a register, used as
the base address of the I/O registers being accessed.

The CALLOUT_PATCH macro modifies those instructions so that they
generate the value returned by callout_io_map().

Sunil.

Jan Raddatz wrote:
Quote:
Hello,
actually I am trying to port QNX onto the DNP9200 Board.

My problem is that I got stuck when writing Callout routines for the Startup
programm for the DNP9200 Board.

As reference implementation I am using the Integrator BSP and the problem is
as follows:


The Integrator Callout function calls some Patch code at first.
CALLOUT_START(interrupt_mask_integrator, 0, interrupt_patch)


This Patch code is using a constant which is used in other implementations
for other boards as well.
It is called #INTEGRATOR_INTR_SIZE:

....
mov r0, #INTEGRATOR_INTR_SIZE
ldr r1, Lpaddr
bl callout_io_map

...
Lpaddr: .word INTEGRATOR_INTR_BASE



For the Integrator Board this constant is 0xf0 for another board the ixp2400
it is 0x210.

I dont't get the meaning of this constant and its function. I would be glad
if you could help me out.

Thanks a lot in advance!!

Jan

 
   
Reply with quote Back to top
Jan Raddatz
Post subject: Re: Porting QNX on DNP9200 Problem  PostPosted: May 09, 2006 - 06:39 AM
Guest





Dear Sunil,
thanks a lot for your detailed description!

It helped a lot!

Greetings
Jan


"Sunil Kittur" <skittur@qnx.com> schrieb im Newsbeitrag
news:e3nlef$erj$1@inn.qnx.com...
Quote:
The callout_io_map function is used to map the registers
for use by the callout once the kernel is running.

The 1st parameter (r0) is size of the registers to map.
The 2nd parameter (r1) is the physical address of the registers.
It returns a virtual address, and the CALLOUT_PATCH macro is
used to modify the callout code to use this virtual address.

Since virtual address mappings are always 4K page size multiples,
the actual size mapped is rounded up to a 4K boundary.

The start of most callout routines consist of a sequence of
instructions that put a 32-bit value into a register, used as
the base address of the I/O registers being accessed.

The CALLOUT_PATCH macro modifies those instructions so that they
generate the value returned by callout_io_map().

Sunil.

Jan Raddatz wrote:
Hello,
actually I am trying to port QNX onto the DNP9200 Board.

My problem is that I got stuck when writing Callout routines for the
Startup programm for the DNP9200 Board.

As reference implementation I am using the Integrator BSP and the problem
is as follows:


The Integrator Callout function calls some Patch code at first.
CALLOUT_START(interrupt_mask_integrator, 0, interrupt_patch)


This Patch code is using a constant which is used in other
implementations for other boards as well.
It is called #INTEGRATOR_INTR_SIZE:

....
mov r0, #INTEGRATOR_INTR_SIZE
ldr r1, Lpaddr
bl callout_io_map

...
Lpaddr: .word INTEGRATOR_INTR_BASE



For the Integrator Board this constant is 0xf0 for another board the
ixp2400 it is 0x210.

I dont't get the meaning of this constant and its function. I would be
glad if you could help me out.

Thanks a lot in advance!!

Jan
 
   
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2007 The PNphpBB Group
Credits
All logos and trademarks in this site are property of their respective owners. The comments are property of their posters.
Powered by OpenQNX: The QNX Community Portal Site
QNX and the QNX logo are registered trademarks of QNX Software Systems.