* [cxl:for-6.4/cxl-type-2 17/22] drivers/cxl/core/memdev.c:414 cxl_acquire_endpoint() warn: inconsistent returns '&cxlmd->dev.mutex'.
@ 2023-03-25 5:34 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2023-03-25 5:34 UTC (permalink / raw)
To: oe-kbuild; +Cc: lkp, Dan Carpenter
BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
CC: Alison Schofield <alison.schofield@intel.com>
CC: Vishal Verma <vishal.l.verma@intel.com>
CC: Ira Weiny <ira.weiny@intel.com>
CC: Ben Widawsky <ben.widawsky@intel.com>
CC: Dan Williams <dan.j.williams@intel.com>
CC: linux-cxl@vger.kernel.org
TO: Dan Williams <dan.j.williams@intel.com>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/cxl/cxl.git for-6.4/cxl-type-2
head: 0b80e8b55828313bcd08c4740646689e648de444
commit: 61f6d520258ef0a4e558e7d00442ae9297c6c107 [17/22] cxl/memdev: Indicate probe deferral
:::::: branch date: 5 hours ago
:::::: commit date: 9 hours ago
config: i386-randconfig-m021 (https://download.01.org/0day-ci/archive/20230325/202303251356.rx03HcjE-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-8) 11.3.0
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Dan Carpenter <error27@gmail.com>
| Link: https://lore.kernel.org/r/202303251356.rx03HcjE-lkp@intel.com/
smatch warnings:
drivers/cxl/core/memdev.c:414 cxl_acquire_endpoint() warn: inconsistent returns '&cxlmd->dev.mutex'.
vim +414 drivers/cxl/core/memdev.c
3d135db510240f Ben Widawsky 2021-08-02 383
61f6d520258ef0 Dan Williams 2023-03-22 384 /*
61f6d520258ef0 Dan Williams 2023-03-22 385 * Try to get a locked reference on a memdev's CXL port topology
61f6d520258ef0 Dan Williams 2023-03-22 386 * connection. Be careful to observe when cxl_mem_probe() has deposited
61f6d520258ef0 Dan Williams 2023-03-22 387 * a probe deferral awaiting the arrival of the CXL root driver
61f6d520258ef0 Dan Williams 2023-03-22 388 */
61f6d520258ef0 Dan Williams 2023-03-22 389 struct cxl_port *cxl_acquire_endpoint(struct cxl_memdev *cxlmd)
61f6d520258ef0 Dan Williams 2023-03-22 390 {
61f6d520258ef0 Dan Williams 2023-03-22 391 struct cxl_port *endpoint;
61f6d520258ef0 Dan Williams 2023-03-22 392 int rc = -ENXIO;
61f6d520258ef0 Dan Williams 2023-03-22 393
61f6d520258ef0 Dan Williams 2023-03-22 394 device_lock(&cxlmd->dev);
61f6d520258ef0 Dan Williams 2023-03-22 395 endpoint = cxlmd->endpoint;
61f6d520258ef0 Dan Williams 2023-03-22 396 if (!endpoint)
61f6d520258ef0 Dan Williams 2023-03-22 397 goto err;
61f6d520258ef0 Dan Williams 2023-03-22 398
61f6d520258ef0 Dan Williams 2023-03-22 399 if (IS_ERR(endpoint)) {
61f6d520258ef0 Dan Williams 2023-03-22 400 rc = PTR_ERR(endpoint);
61f6d520258ef0 Dan Williams 2023-03-22 401 goto err;
61f6d520258ef0 Dan Williams 2023-03-22 402 }
61f6d520258ef0 Dan Williams 2023-03-22 403
61f6d520258ef0 Dan Williams 2023-03-22 404 device_lock(&endpoint->dev);
61f6d520258ef0 Dan Williams 2023-03-22 405 if (!endpoint->dev.driver)
61f6d520258ef0 Dan Williams 2023-03-22 406 goto err_endpoint;
61f6d520258ef0 Dan Williams 2023-03-22 407
61f6d520258ef0 Dan Williams 2023-03-22 408 return endpoint;
61f6d520258ef0 Dan Williams 2023-03-22 409
61f6d520258ef0 Dan Williams 2023-03-22 410 err_endpoint:
61f6d520258ef0 Dan Williams 2023-03-22 411 device_unlock(&endpoint->dev);
61f6d520258ef0 Dan Williams 2023-03-22 412 err:
61f6d520258ef0 Dan Williams 2023-03-22 413 device_unlock(&cxlmd->dev);
61f6d520258ef0 Dan Williams 2023-03-22 @414 return ERR_PTR(rc);
61f6d520258ef0 Dan Williams 2023-03-22 415 }
61f6d520258ef0 Dan Williams 2023-03-22 416 EXPORT_SYMBOL_NS(cxl_acquire_endpoint, CXL);
61f6d520258ef0 Dan Williams 2023-03-22 417
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-03-25 5:34 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-25 5:34 [cxl:for-6.4/cxl-type-2 17/22] drivers/cxl/core/memdev.c:414 cxl_acquire_endpoint() warn: inconsistent returns '&cxlmd->dev.mutex' kernel test robot
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.