Received: by 10.213.65.68 with SMTP id h4csp2315639imn; Mon, 2 Apr 2018 05:27:10 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+5yNweckLH47keQjP1U5coWVZ2MLVk7vGGO4uadOSrVfUnQTM5wu3f0sape4U6r5PBJ3C6 X-Received: by 2002:a17:902:8c94:: with SMTP id t20-v6mr9670053plo.95.1522672030021; Mon, 02 Apr 2018 05:27:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522672029; cv=none; d=google.com; s=arc-20160816; b=AriVpzNNzqIMcJrsRt35nzZLLNOQKr2dafHPLunJoob321XvYp3IiFAjtO/bk43ngb Ed2f/DB0wFzCcdPlxVCIAq3gyYCAeoH7jXmqNC11POTgQ0t1nO3zbTWpBXzvNyGcU9pt 1NXAtpkYLUC1qYGZcy70QLCqE4PeVfGFuPm19YIyG4I5SEsfsClftAp2MIPwb7x6JpT+ ufxoQNojZ/Vmdtw5ZA5dzHVHSbEpj/cESYXDIdnbVxA3fDN2c4KCJCrurezQt3sHTjzA X4iP7C+UcO5k4XAe61dDJiR1//2TkLWWMMnZFBSZ6j6Za3+bmjr6LdF07L8m//l5pDar v73Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:to:from:arc-authentication-results; bh=42BcgaJnAkq+2rJ1rntz2JwK5cZiMbI/Af8WYX0NF08=; b=nkwX/b8qJQLFf36LWYA6aDXl3Z5gN79TWtP+K44aBruSksKlS5wxhmgOcB6GfoBuKt 1A6pyYTIKSB+0YUIpBf6BYR21ycJYjE1q3T+SALftgj4FN+NDnSDPKMhn/2FM+U7pkDJ FfWh6LfsCuSVoBQEji3aMXr6+L3jj3h/IKHNzz7lXF+ZQ5IE5PRUQa3hTHkqaTcH4/7M 0A0EPu84kE9aBNSyIKAunu9E0l1PmNQOaGjYMrAYhTbXmC9ahaOFuihNvRGy+fJyTc5Y PP2I1kjN3xKEj4osXJFmp40Dvsk1ZY/HespIyk4qO4aycyHEOixDNhxjMpfQZ3c/tIb6 f5vw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d64si174169pfa.384.2018.04.02.05.26.56; Mon, 02 Apr 2018 05:27:09 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752222AbeDBMZf (ORCPT + 99 others); Mon, 2 Apr 2018 08:25:35 -0400 Received: from szxga07-in.huawei.com ([45.249.212.35]:57450 "EHLO huawei.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1751315AbeDBMZG (ORCPT ); Mon, 2 Apr 2018 08:25:06 -0400 Received: from DGGEMS412-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 33F342E70BD80; Mon, 2 Apr 2018 20:24:59 +0800 (CST) Received: from linux.site (10.67.187.223) by DGGEMS412-HUB.china.huawei.com (10.3.19.212) with Microsoft SMTP Server id 14.3.361.1; Mon, 2 Apr 2018 20:24:53 +0800 From: Abbott Liu To: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , Subject: [PATCH v3 6/6] Enable KASan for arm Date: Mon, 2 Apr 2018 20:04:40 +0800 Message-ID: <20180402120440.31900-7-liuwenliang@huawei.com> X-Mailer: git-send-email 2.9.0 In-Reply-To: <20180402120440.31900-1-liuwenliang@huawei.com> References: <20180402120440.31900-1-liuwenliang@huawei.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.67.187.223] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Andrey Ryabinin This patch enable kernel address sanitizer for arm. Cc: Andrey Ryabinin Acked-by: Dmitry Vyukov Tested-by: Joel Stanley Tested-by: Florian Fainelli Tested-by: Abbott Liu Signed-off-by: Abbott Liu --- Documentation/dev-tools/kasan.rst | 2 +- arch/arm/Kconfig | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Documentation/dev-tools/kasan.rst b/Documentation/dev-tools/kasan.rst index f7a18f2..d92120d 100644 --- a/Documentation/dev-tools/kasan.rst +++ b/Documentation/dev-tools/kasan.rst @@ -12,7 +12,7 @@ KASAN uses compile-time instrumentation for checking every memory access, therefore you will need a GCC version 4.9.2 or later. GCC 5.0 or later is required for detection of out-of-bounds accesses to stack or global variables. -Currently KASAN is supported only for the x86_64 and arm64 architectures. +Currently KASAN is supported only for the x86_64, arm64 and arm architectures. Usage ----- diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 7e3d535..ac2287b 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -49,6 +49,7 @@ config ARM select HAVE_ARCH_BITREVERSE if (CPU_32v7M || CPU_32v7) && !CPU_32v6 select HAVE_ARCH_JUMP_LABEL if !XIP_KERNEL && !CPU_ENDIAN_BE32 && MMU select HAVE_ARCH_KGDB if !CPU_ENDIAN_BE32 && MMU + select HAVE_ARCH_KASAN if MMU select HAVE_ARCH_MMAP_RND_BITS if MMU select HAVE_ARCH_SECCOMP_FILTER if (AEABI && !OABI_COMPAT) select HAVE_ARCH_THREAD_STRUCT_WHITELIST -- 2.9.0