[Xenomai-git] Gilles Chanteperdrix : Adapt to preemptible context switch proposed by newer I-pipe patches

2009-05-28 Thread GIT version control
Module: xenomai-2.4
Branch: master
Commit: 6a9d770619a7c7faf5cbe8bc4a61c3136793cf22
URL:
http://git.xenomai.org/?p=xenomai-2.4.git;a=commit;h=6a9d770619a7c7faf5cbe8bc4a61c3136793cf22

Author: Gilles Chanteperdrix gilles.chanteperd...@xenomai.org
Date:   Thu May 28 00:08:51 2009 +0200

Adapt to preemptible context switch proposed by newer I-pipe patches

---

 ksrc/arch/arm/Kconfig |4 
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/ksrc/arch/arm/Kconfig b/ksrc/arch/arm/Kconfig
index 675c6da..c79fe66 100644
--- a/ksrc/arch/arm/Kconfig
+++ b/ksrc/arch/arm/Kconfig
@@ -8,6 +8,10 @@ menu Machine
 
 depends on XENO_OPT_NUCLEUS
 
+config IPIPE_WANT_PREEMPTIBLE_SWITCH
+   bool
+   default y
+
 config XENO_HW_FPU
bool Enable FPU support
default y


___
Xenomai-git mailing list
Xenomai-git@gna.org
https://mail.gna.org/listinfo/xenomai-git


[Xenomai-git] Gilles Chanteperdrix : Fix computation of heap overhead

2009-05-28 Thread GIT version control
Module: xenomai-2.4
Branch: master
Commit: 912dc2f84c02cb1468e6c4d63037751e05936445
URL:
http://git.xenomai.org/?p=xenomai-2.4.git;a=commit;h=912dc2f84c02cb1468e6c4d63037751e05936445

Author: Gilles Chanteperdrix gilles.chanteperd...@xenomai.org
Date:   Thu May 28 00:07:09 2009 +0200

Fix computation of heap overhead

---

 include/nucleus/heap.h |   22 +-
 ksrc/nucleus/heap.c|2 +-
 2 files changed, 18 insertions(+), 6 deletions(-)

diff --git a/include/nucleus/heap.h b/include/nucleus/heap.h
index be2d70f..d04aeed 100644
--- a/include/nucleus/heap.h
+++ b/include/nucleus/heap.h
@@ -126,11 +126,23 @@ static inline size_t xnheap_align(size_t size, size_t al)
return ((size+al-1)(~(al-1)));
 }
 
-static inline size_t xnheap_overhead(size_t hsize, size_t psize)
+static inline size_t xnheap_external_overhead(size_t hsize, size_t psize)
 {
-   size_t m = psize / sizeof(struct xnpagemap);
-   size_t q = (size_t)xnarch_llimd(hsize - sizeof(xnextent_t), m, m + 1);
-   return xnheap_align(hsize - q, XNHEAP_MINALIGNSZ);
+   size_t pages = (hsize + psize - 1) / psize;
+   return xnheap_align(sizeof(xnextent_t)
+   + pages * sizeof(struct xnpagemap), psize);
+}
+
+static inline size_t xnheap_internal_overhead(size_t hsize, size_t psize)
+{
+   /* o = (h - o) * m / p + e
+  o * p = (h - o) * m + e * p
+  o * (p + m) = h * m + e * p
+  o = (h * m + e *p) / (p + m)
+   */
+   return xnheap_align((sizeof(xnextent_t) * psize
++ sizeof(struct xnpagemap) * hsize)
+   / (psize + sizeof(struct xnpagemap)), psize);
 }
 
 #define xnmalloc(size) xnheap_alloc(kheap,size)
@@ -156,7 +168,7 @@ static inline size_t xnheap_rounded_size(size_t hsize, 
size_t psize)
 */
if (hsize  2 * psize)
hsize = 2 * psize;
-   hsize += xnheap_overhead(hsize, psize);
+   hsize += xnheap_external_overhead(hsize, psize);
return xnheap_align(hsize, psize);
 }
 
