All of lore.kernel.org
 help / color / mirror / Atom feed
* [Xenomai-core] [PATCH v3 0/9] heap setup/cleanup fixes, refactorings & more
@ 2009-10-20 11:37 Jan Kiszka
  2009-10-20 11:37 ` [Xenomai-core] [PATCH v3 3/9] nucleus: Fix race window in heap mapping procedure Jan Kiszka
                   ` (8 more replies)
  0 siblings, 9 replies; 34+ messages in thread
From: Jan Kiszka @ 2009-10-20 11:37 UTC (permalink / raw)
  To: Philippe Gerum; +Cc: xenomai

Third round of this series. This time I dug deeper into the heap
management, trying to simplify its use which should remove a few race
conditions of the existing code.

The central change is patch 5: xnheap_destroy_mapped will no longer
return an error, it will always start deferred deletion in case the
heap's memory is still in use. This simplifies the use a lot, allowing
among other things to drop -EBUSY from the list of possible return codes
of rt_queue/heap_delete.

The series furthermore contains an attempt to fix RTAI's shm code, fixes
the know leakages of rt_mutex/queue/heap auto-deletion and introduces
complete heap statistics (this time without using a Linux spin lock).

Please pull the series (or cherry-pick individual patches) from

    git://xenomai.org/xenomai-jki.git for-upstream

if there are no concerns.

Jan Kiszka (9):
      native: Release fastlock to the proper heap
      nucleus: Use Linux spin lock for heap list management
      nucleus: Fix race window in heap mapping procedure
      nucleus: xnheap_destroy does not fail
      nucleus: Avoid returning errors from xnheap_destroy_mapped
      rtai: Try to fix _shm_free
      native: Do not requeue on auto-cleanup errors
      native: Fix memory leak on heap/queue auto-deletion
      nucleus: Include all heaps in statistics

 include/asm-generic/bits/heap.h |    2 +-
 include/asm-generic/system.h    |    2 +-
 include/native/ppd.h            |   16 +--
 include/nucleus/heap.h          |   32 +++--
 ksrc/drivers/ipc/iddp.c         |    3 +-
 ksrc/drivers/ipc/xddp.c         |    6 +-
 ksrc/nucleus/heap.c             |  258 +++++++++++++++++++++++++++------------
 ksrc/nucleus/module.c           |    2 +-
 ksrc/nucleus/pod.c              |    5 +-
 ksrc/nucleus/shadow.c           |    5 +-
 ksrc/skins/native/heap.c        |   41 +++---
 ksrc/skins/native/mutex.c       |   14 ++-
 ksrc/skins/native/pipe.c        |    4 +-
 ksrc/skins/native/queue.c       |   34 +++---
 ksrc/skins/native/syscall.c     |   25 +---
 ksrc/skins/posix/shm.c          |    4 +-
 ksrc/skins/psos+/rn.c           |    6 +-
 ksrc/skins/rtai/shm.c           |   47 ++++---
 ksrc/skins/vrtx/heap.c          |    6 +-
 ksrc/skins/vrtx/syscall.c       |    3 +-
 20 files changed, 317 insertions(+), 198 deletions(-)

[1] http://thread.gmane.org/gmane.linux.real-time.xenomai.devel/6559


^ permalink raw reply	[flat|nested] 34+ messages in thread
* Re: [Xenomai-help] Xenomai on ARMadeus
@ 2009-11-12 14:34 Gwenhaël Goavec-Merou
  0 siblings, 0 replies; 34+ messages in thread
From: Gwenhaël Goavec-Merou @ 2009-11-12 14:34 UTC (permalink / raw)
  To: xenomai

Sorry for the late
> gwenhael.goavec wrote:
>> On Mon, 02 Nov 2009 23:29:31 +0100
>> Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
>> wrote:
>>
>>> gwenhael.goavec wrote:
>>>> On Mon, 02 Nov 2009 19:38:51 +0100
>>>> Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
>>>> wrote:
>>>>
>>>>> By the way, did you make any change to the I-pipe patch to get it
running on this board?
>>>> The only change realized, is made because Armadeus and
>>>> I-pipe does the same change on
>>>> mach-imx/include/mach/imxfb.h :
>>>>
>>>> --- a/arch/arm/mach-imx/include/mach/imxfb.h
>>>> +++ b/arch/arm/mach-imx/include/mach/imxfb.h
>>>> @@ -14,7 +14,6 @@
>>>>  #define PCR_BPIX_8 (3 << 25)
>>>>  #define PCR_BPIX_12    (4 << 25)
>>>>  #define PCR_BPIX_16    (4 << 25)
>>>> +#define PCR_BPIX_MASK   (7 << 25)
>>>>  #define PCR_PIXPOL (1 << 24)
>>>>  #define PCR_FLMPOL (1 << 23)
>>>>  #define PCR_LPPOL  (1 << 22)
>>>>
>>>> I take this opportunity to ask a question:
>>>> on APF27 with imx27, I found that the system freeze
>>>> when an interrupt handler is in place and an
>>>> interruption happens.
>>>> if interrupt handler is in place without interruption no
>>>> problems and if interruption happens without interrupt
>>>> handler it's ok too.
>>>>
>>>> If someone could help or advise me.
>>>> thank you very much
>
> The reason I knew for this problem was if handle_edge_irq was used for
some interrupts. But problems of this kind for IMX GPIOs are fixed in
1.3-03.
>
> Do you have this problem with in-kernel or out-of-tree drivers? With
real-time or non real-time interrupts? Could you show us
> /proc/interrupts before the system freezes?
>
I use an RTDM real-time driver for testing
GPIO interrupt don't appears in /proc/interrupts

