Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp528845pxm; Wed, 23 Feb 2022 05:47:11 -0800 (PST) X-Google-Smtp-Source: ABdhPJye63zmzptqrlqL/BzCuBkcnvcUDUn/fQj85Rr2nKnqiAuXYNZrq6RRgEXg2qMmqmHVAFoE X-Received: by 2002:aa7:c391:0:b0:410:83fb:abab with SMTP id k17-20020aa7c391000000b0041083fbababmr31614928edq.435.1645624031453; Wed, 23 Feb 2022 05:47:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645624031; cv=none; d=google.com; s=arc-20160816; b=TOUSCQBBCH+JaDuwX2TgXVs7WKcP/RRC4lyIV0cLiIwuuZif3uQxAM09zstN6/fcV9 X8es0sZp6+6e7SfPKcr/BucVQZ+0PV+YpapH37pWwvcuLrPdrN7jCe57W/dagOh6PmfS wKF1we3SA/x4i5oxWEPukwoGDnYM3d2wxbZ0shfmLP6m5ZDVbWNbp4pUqiVh6kKAnvIk lwIonH7UkCHzM29lgJ9cic2k1Mm90hC0mOj027KU30AcpyYbrtelzMYe+eReDmhL1AM7 ExXN/qFL9UqY/s4reqC22nvApHsT8nK21+N8/72B7DZrGJXibujq9XO78WF0Gh/s9xQJ /++w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=WtAp4AiQx2cFjDZg+kQhLqiCnjHbJYbWSztFNAebJV0=; b=FyWZYKlxUax+hPbmW9TAF6XNPRHCCY4nVJUBXwVp2/ffkiKu60zLmzdTwPT2ptbtDZ Hgepgu6AJXxdUueohx62Mh98enIxfwJgB3mZp5A92zfxHxcW1Fuu/69XWOOfef/3AT16 LKwMxJVt7NDoUFLHOZz8BcyrFAt5DlXW32Q96nV65fouAHsv6gXRYvecpjThQ+bMntOG DjjkY44c7x+eqk2QQDYu6MSaqAmk/UKWWdcZW4NHnwZh+t4ga++3ca1N5SEi073m9G+G 3bLZEV69PY2KWobr9ryjcAJLI3FsL64dLOx2qE4opBSzgLeBeas4ZgQ3B/7XhN8nyE+z 7gtg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=xlYQqe08; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id sb25si15688280ejc.225.2022.02.23.05.46.47; Wed, 23 Feb 2022 05:47:11 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=xlYQqe08; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233774AbiBVRKq (ORCPT + 99 others); Tue, 22 Feb 2022 12:10:46 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42586 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231278AbiBVRKp (ORCPT ); Tue, 22 Feb 2022 12:10:45 -0500 Received: from out2.migadu.com (out2.migadu.com [IPv6:2001:41d0:2:aacc::]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C88BDD1082 for ; Tue, 22 Feb 2022 09:10:19 -0800 (PST) X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1645549816; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=WtAp4AiQx2cFjDZg+kQhLqiCnjHbJYbWSztFNAebJV0=; b=xlYQqe087ezV+XM7I/ABgA88EuEsv37JtzM7yYXaZZjF4VPd8bMVFm520holvBULzpTQKZ NkeBoBwoNSpuIx9d6QofDAZ8PjTvilEBTK0k0yS3I7O4Xs9LaI7ndLeiGzhLg+ycfDs2lY JNPjBQBx5ueUdsUcBU8UNPQhj+h2PUY= From: andrey.konovalov@linux.dev To: Andrew Morton Cc: Andrey Konovalov , Marco Elver , Alexander Potapenko , Dmitry Vyukov , Andrey Ryabinin , kasan-dev@googlegroups.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrey Konovalov , kernel test robot Subject: [PATCH mm] another fix for "kasan: improve vmalloc tests" Date: Tue, 22 Feb 2022 18:10:14 +0100 Message-Id: <2d44632c4067be35491b58b147a4d1329fdfcf16.1645549750.git.andreyknvl@google.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: linux.dev X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Andrey Konovalov set_memory_rw/ro() are not exported to be used in modules and thus cannot be used in KUnit-compatible KASAN tests. Drop the checks that rely on these functions. Reported-by: kernel test robot Signed-off-by: Andrey Konovalov --- lib/test_kasan.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/lib/test_kasan.c b/lib/test_kasan.c index ef99d81fe8b3..448194bbc41d 100644 --- a/lib/test_kasan.c +++ b/lib/test_kasan.c @@ -1083,12 +1083,6 @@ static void vmalloc_helpers_tags(struct kunit *test) KUNIT_ASSERT_TRUE(test, is_vmalloc_addr(ptr)); KUNIT_ASSERT_NOT_ERR_OR_NULL(test, vmalloc_to_page(ptr)); - /* Make sure vmalloc'ed memory permissions can be changed. */ - rv = set_memory_ro((unsigned long)ptr, 1); - KUNIT_ASSERT_GE(test, rv, 0); - rv = set_memory_rw((unsigned long)ptr, 1); - KUNIT_ASSERT_GE(test, rv, 0); - vfree(ptr); } -- 2.25.1