Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 95328
b: refs/heads/master
c: 0b18d31
h: refs/heads/master
v: v3
  • Loading branch information
Heiko Carstens authored and Martin Schwidefsky committed Apr 30, 2008
1 parent 1e4dff0 commit 0d8ec78
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f291e17227cf30432ca7c402220f62e6924dd97d
refs/heads/master: 0b18d318b80a7f350648ca8f7cc00a2f688104cb
12 changes: 6 additions & 6 deletions trunk/arch/s390/kernel/smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -890,8 +890,8 @@ static ssize_t cpu_configure_store(struct sys_device *dev, const char *buf,
if (val != 0 && val != 1)
return -EINVAL;

mutex_lock(&smp_cpu_state_mutex);
get_online_cpus();
mutex_lock(&smp_cpu_state_mutex);
rc = -EBUSY;
if (cpu_online(cpu))
goto out;
Expand Down Expand Up @@ -919,8 +919,8 @@ static ssize_t cpu_configure_store(struct sys_device *dev, const char *buf,
break;
}
out:
put_online_cpus();
mutex_unlock(&smp_cpu_state_mutex);
put_online_cpus();
return rc ? rc : count;
}
static SYSDEV_ATTR(configure, 0644, cpu_configure_show, cpu_configure_store);
Expand Down Expand Up @@ -1095,8 +1095,8 @@ static ssize_t __ref rescan_store(struct sys_device *dev,
int cpu;
int rc;

mutex_lock(&smp_cpu_state_mutex);
get_online_cpus();
mutex_lock(&smp_cpu_state_mutex);
newcpus = cpu_present_map;
rc = smp_rescan_cpus();
if (rc)
Expand All @@ -1109,8 +1109,8 @@ static ssize_t __ref rescan_store(struct sys_device *dev,
}
rc = 0;
out:
put_online_cpus();
mutex_unlock(&smp_cpu_state_mutex);
put_online_cpus();
if (!cpus_empty(newcpus))
topology_schedule_update();
return rc ? rc : count;
Expand Down Expand Up @@ -1139,16 +1139,16 @@ static ssize_t dispatching_store(struct sys_device *dev, const char *buf,
if (val != 0 && val != 1)
return -EINVAL;
rc = 0;
mutex_lock(&smp_cpu_state_mutex);
get_online_cpus();
mutex_lock(&smp_cpu_state_mutex);
if (cpu_management == val)
goto out;
rc = topology_set_cpu_management(val);
if (!rc)
cpu_management = val;
out:
put_online_cpus();
mutex_unlock(&smp_cpu_state_mutex);
put_online_cpus();
return rc ? rc : count;
}
static SYSDEV_ATTR(dispatching, 0644, dispatching_show, dispatching_store);
Expand Down

0 comments on commit 0d8ec78

Please sign in to comment.