Skip to content
Commit 3ad4f59f authored by Li Ming's avatar Li Ming Committed by Dave Jiang
Browse files

cxl/core: cxl_mem_sanitize() cleanup



In cxl_mem_sanitize(), the down_read() and up_read() for
cxl_region_rwsem can be simply replaced by a guard(rwsem_read), and the
local variable 'rc' can be removed.

Reviewed-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: default avatarDave Jiang <dave.jiang@intel.com>
Reviewed-by: default avatarAlison Schofield <alison.schofield@intel.com>
Reviewed-by: default avatarIra Weiny <ira.weiny@intel.com>
Acked-by: default avatarDavidlohr Bueso <dave@stgolabs.net>
Signed-off-by: default avatarLi Ming <ming.li@zohomail.com>
Link: https://patch.msgid.link/20250221012453.126366-3-ming.li@zohomail.com


Signed-off-by: default avatarDave Jiang <dave.jiang@intel.com>
parent eeba7474
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment