All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com, Julia Lawall <julia.lawall@inria.fr>
Subject: [android-common:android13-5.15 10/10] drivers/dma-buf/st-dma-fence-unwrap.c:75:39-45: ERROR: reference preceded by free on line 70
Date: Fri, 27 Dec 2024 22:05:29 +0800	[thread overview]
Message-ID: <202412272143.B9jfMgsY-lkp@intel.com> (raw)

BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
TO: cros-kernel-buildreports@googlegroups.com

tree:   https://android.googlesource.com/kernel/common android13-5.15
head:   f0b678d66a6fea50a07caa82f754461f550d500c
commit: 7aa4d35d52466ff170359781977cb644b595d2d1 [10/10] UPSTREAM: dma-buf: cleanup dma_fence_unwrap selftest v2
:::::: branch date: 19 hours ago
:::::: commit date: 19 hours ago
config: x86_64-randconfig-101-20241227 (https://download.01.org/0day-ci/archive/20241227/202412272143.B9jfMgsY-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Julia Lawall <julia.lawall@inria.fr>
| Closes: https://lore.kernel.org/r/202412272143.B9jfMgsY-lkp@intel.com/

cocci warnings: (new ones prefixed by >>)
>> drivers/dma-buf/st-dma-fence-unwrap.c:75:39-45: ERROR: reference preceded by free on line 70

vim +75 drivers/dma-buf/st-dma-fence-unwrap.c

169630111a051b Christian König 2022-03-11  45  
169630111a051b Christian König 2022-03-11  46  static struct dma_fence *mock_array(unsigned int num_fences, ...)
169630111a051b Christian König 2022-03-11  47  {
169630111a051b Christian König 2022-03-11  48  	struct dma_fence_array *array;
169630111a051b Christian König 2022-03-11  49  	struct dma_fence **fences;
169630111a051b Christian König 2022-03-11  50  	va_list valist;
169630111a051b Christian König 2022-03-11  51  	int i;
169630111a051b Christian König 2022-03-11  52  
169630111a051b Christian König 2022-03-11  53  	fences = kcalloc(num_fences, sizeof(*fences), GFP_KERNEL);
169630111a051b Christian König 2022-03-11  54  	if (!fences)
7aa4d35d52466f Christian König 2022-05-04  55  		goto error_put;
169630111a051b Christian König 2022-03-11  56  
169630111a051b Christian König 2022-03-11  57  	va_start(valist, num_fences);
169630111a051b Christian König 2022-03-11  58  	for (i = 0; i < num_fences; ++i)
169630111a051b Christian König 2022-03-11  59  		fences[i] = va_arg(valist, typeof(*fences));
169630111a051b Christian König 2022-03-11  60  	va_end(valist);
169630111a051b Christian König 2022-03-11  61  
169630111a051b Christian König 2022-03-11  62  	array = dma_fence_array_create(num_fences, fences,
169630111a051b Christian König 2022-03-11  63  				       dma_fence_context_alloc(1),
169630111a051b Christian König 2022-03-11  64  				       1, false);
169630111a051b Christian König 2022-03-11  65  	if (!array)
7aa4d35d52466f Christian König 2022-05-04  66  		goto error_free;
169630111a051b Christian König 2022-03-11  67  	return &array->base;
169630111a051b Christian König 2022-03-11  68  
7aa4d35d52466f Christian König 2022-05-04  69  error_free:
169630111a051b Christian König 2022-03-11 @70  	kfree(fences);
7aa4d35d52466f Christian König 2022-05-04  71  
7aa4d35d52466f Christian König 2022-05-04  72  error_put:
7aa4d35d52466f Christian König 2022-05-04  73  	va_start(valist, num_fences);
7aa4d35d52466f Christian König 2022-05-04  74  	for (i = 0; i < num_fences; ++i)
7aa4d35d52466f Christian König 2022-05-04 @75  		dma_fence_put(va_arg(valist, typeof(*fences)));
7aa4d35d52466f Christian König 2022-05-04  76  	va_end(valist);
169630111a051b Christian König 2022-03-11  77  	return NULL;
169630111a051b Christian König 2022-03-11  78  }
169630111a051b Christian König 2022-03-11  79  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

                 reply	other threads:[~2024-12-27 14:06 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202412272143.B9jfMgsY-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=julia.lawall@inria.fr \
    --cc=oe-kbuild@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.