Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1500622
| From | Mark Rutland <mark.rutland@arm.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 2/3] sched/preempt: include asm/current.h |
| Date | 2016-10-14 01:30 +0200 |
| Message-ID | <srXBL-1Hs-15@gated-at.bofh.it> (permalink) |
| References | <srNCp-3zR-19@gated-at.bofh.it> <srNVM-3VP-11@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Hi, On Thu, Oct 13, 2016 at 01:57:11PM +0200, Heiko Carstens wrote: > The generic preempt code needs to include <asm/current.h>. Otherwise > compilation fails if THREAD_INFO_IN_TASK is selected and the generic > preempt code is used: > > ./include/linux/thread_info.h:17:54: error: 'current' undeclared (first use in this function) > #define current_thread_info() ((struct thread_info *)current) I don't think this is the right fix. Users of current_thread_info() should only have to include <linux/thread_info.h>, as <asm-generic/preempt.h> already does. I have a patch [1] which has <linux/thread_info.h> include <asm/current.h> the THREAD_INFO_IN_TASK case (while avoiding circular includes over <asm/current.h> and <asm/thread_info.h> in the !THREAD_INFO_IN_TASK case). I was planning on posting an updated series with that come -rc1. Thanks, Mark. [1] http://lists.infradead.org/pipermail/linux-arm-kernel/2016-September/457243.html > > Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> > --- > include/asm-generic/preempt.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/include/asm-generic/preempt.h b/include/asm-generic/preempt.h > index c1cde3577551..66fcd6cd7fc6 100644 > --- a/include/asm-generic/preempt.h > +++ b/include/asm-generic/preempt.h > @@ -2,6 +2,7 @@ > #define __ASM_PREEMPT_H > > #include <linux/thread_info.h> > +#include <asm/current.h> > > #define PREEMPT_ENABLED (0) > > -- > 2.8.4 >
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 0/3] THREAD_INFO_IN_TASK_STRUCT vs generic preemption code Heiko Carstens <heiko.carstens@de.ibm.com> - 2016-10-13 14:50 +0200
[PATCH 1/3] sched/core,x86: make struct thread_info arch specific again Heiko Carstens <heiko.carstens@de.ibm.com> - 2016-10-13 15:10 +0200
Re: [PATCH 1/3] sched/core,x86: make struct thread_info arch specific again Mark Rutland <mark.rutland@arm.com> - 2016-10-14 01:50 +0200
Re: [PATCH 1/3] sched/core,x86: make struct thread_info arch specific again Andy Lutomirski <luto@amacapital.net> - 2016-10-14 02:00 +0200
[PATCH 2/3] sched/preempt: include asm/current.h Heiko Carstens <heiko.carstens@de.ibm.com> - 2016-10-13 15:10 +0200
Re: [PATCH 2/3] sched/preempt: include asm/current.h Mark Rutland <mark.rutland@arm.com> - 2016-10-14 01:30 +0200
Re: [PATCH 2/3] sched/preempt: include asm/current.h Heiko Carstens <heiko.carstens@de.ibm.com> - 2016-10-14 10:20 +0200
[PATCH] thread_info: include <current.h> for THREAD_INFO_IN_TASK (WAS: [PATCH 2/3] sched/preempt: include asm/current.h) Mark Rutland <mark.rutland@arm.com> - 2016-10-14 12:50 +0200
Re: [PATCH] thread_info: include <current.h> for THREAD_INFO_IN_TASK (WAS: [PATCH 2/3] sched/preempt: include asm/current.h) Mark Rutland <mark.rutland@arm.com> - 2016-10-17 16:50 +0200
Re: [PATCH] thread_info: include <current.h> for THREAD_INFO_IN_TASK (WAS: [PATCH 2/3] sched/preempt: include asm/current.h) Mark Rutland <mark.rutland@arm.com> - 2016-10-17 19:40 +0200
Re: [PATCH] thread_info: include <current.h> for THREAD_INFO_IN_TASK (WAS: [PATCH 2/3] sched/preempt: include asm/current.h) Heiko Carstens <heiko.carstens@de.ibm.com> - 2016-10-18 12:40 +0200
[PATCH 3/3] s390: move thread_info into task_struct Heiko Carstens <heiko.carstens@de.ibm.com> - 2016-10-13 22:10 +0200
Re: [PATCH 0/3] THREAD_INFO_IN_TASK_STRUCT vs generic preemption code Andy Lutomirski <luto@amacapital.net> - 2016-10-14 00:10 +0200
csiph-web