All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: Fabrice Gasnier <fabrice.gasnier@domain.hid>
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai-help] Build and run xenomai 2.5.5.2 - linux-2.6.33 on imx27
Date: Mon, 07 Mar 2011 15:46:08 +0100	[thread overview]
Message-ID: <4D74EFB0.7000807@domain.hid> (raw)
In-Reply-To: <4D74EE69.5020705@domain.hid>

Fabrice Gasnier wrote:
> Dear all,
> 
> I'm currently evaluating xenomai 2.5.5.2 on a i.MX27 platform with 
> adeos-ipipe-2.6.33-arm-1.18-01.patch.
> 
> 
> I've encountred two issues for the time being  (same with 
> adeos-ipipe-2.6.33-arm-1.18-00.patch).
> 
> 1°/ First one happens when building a 2.6.33.3 kernel (after xenomai 
> prepare/configure/compile stage):
> 
> CC      arch/arm/plat-mxc/time.o
> arch/arm/plat-mxc/time.c: In function 'mxc_timer_init':
> arch/arm/plat-mxc/time.c:400: error: 'TIM1_BASE_ADDR' undeclared (first 
> use in this function)
> arch/arm/plat-mxc/time.c:400: error: (Each undeclared identifier is 
> reported only once
> arch/arm/plat-mxc/time.c:400: error: for each function it appears in.)
> make[1]: *** [arch/arm/plat-mxc/time.o] Erreur 1
> make: *** [arch/arm/plat-mxc] Erreur 2
> 
> 
> I first tried 2.6.31 kernel that was compiling (patched with 
> adeos-ipipe-2.6.31-arm-1.16-02.patch).
> Looking for differences lead me to patch my kernel with:
> 
> Index: linux-2.6.33.3/arch/arm/plat-mxc/time.c
> ===================================================================
> --- linux-2.6.33.3.orig/arch/arm/plat-mxc/time.c    2011-02-28 
> 11:44:02.000000000 +0100
> +++ linux-2.6.33.3/arch/arm/plat-mxc/time.c    2011-02-28 
> 11:48:19.000000000 +0100
> @@ -395,12 +395,17 @@
>       tsc_info.freq = clk_get_rate(timer_clk);
>       mxc_min_delay = ((__ipipe_cpu_freq + 500000) / 1000000) ?: 1;
> 
> -    if (cpu_is_mx1() || cpu_is_mx2()) {
> -#if defined(CONFIG_ARCH_MX1) || defined(CONFIG_ARCH_MX2)
> +    if (cpu_is_mx1()) {
> +#ifdef CONFIG_ARCH_MX1
>           tsc_info.u.counter_paddr = (TIM1_BASE_ADDR + MX1_2_TCN);
>           tsc_info.counter_vaddr =
>               (unsigned long)(timer_base + MX1_2_TCN);
>   #endif
> +    } else if (cpu_is_mx2()) {
> +#ifdef CONFIG_ARCH_MX2
> +        tsc_info.u.counter_paddr = (GPT1_BASE_ADDR + MX1_2_TCN);
> +        tsc_info.counter_vaddr = (unsigned long)(timer_base + MX1_2_TCN);
> +#endif
>       } else if (cpu_is_mx3()) {
>   #ifdef CONFIG_ARCH_MX3
>           tsc_info.u.counter_paddr = (GPT1_BASE_ADDR + MX3_TCN);

Ok. I'll take this one.

>   #ifdef CONFIG_IPIPE
>   void ipipe_mach_allow_hwtimer_uaccess(unsigned long aips1, unsigned 
> long aips2);
> +#if defined(CONFIG_ARCH_MX1) || defined(CONFIG_ARCH_MX2)
> +void ipipe_mach_allow_uaccess(unsigned long aipi_base_addr, unsigned 
> long bit_num);
> +#endif
>   #endif

Look the function above, you are adding a function which is already
there, please reuse the same function, instead of duplicating it...

-- 
					    Gilles.



  reply	other threads:[~2011-03-07 14:46 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-07 14:40 [Xenomai-help] Build and run xenomai 2.5.5.2 - linux-2.6.33 on imx27 Fabrice Gasnier
2011-03-07 14:46 ` Gilles Chanteperdrix [this message]
2011-03-07 15:40   ` Fabrice Gasnier
2011-03-07 16:09     ` Gilles Chanteperdrix
2011-03-07 21:28 ` Gilles Chanteperdrix
2011-03-08  8:26   ` Fabrice Gasnier
2011-03-08  8:45     ` Gilles Chanteperdrix
2011-03-08  8:51     ` Gilles Chanteperdrix
2011-03-08  9:55   ` Fabrice Gasnier
2011-03-08  9:59     ` Gilles Chanteperdrix

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4D74EFB0.7000807@domain.hid \
    --to=gilles.chanteperdrix@xenomai.org \
    --cc=fabrice.gasnier@domain.hid \
    --cc=xenomai@xenomai.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.