Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp3367707rdh; Thu, 28 Sep 2023 09:33:52 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGvtJdAkiWXrOu46wEZ4qPxIgGQEmNekVCqceHOpvlpJyOT3Dcyxv/DtV/ZSK6LGKZ0wcsV X-Received: by 2002:a05:6358:3415:b0:143:8574:4311 with SMTP id h21-20020a056358341500b0014385744311mr1956619rwd.12.1695918832564; Thu, 28 Sep 2023 09:33:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695918832; cv=none; d=google.com; s=arc-20160816; b=CvyUn+sws4wMvz/i/BPakksyaPM6lH+In88QzDEAe+Id8kfLWB0VKE2+MJ+CwvdCZo YBcgurI9g2Wim6vUrOlrAFqrJVomFEQudOYPGKqbx0g2jvyoFjAHx39fc7uaalqD1AOk P4QKfbEc7DbSMk9ZoEajI63u8kXggJcX9wi9CjI4PVkQvdlR8Eqywk3mmusisVdE32Bl IK3pn7pRQ5mVyvzhgYQURzA3IXw5dQ1iN1sShOVVlU7UwfQOiXm2fRF6lqSLe7+7a5ih WWDtVivmBq6peZmjQJA1I1wYhHwt7uISyErTwMuhTSvS+S3o+EiJsuUHDJhmXZcVvzgR WT8w== 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=ThPN2Hhgrb+6YderOJSJbgdsI3cmBjzcJEFDZEakKYA=; fh=oZmO0zOgxBznBN/uybdgnni+iMA2gQbOXdQX0HlH77s=; b=Fgjm/OK/3UmjnqR6BLw6u0YqcrbqDcs0ruJslz3UEp0tuAo9Upc5/9F9caGZNbPs19 C2oeSW+KDUjUoX8N0D8s5SulgLdoliefYqDHjCbuiKkAd45riRfDfiQry8ExtCDW1rNE Ytoe98YDeA9ZdzM2ai9gn+xwJqgsX+vGB95iSDT38FoVMihBfy35Y6SJaSEvn256rzjK tkNEyCpNErvBefVsPeyTyv7uSN+xhsPhaDqqf6pVNhRCs2WOIJvjWA2IKfFypanU06HG 1VAHW4hulws0ZSU2lMCWRgcqnJVPqvTpVPd5uD7CgSrZ9Bj5gjmng4rOeD0gvg1f/sGn P8ig== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=Rb64nivA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id bx22-20020a056a02051600b00578c36d7249si20041562pgb.291.2023.09.28.09.33.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Sep 2023 09:33:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=Rb64nivA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id EDB5B83D0AA7; Thu, 28 Sep 2023 01:54:51 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231455AbjI1IyY (ORCPT + 99 others); Thu, 28 Sep 2023 04:54:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56112 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231397AbjI1IyT (ORCPT ); Thu, 28 Sep 2023 04:54:19 -0400 Received: from mail-pf1-x42d.google.com (mail-pf1-x42d.google.com [IPv6:2607:f8b0:4864:20::42d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5B06AC0; Thu, 28 Sep 2023 01:54:16 -0700 (PDT) Received: by mail-pf1-x42d.google.com with SMTP id d2e1a72fcca58-690d935dbc2so2822306b3a.1; Thu, 28 Sep 2023 01:54:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1695891256; x=1696496056; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=ThPN2Hhgrb+6YderOJSJbgdsI3cmBjzcJEFDZEakKYA=; b=Rb64nivAshbxJ0CuGmfU28MXYClMm5bf0SWEfsMAzKnkQHAaF3QI2m8NSJasjlDQ4T 5DSgahZroODaptYh9lbeNppIJWEEa9EtvjHJGD900ftzPWG3AbTOooafRzyYQ0FY8nPU qRjaBxxVmnADP/hnzx8XU7sFg7lmoAcrW1RtyiqQ7BZ2cQHPV+C7tJwyuQhN/TOUBdM0 w4osi/OWK45HVsUmoUsfnLg6qXVOahjinxyvuAI5BXXqgLZMitWjJezk12QhlRVbefK+ v6JUrXz112LEo8z57qykYtIWmvExGvPfl5mXe/BsdGa/vxUzt6j7+ETtckaIoDpxrypR x10Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695891256; x=1696496056; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ThPN2Hhgrb+6YderOJSJbgdsI3cmBjzcJEFDZEakKYA=; b=a+DZF8+sJnUlYd7lW9e8HIJTbrwMlEQIBKFqHtkyHis7zMWb/4Ql+yCqGDkfEHR82m SW9P6BP1NeXLutCmq83zmUa+QWhLGJAiEmOXDAsxkBFmhDCvszxEnYP/CaSeQkXgDHy+ o6lTUtaPBFl2MwHrnDMtcUd2UB+I1FArNvO9IdNaDGvWIxWfuoEj+HG1VeifQew/lLEZ kxjEf/t/tRksCcHGGJEmbp+ltYgD2G436wdqHxNgwLo+mf+sPc7/xkF6j6eJSlVlmNKq 0FIb6noIpeOnnJsn98CGrYBXoAupbIUF9bs66webql1YgKuMoY8mXSsli6HfV8soGFPQ MWyA== X-Gm-Message-State: AOJu0Yx3FWw4BU5H7WNjmBMpSCfXGkxdoQ1qR6bnuehoerFjjbQg9cTm H4merPSYayPiwIL0f4JDosQ= X-Received: by 2002:a05:6a00:2c8d:b0:68e:3eff:e93a with SMTP id ef13-20020a056a002c8d00b0068e3effe93amr562164pfb.2.1695891255701; Thu, 28 Sep 2023 01:54:15 -0700 (PDT) Received: from abhinav-IdeaPad-Slim-5-14ABR8.. ([103.75.161.211]) by smtp.googlemail.com with ESMTPSA id h11-20020a63574b000000b0056368adf5e2sm12415386pgm.87.2023.09.28.01.54.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Sep 2023 01:54:15 -0700 (PDT) From: Abhinav To: akpm@linux-foundation.org, david@redhat.com, rppt@kernel.org, hughd@google.com, Liam.Howlett@Oracle.com, surenb@google.com, usama.anjum@collabora.com, wangkefeng.wang@huawei.com, ryan.roberts@arm.com, yuanchu@google.com Cc: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, skhan@linuxfoundation.org, Abhinav Subject: [PATCH] Fixed Kunit test warning message for 'fs' module Date: Thu, 28 Sep 2023 14:23:11 +0530 Message-Id: <20230928085311.938163-1-singhabhinav9051571833@gmail.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Thu, 28 Sep 2023 01:54:52 -0700 (PDT) fs/proc/task_mmu : fix warning All the caller of the function pagemap_scan_backout_range(...) are inside ifdef preprocessor which is checking for the macro 'CONFIG_TRANSPARENT_HUGEPAGE' is set or not. When it is not set the function doesn't have a caller and it generates a warning unused function. Putting the whole function inside the preprocessor fixes this warning. Signed-off-by: Abhinav --- fs/proc/task_mmu.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c index 27da6337d675..88b6b8847cf3 100644 --- a/fs/proc/task_mmu.c +++ b/fs/proc/task_mmu.c @@ -2019,6 +2019,7 @@ static bool pagemap_scan_push_range(unsigned long categories, return true; } +#ifdef CONFIG_TRANSPARENT_HUGEPAGE static void pagemap_scan_backout_range(struct pagemap_scan_private *p, unsigned long addr, unsigned long end) { @@ -2031,6 +2032,7 @@ static void pagemap_scan_backout_range(struct pagemap_scan_private *p, p->found_pages -= (end - addr) / PAGE_SIZE; } +#endif static int pagemap_scan_output(unsigned long categories, struct pagemap_scan_private *p, -- 2.34.1