From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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=-15.5 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_SANE_1 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 39823C433DB for ; Fri, 15 Jan 2021 13:15:17 +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 ED4CA22583 for ; Fri, 15 Jan 2021 13:15:16 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org ED4CA22583 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:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=/+daNNMQmWHf1CYgMpFVY13hC1TaMiU2GsN8hvxOW68=; b=kLc5tjTV6KQ24nlX5dJB/YLQe yqJoy/LPLDSIKQF9DhhKLbfcGvlZyvgL1X3Z9d8j2XooZ4sw0nWrAtYfTl9+BJBbJbgiFvHYnkBRw 1Ki5xGPj/V1y1aa/aHLb5SO1bkgv0sBrU03WUfdERRypc3XKc3iiQ02SCyl0EBTkl4qL8AYZCGCJA PqcSN9IpiugPFKPVJVYeGfqKpRpAf3EZMXDsPJKKRbzfF5wYEF61RCo6KnY4vVjbfSKfEvqiSu40h 5gl6ZI9f6eNEl4SVGHBrTmu97Po4/whgIwLoSjAwtTq41AfiyjcND8uMhyKNQGpALGXnBAdFFufxG fIf0nK50Q==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1l0OvP-0002Yl-1u; Fri, 15 Jan 2021 13:13:59 +0000 Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1l0OvL-0002X3-80 for linux-arm-kernel@lists.infradead.org; Fri, 15 Jan 2021 13:13:56 +0000 Received: by mail-wm1-x330.google.com with SMTP id v184so3352541wma.1 for ; Fri, 15 Jan 2021 05:13:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=2g4u3xNSMK8ghZXqKFL1R16HFSl2YerHraRE1h1ytpo=; b=NJnjEoGtqvon0egRK9YDpRFtOVbouVzaWgRbvYfVii+pcX8Ains4e8W1vQK2TqkAOX yJ+CaqAjsp/dYPpBhRRVqsJ50qnOF64iyVZz5gsAoZiYdsB7AJsJ86Dk/jIiH9jdAW7u S2lpxb2tRpaTTc94ebf7nepCVudFXT9rCksZcU/vPJ4mU/wq06zc03tPavGYoFzj48OD mf090vFhbR24JxJnLVx/wcDpnu4RWfAArLaMzN5z0plP5un+8hjwky/AjLPZrND5ddd6 hdqWlLONDBuo3ylfSdJ1j/zS/5DgBHxK/D1fJlkWcQIlg6TjqIfMSzGRac6mDARTo+FP h/Gg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=2g4u3xNSMK8ghZXqKFL1R16HFSl2YerHraRE1h1ytpo=; b=lORxV4V7BabLnSDDkIkc2viSOveEO0G/2PJO8Lxraez05BWj+6eF/HI+WdbSWM/LSh dvI9mXuS5cOghFJbeKq2FlB6fMiI9Y/cVnT3B8/1rlmz19vf95lonbEJRDHsUmozZqoS gIC0oBKt0gamVPDzV2KuVLgFQ0VrBQ6fC3EhuSIaNePkJjQKr2AjPUVgQR29pHjegLIy VhbgK6KBR8c58C9ApQaij3/YD+Olb7DqtaAm03PaU/b9HfltsUb5OFGdevJpS5L32Nru mtrGI8sOk1HtLNJETubv4gPCkQFD/IogVEkVsgd44FQhH287ThekplgpjMCjLlVwq928 LlJQ== X-Gm-Message-State: AOAM533UuPvBu6hop85gDZOHA4SENj3DKEds8wLESL4tjc8320YwWmpj Y6GUu6KZQs+38ZslUWfUa66oIA== X-Google-Smtp-Source: ABdhPJxfOZhdwQYrDchMipN1IZpHmQWkJDk+mAZz8JHVlnN1ck11zGlbUHx0lY6QrlOT4n4wgqVJvA== X-Received: by 2002:a1c:9acb:: with SMTP id c194mr8510839wme.43.1610716433539; Fri, 15 Jan 2021 05:13:53 -0800 (PST) Received: from elver.google.com ([2a00:79e0:15:13:f693:9fff:fef4:2449]) by smtp.gmail.com with ESMTPSA id x17sm14605648wro.40.2021.01.15.05.13.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Jan 2021 05:13:52 -0800 (PST) Date: Fri, 15 Jan 2021 14:13:47 +0100 From: Marco Elver To: Andrey Konovalov Subject: Re: [PATCH v3 15/15] kasan: don't run tests when KASAN is not enabled Message-ID: References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/2.0.2 (2020-11-20) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210115_081355_321259_8F002A6B X-CRM114-Status: GOOD ( 17.92 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arm-kernel@lists.infradead.org, Branislav Rankov , Catalin Marinas , Kevin Brodsky , Will Deacon , linux-kernel@vger.kernel.org, kasan-dev@googlegroups.com, linux-mm@kvack.org, Alexander Potapenko , Evgenii Stepanov , Andrey Ryabinin , Andrew Morton , Vincenzo Frascino , Peter Collingbourne , Dmitry Vyukov Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Jan 14, 2021 at 08:36PM +0100, Andrey Konovalov wrote: > Don't run KASAN tests when it's disabled with kasan.mode=off to avoid > corrupting kernel memory. > > Link: https://linux-review.googlesource.com/id/I6447af436a69a94bfc35477f6bf4e2122948355e > Signed-off-by: Andrey Konovalov Reviewed-by: Marco Elver > --- > lib/test_kasan.c | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/lib/test_kasan.c b/lib/test_kasan.c > index a96376aa7293..6238b56127f8 100644 > --- a/lib/test_kasan.c > +++ b/lib/test_kasan.c > @@ -47,6 +47,11 @@ static bool multishot; > */ > static int kasan_test_init(struct kunit *test) > { > + if (!kasan_enabled()) { > + kunit_err(test, "can't run KASAN tests with KASAN disabled"); > + return -1; > + } > + > multishot = kasan_save_enable_multi_shot(); > hw_set_tagging_report_once(false); > return 0; > -- > 2.30.0.284.gd98b1dd5eaa7-goog > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel