Merge branch 'task_killable' of git://git.kernel.org/pub/scm/linux/kernel/git/willy...
[pandora-kernel.git] / include / linux / cpumask.h
index 23f5514..7047f58 100644 (file)
@@ -218,8 +218,8 @@ int __first_cpu(const cpumask_t *srcp);
 int __next_cpu(int n, const cpumask_t *srcp);
 #define next_cpu(n, src) __next_cpu((n), &(src))
 #else
-#define first_cpu(src)         0
-#define next_cpu(n, src)       1
+#define first_cpu(src)         ({ (void)(src); 0; })
+#define next_cpu(n, src)       ({ (void)(src); 1; })
 #endif
 
 #define cpumask_of_cpu(cpu)                                            \
@@ -397,6 +397,8 @@ extern cpumask_t cpu_present_map;
 #define cpu_present(cpu)       ((cpu) == 0)
 #endif
 
+#define cpu_is_offline(cpu)    unlikely(!cpu_online(cpu))
+
 #ifdef CONFIG_SMP
 extern int nr_cpu_ids;
 #define any_online_cpu(mask) __any_online_cpu(&(mask))