diff --git a/ksrc/nucleus/heap.c b/ksrc/nucleus/heap.c
index 69cd277..3b93d8e 100644
--- a/ksrc/nucleus/heap.c
+++ b/ksrc/nucleus/heap.c
@@ -200,7 +200,7 @@ int xnheap_init(xnheap_t *heap,
 * static_part + pmapsize rounded to the minimum alignment
 * size.
*/
-   hdrsize = xnheap_overhead(heapsize, pagesize);
+   hdrsize = xnheap_internal_overhead(heapsize, pagesize);
 
/* Compute the page shiftmask from the page size (i.e. log2 value). */
for (pageshift = 0, shiftsize = pagesize;


___
Xenomai-git mailing list
Xenomai-git@gna.org
https://mail.gna.org/listinfo/xenomai-git


[Xenomai-git] Philippe Gerum : Decrease some calibration values due to intrinsic latency reduction

2009-05-28 Thread GIT version control
Module: xenomai-head
Branch: master
Commit: 8cb864cdfe3b29d91a2a43a59c4dd69012d67c7a
URL:
http://git.xenomai.org/?p=xenomai-head.git;a=commit;h=8cb864cdfe3b29d91a2a43a59c4dd69012d67c7a

Author: Philippe Gerum r...@xenomai.org
Date:   Thu May 28 14:19:14 2009 +0200

Decrease some calibration values due to intrinsic latency reduction

---

 include/asm-blackfin/calibration.h |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/asm-blackfin/calibration.h 
b/include/asm-blackfin/calibration.h
index 63f0cac..fd8d595 100644
--- a/include/asm-blackfin/calibration.h
+++ b/include/asm-blackfin/calibration.h
@@ -31,9 +31,9 @@ static inline unsigned long xnarch_get_sched_latency (void)
 #define __sched_latency CONFIG_XENO_OPT_TIMING_SCHEDLAT
 #else
 #ifdef CONFIG_BF533
-#define __sched_latency 2
+#define __sched_latency 15000
 #elif defined(CONFIG_BF537)
-#define __sched_latency 4500
+#define __sched_latency 4800
 #elif defined(CONFIG_BF561)
 #define __sched_latency 3000
 #elif defined(CONFIG_BF54x)


___
Xenomai-git mailing list
Xenomai-git@gna.org
https://mail.gna.org/listinfo/xenomai-git


[Xenomai-git] Philippe Gerum : Decrease some calibration values due to intrinsic latency reduction

2009-05-28 Thread GIT version control
Module: xenomai-2.4
Branch: master
Commit: b31a13b63966fd7268615c206f9f2b1ccacd
URL:
http://git.xenomai.org/?p=xenomai-2.4.git;a=commit;h=b31a13b63966fd7268615c206f9f2b1ccacd

Author: Philippe Gerum r...@xenomai.org
Date:   Thu May 28 14:19:05 2009 +0200

Decrease some calibration values due to intrinsic latency reduction

---

 include/asm-blackfin/calibration.h |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/asm-blackfin/calibration.h 
b/include/asm-blackfin/calibration.h
index 53cea04..fd8d595 100644
--- a/include/asm-blackfin/calibration.h
+++ b/include/asm-blackfin/calibration.h
@@ -31,9 +31,9 @@ static inline unsigned long xnarch_get_sched_latency (void)
 #define __sched_latency CONFIG_XENO_OPT_TIMING_SCHEDLAT
 #else
 #ifdef CONFIG_BF533
-#define __sched_latency 2
+#define __sched_latency 15000
 #elif defined(CONFIG_BF537)
-#define __sched_latency 7500
+#define __sched_latency 4800
 #elif defined(CONFIG_BF561)
 #define __sched_latency 3000
 #elif defined(CONFIG_BF54x)


___
Xenomai-git mailing list
Xenomai-git@gna.org
https://mail.gna.org/listinfo/xenomai-git


[Xenomai-git] Philippe Gerum : Update Adeos/arm support

2009-05-28 Thread GIT version control
Module: xenomai-2.4
Branch: master
Commit: a741fad857f482e92481c2928a3a9ebb21d27fbd
URL:
http://git.xenomai.org/?p=xenomai-2.4.git;a=commit;h=a741fad857f482e92481c2928a3a9ebb21d27fbd

Author: Philippe Gerum r...@xenomai.org
Date:   Thu May 28 16:04:22 2009 +0200

Update Adeos/arm support

---

 patch = adeos-ipipe-2.6.27-arm-1.12-02.patch} |   42 
 patch = adeos-ipipe-2.6.28-arm-1.12-02.patch} |   42 
 2 files changed, 68 insertions(+), 16 deletions(-)

