From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id CD9B1C433F5 for ; Tue, 1 Feb 2022 07:53:32 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 2C9A76B0170; Tue, 1 Feb 2022 02:53:32 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 279106B0172; Tue, 1 Feb 2022 02:53:32 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 1420C6B0173; Tue, 1 Feb 2022 02:53:32 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0095.hostedemail.com [216.40.44.95]) by kanga.kvack.org (Postfix) with ESMTP id 05D426B0170 for ; Tue, 1 Feb 2022 02:53:32 -0500 (EST) Received: from smtpin17.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id A2B24972F0 for ; Tue, 1 Feb 2022 07:53:31 +0000 (UTC) X-FDA: 79093446222.17.FA27256 Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by imf20.hostedemail.com (Postfix) with ESMTP id B49131C0002 for ; Tue, 1 Feb 2022 07:53:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1643702010; x=1675238010; h=date:from:to:cc:subject:message-id:mime-version: content-transfer-encoding; bh=M9Mc+8MXZtRYongnYjn+zGcP24akD0fJx0uswZ97HOE=; b=M4vqi74nuDPL9jnhqUf7m5vLRMQH10JrppsbDBNl+jIxma7aXnNY33Qk hzwM6eZKNzQc9owXbFfQKnh6R47oNLs+12ehgDgyMOMm0Ti1b3MxreMqo DLmiOH4nxXpZr2wmlDtGp6vzc39Gm2YpcyE0+vMF6EMqV5qmU/+iJ1nEu YQIjMWyouDuKSlUA0wWkGr1sSyHoV11wWqBtDymwDHxetpGYwgEA8thsI mna32vtiisbi9flfqW9qvB1l7SN6MYd25f+/k5v1X9xPsUnnVjMIFUfvm gYI70+CyKjQv8OhMB3qKRXTvhCAWV3wQ/p6ZGoO3Vjb9rRvJAO6wahGl5 w==; X-IronPort-AV: E=McAfee;i="6200,9189,10244"; a="246471728" X-IronPort-AV: E=Sophos;i="5.88,333,1635231600"; d="scan'208";a="246471728" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 31 Jan 2022 23:53:29 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,333,1635231600"; d="scan'208";a="630318848" Received: from lkp-server01.sh.intel.com (HELO 276f1b88eecb) ([10.239.97.150]) by orsmga004.jf.intel.com with ESMTP; 31 Jan 2022 23:53:27 -0800 Received: from kbuild by 276f1b88eecb with local (Exim 4.92) (envelope-from ) id 1nEnyg-000Sza-EG; Tue, 01 Feb 2022 07:53:26 +0000 Date: Tue, 1 Feb 2022 15:52:42 +0800 From: kernel test robot To: Dan Carpenter Cc: llvm@lists.linux.dev, kbuild-all@lists.01.org, Linux Memory Management List , Tvrtko Ursulin , Rodrigo Vivi Subject: [linux-next:pending-fixes 164/228] drivers/gpu/drm/i915/i915_vma.c:451:4: error: use of undeclared identifier 'ret' Message-ID: <202202011539.ovkZEMAZ-lkp@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) X-Rspamd-Server: rspam09 X-Rspamd-Queue-Id: B49131C0002 X-Stat-Signature: 344n64ac3xeta7gzftoj4yxceaz7qu36 X-Rspam-User: nil Authentication-Results: imf20.hostedemail.com; dkim=pass header.d=intel.com header.s=Intel header.b=M4vqi74n; spf=none (imf20.hostedemail.com: domain of lkp@intel.com has no SPF policy when checking 192.55.52.120) smtp.mailfrom=lkp@intel.com; dmarc=pass (policy=none) header.from=intel.com X-HE-Tag: 1643702010-361709 Content-Transfer-Encoding: quoted-printable X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.g= it pending-fixes head: a7fc3604a297400b1140adf29cc29de7bf17e4f3 commit: 2e872d87cbf2cd02dca570ee187cf35567576a70 [164/228] drm/i915: dele= te shadow "ret" variable config: i386-randconfig-a011-20220131 (https://download.01.org/0day-ci/ar= chive/20220201/202202011539.ovkZEMAZ-lkp@intel.com/config) compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 2cdb= aca3943a4d6259119f185656328bd3805b68) reproduce (this is a W=3D1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbi= n/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next= .git/commit/?id=3D2e872d87cbf2cd02dca570ee187cf35567576a70 git remote add linux-next https://git.kernel.org/pub/scm/linux/ke= rnel/git/next/linux-next.git git fetch --no-tags linux-next pending-fixes git checkout 2e872d87cbf2cd02dca570ee187cf35567576a70 # save the config file to linux build tree mkdir build_dir COMPILER_INSTALL_PATH=3D$HOME/0day COMPILER=3Dclang make.cross W=3D= 1 O=3Dbuild_dir ARCH=3Di386 SHELL=3D/bin/bash If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot Note: the linux-next/pending-fixes HEAD a7fc3604a297400b1140adf29cc29de7b= f17e4f3 builds fine. It only hurts bisectability. All errors (new ones prefixed by >>): >> drivers/gpu/drm/i915/i915_vma.c:451:4: error: use of undeclared identi= fier 'ret' ret =3D i915_gem_object_wait_moving_fence(vma-= >obj, true); ^ drivers/gpu/drm/i915/i915_vma.c:452:8: error: use of undeclared identi= fier 'ret' if (ret) ^ drivers/gpu/drm/i915/i915_vma.c:453:12: error: use of undeclared ident= ifier 'ret' return ret; ^ 3 errors generated. vim +/ret +451 drivers/gpu/drm/i915/i915_vma.c f6c466b84cfa78 Maarten Lankhorst 2021-11-22 376 =20 b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 377 /** b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 378 * i915_vma_bind -= Sets up PTEs for an VMA in it's corresponding address space. b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 379 * @vma: VMA to ma= p b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 380 * @cache_level: m= apping cache level b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 381 * @flags: flags l= ike global or local mapping 2850748ef8763a Chris Wilson 2019-10-04 382 * @work: prealloc= ated worker for allocating and binding the PTE b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 383 * b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 384 * DMA addresses a= re taken from the scatter-gather table of this object (or of b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 385 * this VMA in cas= e of non-default GGTT views) and PTE entries set up. b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 386 * Note that DMA a= ddresses are also the only part of the SG table we care about. b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 387 */ 2850748ef8763a Chris Wilson 2019-10-04 388 int i915_vma_bind(= struct i915_vma *vma, 2850748ef8763a Chris Wilson 2019-10-04 389 enum i915_cach= e_level cache_level, 2850748ef8763a Chris Wilson 2019-10-04 390 u32 flags, 2850748ef8763a Chris Wilson 2019-10-04 391 struct i915_vm= a_work *work) b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 392 { b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 393 u32 bind_flags; b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 394 u32 vma_flags; b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 395 =20 c2ea703dcafccf Thomas Hellstr=F6m 2021-12-21 396 lockdep_assert_= held(&vma->vm->mutex); aa149431279166 Chris Wilson 2017-02-25 397 GEM_BUG_ON(!drm_m= m_node_allocated(&vma->node)); aa149431279166 Chris Wilson 2017-02-25 398 GEM_BUG_ON(vma->s= ize > vma->node.size); aa149431279166 Chris Wilson 2017-02-25 399 =20 bbb8a9d7e000c9 Tvrtko Ursulin 2018-10-12 400 if (GEM_DEBUG_WAR= N_ON(range_overflows(vma->node.start, aa149431279166 Chris Wilson 2017-02-25 401 vma->no= de.size, aa149431279166 Chris Wilson 2017-02-25 402 vma->vm= ->total))) aa149431279166 Chris Wilson 2017-02-25 403 return -ENODEV; aa149431279166 Chris Wilson 2017-02-25 404 =20 bbb8a9d7e000c9 Tvrtko Ursulin 2018-10-12 405 if (GEM_DEBUG_WAR= N_ON(!flags)) b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 406 return -EINVAL; b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 407 =20 2850748ef8763a Chris Wilson 2019-10-04 408 bind_flags =3D fl= ags; 2850748ef8763a Chris Wilson 2019-10-04 409 bind_flags &=3D I= 915_VMA_GLOBAL_BIND | I915_VMA_LOCAL_BIND; b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 410 =20 4dd2fbbfb532d0 Chris Wilson 2019-09-11 411 vma_flags =3D ato= mic_read(&vma->flags); 4dd2fbbfb532d0 Chris Wilson 2019-09-11 412 vma_flags &=3D I9= 15_VMA_GLOBAL_BIND | I915_VMA_LOCAL_BIND; aedbe0a1af585e Chris Wilson 2020-05-21 413 =20 b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 414 bind_flags &=3D ~= vma_flags; b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 415 if (bind_flags =3D= =3D 0) b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 416 return 0; b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 417 =20 0b4d1f0e936e5c Maarten Lankhorst 2021-12-16 418 GEM_BUG_ON(!atomi= c_read(&vma->pages_count)); fa3f46afd38cec Matthew Auld 2017-10-06 419 =20 6146e6da5c9617 Daniele Ceraolo Spurio 2017-01-20 420 trace_i915_vma_bi= nd(vma, bind_flags); aedbe0a1af585e Chris Wilson 2020-05-21 421 if (work && bind_= flags & vma->vm->bind_async_flags) { e3793468b4660a Chris Wilson 2020-01-30 422 struct dma_fence= *prev; e3793468b4660a Chris Wilson 2020-01-30 423 =20 2850748ef8763a Chris Wilson 2019-10-04 424 work->vma =3D vm= a; 2850748ef8763a Chris Wilson 2019-10-04 425 work->cache_leve= l =3D cache_level; 12b07256c22399 Chris Wilson 2020-07-03 426 work->flags =3D = bind_flags; 2850748ef8763a Chris Wilson 2019-10-04 427 =20 2850748ef8763a Chris Wilson 2019-10-04 428 /* 2850748ef8763a Chris Wilson 2019-10-04 429 * Note we only = want to chain up to the migration fence on 2850748ef8763a Chris Wilson 2019-10-04 430 * the pages (no= t the object itself). As we don't track that, 2850748ef8763a Chris Wilson 2019-10-04 431 * yet, we have = to use the exclusive fence instead. 2850748ef8763a Chris Wilson 2019-10-04 432 * 2850748ef8763a Chris Wilson 2019-10-04 433 * Also note tha= t we do not want to track the async vma as 2850748ef8763a Chris Wilson 2019-10-04 434 * part of the o= bj->resv->excl_fence as it only affects 2850748ef8763a Chris Wilson 2019-10-04 435 * execution and= not content or object's backing store lifetime. 2850748ef8763a Chris Wilson 2019-10-04 436 */ e3793468b4660a Chris Wilson 2020-01-30 437 prev =3D i915_ac= tive_set_exclusive(&vma->active, &work->base.dma); 30ca04e16cbeea Chris Wilson 2020-02-03 438 if (prev) { e3793468b4660a Chris Wilson 2020-01-30 439 __i915_sw_fence= _await_dma_fence(&work->base.chain, e3793468b4660a Chris Wilson 2020-01-30 440 prev, e3793468b4660a Chris Wilson 2020-01-30 441 &work->cb); 30ca04e16cbeea Chris Wilson 2020-02-03 442 dma_fence_put(p= rev); 30ca04e16cbeea Chris Wilson 2020-02-03 443 } e3793468b4660a Chris Wilson 2020-01-30 444 =20 2850748ef8763a Chris Wilson 2019-10-04 445 work->base.dma.e= rror =3D 0; /* enable the queue_work() */ 2850748ef8763a Chris Wilson 2019-10-04 446 =20 2850748ef8763a Chris Wilson 2019-10-04 447 __i915_gem_objec= t_pin_pages(vma->obj); 537457a979a02a Chris Wilson 2020-11-02 448 work->pinned =3D= i915_gem_object_get(vma->obj); 2850748ef8763a Chris Wilson 2019-10-04 449 } else { f6c466b84cfa78 Maarten Lankhorst 2021-11-22 450 if (vma->obj) { f6c466b84cfa78 Maarten Lankhorst 2021-11-22 @451 ret =3D i915_ge= m_object_wait_moving_fence(vma->obj, true); f6c466b84cfa78 Maarten Lankhorst 2021-11-22 452 if (ret) f6c466b84cfa78 Maarten Lankhorst 2021-11-22 453 return ret; f6c466b84cfa78 Maarten Lankhorst 2021-11-22 454 } cd0452aa2a0d14 Chris Wilson 2020-07-29 455 vma->ops->bind_v= ma(vma->vm, NULL, vma, cache_level, bind_flags); 2850748ef8763a Chris Wilson 2019-10-04 456 } b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 457 =20 7938d61591d333 Tvrtko Ursulin 2021-10-19 458 if (vma->obj) 7938d61591d333 Tvrtko Ursulin 2021-10-19 459 set_bit(I915_BO_= WAS_BOUND_BIT, &vma->obj->flags); 7938d61591d333 Tvrtko Ursulin 2021-10-19 460 =20 4dd2fbbfb532d0 Chris Wilson 2019-09-11 461 atomic_or(bind_fl= ags, &vma->flags); b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 462 return 0; b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 463 } b42fe9ca0a1e2b Joonas Lahtinen 2016-11-11 464 =20 :::::: The code at line 451 was first introduced by commit :::::: f6c466b84cfa78807b7f71b8adeaf209b4deb72f drm/i915: Add support for= moving fence waiting :::::: TO: Maarten Lankhorst :::::: CC: Thomas Hellstr=F6m --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org