History

Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net

Conflicts: net/bridge/br_mdb.c br_mdb.c conflict was a function call being removed to fix a bug in 'net' but whose signature was changed in 'net-next'.

David S. Miller committed 11 years ago

Commit c5e40ee2 parents 0528318 c5dfd65544 files · +4152 −3347Browse files

Showing the changes to include/linux (23 of 544 files). Show all

Unified · Split

23 files
  1. include/linux/amba/sp810.h +1 −1
  2. include/linux/blk-cgroup.h +3 −8
  3. include/linux/clkdev.h +4 −3
  4. include/linux/compat.h +1 −1
  5. include/linux/configfs.h +2 −1
  6. include/linux/cpu.h +4 −3
  7. include/linux/dcache.h +2 −1
  8. include/linux/device.h +7 −8
  9. include/linux/fs.h +20 −10
  10. include/linux/gpio/driver.h +1 −1
  11. include/linux/hid-sensor-hub.h +1 −0
  12. include/linux/hugetlb.h +8 −9
  13. include/linux/init.h +0 −78
  14. include/linux/iommu.h +1 −1
  15. include/linux/kernel.h +5 −4
  16. include/linux/kobject.h +3 −2
  17. include/linux/kvm_host.h +18 −0
  18. include/linux/mmiotrace.h +1 −1
  19. include/linux/module.h +84 −0
  20. include/linux/page_owner.h +13 −0
  21. include/linux/pata_arasan_cf_data.h +1 −1
  22. include/linux/printk.h +3 −3
  23. include/linux/sched.h +14 −2
