Message ID | ece9cd2cca38dd3797c6cd1756e30a2e40b0d451.1612538932.git.andreyknvl@google.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <SRS0=eMXW=HH=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=-17.1 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 EF141C433E0 for <linux-arm-kernel@archiver.kernel.org>; Fri, 5 Feb 2021 15:41:13 +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 771F7650F2 for <linux-arm-kernel@archiver.kernel.org>; Fri, 5 Feb 2021 15:41:13 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 771F7650F2 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=2pTM4Abs60f8Xohq1WuYazGkHj0xpztWcE925au1Huw=; b=pHxdr0HdyLeGxMlbgLTjDg2G+ VtFL0FAls5HhYmT5vAERcScZx5k5bOMOlfPS/w8oUCGbPEx8450xPQhSqIScTTfIYQrBmRETY21f4 wYMZqscythfE+PgSp3DpV3uMYBoZ890ZcjA5narmjY5AZmj4n3dYQjZyWd2dwuA+8gN7vXC2ilbE9 v/5tPwLMpTo1MH3mMa0eawakqizLtEP5T2kFKFL2yX1f3ppehcOHswHgBZvVo8vHsJCfqYplHjojT Wbn4MmFS1AQDPIC3PQEKrBdwMPIg73QpkBICpxeZWo5sCIfcQgvXld6gl4JhdvMvF/GZu65p04cYD YzygyG3Dg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1l83DB-0007xX-Bw; Fri, 05 Feb 2021 15:39:58 +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 1l83Cl-0007lJ-C2 for linux-arm-kernel@lists.infradead.org; Fri, 05 Feb 2021 15:39:33 +0000 Received: by mail-qk1-x749.google.com with SMTP id o16so6133690qkj.15 for <linux-arm-kernel@lists.infradead.org>; Fri, 05 Feb 2021 07:39:28 -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=p2PHZd2SW9nz4o7+ZB1C3vkb9xhx8DH7M49Qc2p69KA=; b=lF3JI1Wz7SI+mSyZFHoJHyreQdSUTq5QY643cGS9GBBxjPRvwFD+iqezyeavSwGDTF uMprUNPCKb6jIjNQ9H27Fur8RtWhiDepPMiibytUc1NJTu0f7IFzzowNuNjrqBgmlLiv 7Tr4SU49efZvmHAiHw87MpqB2rqt/EdI6B3iqynlt/57vW11+kQCzeiLS4vtTtF/ES7x 3KkjctyAS2VhFEOvDpZJ0NSt8AamjRfvI1fi97PPs+ONtwsp9zEj2O5BeVMpwlZmNVVm vJzDRFXwJbhi9UAyMxR5Qu1VM7ormDH+bsHuZ7T8/e7tIEZCLXPYodKzTASn4vvBqtYJ 5c/w== 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=p2PHZd2SW9nz4o7+ZB1C3vkb9xhx8DH7M49Qc2p69KA=; b=N6TVrlgYiTBaQ1aMbmtXbs3o3NTJRilafUcDVQlyY5LYwJy09XHndzrzg91nbuhdMC GGCjwD+y/3gqQhx0F+JA0I32NTUmTGqK85t1V/SikoetaZfmY2v6a8LOmo+wuaKAr4In IcFK/BAY/aarAdSPwTcimpx80Gj6QqpuPq1jHQq5h6vgirDTaGfSQBgYWgx4Xw7t3UkQ 9L0ij5TYcfVfnRFI1CO5eJgKdK8YE9aqnwryLWqVIKNL6vAd7lHZx0PrZoFAAgDRQS2h nWx18t8AzHmlUid4a8iDTyGhewYqH3FvdYNss5QHuvR84jKiGCKYVPD4Yp1pQUz5xaRX Kx1A== X-Gm-Message-State: AOAM5300KlSNDHH26HE+hZdtwxSO1t+fv3midTa+9ea4uHP6WDPu/Q6C 5xnk4QawM/+q46Wu0wc6r+aLBRzXekz5H5P+ X-Google-Smtp-Source: ABdhPJzwsewfz/TZInoLtcuvYaZ0I40Qn7oK2vNyTP6uAYb18yvMtG1+sQlLK+ggxuOgSY+2gruJ4PNGKknNJrtO X-Received: from andreyknvl3.muc.corp.google.com ([2a00:79e0:15:13:edb8:b79c:2e20:e531]) (user=andreyknvl job=sendgmr) by 2002:a0c:eda6:: with SMTP id h6mr4862060qvr.19.1612539567383; Fri, 05 Feb 2021 07:39:27 -0800 (PST) Date: Fri, 5 Feb 2021 16:39:05 +0100 In-Reply-To: <cover.1612538932.git.andreyknvl@google.com> Message-Id: <ece9cd2cca38dd3797c6cd1756e30a2e40b0d451.1612538932.git.andreyknvl@google.com> Mime-Version: 1.0 References: <cover.1612538932.git.andreyknvl@google.com> X-Mailer: git-send-email 2.30.0.365.g02bc693789-goog Subject: [PATCH v2 04/12] kasan: clean up setting free info in kasan_slab_free From: Andrey Konovalov <andreyknvl@google.com> To: Andrew Morton <akpm@linux-foundation.org>, Catalin Marinas <catalin.marinas@arm.com>, Vincenzo Frascino <vincenzo.frascino@arm.com>, Dmitry Vyukov <dvyukov@google.com>, Alexander Potapenko <glider@google.com>, Marco Elver <elver@google.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210205_103931_544435_95CC17A3 X-CRM114-Status: GOOD ( 11.14 ) 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: Branislav Rankov <Branislav.Rankov@arm.com>, Andrey Konovalov <andreyknvl@google.com>, Kevin Brodsky <kevin.brodsky@arm.com>, Will Deacon <will.deacon@arm.com>, linux-kernel@vger.kernel.org, kasan-dev@googlegroups.com, linux-mm@kvack.org, linux-arm-kernel@lists.infradead.org, Andrey Ryabinin <aryabinin@virtuozzo.com>, Peter Collingbourne <pcc@google.com>, Evgenii Stepanov <eugenis@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: optimizations and fixes for HW_TAGS
|
expand
|
diff --git a/mm/kasan/common.c b/mm/kasan/common.c index f2a6bae13053..da24b144d46c 100644 --- a/mm/kasan/common.c +++ b/mm/kasan/common.c @@ -350,13 +350,11 @@ static bool ____kasan_slab_free(struct kmem_cache *cache, void *object, kasan_poison(object, cache->object_size, KASAN_KMALLOC_FREE); - if (!kasan_stack_collection_enabled()) - return false; - if ((IS_ENABLED(CONFIG_KASAN_GENERIC) && !quarantine)) return false; - kasan_set_free_info(cache, object, tag); + if (kasan_stack_collection_enabled()) + kasan_set_free_info(cache, object, tag); return kasan_quarantine_put(cache, object); }