mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-15 19:01:45 -04:00
usb: typec: mux: remove redundant check on variable match
All the code paths that lead to the return statement are where
match is always true, hence the check to see if it is true is
redundant and can be removed.
Detected by CoverityScan, CID#14769672 ("Logically dead code")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
98bba546e8
commit
eb76b37aaf
@@ -184,7 +184,7 @@ static void *typec_mux_match(struct device_connection *con, int ep, void *data)
|
||||
if (dev_fwnode(mux->dev) == con->fwnode)
|
||||
return mux;
|
||||
|
||||
return match ? ERR_PTR(-EPROBE_DEFER) : NULL;
|
||||
return ERR_PTR(-EPROBE_DEFER);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user