From patchwork Tue Aug 11 02:18:14 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrey Ryabinin X-Patchwork-Id: 6986761 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 4442EC05AC for ; Mon, 10 Aug 2015 22:25:15 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 780C1202AE for ; Mon, 10 Aug 2015 22:25:14 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A06172014A for ; Mon, 10 Aug 2015 22:25:13 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZOvTg-0004f1-6v; Mon, 10 Aug 2015 22:23:32 +0000 Received: from mail-lb0-x244.google.com ([2a00:1450:4010:c04::244]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1ZOvTT-0004Ls-5A for linux-arm-kernel@lists.infradead.org; Mon, 10 Aug 2015 22:23:21 +0000 Received: by lbcje9 with SMTP id je9so1677076lbc.2 for ; Mon, 10 Aug 2015 15:22:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=4+kXEZwGucGpDjGEiB3dGwFWOK58DcGd6PKAK1H90J4=; b=wrQQTRnUtrdv0oB/RDbhyqC+hmecHjQ9k/ramdhVMG6jdYv2BSYUOsSyIhrUdms/JV sDowbGFxgdI1hyfa+EyCdQQ0vOn/UHGycZ4uSaZUyOi2C7WOfLIyb8JJ/xsp+F3jyvpG qXcIY5VmQZpICKyZG+29/bsMiXe6bwt0DOZFRNTJtulKx2I5kGfGBTHZLVodKVU/VfOu fRKH5pyNFtxjpbVFL+8dyAefy9RzT11kl9f7tHe+AkR4BvYPd6YmwAyImQmukWc6BGqJ 9XJ6mXRk78FDjnWPvZdyu3IIVwT3f/ldoWvETvg/nfoByGmuIUdY2Pte0rLUxdvCBYsf auGA== X-Received: by 10.112.72.8 with SMTP id z8mr22893613lbu.24.1439245376281; Mon, 10 Aug 2015 15:22:56 -0700 (PDT) Received: from localhost.localdomain ([84.47.128.244]) by smtp.gmail.com with ESMTPSA id qh3sm1718704lbb.25.2015.08.10.15.22.54 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 10 Aug 2015 15:22:55 -0700 (PDT) From: Andrey Ryabinin To: Catalin Marinas , Will Deacon , linux-arm-kernel@lists.infradead.org Subject: [PATCH v5 1/6] x86/kasan: define KASAN_SHADOW_OFFSET per architecture Date: Tue, 11 Aug 2015 05:18:14 +0300 Message-Id: <1439259499-13913-2-git-send-email-ryabinin.a.a@gmail.com> X-Mailer: git-send-email 2.4.6 In-Reply-To: <1439259499-13913-1-git-send-email-ryabinin.a.a@gmail.com> References: <1439259499-13913-1-git-send-email-ryabinin.a.a@gmail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150810_152319_631612_93A6B49A X-CRM114-Status: GOOD ( 10.90 ) X-Spam-Score: 0.3 (/) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Yury , Alexey Klimov , Arnd Bergmann , linux-mm@kvack.org, Linus Walleij , x86@kernel.org, linux-kernel@vger.kernel.org, David Keitel , Andrey Ryabinin , Alexander Potapenko , "Aneesh Kumar K.V" , "H. Peter Anvin" , Andrew Morton , Ingo Molnar , Thomas Gleixner , Dmitry Vyukov MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00, DATE_IN_FUTURE_03_06, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,FREEMAIL_FROM,RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=no version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Current definition of KASAN_SHADOW_OFFSET in include/linux/kasan.h will not work for upcomming arm64, so move it to the arch header. Signed-off-by: Andrey Ryabinin --- arch/x86/include/asm/kasan.h | 3 +++ include/linux/kasan.h | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/x86/include/asm/kasan.h b/arch/x86/include/asm/kasan.h index 74a2a8d..1410b56 100644 --- a/arch/x86/include/asm/kasan.h +++ b/arch/x86/include/asm/kasan.h @@ -1,6 +1,9 @@ #ifndef _ASM_X86_KASAN_H #define _ASM_X86_KASAN_H +#include +#define KASAN_SHADOW_OFFSET _AC(CONFIG_KASAN_SHADOW_OFFSET, UL) + /* * Compiler uses shadow offset assuming that addresses start * from 0. Kernel addresses don't start from 0, so shadow diff --git a/include/linux/kasan.h b/include/linux/kasan.h index 5486d77..6fb1c7d 100644 --- a/include/linux/kasan.h +++ b/include/linux/kasan.h @@ -10,7 +10,6 @@ struct vm_struct; #ifdef CONFIG_KASAN #define KASAN_SHADOW_SCALE_SHIFT 3 -#define KASAN_SHADOW_OFFSET _AC(CONFIG_KASAN_SHADOW_OFFSET, UL) #include #include