diff options
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/blkdev.h | 9 | ||||
-rw-r--r-- | include/linux/compat.h | 2 | ||||
-rw-r--r-- | include/linux/highmem.h | 2 | ||||
-rw-r--r-- | include/linux/ide.h | 8 | ||||
-rw-r--r-- | include/linux/idr.h | 3 | ||||
-rw-r--r-- | include/linux/irq.h | 11 | ||||
-rw-r--r-- | include/linux/libata.h | 1 | ||||
-rw-r--r-- | include/linux/memory.h | 2 | ||||
-rw-r--r-- | include/linux/mlx4/device.h | 1 | ||||
-rw-r--r-- | include/linux/netfilter/x_tables.h | 2 | ||||
-rw-r--r-- | include/linux/page_cgroup.h | 4 | ||||
-rw-r--r-- | include/linux/sched.h | 4 | ||||
-rw-r--r-- | include/linux/security.h | 12 |
13 files changed, 37 insertions, 24 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index a135256b272c..6dcd30d806cd 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h | |||
@@ -786,6 +786,8 @@ static inline void blk_run_address_space(struct address_space *mapping) | |||
786 | blk_run_backing_dev(mapping->backing_dev_info, NULL); | 786 | blk_run_backing_dev(mapping->backing_dev_info, NULL); |
787 | } | 787 | } |
788 | 788 | ||
789 | extern void blkdev_dequeue_request(struct request *req); | ||
790 | |||
789 | /* | 791 | /* |
790 | * blk_end_request() and friends. | 792 | * blk_end_request() and friends. |
791 | * __blk_end_request() and end_request() must be called with | 793 | * __blk_end_request() and end_request() must be called with |
@@ -820,11 +822,6 @@ extern void blk_update_request(struct request *rq, int error, | |||
820 | extern unsigned int blk_rq_bytes(struct request *rq); | 822 | extern unsigned int blk_rq_bytes(struct request *rq); |
821 | extern unsigned int blk_rq_cur_bytes(struct request *rq); | 823 | extern unsigned int blk_rq_cur_bytes(struct request *rq); |
822 | 824 | ||
823 | static inline void blkdev_dequeue_request(struct request *req) | ||
824 | { | ||
825 | elv_dequeue_request(req->q, req); | ||
826 | } | ||
827 | |||
828 | /* | 825 | /* |
829 | * Access functions for manipulating queue properties | 826 | * Access functions for manipulating queue properties |
830 | */ | 827 | */ |
@@ -921,6 +918,8 @@ extern void blk_set_cmd_filter_defaults(struct blk_cmd_filter *filter); | |||
921 | 918 | ||
922 | #define MAX_SEGMENT_SIZE 65536 | 919 | #define MAX_SEGMENT_SIZE 65536 |
923 | 920 | ||
921 | #define BLK_SEG_BOUNDARY_MASK 0xFFFFFFFFUL | ||
922 | |||
924 | #define blkdev_entry_to_request(entry) list_entry((entry), struct request, queuelist) | 923 | #define blkdev_entry_to_request(entry) list_entry((entry), struct request, queuelist) |
925 | 924 | ||
926 | static inline int queue_hardsect_size(struct request_queue *q) | 925 | static inline int queue_hardsect_size(struct request_queue *q) |
diff --git a/include/linux/compat.h b/include/linux/compat.h index f061a1ea1b74..e88f3ecf38b4 100644 --- a/include/linux/compat.h +++ b/include/linux/compat.h | |||
@@ -252,12 +252,10 @@ extern int compat_ptrace_request(struct task_struct *child, | |||
252 | compat_long_t request, | 252 | compat_long_t request, |
253 | compat_ulong_t addr, compat_ulong_t data); | 253 | compat_ulong_t addr, compat_ulong_t data); |
254 | 254 | ||
255 | #ifdef __ARCH_WANT_COMPAT_SYS_PTRACE | ||
256 | extern long compat_arch_ptrace(struct task_struct *child, compat_long_t request, | 255 | extern long compat_arch_ptrace(struct task_struct *child, compat_long_t request, |
257 | compat_ulong_t addr, compat_ulong_t data); | 256 | compat_ulong_t addr, compat_ulong_t data); |
258 | asmlinkage long compat_sys_ptrace(compat_long_t request, compat_long_t pid, | 257 | asmlinkage long compat_sys_ptrace(compat_long_t request, compat_long_t pid, |
259 | compat_long_t addr, compat_long_t data); | 258 | compat_long_t addr, compat_long_t data); |
260 | #endif /* __ARCH_WANT_COMPAT_SYS_PTRACE */ | ||
261 | 259 | ||
262 | /* | 260 | /* |
263 | * epoll (fs/eventpoll.c) compat bits follow ... | 261 | * epoll (fs/eventpoll.c) compat bits follow ... |
diff --git a/include/linux/highmem.h b/include/linux/highmem.h index 7dcbc82f3b7b..13875ce9112a 100644 --- a/include/linux/highmem.h +++ b/include/linux/highmem.h | |||
@@ -63,12 +63,14 @@ static inline void *kmap_atomic(struct page *page, enum km_type idx) | |||
63 | #endif /* CONFIG_HIGHMEM */ | 63 | #endif /* CONFIG_HIGHMEM */ |
64 | 64 | ||
65 | /* when CONFIG_HIGHMEM is not set these will be plain clear/copy_page */ | 65 | /* when CONFIG_HIGHMEM is not set these will be plain clear/copy_page */ |
66 | #ifndef clear_user_highpage | ||
66 | static inline void clear_user_highpage(struct page *page, unsigned long vaddr) | 67 | static inline void clear_user_highpage(struct page *page, unsigned long vaddr) |
67 | { | 68 | { |
68 | void *addr = kmap_atomic(page, KM_USER0); | 69 | void *addr = kmap_atomic(page, KM_USER0); |
69 | clear_user_page(addr, vaddr, page); | 70 | clear_user_page(addr, vaddr, page); |
70 | kunmap_atomic(addr, KM_USER0); | 71 | kunmap_atomic(addr, KM_USER0); |
71 | } | 72 | } |
73 | #endif | ||
72 | 74 | ||
73 | #ifndef __HAVE_ARCH_ALLOC_ZEROED_USER_HIGHPAGE | 75 | #ifndef __HAVE_ARCH_ALLOC_ZEROED_USER_HIGHPAGE |
74 | /** | 76 | /** |
diff --git a/include/linux/ide.h b/include/linux/ide.h index 54525be4b5f8..010fb26a1579 100644 --- a/include/linux/ide.h +++ b/include/linux/ide.h | |||
@@ -1296,6 +1296,13 @@ extern int __ide_pci_register_driver(struct pci_driver *driver, struct module *o | |||
1296 | #define ide_pci_register_driver(d) pci_register_driver(d) | 1296 | #define ide_pci_register_driver(d) pci_register_driver(d) |
1297 | #endif | 1297 | #endif |
1298 | 1298 | ||
1299 | static inline int ide_pci_is_in_compatibility_mode(struct pci_dev *dev) | ||
1300 | { | ||
1301 | if ((dev->class >> 8) == PCI_CLASS_STORAGE_IDE && (dev->class & 5) != 5) | ||
1302 | return 1; | ||
1303 | return 0; | ||
1304 | } | ||
1305 | |||
1299 | void ide_pci_setup_ports(struct pci_dev *, const struct ide_port_info *, int, | 1306 | void ide_pci_setup_ports(struct pci_dev *, const struct ide_port_info *, int, |
1300 | hw_regs_t *, hw_regs_t **); | 1307 | hw_regs_t *, hw_regs_t **); |
1301 | void ide_setup_pci_noise(struct pci_dev *, const struct ide_port_info *); | 1308 | void ide_setup_pci_noise(struct pci_dev *, const struct ide_port_info *); |
@@ -1375,6 +1382,7 @@ enum { | |||
1375 | IDE_HFLAG_IO_32BIT = (1 << 24), | 1382 | IDE_HFLAG_IO_32BIT = (1 << 24), |
1376 | /* unmask IRQs */ | 1383 | /* unmask IRQs */ |
1377 | IDE_HFLAG_UNMASK_IRQS = (1 << 25), | 1384 | IDE_HFLAG_UNMASK_IRQS = (1 << 25), |
1385 | IDE_HFLAG_BROKEN_ALTSTATUS = (1 << 26), | ||
1378 | /* serialize ports if DMA is possible (for sl82c105) */ | 1386 | /* serialize ports if DMA is possible (for sl82c105) */ |
1379 | IDE_HFLAG_SERIALIZE_DMA = (1 << 27), | 1387 | IDE_HFLAG_SERIALIZE_DMA = (1 << 27), |
1380 | /* force host out of "simplex" mode */ | 1388 | /* force host out of "simplex" mode */ |
diff --git a/include/linux/idr.h b/include/linux/idr.h index fa035f96f2a3..dd846df8cd32 100644 --- a/include/linux/idr.h +++ b/include/linux/idr.h | |||
@@ -52,13 +52,14 @@ struct idr_layer { | |||
52 | unsigned long bitmap; /* A zero bit means "space here" */ | 52 | unsigned long bitmap; /* A zero bit means "space here" */ |
53 | struct idr_layer *ary[1<<IDR_BITS]; | 53 | struct idr_layer *ary[1<<IDR_BITS]; |
54 | int count; /* When zero, we can release it */ | 54 | int count; /* When zero, we can release it */ |
55 | int layer; /* distance from leaf */ | ||
55 | struct rcu_head rcu_head; | 56 | struct rcu_head rcu_head; |
56 | }; | 57 | }; |
57 | 58 | ||
58 | struct idr { | 59 | struct idr { |
59 | struct idr_layer *top; | 60 | struct idr_layer *top; |
60 | struct idr_layer *id_free; | 61 | struct idr_layer *id_free; |
61 | int layers; | 62 | int layers; /* only valid without concurrent changes */ |
62 | int id_free_cnt; | 63 | int id_free_cnt; |
63 | spinlock_t lock; | 64 | spinlock_t lock; |
64 | }; | 65 | }; |
diff --git a/include/linux/irq.h b/include/linux/irq.h index d058c57be02d..3dddfa703ebd 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h | |||
@@ -63,7 +63,8 @@ typedef void (*irq_flow_handler_t)(unsigned int irq, | |||
63 | #define IRQ_MOVE_PENDING 0x00200000 /* need to re-target IRQ destination */ | 63 | #define IRQ_MOVE_PENDING 0x00200000 /* need to re-target IRQ destination */ |
64 | #define IRQ_NO_BALANCING 0x00400000 /* IRQ is excluded from balancing */ | 64 | #define IRQ_NO_BALANCING 0x00400000 /* IRQ is excluded from balancing */ |
65 | #define IRQ_SPURIOUS_DISABLED 0x00800000 /* IRQ was disabled by the spurious trap */ | 65 | #define IRQ_SPURIOUS_DISABLED 0x00800000 /* IRQ was disabled by the spurious trap */ |
66 | #define IRQ_MOVE_PCNTXT 0x01000000 /* IRQ migration from process context */ | 66 | #define IRQ_MOVE_PCNTXT 0x01000000 /* IRQ migration from process context */ |
67 | #define IRQ_AFFINITY_SET 0x02000000 /* IRQ affinity was set from userspace*/ | ||
67 | 68 | ||
68 | #ifdef CONFIG_IRQ_PER_CPU | 69 | #ifdef CONFIG_IRQ_PER_CPU |
69 | # define CHECK_IRQ_PER_CPU(var) ((var) & IRQ_PER_CPU) | 70 | # define CHECK_IRQ_PER_CPU(var) ((var) & IRQ_PER_CPU) |
@@ -130,7 +131,7 @@ struct irq_chip { | |||
130 | 131 | ||
131 | /** | 132 | /** |
132 | * struct irq_desc - interrupt descriptor | 133 | * struct irq_desc - interrupt descriptor |
133 | * | 134 | * @irq: interrupt number for this descriptor |
134 | * @handle_irq: highlevel irq-events handler [if NULL, __do_IRQ()] | 135 | * @handle_irq: highlevel irq-events handler [if NULL, __do_IRQ()] |
135 | * @chip: low level interrupt hardware access | 136 | * @chip: low level interrupt hardware access |
136 | * @msi_desc: MSI descriptor | 137 | * @msi_desc: MSI descriptor |
@@ -149,7 +150,6 @@ struct irq_chip { | |||
149 | * @cpu: cpu index useful for balancing | 150 | * @cpu: cpu index useful for balancing |
150 | * @pending_mask: pending rebalanced interrupts | 151 | * @pending_mask: pending rebalanced interrupts |
151 | * @dir: /proc/irq/ procfs entry | 152 | * @dir: /proc/irq/ procfs entry |
152 | * @affinity_entry: /proc/irq/smp_affinity procfs entry on SMP | ||
153 | * @name: flow handler name for /proc/interrupts output | 153 | * @name: flow handler name for /proc/interrupts output |
154 | */ | 154 | */ |
155 | struct irq_desc { | 155 | struct irq_desc { |
@@ -210,7 +210,6 @@ extern int setup_irq(unsigned int irq, struct irqaction *new); | |||
210 | 210 | ||
211 | #ifdef CONFIG_GENERIC_PENDING_IRQ | 211 | #ifdef CONFIG_GENERIC_PENDING_IRQ |
212 | 212 | ||
213 | void set_pending_irq(unsigned int irq, cpumask_t mask); | ||
214 | void move_native_irq(int irq); | 213 | void move_native_irq(int irq); |
215 | void move_masked_irq(int irq); | 214 | void move_masked_irq(int irq); |
216 | 215 | ||
@@ -228,10 +227,6 @@ static inline void move_masked_irq(int irq) | |||
228 | { | 227 | { |
229 | } | 228 | } |
230 | 229 | ||
231 | static inline void set_pending_irq(unsigned int irq, cpumask_t mask) | ||
232 | { | ||
233 | } | ||
234 | |||
235 | #endif /* CONFIG_GENERIC_PENDING_IRQ */ | 230 | #endif /* CONFIG_GENERIC_PENDING_IRQ */ |
236 | 231 | ||
237 | #else /* CONFIG_SMP */ | 232 | #else /* CONFIG_SMP */ |
diff --git a/include/linux/libata.h b/include/linux/libata.h index 59b0f1c807b5..ed3f26eb5df1 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h | |||
@@ -375,6 +375,7 @@ enum { | |||
375 | ATA_HORKAGE_BRIDGE_OK = (1 << 10), /* no bridge limits */ | 375 | ATA_HORKAGE_BRIDGE_OK = (1 << 10), /* no bridge limits */ |
376 | ATA_HORKAGE_ATAPI_MOD16_DMA = (1 << 11), /* use ATAPI DMA for commands | 376 | ATA_HORKAGE_ATAPI_MOD16_DMA = (1 << 11), /* use ATAPI DMA for commands |
377 | not multiple of 16 bytes */ | 377 | not multiple of 16 bytes */ |
378 | ATA_HORKAGE_FIRMWARE_WARN = (1 << 12), /* firwmare update warning */ | ||
378 | 379 | ||
379 | /* DMA mask for user DMA control: User visible values; DO NOT | 380 | /* DMA mask for user DMA control: User visible values; DO NOT |
380 | renumber */ | 381 | renumber */ |
diff --git a/include/linux/memory.h b/include/linux/memory.h index 2f5f8a5ef2a0..36c82c9e6ea7 100644 --- a/include/linux/memory.h +++ b/include/linux/memory.h | |||
@@ -91,7 +91,7 @@ extern int memory_notify(unsigned long val, void *v); | |||
91 | 91 | ||
92 | #ifdef CONFIG_MEMORY_HOTPLUG | 92 | #ifdef CONFIG_MEMORY_HOTPLUG |
93 | #define hotplug_memory_notifier(fn, pri) { \ | 93 | #define hotplug_memory_notifier(fn, pri) { \ |
94 | static struct notifier_block fn##_mem_nb = \ | 94 | static __meminitdata struct notifier_block fn##_mem_nb =\ |
95 | { .notifier_call = fn, .priority = pri }; \ | 95 | { .notifier_call = fn, .priority = pri }; \ |
96 | register_memory_notifier(&fn##_mem_nb); \ | 96 | register_memory_notifier(&fn##_mem_nb); \ |
97 | } | 97 | } |
diff --git a/include/linux/mlx4/device.h b/include/linux/mlx4/device.h index bd9977b89490..371086fd946f 100644 --- a/include/linux/mlx4/device.h +++ b/include/linux/mlx4/device.h | |||
@@ -179,6 +179,7 @@ struct mlx4_caps { | |||
179 | int num_ports; | 179 | int num_ports; |
180 | int vl_cap[MLX4_MAX_PORTS + 1]; | 180 | int vl_cap[MLX4_MAX_PORTS + 1]; |
181 | int ib_mtu_cap[MLX4_MAX_PORTS + 1]; | 181 | int ib_mtu_cap[MLX4_MAX_PORTS + 1]; |
182 | __be32 ib_port_def_cap[MLX4_MAX_PORTS + 1]; | ||
182 | u64 def_mac[MLX4_MAX_PORTS + 1]; | 183 | u64 def_mac[MLX4_MAX_PORTS + 1]; |
183 | int eth_mtu_cap[MLX4_MAX_PORTS + 1]; | 184 | int eth_mtu_cap[MLX4_MAX_PORTS + 1]; |
184 | int gid_table_len[MLX4_MAX_PORTS + 1]; | 185 | int gid_table_len[MLX4_MAX_PORTS + 1]; |
diff --git a/include/linux/netfilter/x_tables.h b/include/linux/netfilter/x_tables.h index be41b609c88f..e52ce475d19f 100644 --- a/include/linux/netfilter/x_tables.h +++ b/include/linux/netfilter/x_tables.h | |||
@@ -251,7 +251,7 @@ struct xt_target_param { | |||
251 | */ | 251 | */ |
252 | struct xt_tgchk_param { | 252 | struct xt_tgchk_param { |
253 | const char *table; | 253 | const char *table; |
254 | void *entryinfo; | 254 | const void *entryinfo; |
255 | const struct xt_target *target; | 255 | const struct xt_target *target; |
256 | void *targinfo; | 256 | void *targinfo; |
257 | unsigned int hook_mask; | 257 | unsigned int hook_mask; |
diff --git a/include/linux/page_cgroup.h b/include/linux/page_cgroup.h index f546ad6fc028..1e6d34bfa094 100644 --- a/include/linux/page_cgroup.h +++ b/include/linux/page_cgroup.h | |||
@@ -17,7 +17,7 @@ struct page_cgroup { | |||
17 | struct list_head lru; /* per cgroup LRU list */ | 17 | struct list_head lru; /* per cgroup LRU list */ |
18 | }; | 18 | }; |
19 | 19 | ||
20 | void __init pgdat_page_cgroup_init(struct pglist_data *pgdat); | 20 | void __meminit pgdat_page_cgroup_init(struct pglist_data *pgdat); |
21 | void __init page_cgroup_init(void); | 21 | void __init page_cgroup_init(void); |
22 | struct page_cgroup *lookup_page_cgroup(struct page *page); | 22 | struct page_cgroup *lookup_page_cgroup(struct page *page); |
23 | 23 | ||
@@ -91,7 +91,7 @@ static inline void unlock_page_cgroup(struct page_cgroup *pc) | |||
91 | #else /* CONFIG_CGROUP_MEM_RES_CTLR */ | 91 | #else /* CONFIG_CGROUP_MEM_RES_CTLR */ |
92 | struct page_cgroup; | 92 | struct page_cgroup; |
93 | 93 | ||
94 | static inline void pgdat_page_cgroup_init(struct pglist_data *pgdat) | 94 | static inline void __meminit pgdat_page_cgroup_init(struct pglist_data *pgdat) |
95 | { | 95 | { |
96 | } | 96 | } |
97 | 97 | ||
diff --git a/include/linux/sched.h b/include/linux/sched.h index 644ffbda17ca..55e30d114477 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -630,6 +630,10 @@ struct user_struct { | |||
630 | atomic_t inotify_watches; /* How many inotify watches does this user have? */ | 630 | atomic_t inotify_watches; /* How many inotify watches does this user have? */ |
631 | atomic_t inotify_devs; /* How many inotify devs does this user have opened? */ | 631 | atomic_t inotify_devs; /* How many inotify devs does this user have opened? */ |
632 | #endif | 632 | #endif |
633 | #ifdef CONFIG_EPOLL | ||
634 | atomic_t epoll_devs; /* The number of epoll descriptors currently open */ | ||
635 | atomic_t epoll_watches; /* The number of file descriptors currently watched */ | ||
636 | #endif | ||
633 | #ifdef CONFIG_POSIX_MQUEUE | 637 | #ifdef CONFIG_POSIX_MQUEUE |
634 | /* protected by mq_lock */ | 638 | /* protected by mq_lock */ |
635 | unsigned long mq_bytes; /* How many bytes can be allocated to mqueue? */ | 639 | unsigned long mq_bytes; /* How many bytes can be allocated to mqueue? */ |
diff --git a/include/linux/security.h b/include/linux/security.h index c13f1cec9abb..e3d4ecda2673 100644 --- a/include/linux/security.h +++ b/include/linux/security.h | |||
@@ -1818,17 +1818,21 @@ static inline int security_settime(struct timespec *ts, struct timezone *tz) | |||
1818 | 1818 | ||
1819 | static inline int security_vm_enough_memory(long pages) | 1819 | static inline int security_vm_enough_memory(long pages) |
1820 | { | 1820 | { |
1821 | WARN_ON(current->mm == NULL); | ||
1821 | return cap_vm_enough_memory(current->mm, pages); | 1822 | return cap_vm_enough_memory(current->mm, pages); |
1822 | } | 1823 | } |
1823 | 1824 | ||
1824 | static inline int security_vm_enough_memory_kern(long pages) | 1825 | static inline int security_vm_enough_memory_mm(struct mm_struct *mm, long pages) |
1825 | { | 1826 | { |
1826 | return cap_vm_enough_memory(current->mm, pages); | 1827 | WARN_ON(mm == NULL); |
1828 | return cap_vm_enough_memory(mm, pages); | ||
1827 | } | 1829 | } |
1828 | 1830 | ||
1829 | static inline int security_vm_enough_memory_mm(struct mm_struct *mm, long pages) | 1831 | static inline int security_vm_enough_memory_kern(long pages) |
1830 | { | 1832 | { |
1831 | return cap_vm_enough_memory(mm, pages); | 1833 | /* If current->mm is a kernel thread then we will pass NULL, |
1834 | for this specific case that is fine */ | ||
1835 | return cap_vm_enough_memory(current->mm, pages); | ||
1832 | } | 1836 | } |
1833 | 1837 | ||
1834 | static inline int security_bprm_alloc(struct linux_binprm *bprm) | 1838 | static inline int security_bprm_alloc(struct linux_binprm *bprm) |