diff mbox series

IB/core: Declare local functions 'static'

Message ID 20190122182423.59313-1-bvanassche@acm.org (mailing list archive)
State Mainlined
Commit f37385919045ad611bcf40bbb899591ec8aac86c
Delegated to: Jason Gunthorpe
Headers show
Series IB/core: Declare local functions 'static' | expand

Commit Message

Bart Van Assche Jan. 22, 2019, 6:24 p.m. UTC
This patch avoids that sparse complains about missing function declarations.

Cc: Jason Gunthorpe <jgg@mellanox.com>
Cc: Leon Romanovsky <leonro@mellanox.com>
Cc: Doug Ledford <dledford@redhat.com>
Fixes: f27a0d50a4bc ("RDMA/umem: Use umem->owning_mm inside ODP") # v4.20
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
---
 drivers/infiniband/core/umem_odp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Jason Gunthorpe Jan. 22, 2019, 7:48 p.m. UTC | #1
On Tue, Jan 22, 2019 at 10:24:23AM -0800, Bart Van Assche wrote:
> This patch avoids that sparse complains about missing function declarations.
> 
> Cc: Jason Gunthorpe <jgg@mellanox.com>
> Cc: Leon Romanovsky <leonro@mellanox.com>
> Cc: Doug Ledford <dledford@redhat.com>
> Fixes: f27a0d50a4bc ("RDMA/umem: Use umem->owning_mm inside ODP") # v4.20

Is this # v4.20 a thing now? I haven't seen it before with fixes. It
is really easy to get the tag from a fixes with 
  'git describe --contains'

Jason
Bart Van Assche Jan. 22, 2019, 8:49 p.m. UTC | #2
On Tue, 2019-01-22 at 19:48 +0000, Jason Gunthorpe wrote:
> On Tue, Jan 22, 2019 at 10:24:23AM -0800, Bart Van Assche wrote:
> > This patch avoids that sparse complains about missing function declarations.
> > 
> > Cc: Jason Gunthorpe <jgg@mellanox.com>
> > Cc: Leon Romanovsky <leonro@mellanox.com>
> > Cc: Doug Ledford <dledford@redhat.com>
> > Fixes: f27a0d50a4bc ("RDMA/umem: Use umem->owning_mm inside ODP") # v4.20
> 
> Is this # v4.20 a thing now? I haven't seen it before with fixes. It
> is really easy to get the tag from a fixes with 
>   'git describe --contains'

Hi Jason,

Mentioning the tag in a fixes commit is not required. I do that myself because
it saves the reader the effort to run the git describe --contains command.

Bart.
Leon Romanovsky Jan. 23, 2019, 6:05 a.m. UTC | #3
On Tue, Jan 22, 2019 at 10:24:23AM -0800, Bart Van Assche wrote:
> This patch avoids that sparse complains about missing function declarations.
>
> Cc: Jason Gunthorpe <jgg@mellanox.com>
> Cc: Leon Romanovsky <leonro@mellanox.com>
> Cc: Doug Ledford <dledford@redhat.com>
> Fixes: f27a0d50a4bc ("RDMA/umem: Use umem->owning_mm inside ODP") # v4.20
> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
> ---
>  drivers/infiniband/core/umem_odp.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>

Thanks,
Reviewed-by: Leon Romanovsky <leonro@mellanox.com>
Jason Gunthorpe Jan. 23, 2019, 9:38 p.m. UTC | #4
On Tue, Jan 22, 2019 at 10:24:23AM -0800, Bart Van Assche wrote:
> This patch avoids that sparse complains about missing function declarations.
> 
> Cc: Jason Gunthorpe <jgg@mellanox.com>
> Cc: Leon Romanovsky <leonro@mellanox.com>
> Cc: Doug Ledford <dledford@redhat.com>
> Fixes: f27a0d50a4bc ("RDMA/umem: Use umem->owning_mm inside ODP") # v4.20
> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
> Reviewed-by: Leon Romanovsky <leonro@mellanox.com>
> ---
>  drivers/infiniband/core/umem_odp.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied to for-next

Thanks,
Jason
diff mbox series

Patch

diff --git a/drivers/infiniband/core/umem_odp.c b/drivers/infiniband/core/umem_odp.c
index a4ec43093cb3..dc1d7cb15cfa 100644
--- a/drivers/infiniband/core/umem_odp.c
+++ b/drivers/infiniband/core/umem_odp.c
@@ -299,7 +299,7 @@  static void free_per_mm(struct rcu_head *rcu)
 	kfree(container_of(rcu, struct ib_ucontext_per_mm, rcu));
 }
 
-void put_per_mm(struct ib_umem_odp *umem_odp)
+static void put_per_mm(struct ib_umem_odp *umem_odp)
 {
 	struct ib_ucontext_per_mm *per_mm = umem_odp->per_mm;
 	struct ib_ucontext *ctx = umem_odp->umem.context;