Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2234553pxj; Sun, 30 May 2021 18:57:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz16EjogY28fU3k4B2D/gDhga6IFvoeg6uTGekOoMi6Ppf8AopnyD2IJaYdyzl9dvLO8WYx X-Received: by 2002:a92:700a:: with SMTP id l10mr15290874ilc.44.1622426242936; Sun, 30 May 2021 18:57:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622426242; cv=none; d=google.com; s=arc-20160816; b=M2Lawb28sHu8gDo1QZeB4USOBiFwLrd0U1h+zYr4ttvYfR4P+9B5bfHMdxp7DAM/Lj 3WbA2pZIW9lnn+RDZGRuvVLDObipUGEd2HNDFrFdZD9eNVvmTsl0IJZer/UsNlcNzRsN D3O5sV9CkhqzjqFe0Vb+uQ9RTzisuY+jPcizODhjAGKyy6/qzrmgiprCkX62h6t4tUsE BDBN0lTry7QWFmqT7AczCTz/EP4empS/l+00GDEVeBSYj2+bW9MOT6zvAwGyADyG4AMf HcVVtu6H/admEj5i4NdpGpJFKz1Vs7zPrkVtfNlIJ87YHiZBmB69SnpbCxCWF7i1tTpl wuBg== 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; bh=LARxUde94kkOdgXl6iYn8uRUV6Ib5yqcewwSbIQC2E0=; b=Nv3Iu5MqHvxNiUzmfuA1KC5m+X0jGLwSsuojzdjGNK5NkXMZWODHwFYU4azERGI5ds fTtp7i8B8iyWS0ZrDQwS2YS0MFy25W3EoYkqnbH6Xv57lr/D9PK/7Ujocbs5y5YGkXpp 0TDt0xkc0cREqlzkZVJu7CZTyLGL43eOwxHda2Wy9C4mmiqqFbUTSKa5/jlLZC3ui3WP 8kTwcxO9rLywu+uhb7onB2vS80x3jwrxJAyETrzhtdQUM6zlZEytpAtjkCH45AqCvSmd 45xf8apcHf+CzDebOkAFch043SPH1xVYFZap+wIVujpLa8urghI4crCHV+vg1V6LyCxz WMNw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m4si13444957jah.87.2021.05.30.18.57.09; Sun, 30 May 2021 18:57:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230008AbhEaB6K (ORCPT + 99 others); Sun, 30 May 2021 21:58:10 -0400 Received: from szxga08-in.huawei.com ([45.249.212.255]:3293 "EHLO szxga08-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229912AbhEaB6J (ORCPT ); Sun, 30 May 2021 21:58:09 -0400 Received: from dggemv704-chm.china.huawei.com (unknown [172.30.72.53]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4FtdZD6zdZz1BGmJ; Mon, 31 May 2021 09:51:48 +0800 (CST) Received: from dggpemm500004.china.huawei.com (7.185.36.219) by dggemv704-chm.china.huawei.com (10.3.19.47) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Mon, 31 May 2021 09:56:28 +0800 Received: from huawei.com (10.174.28.241) by dggpemm500004.china.huawei.com (7.185.36.219) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Mon, 31 May 2021 09:56:28 +0800 From: Bixuan Cui To: CC: , , Bixuan Cui Subject: [PATCH -next] mm/mmap_lock: fix warning when CONFIG_TRACING is not defined Date: Mon, 31 May 2021 09:55:27 +0800 Message-ID: <20210531015527.49785-1-cuibixuan@huawei.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain; charset="y" Content-Transfer-Encoding: 8bit X-Originating-IP: [10.174.28.241] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To dggpemm500004.china.huawei.com (7.185.36.219) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Fix the warning: [-Wunused-function] mm/mmap_lock.c:157:20: warning: ‘get_mm_memcg_path’ defined but not used static const char *get_mm_memcg_path(struct mm_struct *mm) ^~~~~~~~~~~~~~~~~ Signed-off-by: Bixuan Cui --- mm/mmap_lock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/mmap_lock.c b/mm/mmap_lock.c index 03ee85c696ef..ec7899b08690 100644 --- a/mm/mmap_lock.c +++ b/mm/mmap_lock.c @@ -154,7 +154,7 @@ static inline void put_memcg_path_buf(void) * The caller must call put_memcg_path_buf() once the buffer is no longer * needed. This must be done while preemption is still disabled. */ -static const char *get_mm_memcg_path(struct mm_struct *mm) +static const char __maybe_unused *get_mm_memcg_path(struct mm_struct *mm) { char *buf = NULL; struct mem_cgroup *memcg = get_mem_cgroup_from_mm(mm); -- 2.17.1