Message ID | ebef6425f4468d063e2f09c1b62ccbb2236b71d3.1606161801.git.andreyknvl@google.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <SRS0=Sdul=E6=lists.infradead.org=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@kernel.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4C17FC56201 for <linux-arm-kernel@archiver.kernel.org>; Tue, 24 Nov 2020 13:50:11 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C0AEF20888 for <linux-arm-kernel@archiver.kernel.org>; Tue, 24 Nov 2020 13:50:10 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="RgIPhX0g"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=google.com header.i=@google.com header.b="vkxW6RZN" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C0AEF20888 Authentication-Results: mail.kernel.org; dmarc=fail (p=reject dis=none) header.from=google.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:To:From:Subject:References:Mime-Version:Message-Id: In-Reply-To:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=Y+xWwac4QvlB3iqDJWJ4x0ZC/ghOvP2AVuSND0CRevw=; b=RgIPhX0gBopHC1v+EmwlhFb+h IMHJYOmAnZHYZDn9vNC5m3982PJvubc0W6oL+BFMIkNT9hBjIARbmzFLzhSAcCB/uqI4uqXcpe7nj FNNTb6clQfupDA3EWRiw3Pp0kdR9xjbNt7/3o4Q2m5QbmhpyKsJ7DyWMqX8kaZUgEevTrIJT6/2ZZ euSoaxzgMVsB0r2qKblBIV7LKAPIs0KHy3h/zgyPpnrSUvKCRU0Iz8wtklTrpRS00cM0NJHENf/39 ErccXyQBxLztmRN5VTxlhSlU/hb9FydmlD9nLdqYZfOgr9QaiG1po0nceITSA1BnLcPbRew08kP/j g9VUpSFxg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1khYgh-0005RA-RB; Tue, 24 Nov 2020 13:48:55 +0000 Received: from mail-qk1-x749.google.com ([2607:f8b0:4864:20::749]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1khI9i-0008Nf-64 for linux-arm-kernel@lists.infradead.org; Mon, 23 Nov 2020 20:09:58 +0000 Received: by mail-qk1-x749.google.com with SMTP id l23so5158957qkk.3 for <linux-arm-kernel@lists.infradead.org>; Mon, 23 Nov 2020 12:09:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=sender:date:in-reply-to:message-id:mime-version:references:subject :from:to:cc; bh=JqOdOudIAs6fCsGoOMJBOXRAJ4nBM51Q9IuLvpe9X7o=; b=vkxW6RZNeiKt3uDXc9cHATR3yMNcOPJqStPkUehbC/zuvJcXUjcLUlqnCHiChMMXOM c71zmtYoiGl5xy8iIG7mT1M1VQucOQvK1LAC5ywznp2VK69TDjuYjE4jSsbKaRpiUm8y sM6M/LJaplFV13/x/OJvNqf/icVGsPo2tG/Lf+RwL6jkzxr7ofjAqqsanPWI677zjgYP lbRjaTr3RXJWAWEbSbifTQIYdzFOZ9607IvrKeoWsbPXMOJQyh/MOW++TV1RAnTyiBD0 rGAzeg91KocpdVKgKspqM96WumykTFfRxbnrlu4hk2QablCk2YfVGGBB8TQ2fNZAYkRT bJOw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=JqOdOudIAs6fCsGoOMJBOXRAJ4nBM51Q9IuLvpe9X7o=; b=RdI+ubyOPsbc1JUEfhH2flhvesl1ZNfxR1g1c0CgJuYcQZQD5FR1rzskff0ULlmPip Nd0f8SWL+xIOcpOgIyNamqayn+IjZomVyWLeS6DunXgE5CuN/1dK56K42vGNCNUWTTEI aJ6A/hMZ94E+3KaHBhxlwUdgDYGYNw5fSyDwjRovyw48KV9z9tECdUVy+MoTObPFYYzj t/+yIqeHTsgM+N5Xt/PkiTk8muMXpX13O6+0EEc1Mkf6511GpijXLaWHoSuTR1OV4MGT rVtVVeS4eNoXq5SaHXHssUjxjbcZFmiHsS4UJ4dBMNpXVNR+jZsggLM3haVdfwMztqDr ZVkg== X-Gm-Message-State: AOAM530kzsm/vACl4mVPNVe/UjXIOr3QuOwKnRtEXlSxoQq7pUIyaNC/ rKPaTGHZGKPE4JhvZ+Hx6cPO+V95xMARkJ1n X-Google-Smtp-Source: ABdhPJw73/jwZg0RlewlvU4441kNk0gTp+b0T2ipYrKP6rHNENxFPnemmxMhgs3u5M7bN/vqoeTq/VUwN6Xwbz1I X-Received: from andreyknvl3.muc.corp.google.com ([2a00:79e0:15:13:7220:84ff:fe09:7e9d]) (user=andreyknvl job=sendgmr) by 2002:a05:6214:a8f:: with SMTP id ev15mr1201051qvb.20.1606162180614; Mon, 23 Nov 2020 12:09:40 -0800 (PST) Date: Mon, 23 Nov 2020 21:07:55 +0100 In-Reply-To: <cover.1606161801.git.andreyknvl@google.com> Message-Id: <ebef6425f4468d063e2f09c1b62ccbb2236b71d3.1606161801.git.andreyknvl@google.com> Mime-Version: 1.0 References: <cover.1606161801.git.andreyknvl@google.com> X-Mailer: git-send-email 2.29.2.454.gaff20da3a2-goog Subject: [PATCH mm v11 31/42] kasan, mm: untag page address in free_reserved_area From: Andrey Konovalov <andreyknvl@google.com> To: Andrew Morton <akpm@linux-foundation.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201123_150946_356857_4E01A5A3 X-CRM114-Status: GOOD ( 12.87 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: <linux-arm-kernel.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-arm-kernel/> List-Post: <mailto:linux-arm-kernel@lists.infradead.org> List-Help: <mailto:linux-arm-kernel-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=subscribe> Cc: linux-arm-kernel@lists.infradead.org, Marco Elver <elver@google.com>, Catalin Marinas <catalin.marinas@arm.com>, Kevin Brodsky <kevin.brodsky@arm.com>, Will Deacon <will.deacon@arm.com>, Branislav Rankov <Branislav.Rankov@arm.com>, kasan-dev@googlegroups.com, linux-kernel@vger.kernel.org, linux-mm@kvack.org, Alexander Potapenko <glider@google.com>, Evgenii Stepanov <eugenis@google.com>, Andrey Konovalov <andreyknvl@google.com>, Andrey Ryabinin <aryabinin@virtuozzo.com>, Vincenzo Frascino <vincenzo.frascino@arm.com>, Dmitry Vyukov <dvyukov@google.com> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org> Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org |
Series |
kasan: add hardware tag-based mode for arm64
|
expand
|
diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 42c32e8a9c5d..236aa4b6b2cc 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -7659,6 +7659,11 @@ unsigned long free_reserved_area(void *start, void *end, int poison, const char * alias for the memset(). */ direct_map_addr = page_address(page); + /* + * Perform a kasan-unchecked memset() since this memory + * has not been initialized. + */ + direct_map_addr = kasan_reset_tag(direct_map_addr); if ((unsigned int)poison <= 0xFF) memset(direct_map_addr, poison, PAGE_SIZE);