lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180529133615.26889-1-nixiaoming@huawei.com>
Date:   Tue, 29 May 2018 21:36:15 +0800
From:   nixiaoming <nixiaoming@...wei.com>
To:     <catalin.marinas@....com>, <will.deacon@....com>,
        <ard.biesheuvel@...aro.org>, <marc.zyngier@....com>,
        <james.morse@....com>, <kristina.martsenko@....com>,
        <steve.capper@....com>, <tglx@...utronix.de>, <mingo@...hat.com>,
        <hpa@...or.com>, <akpm@...ux-foundation.org>, <vbabka@...e.cz>,
        <mhocko@...e.com>, <dave.hansen@...ux.intel.com>,
        <dan.j.williams@...el.com>, <kirill.shutemov@...ux.intel.com>,
        <zhang.jia@...ux.alibaba.com>, <schwidefsky@...ibm.com>,
        <heiko.carstens@...ibm.com>, <gregkh@...uxfoundation.org>
CC:     <nixiaoming@...wei.com>, <linux-kernel@...r.kernel.org>,
        <linux-arm-kernel@...ts.infradead.org>, <x86@...nel.org>,
        <linux-s390@...r.kernel.org>
Subject: [PATCH 1/3] arm64:add missing CONFIG_STRICT_KERNEL_RWX for mark_rodata_ro

mark_rodata_ro is only called by the function mark_readonly when
CONFIG_STRICT_KERNEL_RWX=y,
if CONFIG_STRICT_KERNEL_RWX is not set
a compile warning may be triggered: unused function

Signed-off-by: nixiaoming <nixiaoming@...wei.com>
---
 arch/arm64/mm/mmu.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm64/mm/mmu.c b/arch/arm64/mm/mmu.c
index 2dbb2c9..849f326 100644
--- a/arch/arm64/mm/mmu.c
+++ b/arch/arm64/mm/mmu.c
@@ -491,6 +491,7 @@ static void __init map_mem(pgd_t *pgdp)
 #endif
 }
 
+#ifdef CONFIG_STRICT_KERNEL_RWX
 void mark_rodata_ro(void)
 {
 	unsigned long section_size;
@@ -505,6 +506,7 @@ void mark_rodata_ro(void)
 
 	debug_checkwx();
 }
+#endif
 
 static void __init map_kernel_segment(pgd_t *pgdp, void *va_start, void *va_end,
 				      pgprot_t prot, struct vm_struct *vma,
-- 
2.10.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