diff --git a/ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-01.patch 
b/ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-02.patch
similarity index 99%
rename from ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-01.patch
rename to ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-02.patch
index 49bf9a6..41e92fa 100644
--- a/ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-01.patch
+++ b/ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-02.patch
@@ -445,10 +445,10 @@ index 000..2a0c0e3
 +#endif /* __ASM_ARM_FCSE_H */
 diff --git a/arch/arm/include/asm/ipipe.h b/arch/arm/include/asm/ipipe.h
 new file mode 100644
-index 000..89c352b
+index 000..e8e76e1
 --- /dev/null
 +++ b/arch/arm/include/asm/ipipe.h
-@@ -0,0 +1,200 @@
+@@ -0,0 +1,226 @@
 +/* -*- linux-c -*-
 + * arch/arm/include/asm/ipipe.h
 + *
@@ -479,10 +479,10 @@ index 000..89c352b
 +
 +#include linux/ipipe_percpu.h
 +
-+#define IPIPE_ARCH_STRING 1.12-01
++#define IPIPE_ARCH_STRING 1.12-02
 +#define IPIPE_MAJOR_NUMBER1
 +#define IPIPE_MINOR_NUMBER12
-+#define IPIPE_PATCH_NUMBER1
++#define IPIPE_PATCH_NUMBER2
 +
 +#ifdef CONFIG_SMP
 +#error I-pipe/arm: SMP not yet implemented
@@ -493,11 +493,37 @@ index 000..89c352b
 +
 +#define smp_processor_id_hw() ipipe_processor_id()
 +
-+#define prepare_arch_switch(next) ipipe_schedule_notify(current, next)
++#ifdef CONFIG_IPIPE_WANT_PREEMPTIBLE_SWITCH
 +
-+/* We would need to clear the SYNC flag for the root domain */
-+/* over the current processor in SMP mode. */
-+#define task_hijacked(p) !ipipe_root_domain_p
++#define prepare_arch_switch(next) \
++  do {\
++  local_irq_enable_hw();  \
++  ipipe_schedule_notify(current, next);   \
++  } while(0)
++
++#define task_hijacked(p)  \
++  ({  \
++  int x = !ipipe_root_domain_p;   \
++  clear_bit(IPIPE_SYNC_FLAG, ipipe_root_cpudom_var(status)); \
++  x;  \
++  })
++
++#else /* !CONFIG_IPIPE_WANT_PREEMPTIBLE_SWITCH */
++
++#define prepare_arch_switch(next) \
++  do {\
++  ipipe_schedule_notify(current ,next);   \
++  local_irq_disable_hw(); \
++  } while(0)
++
++#define task_hijacked(p)  \
++  ({  \
++  int x = !ipipe_root_domain_p;   \
++  __clear_bit(IPIPE_SYNC_FLAG, ipipe_root_cpudom_var(status)); \
++  if (!x) local_irq_enable_hw(); x;   \
++  })
++
++#endif /* !CONFIG_IPIPE_WANT_PREEMPTIBLE_SWITCH */
 +
 +extern unsigned long arm_return_addr(int level);
 +
diff --git a/ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-01.patch 
b/ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-02.patch
similarity index 99%
rename from ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-01.patch
rename to ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-02.patch
index 77e315f..1f8dc1b 100644
--- a/ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-01.patch
+++ b/ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-02.patch
@@ -445,10 +445,10 @@ index 000..2a0c0e3
 +#endif /* __ASM_ARM_FCSE_H */
 diff --git a/arch/arm/include/asm/ipipe.h b/arch/arm/include/asm/ipipe.h
 new file mode 100644
