diff options
| author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-04-28 00:36:39 -0400 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-04-28 00:36:39 -0400 |
| commit | d35cc56ddfc948d8df1aa6d41ac345fcec01854d (patch) | |
| tree | 7e23a0e3dde639236e019aa88309d919941958e5 /include/linux/interrupt.h | |
| parent | 86d56134f1b67d0c18025ba5cade95c048ed528d (diff) | |
| parent | d1db0eea852497762cab43b905b879dfcd3b8987 (diff) | |
Merge 3.15-rc3 into staging-next
Diffstat (limited to 'include/linux/interrupt.h')
| -rw-r--r-- | include/linux/interrupt.h | 35 |
1 files changed, 34 insertions, 1 deletions
diff --git a/include/linux/interrupt.h b/include/linux/interrupt.h index c7bfac1c4a7b..8834a7e5b944 100644 --- a/include/linux/interrupt.h +++ b/include/linux/interrupt.h | |||
| @@ -203,7 +203,40 @@ static inline int check_wakeup_irqs(void) { return 0; } | |||
| 203 | 203 | ||
| 204 | extern cpumask_var_t irq_default_affinity; | 204 | extern cpumask_var_t irq_default_affinity; |
| 205 | 205 | ||
| 206 | extern int irq_set_affinity(unsigned int irq, const struct cpumask *cpumask); | 206 | /* Internal implementation. Use the helpers below */ |
| 207 | extern int __irq_set_affinity(unsigned int irq, const struct cpumask *cpumask, | ||
| 208 | bool force); | ||
| 209 | |||
| 210 | /** | ||
| 211 | * irq_set_affinity - Set the irq affinity of a given irq | ||
| 212 | * @irq: Interrupt to set affinity | ||
| 213 | * @mask: cpumask | ||
| 214 | * | ||
| 215 | * Fails if cpumask does not contain an online CPU | ||
| 216 | */ | ||
| 217 | static inline int | ||
| 218 | irq_set_affinity(unsigned int irq, const struct cpumask *cpumask) | ||
| 219 | { | ||
| 220 | return __irq_set_affinity(irq, cpumask, false); | ||
| 221 | } | ||
| 222 | |||
| 223 | /** | ||
| 224 | * irq_force_affinity - Force the irq affinity of a given irq | ||
| 225 | * @irq: Interrupt to set affinity | ||
| 226 | * @mask: cpumask | ||
| 227 | * | ||
| 228 | * Same as irq_set_affinity, but without checking the mask against | ||
| 229 | * online cpus. | ||
| 230 | * | ||
| 231 | * Solely for low level cpu hotplug code, where we need to make per | ||
| 232 | * cpu interrupts affine before the cpu becomes online. | ||
| 233 | */ | ||
| 234 | static inline int | ||
| 235 | irq_force_affinity(unsigned int irq, const struct cpumask *cpumask) | ||
| 236 | { | ||
| 237 | return __irq_set_affinity(irq, cpumask, true); | ||
| 238 | } | ||
| 239 | |||
| 207 | extern int irq_can_set_affinity(unsigned int irq); | 240 | extern int irq_can_set_affinity(unsigned int irq); |
| 208 | extern int irq_select_affinity(unsigned int irq); | 241 | extern int irq_select_affinity(unsigned int irq); |
| 209 | 242 | ||
