All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: Peter Howard <pjh@northern-ridge.com.au>
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai] OMAP L138
Date: Fri, 11 Apr 2014 00:55:20 +0200	[thread overview]
Message-ID: <53472158.1080804@xenomai.org> (raw)
In-Reply-To: <1397170339.6356.17.camel@localhost.localdomain>

On 04/11/2014 12:52 AM, Peter Howard wrote:
> On Fri, 2014-04-11 at 00:48 +0200, Gilles Chanteperdrix wrote:
>> On 04/11/2014 12:34 AM, Peter Howard wrote:
>>> On Fri, 2014-04-11 at 00:23 +0200, Gilles Chanteperdrix wrote:
>>> (Stripping back conversation on this one - apologies if that's bad
>>> etiquette for this list)
>>>  
>>>> Attachment is better. Also please post the changes you made for omapL138
>>>>
>>>
>>> diff --git a/arch/arm/mach-davinci/Kconfig b/arch/arm/mach-davinci/Kconfig
>>> index a075b3e..3d8bc59 100644
>>> --- a/arch/arm/mach-davinci/Kconfig
>>> +++ b/arch/arm/mach-davinci/Kconfig
>>> @@ -41,6 +41,8 @@ config ARCH_DAVINCI_DA850
>>>  	select ARCH_DAVINCI_DA8XX
>>>  	select ARCH_HAS_CPUFREQ
>>>  	select CP_INTC
>>> +    select IPIPE_ARM_KUSER_TSC if IPIPE
>>> +    select ARM_FCSE if IPIPE
>>
>> You may want to leave the choice of enabling or disabling FCSE to the user.
>>
> 
> Understood; at the moment the variance on max latency is really bad if
> you don't enable FCSE.  When I sort out the crashing issues I'll re-test
> with it off.
> 
>>>  
>>>  config ARCH_DAVINCI_DA8XX
>>>  	bool
>>> diff --git a/arch/arm/mach-davinci/cp_intc.c b/arch/arm/mach-davinci/cp_intc.c
>>> index 006dae8..61fa26f 100644
>>> --- a/arch/arm/mach-davinci/cp_intc.c
>>> +++ b/arch/arm/mach-davinci/cp_intc.c
>>> @@ -17,6 +17,7 @@
>>>  #include <linux/of.h>
>>>  #include <linux/of_address.h>
>>>  #include <linux/of_irq.h>
>>> +#include <linux/ipipe.h>
>>>  
>>>  #include <mach/common.h>
>>>  #include <mach/cp_intc.h>
>>> @@ -39,6 +40,7 @@ static void cp_intc_ack_irq(struct irq_data *d)
>>>  /* Disable interrupt */
>>>  static void cp_intc_mask_irq(struct irq_data *d)
>>>  {
>>> +	ipipe_lock_irq(d->irq);
>>>  	/* XXX don't know why we need to disable nIRQ here... */
>>>  	cp_intc_write(1, CP_INTC_HOST_ENABLE_IDX_CLR);
>>>  	cp_intc_write(d->hwirq, CP_INTC_SYS_ENABLE_IDX_CLR);
>>> @@ -49,8 +51,25 @@ static void cp_intc_mask_irq(struct irq_data *d)
>>>  static void cp_intc_unmask_irq(struct irq_data *d)
>>>  {
>>>  	cp_intc_write(d->hwirq, CP_INTC_SYS_ENABLE_IDX_SET);
>>> +	ipipe_unlock_irq(d->irq);
>>>  }
>>>  
>>> +#ifdef CONFIG_IPIPE
>>> +/* Hold and release without irq locking */
>>> +static void cp_intc_hold_irq(struct irq_data *d)
>>> +{
>>> +	/* XXX don't know why we need to disable nIRQ here... */
>>> +	cp_intc_write(1, CP_INTC_HOST_ENABLE_IDX_CLR);
>>> +	cp_intc_write(d->hwirq, CP_INTC_SYS_ENABLE_IDX_CLR);
>>> +	cp_intc_write(1, CP_INTC_HOST_ENABLE_IDX_SET);
>>> +}
>>> +
>>> +static void cp_intc_release_irq(struct irq_data *d)
>>> +{
>>> +	cp_intc_write(d->hwirq, CP_INTC_SYS_ENABLE_IDX_SET);
>>> +}
>>> +#endif /* CONFIG_IPIPE */
>>> +
>>>  static int cp_intc_set_irq_type(struct irq_data *d, unsigned int flow_type)
>>>  {
>>>  	unsigned reg		= BIT_WORD(d->hwirq);
>>> @@ -100,6 +119,12 @@ static struct irq_chip cp_intc_irq_chip = {
>>>  	.irq_ack	= cp_intc_ack_irq,
>>>  	.irq_mask	= cp_intc_mask_irq,
>>>  	.irq_unmask	= cp_intc_unmask_irq,
>>> +#ifdef CONFIG_IPIPE
>>> +	.irq_disable = cp_intc_hold_irq,
>>> +	.irq_enable = cp_intc_release_irq,
>>> +	.irq_hold	= cp_intc_hold_irq,
>>> +	.irq_release = cp_intc_release_irq,
>>> +#endif /* CONFIG_IPIPE */
>>>  	.irq_set_type	= cp_intc_set_irq_type,
>>>  	.irq_set_wake	= cp_intc_set_wake,
>>>  };
>>
>> The hold/release stuff should be only be needed for fasteoi irq, not for
>> edge irqs.
>>
> 
> Are those changes a problem, or just irrelevant with edge triggering?

They should not be a problem, as for an edge irq, only ack is called,
not mask and unmask.

-- 
                                                                Gilles.


  reply	other threads:[~2014-04-10 22:55 UTC|newest]

Thread overview: 57+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-02  2:59 [Xenomai] OMAP L138 Peter Howard
2014-04-02  7:24 ` Gilles Chanteperdrix
2014-04-02 22:37   ` Peter Howard
2014-04-02 23:31     ` Gilles Chanteperdrix
2014-04-03  1:28       ` Peter Howard
2014-04-07  5:34   ` Peter Howard
2014-04-07  9:53     ` Gilles Chanteperdrix
2014-04-08  2:37       ` Peter Howard
2014-04-08  8:12         ` Gilles Chanteperdrix
2014-04-08 23:44           ` Peter Howard
2014-04-08  9:18     ` Gilles Chanteperdrix
2014-04-08 23:30       ` Peter Howard
2014-04-09  0:18         ` Gilles Chanteperdrix
2014-04-09  0:20         ` Gilles Chanteperdrix
2014-04-09  0:34           ` Peter Howard
2014-04-09  4:27             ` Peter Howard
2014-04-09 11:54               ` Gilles Chanteperdrix
2014-04-10  7:01                 ` Peter Howard
2014-04-10 12:06                   ` Gilles Chanteperdrix
2014-04-10 19:57                     ` Peter Howard
2014-04-10 21:56                       ` Gilles Chanteperdrix
2014-04-10 22:17                         ` Peter Howard
2014-04-10 22:23                           ` Gilles Chanteperdrix
2014-04-10 22:27                             ` Peter Howard
2014-04-10 22:34                             ` Peter Howard
2014-04-10 22:48                               ` Gilles Chanteperdrix
2014-04-10 22:52                                 ` Peter Howard
2014-04-10 22:55                                   ` Gilles Chanteperdrix [this message]
2014-04-15  6:03                                   ` Peter Howard
2014-04-15 11:37                                     ` Gilles Chanteperdrix
2014-04-15 21:59                                       ` Peter Howard
2014-04-15 22:25                                         ` Gilles Chanteperdrix
2014-04-16  0:58                                           ` Peter Howard
2014-04-16  7:34                                             ` Gilles Chanteperdrix
2014-04-17  0:30                                               ` Peter Howard
2014-04-17 11:37                                                 ` Gilles Chanteperdrix
2014-04-22 23:02                                         ` Gilles Chanteperdrix
2014-04-23  1:45                                           ` Peter Howard
2014-04-23  2:15                                             ` Peter Howard
2014-04-23 12:13                                             ` Gilles Chanteperdrix
2014-04-24 21:30                                             ` Gilles Chanteperdrix
2014-04-27 22:14                                               ` Peter Howard
2014-04-28  1:19                                               ` Peter Howard
2014-04-29  1:46                                               ` Peter Howard
2014-05-04 19:25                                                 ` Gilles Chanteperdrix
2014-05-05 23:00                                                   ` Peter Howard
2014-05-06 11:35                                                     ` Gilles Chanteperdrix
2014-05-06 22:44                                                       ` Peter Howard
2014-05-07  0:26                                                         ` Gilles Chanteperdrix
2014-04-10 23:01                             ` Peter Howard
2014-04-11 15:46                               ` Lennart Sorensen
2014-04-14  0:28                                 ` Peter Howard
2014-04-14  1:10                                   ` Lennart Sorensen
2014-04-14  5:02                                     ` Peter Howard
2014-04-14  5:48                                       ` Peter Howard
2014-04-14 13:21                                       ` Lennart Sorensen
2014-04-15  1:58                                     ` Peter Howard

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=53472158.1080804@xenomai.org \
    --to=gilles.chanteperdrix@xenomai.org \
    --cc=pjh@northern-ridge.com.au \
    --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.