Skip to content

Commit f7813ad

Browse files
committed
Merge tag 'for-linus-4.6' of git://git.code.sf.net/p/openipmi/linux-ipmi
Pull IPMI updates from Corey Minyard: "Just some minor fixes, nothing big" * tag 'for-linus-4.6' of git://git.code.sf.net/p/openipmi/linux-ipmi: ipmi: do not probe ACPI devices if si_tryacpi is unset ipmi_si: Avoid a wrong long timeout on transaction done ipmi_si: Fix module parameter doc names ipmi_ssif: Fix logic around alert handling
2 parents 12e7b0a + 9f0257b commit f7813ad

File tree

2 files changed

+11
-13
lines changed

2 files changed

+11
-13
lines changed

drivers/char/ipmi/ipmi_si_intf.c

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -849,7 +849,7 @@ static enum si_sm_result smi_event_handler(struct smi_info *smi_info,
849849
smi_inc_stat(smi_info, complete_transactions);
850850

851851
handle_transaction_done(smi_info);
852-
si_sm_result = smi_info->handlers->event(smi_info->si_sm, 0);
852+
goto restart;
853853
} else if (si_sm_result == SI_SM_HOSED) {
854854
smi_inc_stat(smi_info, hosed_count);
855855

@@ -866,7 +866,7 @@ static enum si_sm_result smi_event_handler(struct smi_info *smi_info,
866866
*/
867867
return_hosed_msg(smi_info, IPMI_ERR_UNSPECIFIED);
868868
}
869-
si_sm_result = smi_info->handlers->event(smi_info->si_sm, 0);
869+
goto restart;
870870
}
871871

872872
/*
@@ -1363,12 +1363,12 @@ MODULE_PARM_DESC(trydmi, "Setting this to zero will disable the"
13631363
" default scan of the interfaces identified via DMI");
13641364
#endif
13651365
module_param_named(tryplatform, si_tryplatform, bool, 0);
1366-
MODULE_PARM_DESC(tryacpi, "Setting this to zero will disable the"
1366+
MODULE_PARM_DESC(tryplatform, "Setting this to zero will disable the"
13671367
" default scan of the interfaces identified via platform"
13681368
" interfaces like openfirmware");
13691369
#ifdef CONFIG_PCI
13701370
module_param_named(trypci, si_trypci, bool, 0);
1371-
MODULE_PARM_DESC(tryacpi, "Setting this to zero will disable the"
1371+
MODULE_PARM_DESC(trypci, "Setting this to zero will disable the"
13721372
" default scan of the interfaces identified via pci");
13731373
#endif
13741374
module_param_named(trydefaults, si_trydefaults, bool, 0);
@@ -2690,6 +2690,9 @@ static int acpi_ipmi_probe(struct platform_device *dev)
26902690
unsigned long long tmp;
26912691
int rv = -EINVAL;
26922692

2693+
if (!si_tryacpi)
2694+
return 0;
2695+
26932696
handle = ACPI_HANDLE(&dev->dev);
26942697
if (!handle)
26952698
return -ENODEV;

drivers/char/ipmi/ipmi_ssif.c

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -920,23 +920,18 @@ static void msg_written_handler(struct ssif_info *ssif_info, int result,
920920
msg_done_handler(ssif_info, -EIO, NULL, 0);
921921
}
922922
} else {
923+
/* Ready to request the result. */
923924
unsigned long oflags, *flags;
924-
bool got_alert;
925925

926926
ssif_inc_stat(ssif_info, sent_messages);
927927
ssif_inc_stat(ssif_info, sent_messages_parts);
928928

929929
flags = ipmi_ssif_lock_cond(ssif_info, &oflags);
930-
got_alert = ssif_info->got_alert;
931-
if (got_alert) {
930+
if (ssif_info->got_alert) {
931+
/* The result is already ready, just start it. */
932932
ssif_info->got_alert = false;
933-
ssif_info->waiting_alert = false;
934-
}
935-
936-
if (got_alert) {
937933
ipmi_ssif_unlock_cond(ssif_info, flags);
938-
/* The alert already happened, try now. */
939-
retry_timeout((unsigned long) ssif_info);
934+
start_get(ssif_info);
940935
} else {
941936
/* Wait a jiffie then request the next message */
942937
ssif_info->waiting_alert = true;

0 commit comments

Comments
 (0)