summaryrefslogtreecommitdiff
path: root/mausezahn/Makefile
AgeCommit message (Expand)AuthorFilesLines
2016-09-21mz: Check device argument by ifindex instead of name prefixVadim Kochan1-0/+4
2015-04-21netsniff-ng: Delete rfmon mac80211 device in case of panicVadim Kochan1-0/+2
2014-04-22conf: Use configuration file path from Makefile instead of hardcoded pathsTobias Klauser1-1/+0
2013-07-30build: reduce Extra contents to bare minimumDaniel Borkmann1-0/+2
2013-07-11build: refactor tool specific flags into <tool>/MakefileDaniel Borkmann1-0/+5
2013-06-04xutils: eliminate xutils, move rest to epoll2Daniel Borkmann1-3/+1
2013-06-04sock: add socket management functionsDaniel Borkmann1-0/+1
2013-06-04xutils: break out string handling and lockingDaniel Borkmann1-0/+1
2013-05-13staging: add mausezahn staging directoryDaniel Borkmann1-0/+66
st bits of the image kernel's memory contents to the page frames occupied by them previoulsy doesn't use the kernel text mapping, because it runs from a special page covered by the identity mapping set up for that code from scratch. Hence, the kernel text mapping is only needed before that code starts to run and then it will only be used just for the final jump to the image kernel's entry point. Accordingly, the temporary page tables set up in swsusp_arch_resume() on x86-64 need to contain the kernel text mapping too. That mapping is only going to be used for the final jump to the image kernel, so it only needs to cover the image kernel's entry point, because the first thing the image kernel does after getting control back is to switch over to its own original page tables. Moreover, the virtual address of the image kernel's entry point in that mapping has to be the same as the one mapped by the image kernel's page tables. With that in mind, modify the x86-64's arch_hibernation_header_save() and arch_hibernation_header_restore() routines to pass the physical address of the image kernel's entry point (in addition to its virtual address) to the boot kernel (a small piece of assembly code involved in passing the entry point's virtual address to the image kernel is not necessary any more after that, so drop it). Update RESTORE_MAGIC too to reflect the image header format change. Next, in set_up_temporary_mappings(), use the physical and virtual addresses of the image kernel's entry point passed in the image header to set up a minimum kernel text mapping (using memory pages that won't be overwritten by the image kernel's memory contents) that will map those addresses to each other as appropriate. This makes the concern about the possible corruption of the original boot kernel text mapping go away and if the the minimum kernel text mapping used for the final jump marks the image kernel's entry point memory as executable, the jump to it is guaraneed to succeed. Fixes: ab76f7b4ab23 (x86/mm: Set NX on gap between __ex_table and rodata) Link: http://marc.info/?l=linux-pm&m=146372852823760&w=2 Reported-by: Logan Gunthorpe <logang@deltatee.com> Reported-and-tested-by: Borislav Petkov <bp@suse.de> Tested-by: Kees Cook <keescook@chromium.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'Documentation')