Skip to content

Commit f6f9760

Browse files
ColinIanKingcminyard
authored andcommitted
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 <[email protected]> Message-ID: <[email protected]> Signed-off-by: Corey Minyard <[email protected]>
1 parent 8ffcb75 commit f6f9760

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

drivers/char/ipmi/ipmi_si_intf.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2107,7 +2107,6 @@ static bool __init ipmi_smi_info_same(struct smi_info *e1, struct smi_info *e2)
21072107
static int __init init_ipmi_si(void)
21082108
{
21092109
struct smi_info *e, *e2;
2110-
enum ipmi_addr_src type = SI_INVALID;
21112110

21122111
if (initialized)
21132112
return 0;
@@ -2189,9 +2188,6 @@ static int __init init_ipmi_si(void)
21892188
initialized = true;
21902189
mutex_unlock(&smi_infos_lock);
21912190

2192-
if (type)
2193-
return 0;
2194-
21952191
mutex_lock(&smi_infos_lock);
21962192
if (unload_when_empty && list_empty(&smi_infos)) {
21972193
mutex_unlock(&smi_infos_lock);

0 commit comments

Comments
 (0)