include/linux/amba/sp810.h+1−1
@@ -2,7 +2,7 @@ · 1 unmodified line
2 * ARM PrimeXsys System Controller SP810 header file2 * ARM PrimeXsys System Controller SP810 header file
3 *3 *
4 * Copyright (C) 2009 ST Microelectronics4 * Copyright (C) 2009 ST Microelectronics
5 * Viresh Kumar <viresh.linux@gmail.com>5 * Viresh Kumar <vireshk@kernel.org>
6 *6 *
7 * This file is licensed under the terms of the GNU General Public7 * This file is licensed under the terms of the GNU General Public
8 * License version 2. This program is licensed "as is" without any8 * License version 2. This program is licensed "as is" without any
include/linux/blk-cgroup.h+3−8
@@ -47,6 +47,7 @@ struct blkcg { · 46 unmodified lines
47 47
48 struct blkcg_policy_data *pd[BLKCG_MAX_POLS];48 struct blkcg_policy_data *pd[BLKCG_MAX_POLS];
49 49
50 struct list_head all_blkcgs_node;
50#ifdef CONFIG_CGROUP_WRITEBACK51#ifdef CONFIG_CGROUP_WRITEBACK
51 struct list_head cgwb_list;52 struct list_head cgwb_list;
52#endif53#endif
@@ -88,18 +89,12 @@ struct blkg_policy_data { · 35 unmodified lines
88 * Policies that need to keep per-blkcg data which is independent89 * Policies that need to keep per-blkcg data which is independent
89 * from any request_queue associated to it must specify its size90 * from any request_queue associated to it must specify its size
90 * with the cpd_size field of the blkcg_policy structure and91 * with the cpd_size field of the blkcg_policy structure and
91 * embed a blkcg_policy_data in it. blkcg core allocates92 * embed a blkcg_policy_data in it. cpd_init() is invoked to let
92 * policy-specific per-blkcg structures lazily the first time93 * each policy handle per-blkcg data.
93 * they are actually needed, so it handles them together with
94 * blkgs. cpd_init() is invoked to let each policy handle
95 * per-blkcg data.
96 */94 */
97struct blkcg_policy_data {95struct blkcg_policy_data {
98 /* the policy id this per-policy data belongs to */96 /* the policy id this per-policy data belongs to */
99 int plid;97 int plid;
100
101 /* used during policy activation */
102 struct list_head alloc_node;
103};98};
104 99
105/* association between a blk cgroup and a request queue */100/* association between a blk cgroup and a request queue */
include/linux/clkdev.h+4−3
@@ -33,18 +33,19 @@ struct clk_lookup { · 32 unmodified lines
33 }33 }
34 34
35struct clk_lookup *clkdev_alloc(struct clk *clk, const char *con_id,35struct clk_lookup *clkdev_alloc(struct clk *clk, const char *con_id,
36 const char *dev_fmt, ...);36 const char *dev_fmt, ...) __printf(3, 4);
37 37
38void clkdev_add(struct clk_lookup *cl);38void clkdev_add(struct clk_lookup *cl);
39void clkdev_drop(struct clk_lookup *cl);39void clkdev_drop(struct clk_lookup *cl);
40 40
41struct clk_lookup *clkdev_create(struct clk *clk, const char *con_id,41struct clk_lookup *clkdev_create(struct clk *clk, const char *con_id,
42 const char *dev_fmt, ...);42 const char *dev_fmt, ...) __printf(3, 4);
43 43
44void clkdev_add_table(struct clk_lookup *, size_t);44void clkdev_add_table(struct clk_lookup *, size_t);
45int clk_add_alias(const char *, const char *, const char *, struct device *);45int clk_add_alias(const char *, const char *, const char *, struct device *);
46 46
47int clk_register_clkdev(struct clk *, const char *, const char *, ...);47int clk_register_clkdev(struct clk *, const char *, const char *, ...)
48 __printf(3, 4);
48int clk_register_clkdevs(struct clk *, struct clk_lookup *, size_t);49int clk_register_clkdevs(struct clk *, struct clk_lookup *, size_t);
49 50
50#ifdef CONFIG_COMMON_CLK51#ifdef CONFIG_COMMON_CLK
include/linux/compat.h+1−1
@@ -424,7 +424,7 @@ asmlinkage long compat_sys_settimeofday(struct compat_timeval __user *tv, · 423 unmodified lines
424 424
425asmlinkage long compat_sys_adjtimex(struct compat_timex __user *utp);425asmlinkage long compat_sys_adjtimex(struct compat_timex __user *utp);
426 426
427extern int compat_printk(const char *fmt, ...);427extern __printf(1, 2) int compat_printk(const char *fmt, ...);
428extern void sigset_from_compat(sigset_t *set, const compat_sigset_t *compat);428extern void sigset_from_compat(sigset_t *set, const compat_sigset_t *compat);
429extern void sigset_to_compat(compat_sigset_t *compat, const sigset_t *set);429extern void sigset_to_compat(compat_sigset_t *compat, const sigset_t *set);
430 430
include/linux/configfs.h+2−1
@@ -64,7 +64,8 @@ struct config_item { · 63 unmodified lines
64 struct dentry *ci_dentry;64 struct dentry *ci_dentry;
65};65};
66 66
67extern int config_item_set_name(struct config_item *, const char *, ...);67extern __printf(2, 3)
68int config_item_set_name(struct config_item *, const char *, ...);
68 69
69static inline char *config_item_name(struct config_item * item)70static inline char *config_item_name(struct config_item * item)
70{71{
include/linux/cpu.h+4−3
@@ -40,9 +40,10 @@ extern void cpu_remove_dev_attr(struct device_attribute *attr); · 39 unmodified lines
40extern int cpu_add_dev_attr_group(struct attribute_group *attrs);40extern int cpu_add_dev_attr_group(struct attribute_group *attrs);
41extern void cpu_remove_dev_attr_group(struct attribute_group *attrs);41extern void cpu_remove_dev_attr_group(struct attribute_group *attrs);
42 42
43extern struct device *cpu_device_create(struct device *parent, void *drvdata,43extern __printf(4, 5)
44 const struct attribute_group **groups,44struct device *cpu_device_create(struct device *parent, void *drvdata,
45 const char *fmt, ...);45 const struct attribute_group **groups,
46 const char *fmt, ...);
46#ifdef CONFIG_HOTPLUG_CPU47#ifdef CONFIG_HOTPLUG_CPU
47extern void unregister_cpu(struct cpu *cpu);48extern void unregister_cpu(struct cpu *cpu);
48extern ssize_t arch_cpu_probe(const char *, size_t);49extern ssize_t arch_cpu_probe(const char *, size_t);
include/linux/dcache.h+2−1
@@ -327,7 +327,8 @@ static inline unsigned d_count(const struct dentry *dentry) · 326 unmodified lines
327/*327/*
328 * helper function for dentry_operations.d_dname() members328 * helper function for dentry_operations.d_dname() members
329 */329 */
330extern char *dynamic_dname(struct dentry *, char *, int, const char *, ...);330extern __printf(4, 5)
331char *dynamic_dname(struct dentry *, char *, int, const char *, ...);
331extern char *simple_dname(struct dentry *, char *, int);332extern char *simple_dname(struct dentry *, char *, int);
332 333
333extern char *__d_path(const struct path *, const struct path *, char *, int);334extern char *__d_path(const struct path *, const struct path *, char *, int);
include/linux/device.h+7−8
@@ -637,8 +637,9 @@ extern int devres_release_group(struct device *dev, void *id); · 636 unmodified lines
637 637
638/* managed devm_k.alloc/kfree for device drivers */638/* managed devm_k.alloc/kfree for device drivers */
639extern void *devm_kmalloc(struct device *dev, size_t size, gfp_t gfp);639extern void *devm_kmalloc(struct device *dev, size_t size, gfp_t gfp);
640extern char *devm_kvasprintf(struct device *dev, gfp_t gfp, const char *fmt,640extern __printf(3, 0)
641 va_list ap);641char *devm_kvasprintf(struct device *dev, gfp_t gfp, const char *fmt,
642 va_list ap);
642extern __printf(3, 4)643extern __printf(3, 4)
643char *devm_kasprintf(struct device *dev, gfp_t gfp, const char *fmt, ...);644char *devm_kasprintf(struct device *dev, gfp_t gfp, const char *fmt, ...);
644static inline void *devm_kzalloc(struct device *dev, size_t size, gfp_t gfp)645static inline void *devm_kzalloc(struct device *dev, size_t size, gfp_t gfp)
@@ -1011,12 +1012,10 @@ extern int __must_check device_reprobe(struct device *dev); · 366 unmodified lines
1011/*1012/*
1012 * Easy functions for dynamically creating devices on the fly1013 * Easy functions for dynamically creating devices on the fly
1013 */1014 */
1014extern struct device *device_create_vargs(struct class *cls,1015extern __printf(5, 0)
1015 struct device *parent,1016struct device *device_create_vargs(struct class *cls, struct device *parent,
1016 dev_t devt,1017 dev_t devt, void *drvdata,
1017 void *drvdata,1018 const char *fmt, va_list vargs);
1018 const char *fmt,
1019 va_list vargs);
1020extern __printf(5, 6)1019extern __printf(5, 6)
1021struct device *device_create(struct class *cls, struct device *parent,1020struct device *device_create(struct class *cls, struct device *parent,
1022 dev_t devt, void *drvdata,1021 dev_t devt, void *drvdata,
include/linux/fs.h+20−10
@@ -1046,12 +1046,12 @@ extern void locks_remove_file(struct file *); · 1045 unmodified lines
1046extern void locks_release_private(struct file_lock *);1046extern void locks_release_private(struct file_lock *);
1047extern void posix_test_lock(struct file *, struct file_lock *);1047extern void posix_test_lock(struct file *, struct file_lock *);
1048extern int posix_lock_file(struct file *, struct file_lock *, struct file_lock *);1048extern int posix_lock_file(struct file *, struct file_lock *, struct file_lock *);
1049extern int posix_lock_file_wait(struct file *, struct file_lock *);1049extern int posix_lock_inode_wait(struct inode *, struct file_lock *);
1050extern int posix_unblock_lock(struct file_lock *);1050extern int posix_unblock_lock(struct file_lock *);
1051extern int vfs_test_lock(struct file *, struct file_lock *);1051extern int vfs_test_lock(struct file *, struct file_lock *);
1052extern int vfs_lock_file(struct file *, unsigned int, struct file_lock *, struct file_lock *);1052extern int vfs_lock_file(struct file *, unsigned int, struct file_lock *, struct file_lock *);
1053extern int vfs_cancel_lock(struct file *filp, struct file_lock *fl);1053extern int vfs_cancel_lock(struct file *filp, struct file_lock *fl);
1054extern int flock_lock_file_wait(struct file *filp, struct file_lock *fl);1054extern int flock_lock_inode_wait(struct inode *inode, struct file_lock *fl);
1055extern int __break_lease(struct inode *inode, unsigned int flags, unsigned int type);1055extern int __break_lease(struct inode *inode, unsigned int flags, unsigned int type);
1056extern void lease_get_mtime(struct inode *, struct timespec *time);1056extern void lease_get_mtime(struct inode *, struct timespec *time);
1057extern int generic_setlease(struct file *, long, struct file_lock **, void **priv);1057extern int generic_setlease(struct file *, long, struct file_lock **, void **priv);
@@ -1137,7 +1137,8 @@ static inline int posix_lock_file(struct file *filp, struct file_lock *fl, · 79 unmodified lines
1137 return -ENOLCK;1137 return -ENOLCK;
1138}1138}
1139 1139
1140static inline int posix_lock_file_wait(struct file *filp, struct file_lock *fl)1140static inline int posix_lock_inode_wait(struct inode *inode,
1141 struct file_lock *fl)
1141{1142{
1142 return -ENOLCK;1143 return -ENOLCK;
1143}1144}
@@ -1163,8 +1164,8 @@ static inline int vfs_cancel_lock(struct file *filp, struct file_lock *fl) · 19 unmodified lines
1163 return 0;1164 return 0;
1164}1165}
1165 1166
1166static inline int flock_lock_file_wait(struct file *filp,1167static inline int flock_lock_inode_wait(struct inode *inode,
1167 struct file_lock *request)1168 struct file_lock *request)
1168{1169{
1169 return -ENOLCK;1170 return -ENOLCK;
1170}1171}
@@ -1202,6 +1203,20 @@ static inline void show_fd_locks(struct seq_file *f, · 31 unmodified lines
1202 struct file *filp, struct files_struct *files) {}1203 struct file *filp, struct files_struct *files) {}
1203#endif /* !CONFIG_FILE_LOCKING */1204#endif /* !CONFIG_FILE_LOCKING */
1204 1205
1206static inline struct inode *file_inode(const struct file *f)
1207{
1208 return f->f_inode;
1209}
1210
1211static inline int posix_lock_file_wait(struct file *filp, struct file_lock *fl)
1212{
1213 return posix_lock_inode_wait(file_inode(filp), fl);
1214}
1215
1216static inline int flock_lock_file_wait(struct file *filp, struct file_lock *fl)
1217{
1218 return flock_lock_inode_wait(file_inode(filp), fl);
1219}
1205 1220
1206struct fasync_struct {1221struct fasync_struct {
1207 spinlock_t fa_lock;1222 spinlock_t fa_lock;
@@ -2011,11 +2026,6 @@ extern void ihold(struct inode * inode); · 803 unmodified lines
2011extern void iput(struct inode *);2026extern void iput(struct inode *);
2012extern int generic_update_time(struct inode *, struct timespec *, int);2027extern int generic_update_time(struct inode *, struct timespec *, int);
2013 2028
2014static inline struct inode *file_inode(const struct file *f)
2015{
2016 return f->f_inode;
2017}
2018
2019/* /sys/fs */2029/* /sys/fs */
2020extern struct kobject *fs_kobj;2030extern struct kobject *fs_kobj;
2021 2031
include/linux/gpio/driver.h+1−1
@@ -45,7 +45,7 @@ struct seq_file; · 44 unmodified lines
45 * @base: identifies the first GPIO number handled by this chip;45 * @base: identifies the first GPIO number handled by this chip;
46 * or, if negative during registration, requests dynamic ID allocation.46 * or, if negative during registration, requests dynamic ID allocation.
47 * DEPRECATION: providing anything non-negative and nailing the base47 * DEPRECATION: providing anything non-negative and nailing the base
48 * base offset of GPIO chips is deprecated. Please pass -1 as base to48 * offset of GPIO chips is deprecated. Please pass -1 as base to
49 * let gpiolib select the chip base in all possible cases. We want to49 * let gpiolib select the chip base in all possible cases. We want to
50 * get rid of the static GPIO number space in the long run.50 * get rid of the static GPIO number space in the long run.
51 * @ngpio: the number of GPIOs handled by this controller; the last GPIO51 * @ngpio: the number of GPIOs handled by this controller; the last GPIO
include/linux/hid-sensor-hub.h+1−0
@@ -230,6 +230,7 @@ struct hid_sensor_common { · 229 unmodified lines
230 struct platform_device *pdev;230 struct platform_device *pdev;
231 unsigned usage_id;231 unsigned usage_id;
232 atomic_t data_ready;232 atomic_t data_ready;
233 atomic_t user_requested_state;
233 struct iio_trigger *trigger;234 struct iio_trigger *trigger;
234 struct hid_sensor_hub_attribute_info poll;235 struct hid_sensor_hub_attribute_info poll;
235 struct hid_sensor_hub_attribute_info report_state;236 struct hid_sensor_hub_attribute_info report_state;
include/linux/hugetlb.h+8−9
@@ -460,15 +460,14 @@ static inline spinlock_t *huge_pte_lockptr(struct hstate *h, · 459 unmodified lines
460 return &mm->page_table_lock;460 return &mm->page_table_lock;
461}461}
462 462
463static inline bool hugepages_supported(void)463#ifndef hugepages_supported
464{464/*
465 /*465 * Some platform decide whether they support huge pages at boot
466 * Some platform decide whether they support huge pages at boot466 * time. Some of them, such as powerpc, set HPAGE_SHIFT to 0
467 * time. On these, such as powerpc, HPAGE_SHIFT is set to 0 when467 * when there is no such support
468 * there is no such support468 */
469 */469#define hugepages_supported() (HPAGE_SHIFT != 0)
470 return HPAGE_SHIFT != 0;470#endif
471}
472 471
473#else /* CONFIG_HUGETLB_PAGE */472#else /* CONFIG_HUGETLB_PAGE */
474struct hstate {};473struct hstate {};
include/linux/init.h+0−78
@@ -282,68 +282,8 @@ void __init parse_early_param(void); · 281 unmodified lines
282void __init parse_early_options(char *cmdline);282void __init parse_early_options(char *cmdline);
283#endif /* __ASSEMBLY__ */283#endif /* __ASSEMBLY__ */
284 284
285/**
286 * module_init() - driver initialization entry point
287 * @x: function to be run at kernel boot time or module insertion
288 *
289 * module_init() will either be called during do_initcalls() (if
290 * builtin) or at module insertion time (if a module). There can only
291 * be one per module.
292 */
293#define module_init(x) __initcall(x);
294
295/**
296 * module_exit() - driver exit entry point
297 * @x: function to be run when driver is removed
298 *
299 * module_exit() will wrap the driver clean-up code
300 * with cleanup_module() when used with rmmod when
301 * the driver is a module. If the driver is statically
302 * compiled into the kernel, module_exit() has no effect.
303 * There can only be one per module.
304 */
305#define module_exit(x) __exitcall(x);
306
307#else /* MODULE */285#else /* MODULE */
308 286
309/*
310 * In most cases loadable modules do not need custom
311 * initcall levels. There are still some valid cases where
312 * a driver may be needed early if built in, and does not
313 * matter when built as a loadable module. Like bus
314 * snooping debug drivers.
315 */
316#define early_initcall(fn) module_init(fn)
317#define core_initcall(fn) module_init(fn)
318#define core_initcall_sync(fn) module_init(fn)
319#define postcore_initcall(fn) module_init(fn)
320#define postcore_initcall_sync(fn) module_init(fn)
321#define arch_initcall(fn) module_init(fn)
322#define subsys_initcall(fn) module_init(fn)
323#define subsys_initcall_sync(fn) module_init(fn)
324#define fs_initcall(fn) module_init(fn)
325#define fs_initcall_sync(fn) module_init(fn)
326#define rootfs_initcall(fn) module_init(fn)
327#define device_initcall(fn) module_init(fn)
328#define device_initcall_sync(fn) module_init(fn)
329#define late_initcall(fn) module_init(fn)
330#define late_initcall_sync(fn) module_init(fn)
331
332#define console_initcall(fn) module_init(fn)
333#define security_initcall(fn) module_init(fn)
334
335/* Each module must use one module_init(). */
336#define module_init(initfn) \
337 static inline initcall_t __inittest(void) \
338 { return initfn; } \
339 int init_module(void) __attribute__((alias(#initfn)));
340
341/* This is only required if you want to be unloadable. */
342#define module_exit(exitfn) \
343 static inline exitcall_t __exittest(void) \
344 { return exitfn; } \
345 void cleanup_module(void) __attribute__((alias(#exitfn)));
346
347#define __setup_param(str, unique_id, fn) /* nothing */287#define __setup_param(str, unique_id, fn) /* nothing */
348#define __setup(str, func) /* nothing */288#define __setup(str, func) /* nothing */
349#endif289#endif
@@ -351,24 +291,6 @@ void __init parse_early_options(char *cmdline); · 1 unmodified line
351/* Data marked not to be saved by software suspend */291/* Data marked not to be saved by software suspend */
352#define __nosavedata __section(.data..nosave)292#define __nosavedata __section(.data..nosave)
353 293
354/* This means "can be init if no module support, otherwise module load
355 may call it." */
356#ifdef CONFIG_MODULES
357#define __init_or_module
358#define __initdata_or_module
359#define __initconst_or_module
360#define __INIT_OR_MODULE .text
361#define __INITDATA_OR_MODULE .data
362#define __INITRODATA_OR_MODULE .section ".rodata","a",%progbits
363#else
364#define __init_or_module __init
365#define __initdata_or_module __initdata
366#define __initconst_or_module __initconst
367#define __INIT_OR_MODULE __INIT
368#define __INITDATA_OR_MODULE __INITDATA
369#define __INITRODATA_OR_MODULE __INITRODATA
370#endif /*CONFIG_MODULES*/
371
372#ifdef MODULE294#ifdef MODULE
373#define __exit_p(x) x295#define __exit_p(x) x
374#else296#else
include/linux/iommu.h+1−1
@@ -258,7 +258,7 @@ extern int iommu_domain_set_attr(struct iommu_domain *domain, enum iommu_attr, · 257 unmodified lines
258 void *data);258 void *data);
259struct device *iommu_device_create(struct device *parent, void *drvdata,259struct device *iommu_device_create(struct device *parent, void *drvdata,
260 const struct attribute_group **groups,260 const struct attribute_group **groups,
261 const char *fmt, ...);261 const char *fmt, ...) __printf(4, 5);
262void iommu_device_destroy(struct device *dev);262void iommu_device_destroy(struct device *dev);
263int iommu_device_link(struct device *dev, struct device *link);263int iommu_device_link(struct device *dev, struct device *link);
264void iommu_device_unlink(struct device *dev, struct device *link);264void iommu_device_unlink(struct device *dev, struct device *link);
include/linux/kernel.h+5−4
@@ -411,7 +411,8 @@ extern __printf(3, 0) · 410 unmodified lines
411int vscnprintf(char *buf, size_t size, const char *fmt, va_list args);411int vscnprintf(char *buf, size_t size, const char *fmt, va_list args);
412extern __printf(2, 3)412extern __printf(2, 3)
413char *kasprintf(gfp_t gfp, const char *fmt, ...);413char *kasprintf(gfp_t gfp, const char *fmt, ...);
414extern char *kvasprintf(gfp_t gfp, const char *fmt, va_list args);414extern __printf(2, 0)
415char *kvasprintf(gfp_t gfp, const char *fmt, va_list args);
415 416
416extern __scanf(2, 3)417extern __scanf(2, 3)
417int sscanf(const char *, const char *, ...);418int sscanf(const char *, const char *, ...);
@@ -679,10 +680,10 @@ do { \ · 261 unmodified lines
679 __ftrace_vprintk(_THIS_IP_, fmt, vargs); \680 __ftrace_vprintk(_THIS_IP_, fmt, vargs); \
680} while (0)681} while (0)
681 682
682extern int683extern __printf(2, 0) int
683__ftrace_vbprintk(unsigned long ip, const char *fmt, va_list ap);684__ftrace_vbprintk(unsigned long ip, const char *fmt, va_list ap);
684 685
685extern int686extern __printf(2, 0) int
686__ftrace_vprintk(unsigned long ip, const char *fmt, va_list ap);687__ftrace_vprintk(unsigned long ip, const char *fmt, va_list ap);
687 688
688extern void ftrace_dump(enum ftrace_dump_mode oops_dump_mode);689extern void ftrace_dump(enum ftrace_dump_mode oops_dump_mode);
@@ -702,7 +703,7 @@ int trace_printk(const char *fmt, ...) · 13 unmodified lines
702{703{
703 return 0;704 return 0;
704}705}
705static inline int706static __printf(1, 0) inline int
706ftrace_vprintk(const char *fmt, va_list ap)707ftrace_vprintk(const char *fmt, va_list ap)
707{708{
708 return 0;709 return 0;
include/linux/kobject.h+3−2
@@ -80,8 +80,9 @@ struct kobject { · 79 unmodified lines
80 80
81extern __printf(2, 3)81extern __printf(2, 3)
82int kobject_set_name(struct kobject *kobj, const char *name, ...);82int kobject_set_name(struct kobject *kobj, const char *name, ...);
83extern int kobject_set_name_vargs(struct kobject *kobj, const char *fmt,83extern __printf(2, 0)
84 va_list vargs);84int kobject_set_name_vargs(struct kobject *kobj, const char *fmt,
85 va_list vargs);
85 86
86static inline const char *kobject_name(const struct kobject *kobj)87static inline const char *kobject_name(const struct kobject *kobj)
87{88{
include/linux/kvm_host.h+18−0
@@ -734,6 +734,24 @@ static inline bool kvm_arch_has_noncoherent_dma(struct kvm *kvm) · 733 unmodified lines
734 return false;734 return false;
735}735}
736#endif736#endif
737#ifdef __KVM_HAVE_ARCH_ASSIGNED_DEVICE
738void kvm_arch_start_assignment(struct kvm *kvm);
739void kvm_arch_end_assignment(struct kvm *kvm);
740bool kvm_arch_has_assigned_device(struct kvm *kvm);
741#else
742static inline void kvm_arch_start_assignment(struct kvm *kvm)
743{
744}
745
746static inline void kvm_arch_end_assignment(struct kvm *kvm)
747{
748}
749
750static inline bool kvm_arch_has_assigned_device(struct kvm *kvm)
751{
752 return false;
753}
754#endif
737 755
738static inline wait_queue_head_t *kvm_arch_vcpu_wq(struct kvm_vcpu *vcpu)756static inline wait_queue_head_t *kvm_arch_vcpu_wq(struct kvm_vcpu *vcpu)
739{757{
include/linux/mmiotrace.h+1−1
@@ -106,6 +106,6 @@ extern void enable_mmiotrace(void); · 105 unmodified lines
106extern void disable_mmiotrace(void);106extern void disable_mmiotrace(void);
107extern void mmio_trace_rw(struct mmiotrace_rw *rw);107extern void mmio_trace_rw(struct mmiotrace_rw *rw);
108extern void mmio_trace_mapping(struct mmiotrace_map *map);108extern void mmio_trace_mapping(struct mmiotrace_map *map);
109extern int mmio_trace_printk(const char *fmt, va_list args);109extern __printf(1, 0) int mmio_trace_printk(const char *fmt, va_list args);
110 110
111#endif /* _LINUX_MMIOTRACE_H */111#endif /* _LINUX_MMIOTRACE_H */
include/linux/module.h+84−0
@@ -11,6 +11,7 @@ · 10 unmodified lines
11#include <linux/compiler.h>11#include <linux/compiler.h>
12#include <linux/cache.h>12#include <linux/cache.h>
13#include <linux/kmod.h>13#include <linux/kmod.h>
14#include <linux/init.h>
14#include <linux/elf.h>15#include <linux/elf.h>
15#include <linux/stringify.h>16#include <linux/stringify.h>
16#include <linux/kobject.h>17#include <linux/kobject.h>
@@ -71,6 +72,89 @@ extern struct module_attribute module_uevent; · 54 unmodified lines
71extern int init_module(void);72extern int init_module(void);
72extern void cleanup_module(void);73extern void cleanup_module(void);
73 74
75#ifndef MODULE
76/**
77 * module_init() - driver initialization entry point
78 * @x: function to be run at kernel boot time or module insertion
79 *
80 * module_init() will either be called during do_initcalls() (if
81 * builtin) or at module insertion time (if a module). There can only
82 * be one per module.
83 */
84#define module_init(x) __initcall(x);
85
86/**
87 * module_exit() - driver exit entry point
88 * @x: function to be run when driver is removed
89 *
90 * module_exit() will wrap the driver clean-up code
91 * with cleanup_module() when used with rmmod when
92 * the driver is a module. If the driver is statically
93 * compiled into the kernel, module_exit() has no effect.
94 * There can only be one per module.
95 */
96#define module_exit(x) __exitcall(x);
97
98#else /* MODULE */
99
100/*
101 * In most cases loadable modules do not need custom
102 * initcall levels. There are still some valid cases where
103 * a driver may be needed early if built in, and does not
104 * matter when built as a loadable module. Like bus
105 * snooping debug drivers.
106 */
107#define early_initcall(fn) module_init(fn)
108#define core_initcall(fn) module_init(fn)
109#define core_initcall_sync(fn) module_init(fn)
110#define postcore_initcall(fn) module_init(fn)
111#define postcore_initcall_sync(fn) module_init(fn)
112#define arch_initcall(fn) module_init(fn)
113#define subsys_initcall(fn) module_init(fn)
114#define subsys_initcall_sync(fn) module_init(fn)
115#define fs_initcall(fn) module_init(fn)
116#define fs_initcall_sync(fn) module_init(fn)
117#define rootfs_initcall(fn) module_init(fn)
118#define device_initcall(fn) module_init(fn)
119#define device_initcall_sync(fn) module_init(fn)
120#define late_initcall(fn) module_init(fn)
121#define late_initcall_sync(fn) module_init(fn)
122
123#define console_initcall(fn) module_init(fn)
124#define security_initcall(fn) module_init(fn)
125
126/* Each module must use one module_init(). */
127#define module_init(initfn) \
128 static inline initcall_t __inittest(void) \
129 { return initfn; } \
130 int init_module(void) __attribute__((alias(#initfn)));
131
132/* This is only required if you want to be unloadable. */
133#define module_exit(exitfn) \
134 static inline exitcall_t __exittest(void) \
135 { return exitfn; } \
136 void cleanup_module(void) __attribute__((alias(#exitfn)));
137
138#endif
139
140/* This means "can be init if no module support, otherwise module load
141 may call it." */
142#ifdef CONFIG_MODULES
143#define __init_or_module
144#define __initdata_or_module
145#define __initconst_or_module
146#define __INIT_OR_MODULE .text
147#define __INITDATA_OR_MODULE .data
148#define __INITRODATA_OR_MODULE .section ".rodata","a",%progbits
149#else
150#define __init_or_module __init
151#define __initdata_or_module __initdata
152#define __initconst_or_module __initconst
153#define __INIT_OR_MODULE __INIT
154#define __INITDATA_OR_MODULE __INITDATA
155#define __INITRODATA_OR_MODULE __INITRODATA
156#endif /*CONFIG_MODULES*/
157
74/* Archs provide a method of finding the correct exception table. */158/* Archs provide a method of finding the correct exception table. */
75struct exception_table_entry;159struct exception_table_entry;
76 160
include/linux/page_owner.h+13−0
@@ -8,6 +8,7 @@ extern struct page_ext_operations page_owner_ops; · 7 unmodified lines
8extern void __reset_page_owner(struct page *page, unsigned int order);8extern void __reset_page_owner(struct page *page, unsigned int order);
9extern void __set_page_owner(struct page *page,9extern void __set_page_owner(struct page *page,
10 unsigned int order, gfp_t gfp_mask);10 unsigned int order, gfp_t gfp_mask);
11extern gfp_t __get_page_owner_gfp(struct page *page);
11 12
12static inline void reset_page_owner(struct page *page, unsigned int order)13static inline void reset_page_owner(struct page *page, unsigned int order)
13{14{
@@ -25,6 +26,14 @@ static inline void set_page_owner(struct page *page, · 11 unmodified lines
25 26
26 __set_page_owner(page, order, gfp_mask);27 __set_page_owner(page, order, gfp_mask);
27}28}
29
30static inline gfp_t get_page_owner_gfp(struct page *page)
31{
32 if (likely(!page_owner_inited))
33 return 0;
34
35 return __get_page_owner_gfp(page);
36}
28#else37#else
29static inline void reset_page_owner(struct page *page, unsigned int order)38static inline void reset_page_owner(struct page *page, unsigned int order)
30{39{
@@ -33,6 +42,10 @@ static inline void set_page_owner(struct page *page, · 2 unmodified lines
33 unsigned int order, gfp_t gfp_mask)42 unsigned int order, gfp_t gfp_mask)
34{43{
35}44}
45static inline gfp_t get_page_owner_gfp(struct page *page)
46{
47 return 0;
48}
36 49
37#endif /* CONFIG_PAGE_OWNER */50#endif /* CONFIG_PAGE_OWNER */
38#endif /* __LINUX_PAGE_OWNER_H */51#endif /* __LINUX_PAGE_OWNER_H */
include/linux/pata_arasan_cf_data.h+1−1
@@ -4,7 +4,7 @@ · 3 unmodified lines
4 * Arasan Compact Flash host controller platform data header file4 * Arasan Compact Flash host controller platform data header file
5 *5 *
6 * Copyright (C) 2011 ST Microelectronics6 * Copyright (C) 2011 ST Microelectronics
7 * Viresh Kumar <viresh.linux@gmail.com>7 * Viresh Kumar <vireshk@kernel.org>
8 *8 *
9 * This file is licensed under the terms of the GNU General Public9 * This file is licensed under the terms of the GNU General Public
10 * License version 2. This program is licensed "as is" without any10 * License version 2. This program is licensed "as is" without any
include/linux/printk.h+3−3
@@ -122,7 +122,7 @@ static inline __printf(1, 2) __cold · 121 unmodified lines
122void early_printk(const char *s, ...) { }122void early_printk(const char *s, ...) { }
123#endif123#endif
124 124
125typedef int(*printk_func_t)(const char *fmt, va_list args);125typedef __printf(1, 0) int (*printk_func_t)(const char *fmt, va_list args);
126 126
127#ifdef CONFIG_PRINTK127#ifdef CONFIG_PRINTK
128asmlinkage __printf(5, 0)128asmlinkage __printf(5, 0)
@@ -166,7 +166,7 @@ char *log_buf_addr_get(void); · 37 unmodified lines
166u32 log_buf_len_get(void);166u32 log_buf_len_get(void);
167void log_buf_kexec_setup(void);167void log_buf_kexec_setup(void);
168void __init setup_log_buf(int early);168void __init setup_log_buf(int early);
169void dump_stack_set_arch_desc(const char *fmt, ...);169__printf(1, 2) void dump_stack_set_arch_desc(const char *fmt, ...);
170void dump_stack_print_info(const char *log_lvl);170void dump_stack_print_info(const char *log_lvl);
171void show_regs_print_info(const char *log_lvl);171void show_regs_print_info(const char *log_lvl);
172#else172#else
@@ -217,7 +217,7 @@ static inline void setup_log_buf(int early) · 44 unmodified lines
217{217{
218}218}
219 219
220static inline void dump_stack_set_arch_desc(const char *fmt, ...)220static inline __printf(1, 2) void dump_stack_set_arch_desc(const char *fmt, ...)
221{221{
222}222}
223 223
include/linux/sched.h+14−2
@@ -1522,8 +1522,6 @@ struct task_struct { · 1521 unmodified lines
1522/* hung task detection */1522/* hung task detection */
1523 unsigned long last_switch_count;1523 unsigned long last_switch_count;
1524#endif1524#endif
1525/* CPU-specific state of this task */
1526 struct thread_struct thread;
1527/* filesystem information */1525/* filesystem information */
1528 struct fs_struct *fs;1526 struct fs_struct *fs;
1529/* open file information */1527/* open file information */
@@ -1778,8 +1776,22 @@ struct task_struct { · 248 unmodified lines
1778 unsigned long task_state_change;1776 unsigned long task_state_change;
1779#endif1777#endif
1780 int pagefault_disabled;1778 int pagefault_disabled;
1779/* CPU-specific state of this task */
1780 struct thread_struct thread;
1781/*
1782 * WARNING: on x86, 'thread_struct' contains a variable-sized
1783 * structure. It *MUST* be at the end of 'task_struct'.
1784 *
1785 * Do not put anything below here!
1786 */
1781};1787};
1782 1788
1789#ifdef CONFIG_ARCH_WANTS_DYNAMIC_TASK_STRUCT
1790extern int arch_task_struct_size __read_mostly;
1791#else
1792# define arch_task_struct_size (sizeof(struct task_struct))
1793#endif
1794
1783/* Future-safe accessor for struct task_struct's cpus_allowed. */1795/* Future-safe accessor for struct task_struct's cpus_allowed. */
1784#define tsk_cpus_allowed(tsk) (&(tsk)->cpus_allowed)1796#define tsk_cpus_allowed(tsk) (&(tsk)->cpus_allowed)
1785 1797