Commit 7f569e91 authored by Li Ming's avatar Li Ming Committed by Dave Jiang
Browse files

cxl/port: Use scoped_guard()/guard() to drop device_lock() for cxl_port



A device_lock() and device_unlock() pair can be replaced by a cleanup
helper scoped_guard() or guard(), that can enhance code readability. In
CXL subsystem, still use device_lock() and device_unlock() pairs for cxl
port resource protection, most of them can be replaced by a
scoped_guard() or a guard() simply.

Suggested-by: default avatarDan Williams <dan.j.williams@intel.com>
Signed-off-by: default avatarLi Ming <ming4.li@intel.com>
Reviewed-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
Link: https://patch.msgid.link/20240830013138.2256244-2-ming4.li@intel.com


Signed-off-by: default avatarDave Jiang <dave.jiang@intel.com>
parent dd2617eb
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment