Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1651750 > unrolled thread
| Started by | Ricardo Neri <ricardo.neri-calderon@linux.intel.com> |
|---|---|
| First post | 2017-05-27 06:20 +0200 |
| Last post | 2017-06-01 05:10 +0200 |
| Articles | 3 — 2 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH v7 02/26] x86/mm: Relocate page fault error codes to traps.h Ricardo Neri <ricardo.neri-calderon@linux.intel.com> - 2017-05-27 06:20 +0200
Re: [PATCH v7 02/26] x86/mm: Relocate page fault error codes to traps.h Borislav Petkov <bp@suse.de> - 2017-05-27 12:20 +0200
Re: [PATCH v7 02/26] x86/mm: Relocate page fault error codes to traps.h Ricardo Neri <ricardo.neri-calderon@linux.intel.com> - 2017-06-01 05:10 +0200
| From | Ricardo Neri <ricardo.neri-calderon@linux.intel.com> |
|---|---|
| Date | 2017-05-27 06:20 +0200 |
| Subject | Re: [PATCH v7 02/26] x86/mm: Relocate page fault error codes to traps.h |
| Message-ID | <tLBmO-6LG-15@gated-at.bofh.it> |
On Sun, 2017-05-21 at 16:23 +0200, Borislav Petkov wrote:
> On Fri, May 05, 2017 at 11:17:00AM -0700, Ricardo Neri wrote:
> > Up to this point, only fault.c used the definitions of the page fault error
> > codes. Thus, it made sense to keep them within such file. Other portions of
> > code might be interested in those definitions too. For instance, the User-
> > Mode Instruction Prevention emulation code will use such definitions to
> > emulate a page fault when it is unable to successfully copy the results
> > of the emulated instructions to user space.
> >
> > While relocating the error code enumeration, the prefix X86_ is used to
> > make it consistent with the rest of the definitions in traps.h. Of course,
> > code using the enumeration had to be updated as well. No functional changes
> > were performed.
> >
> > Cc: Thomas Gleixner <tglx@linutronix.de>
> > Cc: Ingo Molnar <mingo@redhat.com>
> > Cc: "H. Peter Anvin" <hpa@zytor.com>
> > Cc: Andy Lutomirski <luto@kernel.org>
> > Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>
> > Cc: Josh Poimboeuf <jpoimboe@redhat.com>
> > Cc: Dave Hansen <dave.hansen@linux.intel.com>
> > Cc: Paul Gortmaker <paul.gortmaker@windriver.com>
> > Cc: x86@kernel.org
> > Reviewed-by: Andy Lutomirski <luto@kernel.org>
> > Signed-off-by: Ricardo Neri <ricardo.neri-calderon@linux.intel.com>
> > ---
> > arch/x86/include/asm/traps.h | 18 +++++++++
> > arch/x86/mm/fault.c | 88 +++++++++++++++++---------------------------
> > 2 files changed, 52 insertions(+), 54 deletions(-)
>
> ...
>
> > @@ -1382,7 +1362,7 @@ __do_page_fault(struct pt_regs *regs, unsigned long error_code,
> > * space check, thus avoiding the deadlock:
> > */
> > if (unlikely(!down_read_trylock(&mm->mmap_sem))) {
> > - if ((error_code & PF_USER) == 0 &&
> > + if ((error_code & X86_PF_USER) == 0 &&
>
> if (!(error_code & X86_PF_USER))
This change was initially intended to only rename the error codes,
without functional changes. Would making change be considered a change
in functionality? The behavior would be preserved, though.
Thanks and BR,
Ricardo
>
> With that fixed:
>
> Reviewed-by: Borislav Petkov <bp@suse.de>
Thank you for your review!
BR,
Ricardo
>
> --
> Regards/Gruss,
> Boris.
>
> SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg)
[toc] | [next] | [standalone]
| From | Borislav Petkov <bp@suse.de> |
|---|---|
| Date | 2017-05-27 12:20 +0200 |
| Message-ID | <tLGZc-1Sj-13@gated-at.bofh.it> |
| In reply to | #1651750 |
On Fri, May 26, 2017 at 08:40:26PM -0700, Ricardo Neri wrote:
> This change was initially intended to only rename the error codes,
> without functional changes. Would making change be considered a change
> in functionality?
How?
The before-and-after asm should be the identical.
--
Regards/Gruss,
Boris.
SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg)
--
[toc] | [prev] | [next] | [standalone]
| From | Ricardo Neri <ricardo.neri-calderon@linux.intel.com> |
|---|---|
| Date | 2017-06-01 05:10 +0200 |
| Message-ID | <tNoEO-5s8-7@gated-at.bofh.it> |
| In reply to | #1651836 |
On Sat, 2017-05-27 at 12:13 +0200, Borislav Petkov wrote: > On Fri, May 26, 2017 at 08:40:26PM -0700, Ricardo Neri wrote: > > This change was initially intended to only rename the error codes, > > without functional changes. Would making change be considered a > change > > in functionality? > > How? > > The before-and-after asm should be the identical. Yes but it reads differently. I just wanted to double check. I will make this change, which keeps functionality but is written differently. Thanks and BR, Ricardo
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web