.. | .. |
---|
167 | 167 | return -EINVAL; |
---|
168 | 168 | |
---|
169 | 169 | get_online_cpus(); |
---|
170 | | - read_lock(&tasklist_lock); |
---|
| 170 | + rcu_read_lock(); |
---|
171 | 171 | |
---|
172 | 172 | retval = -ESRCH; |
---|
173 | 173 | p = find_process_by_pid(pid); |
---|
.. | .. |
---|
177 | 177 | if (retval) |
---|
178 | 178 | goto out_unlock; |
---|
179 | 179 | |
---|
180 | | - cpumask_or(&allowed, &p->thread.user_cpus_allowed, &p->cpus_allowed); |
---|
| 180 | + cpumask_or(&allowed, &p->thread.user_cpus_allowed, p->cpus_ptr); |
---|
181 | 181 | cpumask_and(&mask, &allowed, cpu_active_mask); |
---|
182 | 182 | |
---|
183 | 183 | out_unlock: |
---|
184 | | - read_unlock(&tasklist_lock); |
---|
| 184 | + rcu_read_unlock(); |
---|
185 | 185 | put_online_cpus(); |
---|
186 | 186 | if (retval) |
---|
187 | 187 | return retval; |
---|