Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp3193437ybt; Mon, 22 Jun 2020 18:00:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy2e8s5JNCxaOFJX5TT52zz5rT0i5jgQe+rOt3nJkoUsAu9Mx3Jjbhot3REgxRUJlWFc+FK X-Received: by 2002:a17:906:5e06:: with SMTP id n6mr17557631eju.504.1592874040982; Mon, 22 Jun 2020 18:00:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592874040; cv=none; d=google.com; s=arc-20160816; b=F+pkkZfPIQ1XtFAPuJz3TuUrm7B7HOoQM43VL6O3yTl8TmUtpGZQfOYCmSZSCnbym6 htHnpofG8u4z9aijr3cmHIyyz8UhUQZeQBI6tdU0zhoxJiX6cONg2RyEq0fiHE3ncg88 ApPhSLiI3GXmhsGtTf/7ggxOo7xcf9E2o1JrZMrgMcRKkZYO2RT2qvhrNH8Q+0r35Gpd jJiFhcZPAH0T4RyaeIsv7it1XVruW2+bD6fS62z2/ZZpd1iWN8qTLDmnV7Iqm2EnqVi/ 2kelVaTYdgUd9gnwaoCxHd3gVOk8PHiM18dsbv6EVwScbiWpePBJqdXEBCVm/L6zSb4C KIxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:dkim-signature:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=xt/DdoBrc7yZMBZQe7V2Al8LVTlDZOsWZMnDlqU0wok=; b=iBpUNbf6BQcdm0Klrwv98JFv/2Og7i952wjojksTp9CNReH2VIITohikr2MhDEtZM9 xHAMtGhsjSXBHW3R0Y1U7x2qqspsKF4/wnxE2H/Zy4cw+6lRuAKznTvBvkgdXhLbIDkt 4YYkW1kXU5cnZ6Ij+256K0aIifq70voulx5qXRxfaEUnFyEBsBPqdd+aoiBixTonjuHy qiHTYUu+pT6tsqgCf/ThgzvPJjPOzoMDI2u3iLPsTReux/HSN6PGdqWqb9fPL/N/qded EKllfmOLMCf+EA2DWz+zWSsNRnrGdnOf4AkZVeQkxqgnY2mNmOab/S4UhorFex6/b+OZ Z9ig== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nvidia.com header.s=n1 header.b=HFrX1kZH; 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=pass (p=NONE sp=NONE dis=NONE) header.from=nvidia.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id gg26si3849490ejb.128.2020.06.22.18.00.18; Mon, 22 Jun 2020 18:00:40 -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; dkim=pass header.i=@nvidia.com header.s=n1 header.b=HFrX1kZH; 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=pass (p=NONE sp=NONE dis=NONE) header.from=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732527AbgFWA5k (ORCPT + 99 others); Mon, 22 Jun 2020 20:57:40 -0400 Received: from hqnvemgate26.nvidia.com ([216.228.121.65]:19117 "EHLO hqnvemgate26.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732144AbgFWA5j (ORCPT ); Mon, 22 Jun 2020 20:57:39 -0400 Received: from hqpgpgate101.nvidia.com (Not Verified[216.228.121.13]) by hqnvemgate26.nvidia.com (using TLS: TLSv1.2, DES-CBC3-SHA) id ; Mon, 22 Jun 2020 17:57:26 -0700 Received: from hqmail.nvidia.com ([172.20.161.6]) by hqpgpgate101.nvidia.com (PGP Universal service); Mon, 22 Jun 2020 17:57:39 -0700 X-PGP-Universal: processed; by hqpgpgate101.nvidia.com on Mon, 22 Jun 2020 17:57:39 -0700 Received: from [10.2.59.206] (10.124.1.5) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Tue, 23 Jun 2020 00:57:31 +0000 Subject: Re: [RESEND PATCH 3/3] nouveau: make nvkm_vmm_ctor() and nvkm_mmu_ptp_get() static To: Ralph Campbell , , CC: Jerome Glisse , Christoph Hellwig , "Jason Gunthorpe" , Ben Skeggs References: <20200622233854.10889-1-rcampbell@nvidia.com> <20200622233854.10889-4-rcampbell@nvidia.com> From: John Hubbard Message-ID: Date: Mon, 22 Jun 2020 17:57:31 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0 MIME-Version: 1.0 In-Reply-To: <20200622233854.10889-4-rcampbell@nvidia.com> X-Originating-IP: [10.124.1.5] X-ClientProxiedBy: HQMAIL105.nvidia.com (172.20.187.12) To HQMAIL107.nvidia.com (172.20.187.13) Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1592873846; bh=xt/DdoBrc7yZMBZQe7V2Al8LVTlDZOsWZMnDlqU0wok=; h=X-PGP-Universal:Subject:To:CC:References:From:Message-ID:Date: User-Agent:MIME-Version:In-Reply-To:X-Originating-IP: X-ClientProxiedBy:Content-Type:Content-Language: Content-Transfer-Encoding; b=HFrX1kZHglfl1VvYBuoLqx22N0dETh2Vr8k2DJE6gl5LV9ujkobLDnbkPVN6dPZgr BFOxjTfLAPEJZXB5vvaAH7MZMLItWJKYIagC7RXVMlDgABKww7sZt/cpG1Z4tszwC5 OasJ6bXWpHeJ84oshxjFQVD56tIJ+YpmI1RCawYuIbi0nnry6CkmkbVVcUQPgnC4hk Yw6MemJ/1EQ6XXuOig0WTHsBUZv1KaKywMaKvNNVctioQbUa04cBP2D7EVLiHbXlJ6 YqT88zvzC1rZ+C5LNxlc7QOjzBiAjuGQN+EMw6FmDN7cfE5TjmXOlQrC4FftxUP0GK aLUQHXWsAbmcA== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2020-06-22 16:38, Ralph Campbell wrote: > The functions nvkm_vmm_ctor() and nvkm_mmu_ptp_get() are not called outside > of the file defining them so make them static. > > Signed-off-by: Ralph Campbell > --- > drivers/gpu/drm/nouveau/nvkm/subdev/mmu/base.c | 2 +- > drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.c | 2 +- > drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.h | 3 --- > 3 files changed, 2 insertions(+), 5 deletions(-) > > diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/base.c b/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/base.c > index ee11ccaf0563..de91e9a26172 100644 > --- a/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/base.c > +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/base.c > @@ -61,7 +61,7 @@ nvkm_mmu_ptp_put(struct nvkm_mmu *mmu, bool force, struct nvkm_mmu_pt *pt) > kfree(pt); > } > > -struct nvkm_mmu_pt * > +static struct nvkm_mmu_pt * > nvkm_mmu_ptp_get(struct nvkm_mmu *mmu, u32 size, bool zero) > { > struct nvkm_mmu_pt *pt; > diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.c b/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.c > index 199f94e15c5f..67b00dcef4b8 100644 > --- a/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.c > +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.c > @@ -1030,7 +1030,7 @@ nvkm_vmm_ctor_managed(struct nvkm_vmm *vmm, u64 addr, u64 size) > return 0; > } > > -int > +static int > nvkm_vmm_ctor(const struct nvkm_vmm_func *func, struct nvkm_mmu *mmu, > u32 pd_header, bool managed, u64 addr, u64 size, > struct lock_class_key *key, const char *name, > diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.h b/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.h > index d3f8f916d0db..a2b179568970 100644 > --- a/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.h > +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.h > @@ -163,9 +163,6 @@ int nvkm_vmm_new_(const struct nvkm_vmm_func *, struct nvkm_mmu *, > u32 pd_header, bool managed, u64 addr, u64 size, > struct lock_class_key *, const char *name, > struct nvkm_vmm **); > -int nvkm_vmm_ctor(const struct nvkm_vmm_func *, struct nvkm_mmu *, > - u32 pd_header, bool managed, u64 addr, u64 size, > - struct lock_class_key *, const char *name, struct nvkm_vmm *); > struct nvkm_vma *nvkm_vmm_node_search(struct nvkm_vmm *, u64 addr); > struct nvkm_vma *nvkm_vmm_node_split(struct nvkm_vmm *, struct nvkm_vma *, > u64 addr, u64 size); > Looks accurate: the order within vmm.c (now that there is no .h declaration) is still good, and I found no other uses of either function within the linux.git tree, so Reviewed-by: John Hubbard