Messages in this thread |  | | Subject | Re: [PATCH v2 6/9] x86/kexec: set_[gi]dt() -> native_[gi]dt_invalidate() in machine_kexec_*.c | From | Andy Lutomirski <> | Date | Sat, 15 May 2021 08:30:21 -0700 |
| |
On 5/14/21 6:43 PM, H. Peter Anvin wrote: > From: "H. Peter Anvin (Intel)" <hpa@zytor.com> > > These files contain private set_gdt() functions which are only used to > invalid the gdt; machine_kexec_64.c also contains a set_idt() > function to invalidate the idt. > > phys_to_virt(0) *really* doesn't make any sense for creating an > invalid GDT. A NULL pointer (virtual 0) makes a lot more sense; > although neither will allow any actual memory reference, a NULL > pointer stands out more. > > Replace these calls with native_[gi]dt_invalidate(). > > Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com>
Acked-by: Andy Lutomirski <luto@kernel.org>
|  |