2ebe088b73
To avoid having mappings that are writable and executable at the same time, split the init region into a .init.text region that is mapped read-only, and a .init.data region that is mapped non-executable. This is possible now that the alternative patching occurs via the linear mapping, and the linear alias of the init region is always mapped writable (but never executable). Since the alternatives descriptions themselves are read-only data, move those into the .init.text region. Reviewed-by: Laura Abbott <labbott@redhat.com> Reviewed-by: Mark Rutland <mark.rutland@arm.com> Tested-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
32 lines
1.3 KiB
C
32 lines
1.3 KiB
C
/*
|
|
* Copyright (C) 2016 ARM Limited
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License version 2 as
|
|
* published by the Free Software Foundation.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
*/
|
|
#ifndef __ASM_SECTIONS_H
|
|
#define __ASM_SECTIONS_H
|
|
|
|
#include <asm-generic/sections.h>
|
|
|
|
extern char __alt_instructions[], __alt_instructions_end[];
|
|
extern char __exception_text_start[], __exception_text_end[];
|
|
extern char __hibernate_exit_text_start[], __hibernate_exit_text_end[];
|
|
extern char __hyp_idmap_text_start[], __hyp_idmap_text_end[];
|
|
extern char __hyp_text_start[], __hyp_text_end[];
|
|
extern char __idmap_text_start[], __idmap_text_end[];
|
|
extern char __initdata_begin[], __initdata_end[];
|
|
extern char __inittext_begin[], __inittext_end[];
|
|
extern char __irqentry_text_start[], __irqentry_text_end[];
|
|
extern char __mmuoff_data_start[], __mmuoff_data_end[];
|
|
|
|
#endif /* __ASM_SECTIONS_H */
|