All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild@lists.01.org
Subject: Re: [Intel-gfx] [PATCH 07/23] drm/i915: Switch to object allocations for page directories
Date: Sat, 04 Jul 2020 05:47:07 +0800	[thread overview]
Message-ID: <202007040530.iF8IVN2s%lkp@intel.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 4596 bytes --]

CC: kbuild-all(a)lists.01.org
In-Reply-To: <20200702083225.20044-7-chris@chris-wilson.co.uk>
References: <20200702083225.20044-7-chris@chris-wilson.co.uk>
TO: Chris Wilson <chris@chris-wilson.co.uk>
TO: intel-gfx(a)lists.freedesktop.org
CC: Chris Wilson <chris@chris-wilson.co.uk>

Hi Chris,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on drm-intel/for-linux-next]
[cannot apply to drm-tip/drm-tip linus/master v5.8-rc3 next-20200703]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use  as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Chris-Wilson/drm-i915-Drop-vm-ref-for-duplicate-vma-on-construction/20200702-170652
base:   git://anongit.freedesktop.org/drm-intel for-linux-next
:::::: branch date: 2 days ago
:::::: commit date: 2 days ago
config: i386-randconfig-m021-20200701 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-14) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>

New smatch warnings:
drivers/gpu/drm/i915/gt/intel_ppgtt.c:210 i915_vm_alloc_pt_stash() warn: passing a valid pointer to 'PTR_ERR'

Old smatch warnings:
drivers/gpu/drm/i915/gt/intel_ppgtt.c:226 i915_vm_alloc_pt_stash() warn: passing a valid pointer to 'PTR_ERR'

# https://github.com/0day-ci/linux/commit/1571ff000725fd4ad0d04542dba12d14f845292c
git remote add linux-review https://github.com/0day-ci/linux
git remote update linux-review
git checkout 1571ff000725fd4ad0d04542dba12d14f845292c
vim +/PTR_ERR +210 drivers/gpu/drm/i915/gt/intel_ppgtt.c

b05beb6b7751f9 Chris Wilson 2020-07-02  194  
b05beb6b7751f9 Chris Wilson 2020-07-02  195  int i915_vm_alloc_pt_stash(struct i915_address_space *vm,
b05beb6b7751f9 Chris Wilson 2020-07-02  196  			   struct i915_vm_pt_stash *stash,
b05beb6b7751f9 Chris Wilson 2020-07-02  197  			   u64 size)
b05beb6b7751f9 Chris Wilson 2020-07-02  198  {
b05beb6b7751f9 Chris Wilson 2020-07-02  199  	unsigned long count;
b05beb6b7751f9 Chris Wilson 2020-07-02  200  	int shift = 21;
b05beb6b7751f9 Chris Wilson 2020-07-02  201  	int n;
b05beb6b7751f9 Chris Wilson 2020-07-02  202  
b05beb6b7751f9 Chris Wilson 2020-07-02  203  	count = pd_count(size, shift);
b05beb6b7751f9 Chris Wilson 2020-07-02  204  	while (count--) {
b05beb6b7751f9 Chris Wilson 2020-07-02  205  		struct i915_page_table *pt;
b05beb6b7751f9 Chris Wilson 2020-07-02  206  
b05beb6b7751f9 Chris Wilson 2020-07-02  207  		pt = alloc_pt(vm);
b05beb6b7751f9 Chris Wilson 2020-07-02  208  		if (IS_ERR(pt)) {
b05beb6b7751f9 Chris Wilson 2020-07-02  209  			i915_vm_free_pt_stash(vm, stash);
b05beb6b7751f9 Chris Wilson 2020-07-02 @210  			return PTR_ERR(pt);
b05beb6b7751f9 Chris Wilson 2020-07-02  211  		}
b05beb6b7751f9 Chris Wilson 2020-07-02  212  
b05beb6b7751f9 Chris Wilson 2020-07-02  213  		pt->stash = stash->pt[0];
b05beb6b7751f9 Chris Wilson 2020-07-02  214  		stash->pt[0] = pt;
b05beb6b7751f9 Chris Wilson 2020-07-02  215  	}
b05beb6b7751f9 Chris Wilson 2020-07-02  216  
b05beb6b7751f9 Chris Wilson 2020-07-02  217  	for (n = 1; n < vm->top; n++) {
b05beb6b7751f9 Chris Wilson 2020-07-02  218  		shift += 9;
b05beb6b7751f9 Chris Wilson 2020-07-02  219  		count = pd_count(size, shift);
b05beb6b7751f9 Chris Wilson 2020-07-02  220  		while (count--) {
b05beb6b7751f9 Chris Wilson 2020-07-02  221  			struct i915_page_directory *pd;
b05beb6b7751f9 Chris Wilson 2020-07-02  222  
b05beb6b7751f9 Chris Wilson 2020-07-02  223  			pd = alloc_pd(vm);
b05beb6b7751f9 Chris Wilson 2020-07-02  224  			if (IS_ERR(pd)) {
b05beb6b7751f9 Chris Wilson 2020-07-02  225  				i915_vm_free_pt_stash(vm, stash);
b05beb6b7751f9 Chris Wilson 2020-07-02  226  				return PTR_ERR(pd);
b05beb6b7751f9 Chris Wilson 2020-07-02  227  			}
b05beb6b7751f9 Chris Wilson 2020-07-02  228  
b05beb6b7751f9 Chris Wilson 2020-07-02  229  			pd->pt.stash = stash->pt[1];
b05beb6b7751f9 Chris Wilson 2020-07-02  230  			stash->pt[1] = &pd->pt;
b05beb6b7751f9 Chris Wilson 2020-07-02  231  		}
b05beb6b7751f9 Chris Wilson 2020-07-02  232  	}
b05beb6b7751f9 Chris Wilson 2020-07-02  233  
b05beb6b7751f9 Chris Wilson 2020-07-02  234  	return 0;
b05beb6b7751f9 Chris Wilson 2020-07-02  235  }
b05beb6b7751f9 Chris Wilson 2020-07-02  236  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 41842 bytes --]

             reply	other threads:[~2020-07-03 21:47 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-03 21:47 kernel test robot [this message]
  -- strict thread matches above, loose matches on Subject: below --
2020-07-02  8:32 [Intel-gfx] [PATCH 01/23] drm/i915: Drop vm.ref for duplicate vma on construction Chris Wilson
2020-07-02  8:32 ` [Intel-gfx] [PATCH 07/23] drm/i915: Switch to object allocations for page directories Chris Wilson
2020-07-03  8:44   ` Tvrtko Ursulin
2020-07-03  9:00     ` Chris Wilson
2020-07-03  9:24       ` Tvrtko Ursulin
2020-07-03  9:49         ` Chris Wilson
2020-07-03 16:34           ` Tvrtko Ursulin
2020-07-03 16:36   ` Tvrtko Ursulin

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=202007040530.iF8IVN2s%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild@lists.01.org \
    /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.