Code Review
/
kvmfornfv.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
These changes are the raw update to linux-4.4.6-rt14. Kernel sources
[kvmfornfv.git]
/
kernel
/
drivers
/
char
/
ipmi
/
ipmi_ssif.c
diff --git
a/kernel/drivers/char/ipmi/ipmi_ssif.c
b/kernel/drivers/char/ipmi/ipmi_ssif.c
index
207689c
..
90e6246
100644
(file)
--- a/
kernel/drivers/char/ipmi/ipmi_ssif.c
+++ b/
kernel/drivers/char/ipmi/ipmi_ssif.c
@@
-52,6
+52,7
@@
#include <linux/kthread.h>
#include <linux/acpi.h>
#include <linux/ctype.h>
#include <linux/kthread.h>
#include <linux/acpi.h>
#include <linux/ctype.h>
+#include <linux/time64.h>
#define PFX "ipmi_ssif: "
#define DEVICE_NAME "ipmi_ssif"
#define PFX "ipmi_ssif: "
#define DEVICE_NAME "ipmi_ssif"
@@
-1041,12
+1042,12
@@
static void sender(void *send_info,
start_next_msg(ssif_info, flags);
if (ssif_info->ssif_debug & SSIF_DEBUG_TIMING) {
start_next_msg(ssif_info, flags);
if (ssif_info->ssif_debug & SSIF_DEBUG_TIMING) {
- struct time
val
t;
+ struct time
spec64
t;
-
do_gettimeofday
(&t);
- pr_info("**Enqueue %02x %02x: %ld.%6.6ld\n",
+
ktime_get_real_ts64
(&t);
+ pr_info("**Enqueue %02x %02x: %l
l
d.%6.6ld\n",
msg->data[0], msg->data[1],
msg->data[0], msg->data[1],
- (long
) t.tv_sec, (long) t.tv_usec
);
+ (long
long) t.tv_sec, (long) t.tv_nsec / NSEC_PER_USEC
);
}
}
}
}
@@
-1136,6
+1137,10
@@
module_param_array(slave_addrs, int, &num_slave_addrs, 0);
MODULE_PARM_DESC(slave_addrs,
"The default IPMB slave address for the controller.");
MODULE_PARM_DESC(slave_addrs,
"The default IPMB slave address for the controller.");
+static bool alerts_broken;
+module_param(alerts_broken, bool, 0);
+MODULE_PARM_DESC(alerts_broken, "Don't enable alerts for the controller.");
+
/*
* Bit 0 enables message debugging, bit 1 enables state debugging, and
* bit 2 enables timing debugging. This is an array indexed by
/*
* Bit 0 enables message debugging, bit 1 enables state debugging, and
* bit 2 enables timing debugging. This is an array indexed by
@@
-1154,11
+1159,11
@@
static int use_thread;
module_param(use_thread, int, 0);
MODULE_PARM_DESC(use_thread, "Use the thread interface.");
module_param(use_thread, int, 0);
MODULE_PARM_DESC(use_thread, "Use the thread interface.");
-static bool ssif_tryacpi =
1
;
+static bool ssif_tryacpi =
true
;
module_param_named(tryacpi, ssif_tryacpi, bool, 0);
MODULE_PARM_DESC(tryacpi, "Setting this to zero will disable the default scan of the interfaces identified via ACPI");
module_param_named(tryacpi, ssif_tryacpi, bool, 0);
MODULE_PARM_DESC(tryacpi, "Setting this to zero will disable the default scan of the interfaces identified via ACPI");
-static bool ssif_trydmi =
1
;
+static bool ssif_trydmi =
true
;
module_param_named(trydmi, ssif_trydmi, bool, 0);
MODULE_PARM_DESC(trydmi, "Setting this to zero will disable the default scan of the interfaces identified via DMI (SMBIOS)");
module_param_named(trydmi, ssif_trydmi, bool, 0);
MODULE_PARM_DESC(trydmi, "Setting this to zero will disable the default scan of the interfaces identified via DMI (SMBIOS)");
@@
-1582,6
+1587,10
@@
static int ssif_probe(struct i2c_client *client, const struct i2c_device_id *id)
ssif_info->global_enables |= IPMI_BMC_EVT_MSG_BUFF;
}
ssif_info->global_enables |= IPMI_BMC_EVT_MSG_BUFF;
}
+ /* Some systems don't behave well if you enable alerts. */
+ if (alerts_broken)
+ goto found;
+
msg[0] = IPMI_NETFN_APP_REQUEST << 2;
msg[1] = IPMI_SET_BMC_GLOBAL_ENABLES_CMD;
msg[2] = ssif_info->global_enables | IPMI_BMC_RCV_MSG_INTR;
msg[0] = IPMI_NETFN_APP_REQUEST << 2;
msg[1] = IPMI_SET_BMC_GLOBAL_ENABLES_CMD;
msg[2] = ssif_info->global_enables | IPMI_BMC_RCV_MSG_INTR;
@@
-1787,7
+1796,7
@@
skip_addr:
}
#ifdef CONFIG_ACPI
}
#ifdef CONFIG_ACPI
-static struct acpi_device_id ssif_acpi_match[] = {
+static
const
struct acpi_device_id ssif_acpi_match[] = {
{ "IPI0001", 0 },
{ },
};
{ "IPI0001", 0 },
{ },
};