aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/ipmi/ipmi_si_intf.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/char/ipmi/ipmi_si_intf.c')
-rw-r--r--drivers/char/ipmi/ipmi_si_intf.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c
index 5e90a18afbaf..8a45e92ff60c 100644
--- a/drivers/char/ipmi/ipmi_si_intf.c
+++ b/drivers/char/ipmi/ipmi_si_intf.c
@@ -942,8 +942,7 @@ static void sender(void *send_info,
942 * If we are running to completion, start it and run 942 * If we are running to completion, start it and run
943 * transactions until everything is clear. 943 * transactions until everything is clear.
944 */ 944 */
945 smi_info->curr_msg = msg; 945 smi_info->waiting_msg = msg;
946 smi_info->waiting_msg = NULL;
947 946
948 /* 947 /*
949 * Run to completion means we are single-threaded, no 948 * Run to completion means we are single-threaded, no
@@ -2244,7 +2243,7 @@ static int ipmi_pnp_probe(struct pnp_dev *dev,
2244 acpi_handle handle; 2243 acpi_handle handle;
2245 acpi_status status; 2244 acpi_status status;
2246 unsigned long long tmp; 2245 unsigned long long tmp;
2247 int rv; 2246 int rv = -EINVAL;
2248 2247
2249 acpi_dev = pnp_acpi_device(dev); 2248 acpi_dev = pnp_acpi_device(dev);
2250 if (!acpi_dev) 2249 if (!acpi_dev)
@@ -2262,8 +2261,10 @@ static int ipmi_pnp_probe(struct pnp_dev *dev,
2262 2261
2263 /* _IFT tells us the interface type: KCS, BT, etc */ 2262 /* _IFT tells us the interface type: KCS, BT, etc */
2264 status = acpi_evaluate_integer(handle, "_IFT", NULL, &tmp); 2263 status = acpi_evaluate_integer(handle, "_IFT", NULL, &tmp);
2265 if (ACPI_FAILURE(status)) 2264 if (ACPI_FAILURE(status)) {
2265 dev_err(&dev->dev, "Could not find ACPI IPMI interface type\n");
2266 goto err_free; 2266 goto err_free;
2267 }
2267 2268
2268 switch (tmp) { 2269 switch (tmp) {
2269 case 1: 2270 case 1:
@@ -2276,6 +2277,7 @@ static int ipmi_pnp_probe(struct pnp_dev *dev,
2276 info->si_type = SI_BT; 2277 info->si_type = SI_BT;
2277 break; 2278 break;
2278 case 4: /* SSIF, just ignore */ 2279 case 4: /* SSIF, just ignore */
2280 rv = -ENODEV;
2279 goto err_free; 2281 goto err_free;
2280 default: 2282 default:
2281 dev_info(&dev->dev, "unknown IPMI type %lld\n", tmp); 2283 dev_info(&dev->dev, "unknown IPMI type %lld\n", tmp);
@@ -2336,7 +2338,7 @@ static int ipmi_pnp_probe(struct pnp_dev *dev,
2336 2338
2337err_free: 2339err_free:
2338 kfree(info); 2340 kfree(info);
2339 return -EINVAL; 2341 return rv;
2340} 2342}
2341 2343
2342static void ipmi_pnp_remove(struct pnp_dev *dev) 2344static void ipmi_pnp_remove(struct pnp_dev *dev)
@@ -3080,7 +3082,7 @@ static int smi_type_proc_show(struct seq_file *m, void *v)
3080 3082
3081 seq_printf(m, "%s\n", si_to_str[smi->si_type]); 3083 seq_printf(m, "%s\n", si_to_str[smi->si_type]);
3082 3084
3083 return seq_has_overflowed(m); 3085 return 0;
3084} 3086}
3085 3087
3086static int smi_type_proc_open(struct inode *inode, struct file *file) 3088static int smi_type_proc_open(struct inode *inode, struct file *file)
@@ -3153,7 +3155,7 @@ static int smi_params_proc_show(struct seq_file *m, void *v)
3153 smi->irq, 3155 smi->irq,
3154 smi->slave_addr); 3156 smi->slave_addr);
3155 3157
3156 return seq_has_overflowed(m); 3158 return 0;
3157} 3159}
3158 3160
3159static int smi_params_proc_open(struct inode *inode, struct file *file) 3161static int smi_params_proc_open(struct inode *inode, struct file *file)