diff options
author | Colin Ian King <colin.i.king@gmail.com> | 2025-07-08 16:18:05 +0100 |
---|---|---|
committer | Corey Minyard <corey@minyard.net> | 2025-07-08 12:15:44 -0500 |
commit | f6f9760320a93930e70ad6016afbabc475bcdd09 (patch) | |
tree | 435514e7cd889624854211e0c08722956728a533 | |
parent | 8ffcb7560b4a15faf821df95e3ab532b2b020f8c (diff) |
char: ipmi: remove redundant variable 'type' and check
The variable 'type' is assigned the value SI_INVALID which is zero
and later checks of 'type' is non-zero (which is always false). The
variable is not referenced anywhere else, so it is redundant and
so is the check, so remove these.
Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Message-ID: <20250708151805.1893858-1-colin.i.king@gmail.com>
Signed-off-by: Corey Minyard <corey@minyard.net>
-rw-r--r-- | drivers/char/ipmi/ipmi_si_intf.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c index 7fe891783a37..064cc463313d 100644 --- a/drivers/char/ipmi/ipmi_si_intf.c +++ b/drivers/char/ipmi/ipmi_si_intf.c @@ -2107,7 +2107,6 @@ static bool __init ipmi_smi_info_same(struct smi_info *e1, struct smi_info *e2) static int __init init_ipmi_si(void) { struct smi_info *e, *e2; - enum ipmi_addr_src type = SI_INVALID; if (initialized) return 0; @@ -2189,9 +2188,6 @@ static int __init init_ipmi_si(void) initialized = true; mutex_unlock(&smi_infos_lock); - if (type) - return 0; - mutex_lock(&smi_infos_lock); if (unload_when_empty && list_empty(&smi_infos)) { mutex_unlock(&smi_infos_lock); |