[Xenomai-core] Port Xenomai to PXA
Hey, I'm willing to port Xenomai to PXA (arm). It seems possible for me, but it will be easier with some information about the processor-specific functions to implement. Is there a guide to port Xenomai to a certain processor or can somebody provide some information? Or is there somewhere a patch available for PXA? Thanks, Bart ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core
Re: [Xenomai-core] Porting xeno-{info|load|test} to a busybox system
Niklaus Giger wrote: Am Sonntag, 28. Mai 2006 12:45 schrieb Jan Kiszka: Niklaus Giger wrote: Am Samstag, 27. Mai 2006 18:42 schrieb Jan Kiszka: .. Added a ps | grep $_j to show whether a dd job is still running before killing it. Now, at least running under the busybox. the dd jobs get killed as they should. Therefore I added a killall dd for the case the dd_jobs variable is empty. But there is still no load during the tests, correct? Yes. But now it should. The dd_jobs got killed too early, as under the BusyBox the trap exit handler got called too early. I think there are some subtle differences between the trap of the BusyBox- and the Bash-shell. Now I store the pids in a file under /var/lock. Tested it under bash and busybox, works okay for me. Options like -4-W 'dd if=/dev/hda1 of=/dev/null' should also be handled correctly. Default workload behaves as expected now, but specifying something different here via -W let the script hang on the workload startup. Options -L -m -M not tested under the BusyBox PPC405 target, as there I do not have access to curl, script and mail. .. - special characters in line 152 of xeno-test: Sorry. Corrected. I think kate did not handle a paste from your e-mail message correctly .. - the output of xeno-test contains this error: .. /bin/xeno-test: /bin/xeno-test: 325: : not found May be the result of above error? Could not reproduce it here. Could try again the attached patch? Basically, it runs fine. But I have two further suggestions: o some kind of summary of the completed rt-tests on script termination. I know what to lock for in the logs, but will the newbie do so? o a switch to control the test periods. I'm playing with a patch to control the aperiodic timer resolution. When I tune it to 1 ms e.g., having an option to push the test tool periods at this level as well would be nice. Thanks a lot for your effort! Jan signature.asc Description: OpenPGP digital signature ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core
Re: [Xenomai-core] Xenomai on PXA255
Bart Jonkers wrote: Hey, I'm trying to run Xenomai enabled kernel on the PXA255 (arm). When I compile the patched kernel, I get some undefined references errors. When I search through the patched kernel, I found the functions an variables defined for the integrator architecture. Which functions and variables need I to define for the PXA255 and what are there purpose, so I can add support for the PXA255 processor. Or are there some patches around to support the PXA255. The Ipipe patch for ARM only support the integrator platform for now. There exist patch for another ARM platform, but it exist only as a separated patch. Looking at the patch contents it seems that the only patched files specific to the integrator architecture are : arch/arm/mach-integrator/core.c arch/arm/mach-integrator/integrator_cp.c include/asm-arm/arch-integrator/entry-macro.S include/asm-arm/arch-integrator/platform.h include/asm-arm/arch-integrator/timex.h Looking rapidly at these files, it seems that the machine specific functions and variables are reduced to: int __ipipe_mach_timerint; int __ipipe_mach_timerstolen; unsigned int __ipipe_mach_ticks_per_jiffy; void __ipipe_mach_acktimer(void); unsigned long long __ipipe_mach_get_tsc(void); void __ipipe_mach_set_dec(unsigned long reload); unsigned long __ipipe_mach_get_dec(void); If you provide the same variables and functions for the PXA platform, I think there is no modification to be done at Xenomai level. -- Gilles Chanteperdrix. ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core
Re: [Xenomai-core] Xenomai on PXA255
On Mon, 2006-05-29 at 16:00 +0200, Gilles Chanteperdrix wrote: Bart Jonkers wrote: Hey, I'm trying to run Xenomai enabled kernel on the PXA255 (arm). When I compile the patched kernel, I get some undefined references errors. When I search through the patched kernel, I found the functions an variables defined for the integrator architecture. Which functions and variables need I to define for the PXA255 and what are there purpose, so I can add support for the PXA255 processor. Or are there some patches around to support the PXA255. The Ipipe patch for ARM only support the integrator platform for now. There exist patch for another ARM platform, but it exist only as a separated patch. Looking at the patch contents it seems that the only patched files specific to the integrator architecture are : arch/arm/mach-integrator/core.c arch/arm/mach-integrator/integrator_cp.c include/asm-arm/arch-integrator/entry-macro.S include/asm-arm/arch-integrator/platform.h include/asm-arm/arch-integrator/timex.h Looking rapidly at these files, it seems that the machine specific functions and variables are reduced to: int __ipipe_mach_timerint; int __ipipe_mach_timerstolen; unsigned int __ipipe_mach_ticks_per_jiffy; void __ipipe_mach_acktimer(void); unsigned long long __ipipe_mach_get_tsc(void); void __ipipe_mach_set_dec(unsigned long reload); unsigned long __ipipe_mach_get_dec(void); If you provide the same variables and functions for the PXA platform, I think there is no modification to be done at Xenomai level. I found this out already. But it would be a easier to implement this functions if I know what they have to do. So could somebody give an explanation of this variables and functions? Thanks, Bart ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core
Re: [Xenomai-core] Xenomai on PXA255
Le lundi 29 mai 2006 à 16:14 +0200, Bart Jonkers a écrit : The Ipipe patch for ARM only support the integrator platform for now. There exist patch for another ARM platform, but it exist only as a separated patch. Looking at the patch contents it seems that the only patched files specific to the integrator architecture are : arch/arm/mach-integrator/core.c arch/arm/mach-integrator/integrator_cp.c include/asm-arm/arch-integrator/entry-macro.S include/asm-arm/arch-integrator/platform.h include/asm-arm/arch-integrator/timex.h Looking rapidly at these files, it seems that the machine specific functions and variables are reduced to: int __ipipe_mach_timerint; int __ipipe_mach_timerstolen; unsigned int __ipipe_mach_ticks_per_jiffy; void __ipipe_mach_acktimer(void); unsigned long long __ipipe_mach_get_tsc(void); void __ipipe_mach_set_dec(unsigned long reload); unsigned long __ipipe_mach_get_dec(void); If you provide the same variables and functions for the PXA platform, I think there is no modification to be done at Xenomai level. Gilles is 100% correct. All the platform specific code has to do is provide the low level timer manipulation functions. I found this out already. But it would be a easier to implement this functions if I know what they have to do. So could somebody give an explanation of this variables and functions? Well, __ipipe_mach_acktimer acks the timer, __ipipe_mach_get_tsc returns the TSC of the platform, __ipipe_mach_set_dec sets the decrementer etc. Should I go on ? If you have specific questions feel free to ask. But I suggest you read and try to understand the code first. Stelian. -- Stelian Pop [EMAIL PROTECTED] ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core
Re: [Xenomai-core] Xenomai on PXA255
Stelian Pop wrote: If you have specific questions feel free to ask. But I suggest you read and try to understand the code first. Maybe we could provide a quick overview of how this works, Stelian, please correct me if I am wrong. If we start before rthal_timer_request is called, when the timer is handled by Linux, we see that __ipipe_decr_ticks is set to __ipipe_mach_ticks_per_jiffy, so that __ipipe_grab_irq does not reprogram the timer. But __ipipe_mach_timerstolen is set to 0, so integrator_timer_interrupt reprogram the timer at each tick. Now, when rthal_timer_request (defined in ksrc/arch/arm/hal.c) is called when Xenomai start handling the timer, we can see the two different modes: - in periodic mode, ipipe_tune_timer get called (indirectly via rthal_set_timer, defined in include/asm-generic/hal.h), so the proper value of __ipipe_decr_ticks is computed using __ipipe_mach_ticks_per_jiffy, and __ipipe_mach_set_dec get called by __ipipe_grab_irq at each tick to reprogram the timer - in aperiodic (aka one-shot) mode, ipipe_tune_timer does not get called, so __ipipe_decr_ticks remains set to __ipipe_mach_ticks_per_jiffy and __ipipe_grab_irq does not call __ipipe_mach_set_dec. Instead, __ipipe_mach_set_dec is called for each shot by Xenomai (function rthal_timer_program_shot in include/asm-arm/hal.h) In both modes, __ipipe_mach_timerstolen is set to 1, so that integrator_timer_interrupt never reprograms the timer. When CONFIG_IPIPE is set, integrator_timer_interrupt never acks the timer interrupt, instead, it gets ack'ed and unmasked in __ipipe_ack_timerirq, installed as an acknowledge function for the timer IRQ in __ipipe_enable_pipeline. -- Gilles Chanteperdrix. ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core
Re: [Xenomai-core] Xenomai on PXA255
Le lundi 29 mai 2006 à 17:45 +0200, Gilles Chanteperdrix a écrit : Stelian Pop wrote: If you have specific questions feel free to ask. But I suggest you read and try to understand the code first. Maybe we could provide a quick overview of how this works, Stelian, please correct me if I am wrong. Your description is accurate. However, such deep knowledge on the inner workings should not be needed to port Xenomai to a new ARM platform. (well, in case it works immediately. Debugging the port could need more knowledge :) ). In the list of 'undocumented' functions there is also __ipipe_mach_get_tsc() which should return some accurate time information. Most of the ARM platforms do not have a special Time Stamp Clock register, so most of the time the tick count is used instead (giving a TSC resolution of one microsecond). This is what standard Linux also use. If the platform has something more appropriate than the core timer for measuring the time, this function is where you need to wire it. Stelian. -- Stelian Pop [EMAIL PROTECTED] Open Wide ___ Xenomai-core mailing list Xenomai-core@gna.org https://mail.gna.org/listinfo/xenomai-core