aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/macintosh
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2014-07-24 15:36:56 -0400
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2014-07-24 15:36:56 -0400
commitb9f12a5d97f652c77ef6803dccd0d40d1290f5be (patch)
tree8f58c8620ffef0d350a5ec022feda492a96b179a /drivers/macintosh
parent9d8dc3e529a19e427fd379118acd132520935c5d (diff)
parent9a3c4145af32125c5ee39c0272662b47307a8323 (diff)
Merge tag 'v3.16-rc6' into next
Merge with mainline to bring in changes to MFD to allow merging ipaq-micro-ts driver.
Diffstat (limited to 'drivers/macintosh')
-rw-r--r--drivers/macintosh/smu.c3
-rw-r--r--drivers/macintosh/windfarm_pm121.c16
2 files changed, 15 insertions, 4 deletions
diff --git a/drivers/macintosh/smu.c b/drivers/macintosh/smu.c
index 23b4a3b28dbc..4eab93aa570b 100644
--- a/drivers/macintosh/smu.c
+++ b/drivers/macintosh/smu.c
@@ -1257,7 +1257,8 @@ static unsigned int smu_fpoll(struct file *file, poll_table *wait)
1257 if (pp->busy && pp->cmd.status != 1) 1257 if (pp->busy && pp->cmd.status != 1)
1258 mask |= POLLIN; 1258 mask |= POLLIN;
1259 spin_unlock_irqrestore(&pp->lock, flags); 1259 spin_unlock_irqrestore(&pp->lock, flags);
1260 } if (pp->mode == smu_file_events) { 1260 }
1261 if (pp->mode == smu_file_events) {
1261 /* Not yet implemented */ 1262 /* Not yet implemented */
1262 } 1263 }
1263 return mask; 1264 return mask;
diff --git a/drivers/macintosh/windfarm_pm121.c b/drivers/macintosh/windfarm_pm121.c
index 7fe58b0ae8b4..b350fb86ff08 100644
--- a/drivers/macintosh/windfarm_pm121.c
+++ b/drivers/macintosh/windfarm_pm121.c
@@ -555,8 +555,18 @@ static void pm121_create_sys_fans(int loop_id)
555 pid_param.interval = PM121_SYS_INTERVAL; 555 pid_param.interval = PM121_SYS_INTERVAL;
556 pid_param.history_len = PM121_SYS_HISTORY_SIZE; 556 pid_param.history_len = PM121_SYS_HISTORY_SIZE;
557 pid_param.itarget = param->itarget; 557 pid_param.itarget = param->itarget;
558 pid_param.min = control->ops->get_min(control); 558 if(control)
559 pid_param.max = control->ops->get_max(control); 559 {
560 pid_param.min = control->ops->get_min(control);
561 pid_param.max = control->ops->get_max(control);
562 } else {
563 /*
564 * This is probably not the right!?
565 * Perhaps goto fail if control == NULL above?
566 */
567 pid_param.min = 0;
568 pid_param.max = 0;
569 }
560 570
561 wf_pid_init(&pm121_sys_state[loop_id]->pid, &pid_param); 571 wf_pid_init(&pm121_sys_state[loop_id]->pid, &pid_param);
562 572
@@ -571,7 +581,7 @@ static void pm121_create_sys_fans(int loop_id)
571 control the same control */ 581 control the same control */
572 printk(KERN_WARNING "pm121: failed to set up %s loop " 582 printk(KERN_WARNING "pm121: failed to set up %s loop "
573 "setting \"%s\" to max speed.\n", 583 "setting \"%s\" to max speed.\n",
574 loop_names[loop_id], control->name); 584 loop_names[loop_id], control ? control->name : "uninitialized value");
575 585
576 if (control) 586 if (control)
577 wf_control_set_max(control); 587 wf_control_set_max(control);