* [PATCH] powerpc: process.c: fix Kconfig typo @ 2016-10-05 5:57 Valentin Rothberg 2016-10-05 22:54 ` Cyril Bur 2016-10-27 11:41 ` Michael Ellerman 0 siblings, 2 replies; 9+ messages in thread From: Valentin Rothberg @ 2016-10-05 5:57 UTC (permalink / raw) To: mpe, cyrilbur; +Cc: linux-kernel, Valentin Rothberg s/ALIVEC/ALTIVEC/ Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com> --- arch/powerpc/kernel/process.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/kernel/process.c b/arch/powerpc/kernel/process.c index 9e7c10fe205f..ce6dc61b15b2 100644 --- a/arch/powerpc/kernel/process.c +++ b/arch/powerpc/kernel/process.c @@ -1012,7 +1012,7 @@ void restore_tm_state(struct pt_regs *regs) /* Ensure that restore_math() will restore */ if (msr_diff & MSR_FP) current->thread.load_fp = 1; -#ifdef CONFIG_ALIVEC +#ifdef CONFIG_ALTIVEC if (cpu_has_feature(CPU_FTR_ALTIVEC) && msr_diff & MSR_VEC) current->thread.load_vec = 1; #endif -- 2.9.3 ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH] powerpc: process.c: fix Kconfig typo 2016-10-05 5:57 [PATCH] powerpc: process.c: fix Kconfig typo Valentin Rothberg @ 2016-10-05 22:54 ` Cyril Bur 2016-10-26 5:52 ` Michael Ellerman 2016-10-27 11:41 ` Michael Ellerman 1 sibling, 1 reply; 9+ messages in thread From: Cyril Bur @ 2016-10-05 22:54 UTC (permalink / raw) To: Valentin Rothberg, mpe; +Cc: linux-kernel On Wed, 2016-10-05 at 07:57 +0200, Valentin Rothberg wrote: > s/ALIVEC/ALTIVEC/ > Oops, nice catch > Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com> Reviewed-by: Cyril Bur <cyrilbur@gmail.com> > --- > arch/powerpc/kernel/process.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/powerpc/kernel/process.c > b/arch/powerpc/kernel/process.c > index 9e7c10fe205f..ce6dc61b15b2 100644 > --- a/arch/powerpc/kernel/process.c > +++ b/arch/powerpc/kernel/process.c > @@ -1012,7 +1012,7 @@ void restore_tm_state(struct pt_regs *regs) > /* Ensure that restore_math() will restore */ > if (msr_diff & MSR_FP) > current->thread.load_fp = 1; > -#ifdef CONFIG_ALIVEC > +#ifdef CONFIG_ALTIVEC > if (cpu_has_feature(CPU_FTR_ALTIVEC) && msr_diff & MSR_VEC) > current->thread.load_vec = 1; > #endif ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] powerpc: process.c: fix Kconfig typo 2016-10-05 22:54 ` Cyril Bur @ 2016-10-26 5:52 ` Michael Ellerman 2016-10-26 6:25 ` Valentin Rothberg 2016-10-27 1:08 ` Cyril Bur 0 siblings, 2 replies; 9+ messages in thread From: Michael Ellerman @ 2016-10-26 5:52 UTC (permalink / raw) To: Cyril Bur, Valentin Rothberg; +Cc: linux-kernel, linuxppc-dev Cyril Bur <cyrilbur@gmail.com> writes: > On Wed, 2016-10-05 at 07:57 +0200, Valentin Rothberg wrote: >> s/ALIVEC/ALTIVEC/ >> > > Oops, nice catch > >> Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com> > > Reviewed-by: Cyril Bur <cyrilbur@gmail.com> How did we not notice? Sounds like we need a new selftest. Looks like this should have: Fixes: dc16b553c949 ("powerpc: Always restore FPU/VEC/VSX if hardware transactional memory in use") And I guess I need to start running checkkconfigsymbols.py on every commit. cheers ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] powerpc: process.c: fix Kconfig typo 2016-10-26 5:52 ` Michael Ellerman @ 2016-10-26 6:25 ` Valentin Rothberg 2016-10-26 10:40 ` Michael Ellerman 2016-10-27 1:08 ` Cyril Bur 1 sibling, 1 reply; 9+ messages in thread From: Valentin Rothberg @ 2016-10-26 6:25 UTC (permalink / raw) To: Michael Ellerman; +Cc: Cyril Bur, LKML, linuxppc-dev@lists.ozlabs.org On Wed, Oct 26, 2016 at 7:52 AM, Michael Ellerman <mpe@ellerman.id.au> wrote: > Cyril Bur <cyrilbur@gmail.com> writes: > >> On Wed, 2016-10-05 at 07:57 +0200, Valentin Rothberg wrote: >>> s/ALIVEC/ALTIVEC/ >>> >> >> Oops, nice catch >> >>> Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com> >> >> Reviewed-by: Cyril Bur <cyrilbur@gmail.com> > > How did we not notice? Sounds like we need a new selftest. > > Looks like this should have: > > Fixes: dc16b553c949 ("powerpc: Always restore FPU/VEC/VSX if hardware transactional memory in use") > > > And I guess I need to start running checkkconfigsymbols.py on every > commit. Happy to find a new user :-) You can also run the script on a range of commits via '--diff commitA..commitB', which can safe some time. Best regards, Valentin > cheers ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] powerpc: process.c: fix Kconfig typo 2016-10-26 6:25 ` Valentin Rothberg @ 2016-10-26 10:40 ` Michael Ellerman 2016-10-26 10:43 ` Valentin Rothberg 0 siblings, 1 reply; 9+ messages in thread From: Michael Ellerman @ 2016-10-26 10:40 UTC (permalink / raw) To: Valentin Rothberg; +Cc: Cyril Bur, LKML, linuxppc-dev@lists.ozlabs.org Valentin Rothberg <valentinrothberg@gmail.com> writes: > On Wed, Oct 26, 2016 at 7:52 AM, Michael Ellerman <mpe@ellerman.id.au> wrote: >> Cyril Bur <cyrilbur@gmail.com> writes: >> >>> On Wed, 2016-10-05 at 07:57 +0200, Valentin Rothberg wrote: >>>> s/ALIVEC/ALTIVEC/ >>>> >>> >>> Oops, nice catch >>> >>>> Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com> >>> >>> Reviewed-by: Cyril Bur <cyrilbur@gmail.com> >> >> How did we not notice? Sounds like we need a new selftest. >> >> Looks like this should have: >> >> Fixes: dc16b553c949 ("powerpc: Always restore FPU/VEC/VSX if hardware transactional memory in use") >> >> >> And I guess I need to start running checkkconfigsymbols.py on every >> commit. > > Happy to find a new user :-) You can also run the script on a range > of commits via '--diff commitA..commitB', which can safe some time. Yeah I just discovered that, very useful. But my instinct was to do: $ ./scripts/checkkconfigsymbols.py --diff HEAD^^^..HEAD Which didn't work, the regexp is a bit tight, fixed by: diff --git a/scripts/checkkconfigsymbols.py b/scripts/checkkconfigsymbols.py index a32e4da4c117..3820f00b066a 100755 --- a/scripts/checkkconfigsymbols.py +++ b/scripts/checkkconfigsymbols.py @@ -88,7 +88,7 @@ def parse_options(): if args.commit and args.diff: sys.exit("Please specify only one option at once.") - if args.diff and not re.match(r"^[\w\-\.]+\.\.[\w\-\.]+$", args.diff): + if args.diff and not re.match(r"^[\w\-\.\^]+\.\.[\w\-\.\^]+$", args.diff): sys.exit("Please specify valid input in the following format: " "\'commit1..commit2\'") cheers ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH] powerpc: process.c: fix Kconfig typo 2016-10-26 10:40 ` Michael Ellerman @ 2016-10-26 10:43 ` Valentin Rothberg 2016-10-27 0:11 ` Michael Ellerman 0 siblings, 1 reply; 9+ messages in thread From: Valentin Rothberg @ 2016-10-26 10:43 UTC (permalink / raw) To: Michael Ellerman; +Cc: Cyril Bur, LKML, linuxppc-dev@lists.ozlabs.org On Wed, Oct 26, 2016 at 12:40 PM, Michael Ellerman <mpe@ellerman.id.au> wrote: > Valentin Rothberg <valentinrothberg@gmail.com> writes: > >> On Wed, Oct 26, 2016 at 7:52 AM, Michael Ellerman <mpe@ellerman.id.au> wrote: >>> Cyril Bur <cyrilbur@gmail.com> writes: >>> >>>> On Wed, 2016-10-05 at 07:57 +0200, Valentin Rothberg wrote: >>>>> s/ALIVEC/ALTIVEC/ >>>>> >>>> >>>> Oops, nice catch >>>> >>>>> Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com> >>>> >>>> Reviewed-by: Cyril Bur <cyrilbur@gmail.com> >>> >>> How did we not notice? Sounds like we need a new selftest. >>> >>> Looks like this should have: >>> >>> Fixes: dc16b553c949 ("powerpc: Always restore FPU/VEC/VSX if hardware transactional memory in use") >>> >>> >>> And I guess I need to start running checkkconfigsymbols.py on every >>> commit. >> >> Happy to find a new user :-) You can also run the script on a range >> of commits via '--diff commitA..commitB', which can safe some time. > > Yeah I just discovered that, very useful. > > But my instinct was to do: > > $ ./scripts/checkkconfigsymbols.py --diff HEAD^^^..HEAD > > Which didn't work, the regexp is a bit tight, fixed by: > > diff --git a/scripts/checkkconfigsymbols.py b/scripts/checkkconfigsymbols.py > index a32e4da4c117..3820f00b066a 100755 > --- a/scripts/checkkconfigsymbols.py > +++ b/scripts/checkkconfigsymbols.py > @@ -88,7 +88,7 @@ def parse_options(): > if args.commit and args.diff: > sys.exit("Please specify only one option at once.") > > - if args.diff and not re.match(r"^[\w\-\.]+\.\.[\w\-\.]+$", args.diff): > + if args.diff and not re.match(r"^[\w\-\.\^]+\.\.[\w\-\.\^]+$", args.diff): > sys.exit("Please specify valid input in the following format: " > "\'commit1..commit2\'") Looks great. If you agree, I'll pick this up and send the patch to Greg (who takes patches for this script)? Thanks, Valentin ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] powerpc: process.c: fix Kconfig typo 2016-10-26 10:43 ` Valentin Rothberg @ 2016-10-27 0:11 ` Michael Ellerman 0 siblings, 0 replies; 9+ messages in thread From: Michael Ellerman @ 2016-10-27 0:11 UTC (permalink / raw) To: Valentin Rothberg; +Cc: Cyril Bur, LKML, linuxppc-dev@lists.ozlabs.org Valentin Rothberg <valentinrothberg@gmail.com> writes: > On Wed, Oct 26, 2016 at 12:40 PM, Michael Ellerman <mpe@ellerman.id.au> wrote: >> diff --git a/scripts/checkkconfigsymbols.py b/scripts/checkkconfigsymbols.py >> index a32e4da4c117..3820f00b066a 100755 >> --- a/scripts/checkkconfigsymbols.py >> +++ b/scripts/checkkconfigsymbols.py >> @@ -88,7 +88,7 @@ def parse_options(): >> if args.commit and args.diff: >> sys.exit("Please specify only one option at once.") >> >> - if args.diff and not re.match(r"^[\w\-\.]+\.\.[\w\-\.]+$", args.diff): >> + if args.diff and not re.match(r"^[\w\-\.\^]+\.\.[\w\-\.\^]+$", args.diff): >> sys.exit("Please specify valid input in the following format: " >> "\'commit1..commit2\'") > > Looks great. If you agree, I'll pick this up and send the patch to > Greg (who takes patches for this script)? That'd be great, thanks. cheers ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] powerpc: process.c: fix Kconfig typo 2016-10-26 5:52 ` Michael Ellerman 2016-10-26 6:25 ` Valentin Rothberg @ 2016-10-27 1:08 ` Cyril Bur 1 sibling, 0 replies; 9+ messages in thread From: Cyril Bur @ 2016-10-27 1:08 UTC (permalink / raw) To: Michael Ellerman, Valentin Rothberg; +Cc: linux-kernel, linuxppc-dev On Wed, 2016-10-26 at 16:52 +1100, Michael Ellerman wrote: > Cyril Bur <cyrilbur@gmail.com> writes: > > > On Wed, 2016-10-05 at 07:57 +0200, Valentin Rothberg wrote: > > > s/ALIVEC/ALTIVEC/ > > > > > > > Oops, nice catch > > > > > Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com> > > > > Reviewed-by: Cyril Bur <cyrilbur@gmail.com> > > How did we not notice? Sounds like we need a new selftest. > Indeed... Here is probably a good place to say why we didn't catch it and under what circumstances this will have a negative effect. If a thread performs and transaction with altivec and then gets preempted for whatever reason, this bug may cause the kernel to not reenable altivec when that thread runs again. This will result in an altivec unavailable fault, when these faults happen inside a user transaction the kernel has no choice but enable altivec and doom the transaction. The result is that transactions using altivec may get aborted more than they should. The difficulty in catching this with a selftest is my deliberate use of the word may above. Optimisations to avoid FPU/altivec/VSX faults mean that the kernel will always leave them on for 255 switches, this code prevents the kernel turning it off if it got to the 256th switch (and userspace was transactional)... Cyril > Looks like this should have: > > Fixes: dc16b553c949 ("powerpc: Always restore FPU/VEC/VSX if hardware > transactional memory in use") > > > And I guess I need to start running checkkconfigsymbols.py on every > commit. > > cheers ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] powerpc: process.c: fix Kconfig typo 2016-10-05 5:57 [PATCH] powerpc: process.c: fix Kconfig typo Valentin Rothberg 2016-10-05 22:54 ` Cyril Bur @ 2016-10-27 11:41 ` Michael Ellerman 1 sibling, 0 replies; 9+ messages in thread From: Michael Ellerman @ 2016-10-27 11:41 UTC (permalink / raw) To: Valentin Rothberg, cyrilbur; +Cc: linux-kernel, Valentin Rothberg Valentin Rothberg <valentinrothberg@gmail.com> writes: > s/ALIVEC/ALTIVEC/ > > Signed-off-by: Valentin Rothberg <valentinrothberg@gmail.com> Applied to powerpc fixes, thanks. https://git.kernel.org/powerpc/c/39715bf972ed4fee18fe5409609 cheers ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2016-10-27 14:29 UTC | newest] Thread overview: 9+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2016-10-05 5:57 [PATCH] powerpc: process.c: fix Kconfig typo Valentin Rothberg 2016-10-05 22:54 ` Cyril Bur 2016-10-26 5:52 ` Michael Ellerman 2016-10-26 6:25 ` Valentin Rothberg 2016-10-26 10:40 ` Michael Ellerman 2016-10-26 10:43 ` Valentin Rothberg 2016-10-27 0:11 ` Michael Ellerman 2016-10-27 1:08 ` Cyril Bur 2016-10-27 11:41 ` Michael Ellerman
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.