-index 000..89c352b
+index 000..e8e76e1
 --- /dev/null
 +++ b/arch/arm/include/asm/ipipe.h
-@@ -0,0 +1,200 @@
+@@ -0,0 +1,226 @@
 +/* -*- linux-c -*-
 + * arch/arm/include/asm/ipipe.h
 + *
@@ -479,10 +479,10 @@ index 000..89c352b
 +
 +#include linux/ipipe_percpu.h
 +
-+#define IPIPE_ARCH_STRING 1.12-01
++#define IPIPE_ARCH_STRING 1.12-02
 +#define IPIPE_MAJOR_NUMBER1
 +#define IPIPE_MINOR_NUMBER12
-+#define IPIPE_PATCH_NUMBER1
++#define IPIPE_PATCH_NUMBER2
 +
 +#ifdef CONFIG_SMP
 +#error I-pipe/arm: SMP not yet implemented
@@ -493,11 +493,37 @@ index 000..89c352b
 +
 +#define smp_processor_id_hw() ipipe_processor_id()
 +
-+#define prepare_arch_switch(next) ipipe_schedule_notify(current, next)
++#ifdef CONFIG_IPIPE_WANT_PREEMPTIBLE_SWITCH
 +
-+/* We would need to clear the SYNC 

[Xenomai-git] Philippe Gerum : Update Adeos/arm support

2009-05-28 Thread GIT version control
Module: xenomai-head
Branch: master
Commit: 35b5239f70b2632efa189f5ef2b622add8dad234
URL:
http://git.xenomai.org/?p=xenomai-head.git;a=commit;h=35b5239f70b2632efa189f5ef2b622add8dad234

Author: Philippe Gerum r...@xenomai.org
Date:   Thu May 28 16:04:57 2009 +0200

Update Adeos/arm support

---

 patch = adeos-ipipe-2.6.27-arm-1.12-02.patch} |   42 
 patch = adeos-ipipe-2.6.28-arm-1.12-02.patch} |   42 
 2 files changed, 68 insertions(+), 16 deletions(-)

diff --git a/ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-01.patch 
b/ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-02.patch
similarity index 99%
rename from ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-01.patch
rename to ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-02.patch
index 49bf9a6..41e92fa 100644
--- a/ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-01.patch
+++ b/ksrc/arch/arm/patches/adeos-ipipe-2.6.27-arm-1.12-02.patch
@@ -445,10 +445,10 @@ index 000..2a0c0e3
 +#endif /* __ASM_ARM_FCSE_H */
 diff --git a/arch/arm/include/asm/ipipe.h b/arch/arm/include/asm/ipipe.h
 new file mode 100644
-index 000..89c352b
+index 000..e8e76e1
 --- /dev/null
 +++ b/arch/arm/include/asm/ipipe.h
-@@ -0,0 +1,200 @@
+@@ -0,0 +1,226 @@
 +/* -*- linux-c -*-
 + * arch/arm/include/asm/ipipe.h
 + *
@@ -479,10 +479,10 @@ index 000..89c352b
 +
 +#include linux/ipipe_percpu.h
 +
-+#define IPIPE_ARCH_STRING 1.12-01
++#define IPIPE_ARCH_STRING 1.12-02
 +#define IPIPE_MAJOR_NUMBER1
 +#define IPIPE_MINOR_NUMBER12
-+#define IPIPE_PATCH_NUMBER1
++#define IPIPE_PATCH_NUMBER2
 +
 +#ifdef CONFIG_SMP
 +#error I-pipe/arm: SMP not yet implemented
@@ -493,11 +493,37 @@ index 000..89c352b
 +
 +#define smp_processor_id_hw() ipipe_processor_id()
 +
-+#define prepare_arch_switch(next) ipipe_schedule_notify(current, next)
++#ifdef CONFIG_IPIPE_WANT_PREEMPTIBLE_SWITCH
 +
-+/* We would need to clear the SYNC flag for the root domain */
-+/* over the current processor in SMP mode. */
-+#define task_hijacked(p) !ipipe_root_domain_p
++#define prepare_arch_switch(next) \
++  do {\
++  local_irq_enable_hw();  \
++  ipipe_schedule_notify(current, next);   \
++  } while(0)
++
++#define task_hijacked(p)  \
++  ({  \
++  int x = !ipipe_root_domain_p;   \
++  clear_bit(IPIPE_SYNC_FLAG, ipipe_root_cpudom_var(status)); \
++  x;  \
++  })
++
++#else /* !CONFIG_IPIPE_WANT_PREEMPTIBLE_SWITCH */
++
++#define prepare_arch_switch(next) \
++  do {\
++  ipipe_schedule_notify(current ,next);   \
++  local_irq_disable_hw(); \
++  } while(0)
++
++#define task_hijacked(p)  \
++  ({  \
++  int x = !ipipe_root_domain_p;   \
++  __clear_bit(IPIPE_SYNC_FLAG, ipipe_root_cpudom_var(status)); \
++  if (!x) local_irq_enable_hw(); x;   \
++  })
++
++#endif /* !CONFIG_IPIPE_WANT_PREEMPTIBLE_SWITCH */
 +
 +extern unsigned long arm_return_addr(int level);
 +
