From: kbuild test robot <lkp@intel.com> To: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com> Cc: intel-gfx@lists.freedesktop.org, kbuild-all@lists.01.org Subject: Re: [Intel-gfx] [PATCH 2/7] drm/i915/guc: Kill USES_GUC_SUBMISSION macro Date: Mon, 27 Jan 2020 11:00:26 +0800 [thread overview] Message-ID: <202001271034.lId7MaKk%lkp@intel.com> (raw) In-Reply-To: <20200115013143.34961-3-daniele.ceraolospurio@intel.com> Hi Daniele, 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 v5.5-rc7 next-20200124] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Daniele-Ceraolo-Spurio/Commit-early-to-GuC/20200116-112105 base: git://anongit.freedesktop.org/drm-intel for-linux-next reproduce: # apt-get install sparse # sparse version: v0.6.1-153-g47b6dfef-dirty make ARCH=x86_64 allmodconfig make C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' If you fix the issue, kindly add following tag Reported-by: kbuild test robot <lkp@intel.com> sparse warnings: (new ones prefixed by >>) >> drivers/gpu/drm/i915/gem/i915_gem_context.c:1457:51: sparse: sparse: dereference of noderef expression vim +1457 drivers/gpu/drm/i915/gem/i915_gem_context.c 1440 1441 static int 1442 set_engines__load_balance(struct i915_user_extension __user *base, void *data) 1443 { 1444 struct i915_context_engines_load_balance __user *ext = 1445 container_of_user(base, typeof(*ext), base); 1446 const struct set_engines *set = data; 1447 struct intel_engine_cs *stack[16]; 1448 struct intel_engine_cs **siblings; 1449 struct intel_context *ce; 1450 u16 num_siblings, idx; 1451 unsigned int n; 1452 int err; 1453 1454 if (!HAS_EXECLISTS(set->ctx->i915)) 1455 return -ENODEV; 1456 > 1457 if (intel_uc_uses_guc_submission(&set->ctx->vm->gt->uc)) 1458 return -ENODEV; /* not implement yet */ 1459 1460 if (get_user(idx, &ext->engine_index)) 1461 return -EFAULT; 1462 1463 if (idx >= set->engines->num_engines) { 1464 DRM_DEBUG("Invalid placement value, %d >= %d\n", 1465 idx, set->engines->num_engines); 1466 return -EINVAL; 1467 } 1468 1469 idx = array_index_nospec(idx, set->engines->num_engines); 1470 if (set->engines->engines[idx]) { 1471 DRM_DEBUG("Invalid placement[%d], already occupied\n", idx); 1472 return -EEXIST; 1473 } 1474 1475 if (get_user(num_siblings, &ext->num_siblings)) 1476 return -EFAULT; 1477 1478 err = check_user_mbz(&ext->flags); 1479 if (err) 1480 return err; 1481 1482 err = check_user_mbz(&ext->mbz64); 1483 if (err) 1484 return err; 1485 1486 siblings = stack; 1487 if (num_siblings > ARRAY_SIZE(stack)) { 1488 siblings = kmalloc_array(num_siblings, 1489 sizeof(*siblings), 1490 GFP_KERNEL); 1491 if (!siblings) 1492 return -ENOMEM; 1493 } 1494 1495 for (n = 0; n < num_siblings; n++) { 1496 struct i915_engine_class_instance ci; 1497 1498 if (copy_from_user(&ci, &ext->engines[n], sizeof(ci))) { 1499 err = -EFAULT; 1500 goto out_siblings; 1501 } 1502 1503 siblings[n] = intel_engine_lookup_user(set->ctx->i915, 1504 ci.engine_class, 1505 ci.engine_instance); 1506 if (!siblings[n]) { 1507 DRM_DEBUG("Invalid sibling[%d]: { class:%d, inst:%d }\n", 1508 n, ci.engine_class, ci.engine_instance); 1509 err = -EINVAL; 1510 goto out_siblings; 1511 } 1512 } 1513 1514 ce = intel_execlists_create_virtual(siblings, n); 1515 if (IS_ERR(ce)) { 1516 err = PTR_ERR(ce); 1517 goto out_siblings; 1518 } 1519 1520 intel_context_set_gem(ce, set->ctx); 1521 1522 if (cmpxchg(&set->engines->engines[idx], NULL, ce)) { 1523 intel_context_put(ce); 1524 err = -EEXIST; 1525 goto out_siblings; 1526 } 1527 1528 out_siblings: 1529 if (siblings != stack) 1530 kfree(siblings); 1531 1532 return err; 1533 } 1534 --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org Intel Corporation _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx
WARNING: multiple messages have this Message-ID (diff)
From: kbuild test robot <lkp@intel.com> To: kbuild-all@lists.01.org Subject: Re: [Intel-gfx] [PATCH 2/7] drm/i915/guc: Kill USES_GUC_SUBMISSION macro Date: Mon, 27 Jan 2020 11:00:26 +0800 [thread overview] Message-ID: <202001271034.lId7MaKk%lkp@intel.com> (raw) In-Reply-To: <20200115013143.34961-3-daniele.ceraolospurio@intel.com> [-- Attachment #1: Type: text/plain, Size: 4185 bytes --] Hi Daniele, 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 v5.5-rc7 next-20200124] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Daniele-Ceraolo-Spurio/Commit-early-to-GuC/20200116-112105 base: git://anongit.freedesktop.org/drm-intel for-linux-next reproduce: # apt-get install sparse # sparse version: v0.6.1-153-g47b6dfef-dirty make ARCH=x86_64 allmodconfig make C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' If you fix the issue, kindly add following tag Reported-by: kbuild test robot <lkp@intel.com> sparse warnings: (new ones prefixed by >>) >> drivers/gpu/drm/i915/gem/i915_gem_context.c:1457:51: sparse: sparse: dereference of noderef expression vim +1457 drivers/gpu/drm/i915/gem/i915_gem_context.c 1440 1441 static int 1442 set_engines__load_balance(struct i915_user_extension __user *base, void *data) 1443 { 1444 struct i915_context_engines_load_balance __user *ext = 1445 container_of_user(base, typeof(*ext), base); 1446 const struct set_engines *set = data; 1447 struct intel_engine_cs *stack[16]; 1448 struct intel_engine_cs **siblings; 1449 struct intel_context *ce; 1450 u16 num_siblings, idx; 1451 unsigned int n; 1452 int err; 1453 1454 if (!HAS_EXECLISTS(set->ctx->i915)) 1455 return -ENODEV; 1456 > 1457 if (intel_uc_uses_guc_submission(&set->ctx->vm->gt->uc)) 1458 return -ENODEV; /* not implement yet */ 1459 1460 if (get_user(idx, &ext->engine_index)) 1461 return -EFAULT; 1462 1463 if (idx >= set->engines->num_engines) { 1464 DRM_DEBUG("Invalid placement value, %d >= %d\n", 1465 idx, set->engines->num_engines); 1466 return -EINVAL; 1467 } 1468 1469 idx = array_index_nospec(idx, set->engines->num_engines); 1470 if (set->engines->engines[idx]) { 1471 DRM_DEBUG("Invalid placement[%d], already occupied\n", idx); 1472 return -EEXIST; 1473 } 1474 1475 if (get_user(num_siblings, &ext->num_siblings)) 1476 return -EFAULT; 1477 1478 err = check_user_mbz(&ext->flags); 1479 if (err) 1480 return err; 1481 1482 err = check_user_mbz(&ext->mbz64); 1483 if (err) 1484 return err; 1485 1486 siblings = stack; 1487 if (num_siblings > ARRAY_SIZE(stack)) { 1488 siblings = kmalloc_array(num_siblings, 1489 sizeof(*siblings), 1490 GFP_KERNEL); 1491 if (!siblings) 1492 return -ENOMEM; 1493 } 1494 1495 for (n = 0; n < num_siblings; n++) { 1496 struct i915_engine_class_instance ci; 1497 1498 if (copy_from_user(&ci, &ext->engines[n], sizeof(ci))) { 1499 err = -EFAULT; 1500 goto out_siblings; 1501 } 1502 1503 siblings[n] = intel_engine_lookup_user(set->ctx->i915, 1504 ci.engine_class, 1505 ci.engine_instance); 1506 if (!siblings[n]) { 1507 DRM_DEBUG("Invalid sibling[%d]: { class:%d, inst:%d }\n", 1508 n, ci.engine_class, ci.engine_instance); 1509 err = -EINVAL; 1510 goto out_siblings; 1511 } 1512 } 1513 1514 ce = intel_execlists_create_virtual(siblings, n); 1515 if (IS_ERR(ce)) { 1516 err = PTR_ERR(ce); 1517 goto out_siblings; 1518 } 1519 1520 intel_context_set_gem(ce, set->ctx); 1521 1522 if (cmpxchg(&set->engines->engines[idx], NULL, ce)) { 1523 intel_context_put(ce); 1524 err = -EEXIST; 1525 goto out_siblings; 1526 } 1527 1528 out_siblings: 1529 if (siblings != stack) 1530 kfree(siblings); 1531 1532 return err; 1533 } 1534 --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org Intel Corporation
next prev parent reply other threads:[~2020-01-27 3:00 UTC|newest] Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-01-15 1:31 [Intel-gfx] [PATCH 0/7] Commit early to GuC Daniele Ceraolo Spurio 2020-01-15 1:31 ` [Intel-gfx] [PATCH 1/7] drm/i915/guc: Kill USES_GUC macro Daniele Ceraolo Spurio 2020-01-16 19:42 ` Michal Wajdeczko 2020-01-16 20:24 ` Daniele Ceraolo Spurio 2020-01-15 1:31 ` [Intel-gfx] [PATCH 2/7] drm/i915/guc: Kill USES_GUC_SUBMISSION macro Daniele Ceraolo Spurio 2020-01-16 19:49 ` Michal Wajdeczko 2020-01-16 20:42 ` Daniele Ceraolo Spurio 2020-01-16 22:49 ` Michal Wajdeczko 2020-01-16 23:09 ` Daniele Ceraolo Spurio 2020-01-27 3:00 ` kbuild test robot [this message] 2020-01-27 3:00 ` kbuild test robot 2020-01-15 1:31 ` [Intel-gfx] [PATCH 3/7] drm/i915/uc: Improve tracking of uC init status Daniele Ceraolo Spurio 2020-01-27 23:57 ` Fernando Pacheco 2020-01-15 1:31 ` [Intel-gfx] [PATCH 4/7] drm/i915/uc: Abort early on uc_init failure Daniele Ceraolo Spurio 2020-01-27 23:57 ` Fernando Pacheco 2020-01-15 1:31 ` [Intel-gfx] [PATCH 5/7] drm/i915/guc: Apply new uC status tracking to GuC submission as well Daniele Ceraolo Spurio 2020-01-15 1:31 ` [Intel-gfx] [PATCH 6/7] drm/i915/guc: Start considering GuC submission a proper back-end Daniele Ceraolo Spurio 2020-01-15 1:31 ` [Intel-gfx] [PATCH 7/7] HAX: force enable_guc=2 Daniele Ceraolo Spurio 2020-01-15 2:09 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for Commit early to GuC Patchwork 2020-01-15 2:29 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork 2020-01-15 2:29 ` [Intel-gfx] ✗ Fi.CI.BUILD: warning " Patchwork 2020-01-15 8:40 ` [Intel-gfx] [PATCH 0/7] " Chris Wilson 2020-01-15 15:57 ` Daniele Ceraolo Spurio 2020-01-15 16:18 ` Chris Wilson 2020-01-15 20:46 ` Daniele Ceraolo Spurio 2020-01-17 8:38 ` [Intel-gfx] ✓ Fi.CI.IGT: success for " Patchwork
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=202001271034.lId7MaKk%lkp@intel.com \ --to=lkp@intel.com \ --cc=daniele.ceraolospurio@intel.com \ --cc=intel-gfx@lists.freedesktop.org \ --cc=kbuild-all@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: linkBe 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.