diff options
author | Flavio Cruz <flaviocruz@gmail.com> | 2016-01-02 18:38:31 +0100 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2016-01-02 18:48:57 +0100 |
commit | 05e6878c8767cf7006675d5e5a646b2f74aa88c7 (patch) | |
tree | 3cba4a57d98573761d4538f6a24f1be1c2b2c197 /pfinet/linux-src/include/linux/sched.h | |
parent | 5714421bb1d066abebc7e993bdf06e655b879b3a (diff) | |
download | hurd-05e6878c8767cf7006675d5e5a646b2f74aa88c7.tar.gz hurd-05e6878c8767cf7006675d5e5a646b2f74aa88c7.tar.bz2 hurd-05e6878c8767cf7006675d5e5a646b2f74aa88c7.zip |
allow pfinet to link using -O0
This fixes a long list of undefined references when compiling with -O0
by using static instead of extern in header files.
Diffstat (limited to 'pfinet/linux-src/include/linux/sched.h')
-rw-r--r-- | pfinet/linux-src/include/linux/sched.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/pfinet/linux-src/include/linux/sched.h b/pfinet/linux-src/include/linux/sched.h index d983c17e..c0e54d86 100644 --- a/pfinet/linux-src/include/linux/sched.h +++ b/pfinet/linux-src/include/linux/sched.h @@ -410,7 +410,7 @@ extern struct task_struct *task[NR_TASKS]; extern struct task_struct **tarray_freelist; extern spinlock_t taskslot_lock; -extern __inline__ void add_free_taskslot(struct task_struct **t) +static __inline__ void add_free_taskslot(struct task_struct **t) { spin_lock(&taskslot_lock); *t = (struct task_struct *) tarray_freelist; @@ -418,7 +418,7 @@ extern __inline__ void add_free_taskslot(struct task_struct **t) spin_unlock(&taskslot_lock); } -extern __inline__ struct task_struct **get_free_taskslot(void) +static __inline__ struct task_struct **get_free_taskslot(void) { struct task_struct **tslot; @@ -436,7 +436,7 @@ extern struct task_struct *pidhash[PIDHASH_SZ]; #define pid_hashfn(x) ((((x) >> 8) ^ (x)) & (PIDHASH_SZ - 1)) -extern __inline__ void hash_pid(struct task_struct *p) +static __inline__ void hash_pid(struct task_struct *p) { struct task_struct **htable = &pidhash[pid_hashfn(p->pid)]; @@ -446,14 +446,14 @@ extern __inline__ void hash_pid(struct task_struct *p) p->pidhash_pprev = htable; } -extern __inline__ void unhash_pid(struct task_struct *p) +static __inline__ void unhash_pid(struct task_struct *p) { if(p->pidhash_next) p->pidhash_next->pidhash_pprev = p->pidhash_pprev; *p->pidhash_pprev = p->pidhash_next; } -extern __inline__ struct task_struct *find_task_by_pid(int pid) +static __inline__ struct task_struct *find_task_by_pid(int pid) { struct task_struct *p, **htable = &pidhash[pid_hashfn(pid)]; |