aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/init.h
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@osg.samsung.com>2015-04-21 05:33:03 -0400
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>2015-04-21 08:44:55 -0400
commit64131a87f2aae2ed9e05d8227c5b009ca6c50d98 (patch)
treefdea23fd59216120bf54a48c60ca24489a733f14 /include/linux/init.h
parent676ee36be04985062522804c2de04f0764212be6 (diff)
parent2c33ce009ca2389dbf0535d0672214d09738e35e (diff)
Merge branch 'drm-next-merged' of git://people.freedesktop.org/~airlied/linux into v4l_for_linus
* 'drm-next-merged' of git://people.freedesktop.org/~airlied/linux: (9717 commits) media-bus: Fixup RGB444_1X12, RGB565_1X16, and YUV8_1X24 media bus format hexdump: avoid warning in test function fs: take i_mutex during prepare_binprm for set[ug]id executables smp: Fix error case handling in smp_call_function_*() iommu-common: Fix PARISC compile-time warnings sparc: Make LDC use common iommu poll management functions sparc: Make sparc64 use scalable lib/iommu-common.c functions Break up monolithic iommu table/lock into finer graularity pools and lock sparc: Revert generic IOMMU allocator. tools/power turbostat: correct dumped pkg-cstate-limit value tools/power turbostat: calculate TSC frequency from CPUID(0x15) on SKL tools/power turbostat: correct DRAM RAPL units on recent Xeon processors tools/power turbostat: Initial Skylake support tools/power turbostat: Use $(CURDIR) instead of $(PWD) and add support for O= option in Makefile tools/power turbostat: modprobe msr, if needed tools/power turbostat: dump MSR_TURBO_RATIO_LIMIT2 tools/power turbostat: use new MSR_TURBO_RATIO_LIMIT names Bluetooth: hidp: Fix regression with older userspace and flags validation config: Enable NEED_DMA_MAP_STATE by default when SWIOTLB is selected perf/x86/intel/pt: Fix and clean up error handling in pt_event_add() ... That solves several merge conflicts: Documentation/DocBook/media/v4l/subdev-formats.xml Documentation/devicetree/bindings/vendor-prefixes.txt drivers/staging/media/mn88473/mn88473.c include/linux/kconfig.h include/uapi/linux/media-bus-format.h The ones at subdev-formats.xml and media-bus-format.h are not trivial. That's why we opted to merge from DRM.
Diffstat (limited to 'include/linux/init.h')
-rw-r--r--include/linux/init.h38
1 files changed, 29 insertions, 9 deletions
diff --git a/include/linux/init.h b/include/linux/init.h
index 2df8e8dd10a4..21b6d768edd7 100644
--- a/include/linux/init.h
+++ b/include/linux/init.h
@@ -253,21 +253,41 @@ struct obs_kernel_param {
253 * obs_kernel_param "array" too far apart in .init.setup. 253 * obs_kernel_param "array" too far apart in .init.setup.
254 */ 254 */
255#define __setup_param(str, unique_id, fn, early) \ 255#define __setup_param(str, unique_id, fn, early) \
256 static const char __setup_str_##unique_id[] __initconst \ 256 static const char __setup_str_##unique_id[] __initconst \
257 __aligned(1) = str; \ 257 __aligned(1) = str; \
258 static struct obs_kernel_param __setup_##unique_id \ 258 static struct obs_kernel_param __setup_##unique_id \
259 __used __section(.init.setup) \ 259 __used __section(.init.setup) \
260 __attribute__((aligned((sizeof(long))))) \ 260 __attribute__((aligned((sizeof(long))))) \
261 = { __setup_str_##unique_id, fn, early } 261 = { __setup_str_##unique_id, fn, early }
262 262
263#define __setup(str, fn) \ 263#define __setup(str, fn) \
264 __setup_param(str, fn, fn, 0) 264 __setup_param(str, fn, fn, 0)
265 265
266/* NOTE: fn is as per module_param, not __setup! Emits warning if fn 266/*
267 * returns non-zero. */ 267 * NOTE: fn is as per module_param, not __setup!
268#define early_param(str, fn) \ 268 * Emits warning if fn returns non-zero.
269 */
270#define early_param(str, fn) \
269 __setup_param(str, fn, fn, 1) 271 __setup_param(str, fn, fn, 1)
270 272
273#define early_param_on_off(str_on, str_off, var, config) \
274 \
275 int var = IS_ENABLED(config); \
276 \
277 static int __init parse_##var##_on(char *arg) \
278 { \
279 var = 1; \
280 return 0; \
281 } \
282 __setup_param(str_on, parse_##var##_on, parse_##var##_on, 1); \
283 \
284 static int __init parse_##var##_off(char *arg) \
285 { \
286 var = 0; \
287 return 0; \
288 } \
289 __setup_param(str_off, parse_##var##_off, parse_##var##_off, 1)
290
271/* Relies on boot_command_line being set */ 291/* Relies on boot_command_line being set */
272void __init parse_early_param(void); 292void __init parse_early_param(void);
273void __init parse_early_options(char *cmdline); 293void __init parse_early_options(char *cmdline);