~ # cat /proc/interrupts
           CPU0
 20:         69           -  IMX-uart
 26:       1664           -  i.MX Timer Tick
 29:      84439           -  mxc_nd
 50:         75           -  fec
 53:          0           -  VPU_CODEC_IRQ
Err:          0

Gwenhael

Signed-off-by: gwenhael.goavec-merou@domain.hid






^ permalink raw reply	[flat|nested] 34+ messages in thread

end of thread, other threads:[~2009-11-16 12:38 UTC | newest]

Thread overview: 34+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-10-20 11:37 [Xenomai-core] [PATCH v3 0/9] heap setup/cleanup fixes, refactorings & more Jan Kiszka
2009-10-20 11:37 ` [Xenomai-core] [PATCH v3 3/9] nucleus: Fix race window in heap mapping procedure Jan Kiszka
2009-10-20 11:37 ` [Xenomai-core] [PATCH v3 4/9] nucleus: xnheap_destroy does not fail Jan Kiszka
2009-10-20 11:37 ` [Xenomai-core] [PATCH v3 2/9] nucleus: Use Linux spin lock for heap list management Jan Kiszka
2009-10-20 11:37 ` [Xenomai-core] [PATCH v3 1/9] native: Release fastlock to the proper heap Jan Kiszka
2009-10-20 11:37 ` [Xenomai-core] [PATCH v3 5/9] nucleus: Avoid returning errors from xnheap_destroy_mapped Jan Kiszka
2009-10-24 17:22   ` Philippe Gerum
2009-11-02 16:04     ` Philippe Gerum
2009-11-02 16:41       ` Jan Kiszka
2009-11-02 16:51         ` Philippe Gerum
2009-11-02 16:57           ` Jan Kiszka
2009-11-02 18:01             ` Jan Kiszka
2009-11-02 18:19               ` [Xenomai-help] Xenomai on ARMadeus Pierre Ficheux
2009-11-02 18:22                 ` Gilles Chanteperdrix
2009-11-02 18:38                 ` Gilles Chanteperdrix
2009-11-02 19:19                   ` gwenhael.goavec
2009-11-02 22:29                     ` Gilles Chanteperdrix
2009-11-03  7:36                       ` gwenhael.goavec
     [not found]                       ` <20091103082204.248eed59@domain.hid>
2009-11-04 13:14                         ` Gilles Chanteperdrix
     [not found]                           ` <fbc4f538a6f4d84cfe514aba0985a525.squirrel@domain.hid>
2009-11-12 14:59                             ` Gilles Chanteperdrix
2009-11-02 18:26               ` [Xenomai-core] [PATCH v3 5/9] nucleus: Avoid returning errors from xnheap_destroy_mapped Philippe Gerum
2009-11-03  8:26                 ` Jan Kiszka
2009-10-20 11:37 ` [Xenomai-core] [PATCH v3 6/9] rtai: Try to fix _shm_free Jan Kiszka
2009-10-24 17:25   ` Philippe Gerum
2009-10-20 11:37 ` [Xenomai-core] [PATCH v3 7/9] native: Do not requeue on auto-cleanup errors Jan Kiszka
2009-10-20 11:37 ` [Xenomai-core] [PATCH v3 9/9] nucleus: Include all heaps in statistics Jan Kiszka
2009-10-20 23:41   ` Philippe Gerum
2009-10-22 10:52     ` Jan Kiszka
2009-11-11 12:59       ` Jan Kiszka
2009-11-15 17:38         ` Philippe Gerum
2009-11-16 12:38           ` Jan Kiszka
2009-10-20 11:37 ` [Xenomai-core] [PATCH v3 8/9] native: Fix memory leak on heap/queue auto-deletion Jan Kiszka
2009-10-22 10:30   ` [Xenomai-core] [PATCH] native: Avoid double release on queue/heap auto-cleanup Jan Kiszka
2009-11-12 14:34 [Xenomai-help] Xenomai on ARMadeus Gwenhaël Goavec-Merou

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.