diff --git a/ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-01.patch 
b/ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-02.patch
similarity index 99%
rename from ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-01.patch
rename to ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-02.patch
index 77e315f..1f8dc1b 100644
--- a/ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-01.patch
+++ b/ksrc/arch/arm/patches/adeos-ipipe-2.6.28-arm-1.12-02.patch
@@ -445,10 +445,10 @@ index 000..2a0c0e3
 +#endif /* __ASM_ARM_FCSE_H */
 diff --git a/arch/arm/include/asm/ipipe.h b/arch/arm/include/asm/ipipe.h
 new file mode 100644
-index 000..89c352b
+index 000..e8e76e1
 --- /dev/null
 +++ b/arch/arm/include/asm/ipipe.h
-@@ -0,0 +1,200 @@
+@@ -0,0 +1,226 @@
 +/* -*- linux-c -*-
 + * arch/arm/include/asm/ipipe.h
 + *
@@ -479,10 +479,10 @@ index 000..89c352b
 +
 +#include linux/ipipe_percpu.h
 +
-+#define IPIPE_ARCH_STRING 1.12-01
++#define IPIPE_ARCH_STRING 1.12-02
 +#define IPIPE_MAJOR_NUMBER1
 +#define IPIPE_MINOR_NUMBER12
-+#define IPIPE_PATCH_NUMBER1
++#define IPIPE_PATCH_NUMBER2
 +
 +#ifdef CONFIG_SMP
 +#error I-pipe/arm: SMP not yet implemented
@@ -493,11 +493,37 @@ index 000..89c352b
 +
 +#define smp_processor_id_hw() ipipe_processor_id()
 +
-+#define prepare_arch_switch(next) ipipe_schedule_notify(current, next)
++#ifdef CONFIG_IPIPE_WANT_PREEMPTIBLE_SWITCH
 +
-+/* We would need to clear the SYNC 

[Xenomai-git] Wolfgang Grandegger : rtcan: mscan: fix build problems with recent kernel versions

2009-05-28 Thread GIT version control
Module: xenomai-head
Branch: master
Commit: 1ae38daa72de7a2270c5927df923a1280b194bde
URL:
http://git.xenomai.org/?p=xenomai-head.git;a=commit;h=1ae38daa72de7a2270c5927df923a1280b194bde

Author: Wolfgang Grandegger w...@grandegger.com
Date:   Mon May 25 09:42:18 2009 +0200

rtcan: mscan: fix build problems with recent kernel versions

This patch fixes build problems with recent kernel version due
to changes of the OpenFirmware device compatibility names.
Furthermore, it introduces a Kconfig option to leave the CAN
pin routing as-is (normally pre-configured by the boot-loader).

Signed-off-by: Wolfgang Grandegger w...@grandegegr.com

---

 ksrc/drivers/can/mscan/Kconfig|5 -
 ksrc/drivers/can/mscan/rtcan_mscan.c  |   18 ++
 ksrc/drivers/can/mscan/rtcan_mscan_regs.h |   12 +---
 3 files changed, 27 insertions(+), 8 deletions(-)

diff --git a/ksrc/drivers/can/mscan/Kconfig b/ksrc/drivers/can/mscan/Kconfig
index e07c99a..eadad97 100644
--- a/ksrc/drivers/can/mscan/Kconfig
+++ b/ksrc/drivers/can/mscan/Kconfig
@@ -27,9 +27,12 @@ config XENO_DRIVERS_CAN_MSCAN_CLOCK
 choice
depends on XENO_DRIVERS_CAN_MSCAN
prompt Pin Configuration
-   default I2C1/TMR01
+   default XENO_DRIVERS_CAN_MSCAN_PRE
help
 
+config XENO_DRIVERS_CAN_MSCAN_PRE
+   bool Use pre-configured CAN routing
+
 config XENO_DRIVERS_CAN_MSCAN_ALT
bool CAN 1 on I2C1 pins, CAN 2 on TMR01 pins
 
diff --git a/ksrc/drivers/can/mscan/rtcan_mscan.c 
b/ksrc/drivers/can/mscan/rtcan_mscan.c
index 9c866fc..9618057 100644
--- a/ksrc/drivers/can/mscan/rtcan_mscan.c
+++ b/ksrc/drivers/can/mscan/rtcan_mscan.c
@@ -703,9 +703,11 @@ static inline void __init mscan_chip_config(struct 
mscan_regs *regs)
 static inline void __init mscan_gpio_config(void)
 {
 struct mpc5xxx_gpio *gpio = (struct mpc5xxx_gpio *)MPC5xxx_GPIO;
-int can_to_psc2 = 0;
+int can_to_psc2 = -1;
 
-#ifdef CONFIG_XENO_DRIVERS_CAN_MSCAN_PSC2
+#if defined(CONFIG_XENO_DRIVERS_CAN_MSCAN_ALT)
+can_to_psc2 = 0;
+#elif defined(CONFIG_XENO_DRIVERS_CAN_MSCAN_PSC2)
 can_to_psc2 = 1;
 #endif
 
@@ -723,6 +725,12 @@ static inline void __init mscan_gpio_config(void)
   Please use PSC2 or I2C1/TMR01.\n, mscan_pins); 
}
 }
+
+if (!gpio || can_to_psc2  0) {
+   printk(%s: use pre-configure CAN routing\n, RTCAN_DRV_NAME);
+   return;
+}
+
 if (can_to_psc2) {
gpio-port_config = ~0x1070;
gpio-port_config |= 0x0010;
@@ -737,7 +745,7 @@ static inline void __init mscan_gpio_config(void)
 static inline int mscan_get_config(unsigned long *addr,
   unsigned int *irq)
 {
-#ifdef CONFIG_PPC_MERGE
+#if defined(CONFIG_PPC_MERGE) || LINUX_VERSION_CODE  KERNEL_VERSION(2,6,27)
 /* Use Open Firmware device tree */
 struct device_node *np = NULL;
 unsigned int i;
@@ -746,7 +754,9 @@ static inline int mscan_get_config(unsigned long *addr,
 for (i = 0; i  RTCAN_MSCAN_DEVS; i++) {
struct resource r[2] = {};
 
-   np = of_find_compatible_node(np, mscan, mpc5200-mscan);
+   np = of_find_compatible_node(np, NULL, fsl,mpc5200-mscan);
+   if (np == NULL)
+   np = of_find_compatible_node(np, NULL, mpc5200-mscan);
if (np == NULL)
break;
ret = of_address_to_resource(np, 0, r[0]);
diff --git a/ksrc/drivers/can/mscan/rtcan_mscan_regs.h 
b/ksrc/drivers/can/mscan/rtcan_mscan_regs.h
index af806bd..ad996ad 100644
--- a/ksrc/drivers/can/mscan/rtcan_mscan_regs.h
+++ b/ksrc/drivers/can/mscan/rtcan_mscan_regs.h
@@ -27,17 +27,23 @@
 
 #if LINUX_VERSION_CODE  KERNEL_VERSION(2,6,20)
 #include sysdev/fsl_soc.h
+#if LINUX_VERSION_CODE  KERNEL_VERSION(2,6,22)
+#include linux/of_platform.h
+#else
 #include asm/of_platform.h
+#endif
 #include asm/mpc52xx.h
 #if LINUX_VERSION_CODE  KERNEL_VERSION(2,6,24)
-static inline void __iomem *mpc52xx_find_and_map(const char *compatible)
+static inline void __iomem *mpc5xxx_gpio_find_and_map(void)
 {
struct device_node *ofn;
-   ofn = of_find_compatible_node(NULL, NULL, compatible);
+   ofn = of_find_compatible_node(NULL, NULL, mpc5200-gpio);
+   if (!ofn)
+   ofn = of_find_compatible_node(NULL, NULL, fsl,mpc5200-gpio);
return ofn ? of_iomap(ofn, 0) : NULL;
 }
 #endif
-#define MPC5xxx_GPIOmpc52xx_find_and_map(mpc5200-gpio)
+#define MPC5xxx_GPIOmpc5xxx_gpio_find_and_map()
 #define mpc5xxx_gpio   mpc52xx_gpio
 #elif LINUX_VERSION_CODE  KERNEL_VERSION(2,6,10)
 #include asm/mpc5xxx.h


___
Xenomai-git mailing list
Xenomai-git@gna.org
https://mail.gna.org/listinfo/xenomai-git


[Xenomai-git] Jan Kiszka : nucleus: Move xnarch_set_irq_affinity out of intrlock

2009-05-28 Thread GIT version control
Module: xenomai-2.4
Branch: master
Commit: 3952700e76f054f5e71c253c1fea58ae83d8624f
URL:
http://git.xenomai.org/?p=xenomai-2.4.git;a=commit;h=3952700e76f054f5e71c253c1fea58ae83d8624f

Author: Jan Kiszka jan.kis...@siemens.com
Date:   Wed Apr 22 18:44:23 2009 +0200

nucleus: Move xnarch_set_irq_affinity out of intrlock

There is no need to hold intrlock while setting the affinity of the
to-be-registered IRQ. Additionally, we have troubles with MSI code that
can use Linux locks from within this service. So move the affinity
adjustment out of the critical section.

Signed-off-by: Jan Kiszka jan.kis...@siemens.com

---

 ksrc/nucleus/intr.c |5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/ksrc/nucleus/intr.c b/ksrc/nucleus/intr.c
index 0532cb5..85ed438 100644
--- a/ksrc/nucleus/intr.c
+++ b/ksrc/nucleus/intr.c
@@ -705,11 +705,12 @@ int xnintr_attach(xnintr_t *intr, void *cookie)
intr-cookie = cookie;
memset(intr-stat, 0, sizeof(intr-stat));
 
-   xnlock_get_irqsave(intrlock, s);
-
 #ifdef CONFIG_SMP
xnarch_set_irq_affinity(intr-irq, nkaffinity);
 #endif /* CONFIG_SMP */
+
+   xnlock_get_irqsave(intrlock, s);
+
err = xnintr_irq_attach(intr);
 
if (!err)


___
Xenomai-git mailing list
Xenomai-git@gna.org
https://mail.gna.org/listinfo/xenomai-git


[Xenomai-git] Philippe Gerum : Fix generate-doc rule

2009-05-28 Thread GIT version control
Module: xenomai-2.4
Branch: master
Commit: 898e5ab81be72f6feae1bcc34c3328a5f4db6426
URL:
http://git.xenomai.org/?p=xenomai-2.4.git;a=commit;h=898e5ab81be72f6feae1bcc34c3328a5f4db6426

Author: Philippe Gerum r...@xenomai.org
Date:   Thu May 28 16:23:45 2009 +0200

Fix generate-doc rule

---

 doc/Makefile.am |4 ++--
 doc/Makefile.in |4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/doc/Makefile.am b/doc/Makefile.am
index efb1bc4..7e4bf8a 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -3,8 +3,8 @@ SUBDIRS=docbook doxygen man txt
 GENERATE_DOC=$(top_srcdir)/scripts/maint/generate-doc
 
 generate-doc:
-   @if test \! -e $(GENERATE_DOC) -o \! -e $(srcdir)/.svn ; then \
-   echo $@ may only be run from a SVN working copy. ; \
+   @if test \! -e $(GENERATE_DOC) ; then \
+   echo $@ may only be run from a GIT working tree. ; \
else \
srcdir=$(srcdir) $(GENERATE_DOC) ; \
fi
diff --git a/doc/Makefile.in b/doc/Makefile.in
index f20138e..547057b 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -538,8 +538,8 @@ uninstall-am:
 
 
 generate-doc:
-   @if test \! -e $(GENERATE_DOC) -o \! -e $(srcdir)/.svn ; then \
-   echo $@ may only be run from a SVN working copy. ; \
+   @if test \! -e $(GENERATE_DOC) ; then \
+   echo $@ may only be run from a GIT working tree. ; \
else \
srcdir=$(srcdir) $(GENERATE_DOC) ; \
fi


___
Xenomai-git mailing list
Xenomai-git@gna.org
https://mail.gna.org/listinfo/xenomai-git


[Xenomai-git] Philippe Gerum : Fix dist rule

2009-05-28 Thread GIT version control
Module: xenomai-2.4
Branch: master
Commit: 98e420968b64b0a0dd36538adb06af63e7c90c49
URL:
http://git.xenomai.org/?p=xenomai-2.4.git;a=commit;h=98e420968b64b0a0dd36538adb06af63e7c90c49

Author: Philippe Gerum r...@xenomai.org
Date:   Thu May 28 16:39:26 2009 +0200

Fix dist rule

---

 doc/Makefile.am |5 +
 doc/Makefile.in |   10 ++
 2 files changed, 3 insertions(+), 12 deletions(-)

diff --git a/doc/Makefile.am b/doc/Makefile.am
index 7e4bf8a..433ba5b 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -3,11 +3,8 @@ SUBDIRS=docbook doxygen man txt
 GENERATE_DOC=$(top_srcdir)/scripts/maint/generate-doc
 
 generate-doc:
-   @if test \! -e $(GENERATE_DOC) ; then \
+   @if test \! -e $(GENERATE_DOC) -o \! -e $(srcdir)/.git ; then \
echo $@ may only be run from a GIT working tree. ; \
else \
srcdir=$(srcdir) $(GENERATE_DOC) ; \
fi
-
-dist-hook:
-   find $(distdir) -name .svn -depth -exec rm -fr \{\} \;
diff --git a/doc/Makefile.in b/doc/Makefile.in
index 547057b..f6e9031 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -433,9 +433,6 @@ distdir: $(DISTFILES)
  || exit 1; \
  fi; \
done
-   $(MAKE) $(AM_MAKEFLAGS) \
- top_distdir=$(top_distdir) distdir=$(distdir) \
- dist-hook
 check-am: all-am
 check: check-recursive
 all-am: Makefile
@@ -524,7 +521,7 @@ uninstall-am:
 
 .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
all all-am check check-am clean clean-generic clean-libtool \
-   ctags ctags-recursive dist-hook distclean distclean-generic \
+   ctags ctags-recursive distclean distclean-generic \
distclean-libtool distclean-tags distdir dvi dvi-am html \
html-am info info-am install install-am install-data \
install-data-am install-dvi install-dvi-am install-exec \
@@ -538,14 +535,11 @@ uninstall-am:
 
 
 generate-doc:
-   @if test \! -e $(GENERATE_DOC) ; then \
+   @if test \! -e $(GENERATE_DOC) -o \! -e $(srcdir)/.git ; then \
echo $@ may only be run from a GIT working tree. ; \
else \
srcdir=$(srcdir) $(GENERATE_DOC) ; \
fi
-
-dist-hook:
-   find $(distdir) -name .svn -depth -exec rm -fr \{\} \;
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
diff --git a/src/testsuite/clocktest/Makefile.in 
b/src/testsuite/clocktest/Makefile.in
old mode 100755
new mode 100644


___
Xenomai-git mailing list
Xenomai-git@gna.org
https://mail.gna.org/listinfo/xenomai-git