Module: xenomai-abe
Branch: analogy
Commit: bcc61b2a1c69dd3efbd91ce65312f9ab2e15196a
URL:    
http://git.xenomai.org/?p=xenomai-abe.git;a=commit;h=bcc61b2a1c69dd3efbd91ce65312f9ab2e15196a

Author: Philippe Gerum <r...@xenomai.org>
Date:   Thu Oct 22 09:54:06 2009 +0200

powerpc: upgrade legacy I-pipe support to 2.6.20-powerpc-1.9-03

---

 ...tch => adeos-ipipe-2.6.20-powerpc-1.9-03.patch} |  187 ++------------------
 1 files changed, 17 insertions(+), 170 deletions(-)

diff --git a/ksrc/arch/powerpc/patches/adeos-ipipe-2.6.20-powerpc-1.9-02.patch 
b/ksrc/arch/powerpc/patches/adeos-ipipe-2.6.20-powerpc-1.9-03.patch
similarity index 98%
rename from ksrc/arch/powerpc/patches/adeos-ipipe-2.6.20-powerpc-1.9-02.patch
rename to ksrc/arch/powerpc/patches/adeos-ipipe-2.6.20-powerpc-1.9-03.patch
index 0261af1..9d1e0a8 100644
--- a/ksrc/arch/powerpc/patches/adeos-ipipe-2.6.20-powerpc-1.9-02.patch
+++ b/ksrc/arch/powerpc/patches/adeos-ipipe-2.6.20-powerpc-1.9-03.patch
@@ -1,56 +1,3 @@
-diff --git a/.gitignore b/.gitignore
-deleted file mode 100644
-index 060a71d..0000000
---- a/.gitignore
-+++ /dev/null
-@@ -1,47 +0,0 @@
--#
--# NOTE! Don't add files that are generated in specific
--# subdirectories here. Add them in the ".gitignore" file
--# in that subdirectory instead.
--#
--# Normal rules
--#
--.*
--*.o
--*.a
--*.s
--*.ko
--*.so
--*.mod.c
--*.i
--*.lst
--*.symtypes
--
--#
--# Top-level generic files
--#
--tags
--TAGS
--vmlinux*
--System.map
--Module.symvers
--
--#
--# Generated include files
--#
--include/asm
--include/asm-*/asm-offsets.h
--include/config
--include/linux/autoconf.h
--include/linux/compile.h
--include/linux/version.h
--include/linux/utsrelease.h
--
--# stgit generated dirs
--patches-*
--
--# quilt's files
--patches
--series
--
--# cscope files
--cscope.*
 diff --git a/Makefile b/Makefile
 index 7e2750f..055ab06 100644
 --- a/Makefile
@@ -112,40 +59,6 @@ index d2ded19..06dd614 100644
  ifeq ($(CONFIG_PPC_MERGE),y)
  
  extra-$(CONFIG_PPC_STD_MMU)   := head_32.o
-diff --git a/arch/powerpc/kernel/align.c b/arch/powerpc/kernel/align.c
-index 4734b5d..18d72cd 100644
---- a/arch/powerpc/kernel/align.c
-+++ b/arch/powerpc/kernel/align.c
-@@ -492,10 +492,11 @@ int fix_alignment(struct pt_regs *regs)
-               if (flags & S) {
-                       /* Single-precision FP store requires conversion... */
- #ifdef CONFIG_PPC_FPU
--                      preempt_disable();
-+                      unsigned long irqflags;
-+                      ipipe_preempt_disable(irqflags);
-                       enable_kernel_fp();
-                       cvt_df(&data.dd, (float *)&data.v[4], &current->thread);
--                      preempt_enable();
-+                      ipipe_preempt_enable(irqflags);
- #else
-                       return 0;
- #endif
-@@ -535,10 +536,13 @@ int fix_alignment(struct pt_regs *regs)
-       /* Single-precision FP load requires conversion... */
-       case LD+F+S:
- #ifdef CONFIG_PPC_FPU
--              preempt_disable();
-+      {
-+              unsigned long irqflags;
-+              ipipe_preempt_disable(irqflags);
-               enable_kernel_fp();
-               cvt_fd((float *)&data.v[4], &data.dd, &current->thread);
--              preempt_enable();
-+              ipipe_preempt_enable(irqflags);
-+      }
- #else
-               return 0;
- #endif
 diff --git a/arch/powerpc/kernel/cputable.c b/arch/powerpc/kernel/cputable.c
 index b742013..fa5752a 100644
 --- a/arch/powerpc/kernel/cputable.c
@@ -1469,64 +1382,10 @@ index 0000000..83faab8
 +      addi    r1,r1,48
 +      bctr
 diff --git a/arch/powerpc/kernel/process.c b/arch/powerpc/kernel/process.c
-index f3d4dd5..55cbda3 100644
+index f3d4dd5..611683b 100644
 --- a/arch/powerpc/kernel/process.c
 +++ b/arch/powerpc/kernel/process.c
-@@ -63,6 +63,8 @@ struct task_struct *last_task_used_spe = NULL;
-  */
- void flush_fp_to_thread(struct task_struct *tsk)
- {
-+      unsigned long flags;
-+
-       if (tsk->thread.regs) {
-               /*
-                * We need to disable preemption here because if we didn't,
-@@ -72,7 +74,7 @@ void flush_fp_to_thread(struct task_struct *tsk)
-                * FPU, and then when we get scheduled again we would store
-                * bogus values for the remaining FP registers.
-                */
--              preempt_disable();
-+              ipipe_preempt_disable(flags);
-               if (tsk->thread.regs->msr & MSR_FP) {
- #ifdef CONFIG_SMP
-                       /*
-@@ -86,13 +88,13 @@ void flush_fp_to_thread(struct task_struct *tsk)
- #endif
-                       giveup_fpu(current);
-               }
--              preempt_enable();
-+              ipipe_preempt_enable(flags);
-       }
- }
- 
- void enable_kernel_fp(void)
- {
--      WARN_ON(preemptible());
-+      WARN_ON(ipipe_root_domain_p && preemptible());
- 
- #ifdef CONFIG_SMP
-       if (current->thread.regs && (current->thread.regs->msr & MSR_FP))
-@@ -177,15 +179,17 @@ EXPORT_SYMBOL(enable_kernel_spe);
- 
- void flush_spe_to_thread(struct task_struct *tsk)
- {
-+      unsigned long flags;
-+ 
-       if (tsk->thread.regs) {
--              preempt_disable();
-+              ipipe_preempt_disable(flags);
-               if (tsk->thread.regs->msr & MSR_SPE) {
- #ifdef CONFIG_SMP
-                       BUG_ON(tsk != current);
- #endif
-                       giveup_spe(current);
-               }
--              preempt_enable();
-+              ipipe_preempt_enable(flags);
-       }
- }
- 
-@@ -326,7 +330,7 @@ struct task_struct *__switch_to(struct task_struct *prev,
+@@ -326,7 +326,7 @@ struct task_struct *__switch_to(struct task_struct *prev,
        }
  #endif
  
@@ -1535,7 +1394,7 @@ index f3d4dd5..55cbda3 100644
  
        account_system_vtime(current);
        account_process_vtime(current);
-@@ -334,7 +338,7 @@ struct task_struct *__switch_to(struct task_struct *prev,
+@@ -334,7 +334,7 @@ struct task_struct *__switch_to(struct task_struct *prev,
  
        last = _switch(old_thread, new_thread);
  
@@ -1627,7 +1486,7 @@ index f6f0c6b..a73bd9f 100644
  }
  
 diff --git a/arch/powerpc/kernel/traps.c b/arch/powerpc/kernel/traps.c
-index 535f506..34554e7 100644
+index 535f506..30be7ee 100644
 --- a/arch/powerpc/kernel/traps.c
 +++ b/arch/powerpc/kernel/traps.c
 @@ -321,6 +321,9 @@ void machine_check_exception(struct pt_regs *regs)
@@ -1696,29 +1555,17 @@ index 535f506..34554e7 100644
        if (reason & REASON_FP) {
                /* IEEE FP exception */
                parse_fpe(regs);
-@@ -801,6 +820,10 @@ void alignment_exception(struct pt_regs *regs)
+@@ -801,6 +820,9 @@ void alignment_exception(struct pt_regs *regs)
  {
        int sig, code, fixed = 0;
  
-+      if (test_bit(IPIPE_NOSTACK_FLAG, &ipipe_this_cpudom_var(status)) &&
-+          ipipe_trap_notify(IPIPE_TRAP_ALIGNMENT, regs))
++      if (ipipe_trap_notify(IPIPE_TRAP_ALIGNMENT,regs))
 +              return;
 +
        /* we don't implement logging of alignment exceptions */
        if (!(current->thread.align_ctl & PR_UNALIGN_SIGBUS))
                fixed = fix_alignment(regs);
-@@ -811,6 +834,10 @@ void alignment_exception(struct pt_regs *regs)
-               return;
-       }
- 
-+      if (!ipipe_root_domain_p &&
-+          ipipe_trap_notify(IPIPE_TRAP_ALIGNMENT, regs))
-+              return;
-+
-       /* Operand address was bad */
-       if (fixed == -EFAULT) {
-               sig = SIGSEGV;
-@@ -838,6 +865,8 @@ void nonrecoverable_exception(struct pt_regs *regs)
+@@ -838,6 +860,8 @@ void nonrecoverable_exception(struct pt_regs *regs)
  {
        printk(KERN_ERR "Non-recoverable exception at PC=%lx MSR=%lx\n",
               regs->nip, regs->msr);
@@ -1727,7 +1574,7 @@ index 535f506..34554e7 100644
        debugger(regs);
        die("nonrecoverable exception", regs, SIGKILL);
  }
-@@ -853,11 +882,16 @@ void kernel_fp_unavailable_exception(struct pt_regs 
*regs)
+@@ -853,11 +877,16 @@ void kernel_fp_unavailable_exception(struct pt_regs 
*regs)
  {
        printk(KERN_EMERG "Unrecoverable FP Unavailable Exception "
                          "%lx at %lx\n", regs->trap, regs->nip);
@@ -1744,7 +1591,7 @@ index 535f506..34554e7 100644
        if (user_mode(regs)) {
                /* A user program has executed an altivec instruction,
                   but this kernel doesn't support altivec. */
-@@ -882,6 +916,9 @@ void SoftwareEmulation(struct pt_regs *regs)
+@@ -882,6 +911,9 @@ void SoftwareEmulation(struct pt_regs *regs)
        extern int Soft_emulate_8xx(struct pt_regs *);
        int errcode;
  
@@ -1754,7 +1601,7 @@ index 535f506..34554e7 100644
        CHECK_FULL_REGS(regs);
  
        if (!user_mode(regs)) {
-@@ -910,6 +947,9 @@ void SoftwareEmulation(struct pt_regs *regs)
+@@ -910,6 +942,9 @@ void SoftwareEmulation(struct pt_regs *regs)
  
  void DebugException(struct pt_regs *regs, unsigned long debug_status)
  {
@@ -1764,7 +1611,7 @@ index 535f506..34554e7 100644
        if (debug_status & DBSR_IC) {   /* instruction completion */
                regs->msr &= ~MSR_DE;
                if (user_mode(regs)) {
-@@ -940,6 +980,9 @@ void altivec_assist_exception(struct pt_regs *regs)
+@@ -940,6 +975,9 @@ void altivec_assist_exception(struct pt_regs *regs)
  {
        int err;
  
@@ -1774,7 +1621,7 @@ index 535f506..34554e7 100644
        if (!user_mode(regs)) {
                printk(KERN_EMERG "VMX/Altivec assist exception in kernel mode"
                       " at %lx\n", regs->nip);
-@@ -977,8 +1020,11 @@ void CacheLockingException(struct pt_regs *regs, 
unsigned long address,
+@@ -977,8 +1015,11 @@ void CacheLockingException(struct pt_regs *regs, 
unsigned long address,
         * as priv ops, in the future we could try to do
         * something smarter
         */
@@ -1787,7 +1634,7 @@ index 535f506..34554e7 100644
        return;
  }
  #endif /* CONFIG_FSL_BOOKE */
-@@ -990,6 +1036,9 @@ void SPEFloatingPointException(struct pt_regs *regs)
+@@ -990,6 +1031,9 @@ void SPEFloatingPointException(struct pt_regs *regs)
        int fpexc_mode;
        int code = 0;
  
@@ -1797,7 +1644,7 @@ index 535f506..34554e7 100644
        spefscr = current->thread.spefscr;
        fpexc_mode = current->thread.fpexc_mode;
  
-@@ -1029,6 +1078,8 @@ void unrecoverable_exception(struct pt_regs *regs)
+@@ -1029,6 +1073,8 @@ void unrecoverable_exception(struct pt_regs *regs)
  {
        printk(KERN_EMERG "Unrecoverable exception %lx at %lx\n",
               regs->trap, regs->nip);
@@ -3540,7 +3387,7 @@ index 9e4dd98..ed8ae98 100644
  #define hard_irq_disable()    local_irq_disable()
 diff --git a/include/asm-powerpc/ipipe.h b/include/asm-powerpc/ipipe.h
 new file mode 100644
-index 0000000..9ec6a94
+index 0000000..65d6900
 --- /dev/null
 +++ b/include/asm-powerpc/ipipe.h
 @@ -0,0 +1,198 @@
@@ -3583,10 +3430,10 @@ index 0000000..9ec6a94
 +#include <linux/cache.h>
 +#include <linux/threads.h>
 +
-+#define IPIPE_ARCH_STRING     "1.9-02"
++#define IPIPE_ARCH_STRING     "1.9-03"
 +#define IPIPE_MAJOR_NUMBER    1
 +#define IPIPE_MINOR_NUMBER    9
-+#define IPIPE_PATCH_NUMBER    2
++#define IPIPE_PATCH_NUMBER    3
 +
 +#define prepare_arch_switch(next)                     \
 +      do {                                            \


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

Reply via email to