mini-os: Patch in sched.h for ia64
PATCH 1/1 mini-os: Patch in sched.h for ia64
Sorry, I forgot to append the patch.
Quoted 7 lines
Hi Gregor,
for the ia64 port I added a line in
mini-os/include/sched.h. Thanks.Dietmar.
# HG changeset patch
# User [email protected]
# Date 1161260065 -7200
# Node ID bceae1ee499a3ce613d825165c825999f373bf73 # Parent 8e645cf5a78377a9eb1fae0bb7a279cdb57b85d3 Added a line for the ia64 port to get_current().
extras/mini-os/include/sched.h +2 -0
@@ -25,6 +25,8 @@ static inline struct thread* get_currentstruct thread **current;#ifdef __i386__ __asm__("andl %%esp,%0; " :"=r" (current) :"r" (~8191UL )); +#elif __ia64__ + __asm ("mov %0=r13" :"=r" (current));#else __asm__("andq %%rsp,%0; " :"=r" (current) :"r" (~8191UL ));#endif
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Am Donnerstag, 19. Oktober 2006 14:31 schrieb Dietmar Hahn:
Quoted 8 lines
Sorry, I forgot to append the patch.
Quoted 6 lines
Hi Gregor,
for the ia64 port I added a line in
mini-os/include/sched.h. Thanks.Dietmar.
Hi Gregor,
I reworked the sched.h changes and come up with a new patch. This patch introduces the new file include/x86/arch_sched.h for the x86 specific parts.
Please have a look at the patch.
Thanks.
Dietmar
# HG changeset patch
# User [email protected]
# Date 1161349699 -7200
# Node ID a0b9dba41e690bfa237e65405f0efedbfa9776b1
# Parent bceae1ee499a3ce613d825165c825999f373bf73
The x86 special parts are separated in include/sched.h and moved to the new file include/x86/arch_sched.h.
extras/mini-os/include/sched.h +5 -12
@@ -2,13 +2,18 @@#define __SCHED_H__#include <list.h> +#include <arch_sched.h> struct thread {char *name;char *stack; +#if !defined(__ia64__)unsigned long sp;/* Stack pointer */ unsigned long ip;/* Instruction pointer */ +#else /* !defined(__ia64__) */ +thread_regs_t regs; +#endif /* !defined(__ia64__) */ struct list_head thread_list;u32 flags; };
@@ -20,18 +25,6 @@ struct thread* create_thread(char *name,struct thread *create_thread (char *name,void (*function)(void *),void *data);void schedule (void ); -static inline struct thread *get_current (void ) -{ -struct thread **current; -#ifdef __i386__ - __asm__("andl %%esp,%0; " :"=r" (current) :"r" (~8191UL )); -#elif __ia64__ - __asm ("mov %0=r13" :"=r" (current)); -#else - __asm__("andq %%rsp,%0; " :"=r" (current) :"r" (~8191UL )); -#endif -return *current; -}#define current get_current()
extras/mini-os/include/x86/arch_sched.h new file +16 -0
@@ -0,0 +1,16 @@ +#ifndef __ARCH_SCHED_H__ +#define __ARCH_SCHED_H__ + + +static inline struct thread *get_current (void ) +{ +struct thread **current; +#ifdef __i386__ + __asm__("andl %%esp,%0; " :"=r" (current) :"r" (~8191UL )); +#else + __asm__("andq %%rsp,%0; " :"=r" (current) :"r" (~8191UL )); +#endif +return *current; +} + +#endif /* __ARCH_SCHED_H__ */
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
mini-os: No reaction on patches
Hi,
I sent some patches to mini-os for the port to ia64 but I got no answers. Is something complete wrong with my patches (and if yes, can anybody enlighten me) or is there no interest?
Thanks.
Dietmar
Re: mini-os: No reaction on patches
Quoted 3 lines · Dietmar Hahn
I sent some patches to mini-os for the port to ia64 but I got no answers. Is something complete wrong with my patches (and if yes, can anybody enlighten me) or is there no interest?
If Gregor acks them then they'll get checked in.
-- Keir