From 41147b006be2174b825a54b0620ecf4cc7ec5c84 Mon Sep 17 00:00:00 2001 From: Colin Ian King Date: Mon, 15 Apr 2024 11:19:28 +0100 Subject: dax: remove redundant assignment to variable rc The variable rc is being assigned an value and then is being re-assigned a new value in the next statement. The assignment is redundant and can be removed. Cleans up clang scan build warning: drivers/dax/bus.c:1207:2: warning: Value stored to 'rc' is never read [deadcode.DeadStores] Signed-off-by: Colin Ian King Reviewed-by: Alison Schofield Reviewed-by: Dave Jiang Reviewed-by: Vishal Verma Link: https://lore.kernel.org/r/20240415101928.484143-1-colin.i.king@gmail.com Signed-off-by: Ira Weiny --- drivers/dax/bus.c | 1 - 1 file changed, 1 deletion(-) (limited to 'drivers') diff --git a/drivers/dax/bus.c b/drivers/dax/bus.c index 018f81ec82ac..6ec5db8013e8 100644 --- a/drivers/dax/bus.c +++ b/drivers/dax/bus.c @@ -1204,7 +1204,6 @@ static ssize_t mapping_store(struct device *dev, struct device_attribute *attr, if (rc) return rc; - rc = -ENXIO; rc = down_write_killable(&dax_region_rwsem); if (rc) return rc; -- cgit v1.2.3