Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 127135
b: refs/heads/master
c: cc92b87
h: refs/heads/master
i:
  127133: 09deefa
  127131: 31a93fe
  127127: 8e82afa
  127119: c441cd6
  127103: 121e15f
v: v3
  • Loading branch information
Sonic Zhang authored and Bryan Wu committed Jan 7, 2009
1 parent b3af5db commit 242fa79
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 459249aa2d9ae02f49479a2096e5372ccc29c9be
refs/heads/master: cc92b870a779500f444419f27bf73c6c7660ff9c
2 changes: 2 additions & 0 deletions trunk/arch/blackfin/include/asm/l1layout.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

#include <asm/blackfin.h>

#ifndef CONFIG_SMP
#ifndef __ASSEMBLY__

/* Data that is "mapped" into the process VM at the start of the L1 scratch
Expand All @@ -28,5 +29,6 @@ struct l1_scratch_task_info
get_l1_scratch_start())

#endif
#endif

#endif
11 changes: 11 additions & 0 deletions trunk/arch/blackfin/include/asm/processor.h
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ struct thread_struct {
* pass the data segment into user programs if it exists,
* it can't hurt anything as far as I can tell
*/
#ifndef CONFIG_SMP
#define start_thread(_regs, _pc, _usp) \
do { \
set_fs(USER_DS); \
Expand All @@ -78,6 +79,16 @@ do { \
sizeof(*L1_SCRATCH_TASK_INFO)); \
wrusp(_usp); \
} while(0)
#else
#define start_thread(_regs, _pc, _usp) \
do { \
set_fs(USER_DS); \
(_regs)->pc = (_pc); \
if (current->mm) \
(_regs)->p5 = current->mm->start_data; \
wrusp(_usp); \
} while (0)
#endif

/* Forward declaration, a strange C thing */
struct task_struct;
Expand Down
7 changes: 7 additions & 0 deletions trunk/arch/blackfin/include/asm/system.h
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,7 @@ static inline unsigned long __xchg(unsigned long x, volatile void *ptr,

asmlinkage struct task_struct *resume(struct task_struct *prev, struct task_struct *next);

#ifndef CONFIG_SMP
#define switch_to(prev,next,last) \
do { \
memcpy (&task_thread_info(prev)->l1_task_info, L1_SCRATCH_TASK_INFO, \
Expand All @@ -205,5 +206,11 @@ do { \
sizeof *L1_SCRATCH_TASK_INFO); \
(last) = resume (prev, next); \
} while (0)
#else
#define switch_to(prev, next, last) \
do { \
(last) = resume(prev, next); \
} while (0)
#endif

#endif /* _BLACKFIN_SYSTEM_H */
2 changes: 2 additions & 0 deletions trunk/arch/blackfin/include/asm/thread_info.h
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,9 @@ struct thread_info {
int preempt_count; /* 0 => preemptable, <0 => BUG */
mm_segment_t addr_limit; /* address limit */
struct restart_block restart_block;
#ifndef CONFIG_SMP
struct l1_scratch_task_info l1_task_info;
#endif
};

/*
Expand Down

0 comments on commit 242fa79

Please sign in to comment.