Re: [PATCH v2] RDMA/ucma: Check for a cm_id->device in all user calls that need it

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Jason,

I love your patch! Yet something to improve:

[auto build test ERROR on linus/master]
[also build test ERROR on v4.16 next-20180404]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Jason-Gunthorpe/RDMA-ucma-Check-for-a-cm_id-device-in-all-user-calls-that-need-it/20180405-124635
config: x86_64-randconfig-ne0-04051144 (attached as .config)
compiler: gcc-6 (Debian 6.4.0-9) 6.4.0 20171026
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

All errors (new ones prefixed by >>):

   drivers/infiniband/core/ucma.c: In function 'ucma_get_ctx_dev':
>> drivers/infiniband/core/ucma.c:167:3: error: implicit declaration of function 'ucma_put_ctx' [-Werror=implicit-function-declaration]
      ucma_put_ctx(ctx);
      ^~~~~~~~~~~~
   drivers/infiniband/core/ucma.c: At top level:
   drivers/infiniband/core/ucma.c:173:13: warning: conflicting types for 'ucma_put_ctx'
    static void ucma_put_ctx(struct ucma_context *ctx)
                ^~~~~~~~~~~~
   drivers/infiniband/core/ucma.c:173:13: error: static declaration of 'ucma_put_ctx' follows non-static declaration
   drivers/infiniband/core/ucma.c:167:3: note: previous implicit declaration of 'ucma_put_ctx' was here
      ucma_put_ctx(ctx);
      ^~~~~~~~~~~~
   cc1: some warnings being treated as errors

vim +/ucma_put_ctx +167 drivers/infiniband/core/ucma.c

   155	
   156	/*
   157	 * Same as ucm_get_ctx but requires that ->cm_id->device is valid, eg that the
   158	 * CM_ID is bound.
   159	 */
   160	static struct ucma_context *ucma_get_ctx_dev(struct ucma_file *file, int id)
   161	{
   162		struct ucma_context *ctx = ucma_get_ctx(file, id);
   163	
   164		if (IS_ERR(ctx))
   165			return ctx;
   166		if (!ctx->cm_id->device){
 > 167			ucma_put_ctx(ctx);
   168			return ERR_PTR(-EINVAL);
   169		}
   170		return ctx;
   171	}
   172	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux