aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/acpi.h48
-rw-r--r--include/linux/audit.h6
-rw-r--r--include/linux/blkdev.h10
-rw-r--r--include/linux/c2port.h65
-rw-r--r--include/linux/can/core.h2
-rw-r--r--include/linux/compat.h2
-rw-r--r--include/linux/cpuset.h4
-rw-r--r--include/linux/dmi.h2
-rw-r--r--include/linux/fs.h33
-rw-r--r--include/linux/ftrace.h3
-rw-r--r--include/linux/genhd.h4
-rw-r--r--include/linux/highmem.h2
-rw-r--r--include/linux/hrtimer.h5
-rw-r--r--include/linux/ide.h8
-rw-r--r--include/linux/idr.h3
-rw-r--r--include/linux/inotify.h11
-rw-r--r--include/linux/input.h2
-rw-r--r--include/linux/irq.h11
-rw-r--r--include/linux/kernel.h42
-rw-r--r--include/linux/kexec.h4
-rw-r--r--include/linux/libata.h1
-rw-r--r--include/linux/lockdep.h5
-rw-r--r--include/linux/memory.h2
-rw-r--r--include/linux/mfd/wm8350/rtc.h2
-rw-r--r--include/linux/mlx4/device.h1
-rw-r--r--include/linux/mm.h19
-rw-r--r--include/linux/net.h6
-rw-r--r--include/linux/netdevice.h7
-rw-r--r--include/linux/netfilter/nfnetlink_conntrack.h1
-rw-r--r--include/linux/netfilter/x_tables.h2
-rw-r--r--include/linux/page_cgroup.h4
-rw-r--r--include/linux/pci.h6
-rw-r--r--include/linux/pci_ids.h5
-rw-r--r--include/linux/ratelimit.h7
-rw-r--r--include/linux/ring_buffer.h3
-rw-r--r--include/linux/sched.h5
-rw-r--r--include/linux/security.h12
-rw-r--r--include/linux/serial_core.h3
-rw-r--r--include/linux/slab.h28
-rw-r--r--include/linux/smp.h2
-rw-r--r--include/linux/ssb/ssb.h42
-rw-r--r--include/linux/syscalls.h3
-rw-r--r--include/linux/telephony.h2
-rw-r--r--include/linux/usb.h2
-rw-r--r--include/linux/usb/ch9.h8
45 files changed, 343 insertions, 102 deletions
diff --git a/include/linux/acpi.h b/include/linux/acpi.h
index fd6a452b0ceb..fba8051fb297 100644
--- a/include/linux/acpi.h
+++ b/include/linux/acpi.h
@@ -163,8 +163,6 @@ struct acpi_pci_driver {
163int acpi_pci_register_driver(struct acpi_pci_driver *driver); 163int acpi_pci_register_driver(struct acpi_pci_driver *driver);
164void acpi_pci_unregister_driver(struct acpi_pci_driver *driver); 164void acpi_pci_unregister_driver(struct acpi_pci_driver *driver);
165 165
166#ifdef CONFIG_ACPI_EC
167
168extern int ec_read(u8 addr, u8 *val); 166extern int ec_read(u8 addr, u8 *val);
169extern int ec_write(u8 addr, u8 val); 167extern int ec_write(u8 addr, u8 val);
170extern int ec_transaction(u8 command, 168extern int ec_transaction(u8 command,
@@ -172,8 +170,6 @@ extern int ec_transaction(u8 command,
172 u8 *rdata, unsigned rdata_len, 170 u8 *rdata, unsigned rdata_len,
173 int force_poll); 171 int force_poll);
174 172
175#endif /*CONFIG_ACPI_EC*/
176
177#if defined(CONFIG_ACPI_WMI) || defined(CONFIG_ACPI_WMI_MODULE) 173#if defined(CONFIG_ACPI_WMI) || defined(CONFIG_ACPI_WMI_MODULE)
178 174
179typedef void (*wmi_notify_handler) (u32 value, void *context); 175typedef void (*wmi_notify_handler) (u32 value, void *context);
@@ -194,6 +190,50 @@ extern bool wmi_has_guid(const char *guid);
194 190
195#endif /* CONFIG_ACPI_WMI */ 191#endif /* CONFIG_ACPI_WMI */
196 192
193#define ACPI_VIDEO_OUTPUT_SWITCHING 0x0001
194#define ACPI_VIDEO_DEVICE_POSTING 0x0002
195#define ACPI_VIDEO_ROM_AVAILABLE 0x0004
196#define ACPI_VIDEO_BACKLIGHT 0x0008
197#define ACPI_VIDEO_BACKLIGHT_FORCE_VENDOR 0x0010
198#define ACPI_VIDEO_BACKLIGHT_FORCE_VIDEO 0x0020
199#define ACPI_VIDEO_OUTPUT_SWITCHING_FORCE_VENDOR 0x0040
200#define ACPI_VIDEO_OUTPUT_SWITCHING_FORCE_VIDEO 0x0080
201#define ACPI_VIDEO_BACKLIGHT_DMI_VENDOR 0x0100
202#define ACPI_VIDEO_BACKLIGHT_DMI_VIDEO 0x0200
203#define ACPI_VIDEO_OUTPUT_SWITCHING_DMI_VENDOR 0x0400
204#define ACPI_VIDEO_OUTPUT_SWITCHING_DMI_VIDEO 0x0800
205
206#if defined(CONFIG_ACPI_VIDEO) || defined(CONFIG_ACPI_VIDEO_MODULE)
207
208extern long acpi_video_get_capabilities(acpi_handle graphics_dev_handle);
209extern long acpi_is_video_device(struct acpi_device *device);
210extern int acpi_video_backlight_support(void);
211extern int acpi_video_display_switch_support(void);
212
213#else
214
215static inline long acpi_video_get_capabilities(acpi_handle graphics_dev_handle)
216{
217 return 0;
218}
219
220static inline long acpi_is_video_device(struct acpi_device *device)
221{
222 return 0;
223}
224
225static inline int acpi_video_backlight_support(void)
226{
227 return 0;
228}
229
230static inline int acpi_video_display_switch_support(void)
231{
232 return 0;
233}
234
235#endif /* defined(CONFIG_ACPI_VIDEO) || defined(CONFIG_ACPI_VIDEO_MODULE) */
236
197extern int acpi_blacklisted(void); 237extern int acpi_blacklisted(void);
198#ifdef CONFIG_DMI 238#ifdef CONFIG_DMI
199extern void acpi_dmi_osi_linux(int enable, const struct dmi_system_id *d); 239extern void acpi_dmi_osi_linux(int enable, const struct dmi_system_id *d);
diff --git a/include/linux/audit.h b/include/linux/audit.h
index 6272a395d43c..8f0672d13eb1 100644
--- a/include/linux/audit.h
+++ b/include/linux/audit.h
@@ -391,6 +391,7 @@ extern int audit_classify_arch(int arch);
391#ifdef CONFIG_AUDITSYSCALL 391#ifdef CONFIG_AUDITSYSCALL
392/* These are defined in auditsc.c */ 392/* These are defined in auditsc.c */
393 /* Public API */ 393 /* Public API */
394extern void audit_finish_fork(struct task_struct *child);
394extern int audit_alloc(struct task_struct *task); 395extern int audit_alloc(struct task_struct *task);
395extern void audit_free(struct task_struct *task); 396extern void audit_free(struct task_struct *task);
396extern void audit_syscall_entry(int arch, 397extern void audit_syscall_entry(int arch,
@@ -434,7 +435,7 @@ static inline void audit_ptrace(struct task_struct *t)
434 435
435 /* Private API (for audit.c only) */ 436 /* Private API (for audit.c only) */
436extern unsigned int audit_serial(void); 437extern unsigned int audit_serial(void);
437extern void auditsc_get_stamp(struct audit_context *ctx, 438extern int auditsc_get_stamp(struct audit_context *ctx,
438 struct timespec *t, unsigned int *serial); 439 struct timespec *t, unsigned int *serial);
439extern int audit_set_loginuid(struct task_struct *task, uid_t loginuid); 440extern int audit_set_loginuid(struct task_struct *task, uid_t loginuid);
440#define audit_get_loginuid(t) ((t)->loginuid) 441#define audit_get_loginuid(t) ((t)->loginuid)
@@ -504,6 +505,7 @@ static inline int audit_mq_getsetattr(mqd_t mqdes, struct mq_attr *mqstat)
504extern int audit_n_rules; 505extern int audit_n_rules;
505extern int audit_signals; 506extern int audit_signals;
506#else 507#else
508#define audit_finish_fork(t)
507#define audit_alloc(t) ({ 0; }) 509#define audit_alloc(t) ({ 0; })
508#define audit_free(t) do { ; } while (0) 510#define audit_free(t) do { ; } while (0)
509#define audit_syscall_entry(ta,a,b,c,d,e) do { ; } while (0) 511#define audit_syscall_entry(ta,a,b,c,d,e) do { ; } while (0)
@@ -516,7 +518,7 @@ extern int audit_signals;
516#define audit_inode(n,d) do { ; } while (0) 518#define audit_inode(n,d) do { ; } while (0)
517#define audit_inode_child(d,i,p) do { ; } while (0) 519#define audit_inode_child(d,i,p) do { ; } while (0)
518#define audit_core_dumps(i) do { ; } while (0) 520#define audit_core_dumps(i) do { ; } while (0)
519#define auditsc_get_stamp(c,t,s) do { BUG(); } while (0) 521#define auditsc_get_stamp(c,t,s) (0)
520#define audit_get_loginuid(t) (-1) 522#define audit_get_loginuid(t) (-1)
521#define audit_get_sessionid(t) (-1) 523#define audit_get_sessionid(t) (-1)
522#define audit_log_task_context(b) do { ; } while (0) 524#define audit_log_task_context(b) do { ; } while (0)
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index a135256b272c..031a315c0509 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -662,6 +662,7 @@ extern unsigned long blk_max_low_pfn, blk_max_pfn;
662 * default timeout for SG_IO if none specified 662 * default timeout for SG_IO if none specified
663 */ 663 */
664#define BLK_DEFAULT_SG_TIMEOUT (60 * HZ) 664#define BLK_DEFAULT_SG_TIMEOUT (60 * HZ)
665#define BLK_MIN_SG_TIMEOUT (7 * HZ)
665 666
666#ifdef CONFIG_BOUNCE 667#ifdef CONFIG_BOUNCE
667extern int init_emergency_isa_pool(void); 668extern int init_emergency_isa_pool(void);
@@ -786,6 +787,8 @@ static inline void blk_run_address_space(struct address_space *mapping)
786 blk_run_backing_dev(mapping->backing_dev_info, NULL); 787 blk_run_backing_dev(mapping->backing_dev_info, NULL);
787} 788}
788 789
790extern void blkdev_dequeue_request(struct request *req);
791
789/* 792/*
790 * blk_end_request() and friends. 793 * blk_end_request() and friends.
791 * __blk_end_request() and end_request() must be called with 794 * __blk_end_request() and end_request() must be called with
@@ -820,11 +823,6 @@ extern void blk_update_request(struct request *rq, int error,
820extern unsigned int blk_rq_bytes(struct request *rq); 823extern unsigned int blk_rq_bytes(struct request *rq);
821extern unsigned int blk_rq_cur_bytes(struct request *rq); 824extern unsigned int blk_rq_cur_bytes(struct request *rq);
822 825
823static inline void blkdev_dequeue_request(struct request *req)
824{
825 elv_dequeue_request(req->q, req);
826}
827
828/* 826/*
829 * Access functions for manipulating queue properties 827 * Access functions for manipulating queue properties
830 */ 828 */
@@ -921,6 +919,8 @@ extern void blk_set_cmd_filter_defaults(struct blk_cmd_filter *filter);
921 919
922#define MAX_SEGMENT_SIZE 65536 920#define MAX_SEGMENT_SIZE 65536
923 921
922#define BLK_SEG_BOUNDARY_MASK 0xFFFFFFFFUL
923
924#define blkdev_entry_to_request(entry) list_entry((entry), struct request, queuelist) 924#define blkdev_entry_to_request(entry) list_entry((entry), struct request, queuelist)
925 925
926static inline int queue_hardsect_size(struct request_queue *q) 926static inline int queue_hardsect_size(struct request_queue *q)
diff --git a/include/linux/c2port.h b/include/linux/c2port.h
new file mode 100644
index 000000000000..7b5a2388ba67
--- /dev/null
+++ b/include/linux/c2port.h
@@ -0,0 +1,65 @@
1/*
2 * Silicon Labs C2 port Linux support
3 *
4 * Copyright (c) 2007 Rodolfo Giometti <giometti@linux.it>
5 * Copyright (c) 2007 Eurotech S.p.A. <info@eurotech.it>
6 *
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License version 2 as published by
9 * the Free Software Foundation
10 */
11
12#include <linux/device.h>
13
14#define C2PORT_NAME_LEN 32
15
16/*
17 * C2 port basic structs
18 */
19
20/* Main struct */
21struct c2port_ops;
22struct c2port_device {
23 unsigned int access:1;
24 unsigned int flash_access:1;
25
26 int id;
27 char name[C2PORT_NAME_LEN];
28 struct c2port_ops *ops;
29 struct mutex mutex; /* prevent races during read/write */
30
31 struct device *dev;
32
33 void *private_data;
34};
35
36/* Basic operations */
37struct c2port_ops {
38 /* Flash layout */
39 unsigned short block_size; /* flash block size in bytes */
40 unsigned short blocks_num; /* flash blocks number */
41
42 /* Enable or disable the access to C2 port */
43 void (*access)(struct c2port_device *dev, int status);
44
45 /* Set C2D data line as input/output */
46 void (*c2d_dir)(struct c2port_device *dev, int dir);
47
48 /* Read/write C2D data line */
49 int (*c2d_get)(struct c2port_device *dev);
50 void (*c2d_set)(struct c2port_device *dev, int status);
51
52 /* Write C2CK clock line */
53 void (*c2ck_set)(struct c2port_device *dev, int status);
54};
55
56/*
57 * Exported functions
58 */
59
60#define to_class_dev(obj) container_of((obj), struct class_device, kobj)
61#define to_c2port_device(obj) container_of((obj), struct c2port_device, class)
62
63extern struct c2port_device *c2port_device_register(char *name,
64 struct c2port_ops *ops, void *devdata);
65extern void c2port_device_unregister(struct c2port_device *dev);
diff --git a/include/linux/can/core.h b/include/linux/can/core.h
index e9ca210ffa5b..f50785ad4781 100644
--- a/include/linux/can/core.h
+++ b/include/linux/can/core.h
@@ -19,7 +19,7 @@
19#include <linux/skbuff.h> 19#include <linux/skbuff.h>
20#include <linux/netdevice.h> 20#include <linux/netdevice.h>
21 21
22#define CAN_VERSION "20071116" 22#define CAN_VERSION "20081130"
23 23
24/* increment this number each time you change some user-space interface */ 24/* increment this number each time you change some user-space interface */
25#define CAN_ABI_VERSION "8" 25#define CAN_ABI_VERSION "8"
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
256extern long compat_arch_ptrace(struct task_struct *child, compat_long_t request, 255extern 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);
258asmlinkage long compat_sys_ptrace(compat_long_t request, compat_long_t pid, 257asmlinkage 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/cpuset.h b/include/linux/cpuset.h
index 2691926fb506..8e540d32c9fe 100644
--- a/include/linux/cpuset.h
+++ b/include/linux/cpuset.h
@@ -74,8 +74,6 @@ static inline int cpuset_do_slab_mem_spread(void)
74 return current->flags & PF_SPREAD_SLAB; 74 return current->flags & PF_SPREAD_SLAB;
75} 75}
76 76
77extern void cpuset_track_online_nodes(void);
78
79extern int current_cpuset_is_being_rebound(void); 77extern int current_cpuset_is_being_rebound(void);
80 78
81extern void rebuild_sched_domains(void); 79extern void rebuild_sched_domains(void);
@@ -151,8 +149,6 @@ static inline int cpuset_do_slab_mem_spread(void)
151 return 0; 149 return 0;
152} 150}
153 151
154static inline void cpuset_track_online_nodes(void) {}
155
156static inline int current_cpuset_is_being_rebound(void) 152static inline int current_cpuset_is_being_rebound(void)
157{ 153{
158 return 0; 154 return 0;
diff --git a/include/linux/dmi.h b/include/linux/dmi.h
index e5084eb5943a..2bfda178f274 100644
--- a/include/linux/dmi.h
+++ b/include/linux/dmi.h
@@ -44,6 +44,7 @@ extern const struct dmi_device * dmi_find_device(int type, const char *name,
44extern void dmi_scan_machine(void); 44extern void dmi_scan_machine(void);
45extern int dmi_get_year(int field); 45extern int dmi_get_year(int field);
46extern int dmi_name_in_vendors(const char *str); 46extern int dmi_name_in_vendors(const char *str);
47extern int dmi_name_in_serial(const char *str);
47extern int dmi_available; 48extern int dmi_available;
48extern int dmi_walk(void (*decode)(const struct dmi_header *)); 49extern int dmi_walk(void (*decode)(const struct dmi_header *));
49 50
@@ -56,6 +57,7 @@ static inline const struct dmi_device * dmi_find_device(int type, const char *na
56static inline void dmi_scan_machine(void) { return; } 57static inline void dmi_scan_machine(void) { return; }
57static inline int dmi_get_year(int year) { return 0; } 58static inline int dmi_get_year(int year) { return 0; }
58static inline int dmi_name_in_vendors(const char *s) { return 0; } 59static inline int dmi_name_in_vendors(const char *s) { return 0; }
60static inline int dmi_name_in_serial(const char *s) { return 0; }
59#define dmi_available 0 61#define dmi_available 0
60static inline int dmi_walk(void (*decode)(const struct dmi_header *)) 62static inline int dmi_walk(void (*decode)(const struct dmi_header *))
61 { return -1; } 63 { return -1; }
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 0dcdd9458f4b..4a853ef6fd35 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -63,23 +63,24 @@ extern int dir_notify_enable;
63#define MAY_ACCESS 16 63#define MAY_ACCESS 16
64#define MAY_OPEN 32 64#define MAY_OPEN 32
65 65
66#define FMODE_READ ((__force fmode_t)1) 66/* file is open for reading */
67#define FMODE_WRITE ((__force fmode_t)2) 67#define FMODE_READ ((__force fmode_t)1)
68 68/* file is open for writing */
69/* Internal kernel extensions */ 69#define FMODE_WRITE ((__force fmode_t)2)
70#define FMODE_LSEEK ((__force fmode_t)4) 70/* file is seekable */
71#define FMODE_PREAD ((__force fmode_t)8) 71#define FMODE_LSEEK ((__force fmode_t)4)
72#define FMODE_PWRITE FMODE_PREAD /* These go hand in hand */ 72/* file can be accessed using pread/pwrite */
73 73#define FMODE_PREAD ((__force fmode_t)8)
74/* File is being opened for execution. Primary users of this flag are 74#define FMODE_PWRITE FMODE_PREAD /* These go hand in hand */
75 distributed filesystems that can use it to achieve correct ETXTBUSY 75/* File is opened for execution with sys_execve / sys_uselib */
76 behavior for cross-node execution/opening_for_writing of files */ 76#define FMODE_EXEC ((__force fmode_t)16)
77#define FMODE_EXEC ((__force fmode_t)16) 77/* File is opened with O_NDELAY (only set for block devices) */
78 78#define FMODE_NDELAY ((__force fmode_t)32)
79#define FMODE_NDELAY ((__force fmode_t)32) 79/* File is opened with O_EXCL (only set for block devices) */
80#define FMODE_EXCL ((__force fmode_t)64) 80#define FMODE_EXCL ((__force fmode_t)64)
81/* File is opened using open(.., 3, ..) and is writeable only for ioctls
82 (specialy hack for floppy.c) */
81#define FMODE_WRITE_IOCTL ((__force fmode_t)128) 83#define FMODE_WRITE_IOCTL ((__force fmode_t)128)
82#define FMODE_NDELAY_NOW ((__force fmode_t)256)
83 84
84#define RW_MASK 1 85#define RW_MASK 1
85#define RWA_MASK 2 86#define RWA_MASK 2
diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h
index 703eb53cfa2b..9c5bc6be2b09 100644
--- a/include/linux/ftrace.h
+++ b/include/linux/ftrace.h
@@ -6,6 +6,7 @@
6#include <linux/ktime.h> 6#include <linux/ktime.h>
7#include <linux/init.h> 7#include <linux/init.h>
8#include <linux/types.h> 8#include <linux/types.h>
9#include <linux/module.h>
9#include <linux/kallsyms.h> 10#include <linux/kallsyms.h>
10 11
11#ifdef CONFIG_FUNCTION_TRACER 12#ifdef CONFIG_FUNCTION_TRACER
@@ -231,7 +232,7 @@ ftrace_init_module(unsigned long *start, unsigned long *end) { }
231 232
232struct boot_trace { 233struct boot_trace {
233 pid_t caller; 234 pid_t caller;
234 char func[KSYM_NAME_LEN]; 235 char func[KSYM_SYMBOL_LEN];
235 int result; 236 int result;
236 unsigned long long duration; /* usecs */ 237 unsigned long long duration; /* usecs */
237 ktime_t calltime; 238 ktime_t calltime;
diff --git a/include/linux/genhd.h b/include/linux/genhd.h
index e439e6aed832..3df7742ce246 100644
--- a/include/linux/genhd.h
+++ b/include/linux/genhd.h
@@ -522,7 +522,9 @@ extern char *disk_name (struct gendisk *hd, int partno, char *buf);
522 522
523extern int disk_expand_part_tbl(struct gendisk *disk, int target); 523extern int disk_expand_part_tbl(struct gendisk *disk, int target);
524extern int rescan_partitions(struct gendisk *disk, struct block_device *bdev); 524extern int rescan_partitions(struct gendisk *disk, struct block_device *bdev);
525extern int __must_check add_partition(struct gendisk *, int, sector_t, sector_t, int); 525extern struct hd_struct * __must_check add_partition(struct gendisk *disk,
526 int partno, sector_t start,
527 sector_t len, int flags);
526extern void delete_partition(struct gendisk *, int); 528extern void delete_partition(struct gendisk *, int);
527extern void printk_all_partitions(void); 529extern void printk_all_partitions(void);
528 530
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
66static inline void clear_user_highpage(struct page *page, unsigned long vaddr) 67static 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/hrtimer.h b/include/linux/hrtimer.h
index 07e510a3b00a..3eba43878dcb 100644
--- a/include/linux/hrtimer.h
+++ b/include/linux/hrtimer.h
@@ -46,9 +46,6 @@ enum hrtimer_restart {
46 * hrtimer callback modes: 46 * hrtimer callback modes:
47 * 47 *
48 * HRTIMER_CB_SOFTIRQ: Callback must run in softirq context 48 * HRTIMER_CB_SOFTIRQ: Callback must run in softirq context
49 * HRTIMER_CB_IRQSAFE: Callback may run in hardirq context
50 * HRTIMER_CB_IRQSAFE_NO_RESTART: Callback may run in hardirq context and
51 * does not restart the timer
52 * HRTIMER_CB_IRQSAFE_PERCPU: Callback must run in hardirq context 49 * HRTIMER_CB_IRQSAFE_PERCPU: Callback must run in hardirq context
53 * Special mode for tick emulation and 50 * Special mode for tick emulation and
54 * scheduler timer. Such timers are per 51 * scheduler timer. Such timers are per
@@ -61,8 +58,6 @@ enum hrtimer_restart {
61 */ 58 */
62enum hrtimer_cb_mode { 59enum hrtimer_cb_mode {
63 HRTIMER_CB_SOFTIRQ, 60 HRTIMER_CB_SOFTIRQ,
64 HRTIMER_CB_IRQSAFE,
65 HRTIMER_CB_IRQSAFE_NO_RESTART,
66 HRTIMER_CB_IRQSAFE_PERCPU, 61 HRTIMER_CB_IRQSAFE_PERCPU,
67 HRTIMER_CB_IRQSAFE_UNLOCKED, 62 HRTIMER_CB_IRQSAFE_UNLOCKED,
68}; 63};
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
1299static 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
1299void ide_pci_setup_ports(struct pci_dev *, const struct ide_port_info *, int, 1306void 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 **);
1301void ide_setup_pci_noise(struct pci_dev *, const struct ide_port_info *); 1308void 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
58struct idr { 59struct 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/inotify.h b/include/linux/inotify.h
index bd578578a8b9..37ea2894b3c0 100644
--- a/include/linux/inotify.h
+++ b/include/linux/inotify.h
@@ -134,6 +134,8 @@ extern void inotify_remove_watch_locked(struct inotify_handle *,
134 struct inotify_watch *); 134 struct inotify_watch *);
135extern void get_inotify_watch(struct inotify_watch *); 135extern void get_inotify_watch(struct inotify_watch *);
136extern void put_inotify_watch(struct inotify_watch *); 136extern void put_inotify_watch(struct inotify_watch *);
137extern int pin_inotify_watch(struct inotify_watch *);
138extern void unpin_inotify_watch(struct inotify_watch *);
137 139
138#else 140#else
139 141
@@ -228,6 +230,15 @@ static inline void put_inotify_watch(struct inotify_watch *watch)
228{ 230{
229} 231}
230 232
233extern inline int pin_inotify_watch(struct inotify_watch *watch)
234{
235 return 0;
236}
237
238extern inline void unpin_inotify_watch(struct inotify_watch *watch)
239{
240}
241
231#endif /* CONFIG_INOTIFY */ 242#endif /* CONFIG_INOTIFY */
232 243
233#endif /* __KERNEL __ */ 244#endif /* __KERNEL __ */
diff --git a/include/linux/input.h b/include/linux/input.h
index b86fb5581ce6..5341e8251f8c 100644
--- a/include/linux/input.h
+++ b/include/linux/input.h
@@ -238,6 +238,7 @@ struct input_absinfo {
238#define KEY_KPEQUAL 117 238#define KEY_KPEQUAL 117
239#define KEY_KPPLUSMINUS 118 239#define KEY_KPPLUSMINUS 118
240#define KEY_PAUSE 119 240#define KEY_PAUSE 119
241#define KEY_SCALE 120 /* AL Compiz Scale (Expose) */
241 242
242#define KEY_KPCOMMA 121 243#define KEY_KPCOMMA 121
243#define KEY_HANGEUL 122 244#define KEY_HANGEUL 122
@@ -322,6 +323,7 @@ struct input_absinfo {
322#define KEY_PAUSECD 201 323#define KEY_PAUSECD 201
323#define KEY_PROG3 202 324#define KEY_PROG3 202
324#define KEY_PROG4 203 325#define KEY_PROG4 203
326#define KEY_DASHBOARD 204 /* AL Dashboard */
325#define KEY_SUSPEND 205 327#define KEY_SUSPEND 205
326#define KEY_CLOSE 206 /* AC Close */ 328#define KEY_CLOSE 206 /* AC Close */
327#define KEY_PLAY 207 329#define KEY_PLAY 207
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 */
155struct irq_desc { 155struct 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
213void set_pending_irq(unsigned int irq, cpumask_t mask);
214void move_native_irq(int irq); 213void move_native_irq(int irq);
215void move_masked_irq(int irq); 214void 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
231static 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/kernel.h b/include/linux/kernel.h
index fba141d3ca07..dc7e0d0a6474 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -318,32 +318,36 @@ static inline char *pack_hex_byte(char *buf, u8 byte)
318 return buf; 318 return buf;
319} 319}
320 320
321#define pr_emerg(fmt, arg...) \ 321#ifndef pr_fmt
322 printk(KERN_EMERG fmt, ##arg) 322#define pr_fmt(fmt) fmt
323#define pr_alert(fmt, arg...) \ 323#endif
324 printk(KERN_ALERT fmt, ##arg) 324
325#define pr_crit(fmt, arg...) \ 325#define pr_emerg(fmt, ...) \
326 printk(KERN_CRIT fmt, ##arg) 326 printk(KERN_EMERG pr_fmt(fmt), ##__VA_ARGS__)
327#define pr_err(fmt, arg...) \ 327#define pr_alert(fmt, ...) \
328 printk(KERN_ERR fmt, ##arg) 328 printk(KERN_ALERT pr_fmt(fmt), ##__VA_ARGS__)
329#define pr_warning(fmt, arg...) \ 329#define pr_crit(fmt, ...) \
330 printk(KERN_WARNING fmt, ##arg) 330 printk(KERN_CRIT pr_fmt(fmt), ##__VA_ARGS__)
331#define pr_notice(fmt, arg...) \ 331#define pr_err(fmt, ...) \
332 printk(KERN_NOTICE fmt, ##arg) 332 printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
333#define pr_info(fmt, arg...) \ 333#define pr_warning(fmt, ...) \
334 printk(KERN_INFO fmt, ##arg) 334 printk(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
335#define pr_notice(fmt, ...) \
336 printk(KERN_NOTICE pr_fmt(fmt), ##__VA_ARGS__)
337#define pr_info(fmt, ...) \
338 printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__)
335 339
336/* If you are writing a driver, please use dev_dbg instead */ 340/* If you are writing a driver, please use dev_dbg instead */
337#if defined(CONFIG_DYNAMIC_PRINTK_DEBUG) 341#if defined(CONFIG_DYNAMIC_PRINTK_DEBUG)
338#define pr_debug(fmt, ...) do { \ 342#define pr_debug(fmt, ...) do { \
339 dynamic_pr_debug(fmt, ##__VA_ARGS__); \ 343 dynamic_pr_debug(pr_fmt(fmt), ##__VA_ARGS__); \
340 } while (0) 344 } while (0)
341#elif defined(DEBUG) 345#elif defined(DEBUG)
342#define pr_debug(fmt, arg...) \ 346#define pr_debug(fmt, ...) \
343 printk(KERN_DEBUG fmt, ##arg) 347 printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__)
344#else 348#else
345#define pr_debug(fmt, arg...) \ 349#define pr_debug(fmt, ...) \
346 ({ if (0) printk(KERN_DEBUG fmt, ##arg); 0; }) 350 ({ if (0) printk(KERN_DEBUG pr_fmt(fmt), ##__VA_ARGS__); 0; })
347#endif 351#endif
348 352
349/* 353/*
diff --git a/include/linux/kexec.h b/include/linux/kexec.h
index 17f76fc05173..adc34f2c6eff 100644
--- a/include/linux/kexec.h
+++ b/include/linux/kexec.h
@@ -100,6 +100,10 @@ struct kimage {
100#define KEXEC_TYPE_DEFAULT 0 100#define KEXEC_TYPE_DEFAULT 0
101#define KEXEC_TYPE_CRASH 1 101#define KEXEC_TYPE_CRASH 1
102 unsigned int preserve_context : 1; 102 unsigned int preserve_context : 1;
103
104#ifdef ARCH_HAS_KIMAGE_ARCH
105 struct kimage_arch arch;
106#endif
103}; 107};
104 108
105 109
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/lockdep.h b/include/linux/lockdep.h
index 331e5f1c2d8e..29aec6e10020 100644
--- a/include/linux/lockdep.h
+++ b/include/linux/lockdep.h
@@ -331,10 +331,11 @@ static inline void lockdep_on(void)
331# define lock_set_subclass(l, s, i) do { } while (0) 331# define lock_set_subclass(l, s, i) do { } while (0)
332# define lockdep_init() do { } while (0) 332# define lockdep_init() do { } while (0)
333# define lockdep_info() do { } while (0) 333# define lockdep_info() do { } while (0)
334# define lockdep_init_map(lock, name, key, sub) do { (void)(key); } while (0) 334# define lockdep_init_map(lock, name, key, sub) \
335 do { (void)(name); (void)(key); } while (0)
335# define lockdep_set_class(lock, key) do { (void)(key); } while (0) 336# define lockdep_set_class(lock, key) do { (void)(key); } while (0)
336# define lockdep_set_class_and_name(lock, key, name) \ 337# define lockdep_set_class_and_name(lock, key, name) \
337 do { (void)(key); } while (0) 338 do { (void)(key); (void)(name); } while (0)
338#define lockdep_set_class_and_subclass(lock, key, sub) \ 339#define lockdep_set_class_and_subclass(lock, key, sub) \
339 do { (void)(key); } while (0) 340 do { (void)(key); } while (0)
340#define lockdep_set_subclass(lock, sub) do { } while (0) 341#define lockdep_set_subclass(lock, sub) do { } while (0)
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/mfd/wm8350/rtc.h b/include/linux/mfd/wm8350/rtc.h
index dfda69e9f440..24add2bef6c9 100644
--- a/include/linux/mfd/wm8350/rtc.h
+++ b/include/linux/mfd/wm8350/rtc.h
@@ -261,6 +261,8 @@
261 261
262struct wm8350_rtc { 262struct wm8350_rtc {
263 struct platform_device *pdev; 263 struct platform_device *pdev;
264 struct rtc_device *rtc;
265 int alarm_enabled; /* used over suspend/resume */
264}; 266};
265 267
266#endif 268#endif
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/mm.h b/include/linux/mm.h
index ffee2f743418..d3ddd735e375 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -145,6 +145,23 @@ extern pgprot_t protection_map[16];
145#define FAULT_FLAG_WRITE 0x01 /* Fault was a write access */ 145#define FAULT_FLAG_WRITE 0x01 /* Fault was a write access */
146#define FAULT_FLAG_NONLINEAR 0x02 /* Fault was via a nonlinear mapping */ 146#define FAULT_FLAG_NONLINEAR 0x02 /* Fault was via a nonlinear mapping */
147 147
148/*
149 * This interface is used by x86 PAT code to identify a pfn mapping that is
150 * linear over entire vma. This is to optimize PAT code that deals with
151 * marking the physical region with a particular prot. This is not for generic
152 * mm use. Note also that this check will not work if the pfn mapping is
153 * linear for a vma starting at physical address 0. In which case PAT code
154 * falls back to slow path of reserving physical range page by page.
155 */
156static inline int is_linear_pfn_mapping(struct vm_area_struct *vma)
157{
158 return ((vma->vm_flags & VM_PFNMAP) && vma->vm_pgoff);
159}
160
161static inline int is_pfn_mapping(struct vm_area_struct *vma)
162{
163 return (vma->vm_flags & VM_PFNMAP);
164}
148 165
149/* 166/*
150 * vm_fault is filled by the the pagefault handler and passed to the vma's 167 * vm_fault is filled by the the pagefault handler and passed to the vma's
@@ -781,6 +798,8 @@ int copy_page_range(struct mm_struct *dst, struct mm_struct *src,
781 struct vm_area_struct *vma); 798 struct vm_area_struct *vma);
782void unmap_mapping_range(struct address_space *mapping, 799void unmap_mapping_range(struct address_space *mapping,
783 loff_t const holebegin, loff_t const holelen, int even_cows); 800 loff_t const holebegin, loff_t const holelen, int even_cows);
801int follow_phys(struct vm_area_struct *vma, unsigned long address,
802 unsigned int flags, unsigned long *prot, resource_size_t *phys);
784int generic_access_phys(struct vm_area_struct *vma, unsigned long addr, 803int generic_access_phys(struct vm_area_struct *vma, unsigned long addr,
785 void *buf, int len, int write); 804 void *buf, int len, int write);
786 805
diff --git a/include/linux/net.h b/include/linux/net.h
index 6dc14a240042..4515efae4c39 100644
--- a/include/linux/net.h
+++ b/include/linux/net.h
@@ -40,7 +40,7 @@
40#define SYS_GETSOCKOPT 15 /* sys_getsockopt(2) */ 40#define SYS_GETSOCKOPT 15 /* sys_getsockopt(2) */
41#define SYS_SENDMSG 16 /* sys_sendmsg(2) */ 41#define SYS_SENDMSG 16 /* sys_sendmsg(2) */
42#define SYS_RECVMSG 17 /* sys_recvmsg(2) */ 42#define SYS_RECVMSG 17 /* sys_recvmsg(2) */
43#define SYS_PACCEPT 18 /* sys_paccept(2) */ 43#define SYS_ACCEPT4 18 /* sys_accept4(2) */
44 44
45typedef enum { 45typedef enum {
46 SS_FREE = 0, /* not allocated */ 46 SS_FREE = 0, /* not allocated */
@@ -100,7 +100,7 @@ enum sock_type {
100 * remaining bits are used as flags. */ 100 * remaining bits are used as flags. */
101#define SOCK_TYPE_MASK 0xf 101#define SOCK_TYPE_MASK 0xf
102 102
103/* Flags for socket, socketpair, paccept */ 103/* Flags for socket, socketpair, accept4 */
104#define SOCK_CLOEXEC O_CLOEXEC 104#define SOCK_CLOEXEC O_CLOEXEC
105#ifndef SOCK_NONBLOCK 105#ifndef SOCK_NONBLOCK
106#define SOCK_NONBLOCK O_NONBLOCK 106#define SOCK_NONBLOCK O_NONBLOCK
@@ -223,8 +223,6 @@ extern int sock_map_fd(struct socket *sock, int flags);
223extern struct socket *sockfd_lookup(int fd, int *err); 223extern struct socket *sockfd_lookup(int fd, int *err);
224#define sockfd_put(sock) fput(sock->file) 224#define sockfd_put(sock) fput(sock->file)
225extern int net_ratelimit(void); 225extern int net_ratelimit(void);
226extern long do_accept(int fd, struct sockaddr __user *upeer_sockaddr,
227 int __user *upeer_addrlen, int flags);
228 226
229#define net_random() random32() 227#define net_random() random32()
230#define net_srandom(seed) srandom32((__force u32)seed) 228#define net_srandom(seed) srandom32((__force u32)seed)
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 9d77b1d7dca8..e26f54952892 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -319,6 +319,7 @@ enum
319{ 319{
320 NAPI_STATE_SCHED, /* Poll is scheduled */ 320 NAPI_STATE_SCHED, /* Poll is scheduled */
321 NAPI_STATE_DISABLE, /* Disable pending */ 321 NAPI_STATE_DISABLE, /* Disable pending */
322 NAPI_STATE_NPSVC, /* Netpoll - don't dequeue from poll_list */
322}; 323};
323 324
324extern void __napi_schedule(struct napi_struct *n); 325extern void __napi_schedule(struct napi_struct *n);
@@ -1497,6 +1498,12 @@ static inline void netif_rx_complete(struct net_device *dev,
1497{ 1498{
1498 unsigned long flags; 1499 unsigned long flags;
1499 1500
1501 /*
1502 * don't let napi dequeue from the cpu poll list
1503 * just in case its running on a different cpu
1504 */
1505 if (unlikely(test_bit(NAPI_STATE_NPSVC, &napi->state)))
1506 return;
1500 local_irq_save(flags); 1507 local_irq_save(flags);
1501 __netif_rx_complete(dev, napi); 1508 __netif_rx_complete(dev, napi);
1502 local_irq_restore(flags); 1509 local_irq_restore(flags);
diff --git a/include/linux/netfilter/nfnetlink_conntrack.h b/include/linux/netfilter/nfnetlink_conntrack.h
index c19595c89304..29fe9ea1d346 100644
--- a/include/linux/netfilter/nfnetlink_conntrack.h
+++ b/include/linux/netfilter/nfnetlink_conntrack.h
@@ -141,6 +141,7 @@ enum ctattr_protonat {
141#define CTA_PROTONAT_MAX (__CTA_PROTONAT_MAX - 1) 141#define CTA_PROTONAT_MAX (__CTA_PROTONAT_MAX - 1)
142 142
143enum ctattr_natseq { 143enum ctattr_natseq {
144 CTA_NAT_SEQ_UNSPEC,
144 CTA_NAT_SEQ_CORRECTION_POS, 145 CTA_NAT_SEQ_CORRECTION_POS,
145 CTA_NAT_SEQ_OFFSET_BEFORE, 146 CTA_NAT_SEQ_OFFSET_BEFORE,
146 CTA_NAT_SEQ_OFFSET_AFTER, 147 CTA_NAT_SEQ_OFFSET_AFTER,
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 */
252struct xt_tgchk_param { 252struct 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
20void __init pgdat_page_cgroup_init(struct pglist_data *pgdat); 20void __meminit pgdat_page_cgroup_init(struct pglist_data *pgdat);
21void __init page_cgroup_init(void); 21void __init page_cgroup_init(void);
22struct page_cgroup *lookup_page_cgroup(struct page *page); 22struct 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 */
92struct page_cgroup; 92struct page_cgroup;
93 93
94static inline void pgdat_page_cgroup_init(struct pglist_data *pgdat) 94static inline void __meminit pgdat_page_cgroup_init(struct pglist_data *pgdat)
95{ 95{
96} 96}
97 97
diff --git a/include/linux/pci.h b/include/linux/pci.h
index feb4657bb043..03b0b8c3c81b 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -134,6 +134,11 @@ enum pci_dev_flags {
134 PCI_DEV_FLAGS_NO_D3 = (__force pci_dev_flags_t) 2, 134 PCI_DEV_FLAGS_NO_D3 = (__force pci_dev_flags_t) 2,
135}; 135};
136 136
137enum pci_irq_reroute_variant {
138 INTEL_IRQ_REROUTE_VARIANT = 1,
139 MAX_IRQ_REROUTE_VARIANTS = 3
140};
141
137typedef unsigned short __bitwise pci_bus_flags_t; 142typedef unsigned short __bitwise pci_bus_flags_t;
138enum pci_bus_flags { 143enum pci_bus_flags {
139 PCI_BUS_FLAGS_NO_MSI = (__force pci_bus_flags_t) 1, 144 PCI_BUS_FLAGS_NO_MSI = (__force pci_bus_flags_t) 1,
@@ -218,6 +223,7 @@ struct pci_dev {
218 unsigned int no_msi:1; /* device may not use msi */ 223 unsigned int no_msi:1; /* device may not use msi */
219 unsigned int block_ucfg_access:1; /* userspace config space access is blocked */ 224 unsigned int block_ucfg_access:1; /* userspace config space access is blocked */
220 unsigned int broken_parity_status:1; /* Device generates false positive parity */ 225 unsigned int broken_parity_status:1; /* Device generates false positive parity */
226 unsigned int irq_reroute_variant:2; /* device needs IRQ rerouting variant */
221 unsigned int msi_enabled:1; 227 unsigned int msi_enabled:1;
222 unsigned int msix_enabled:1; 228 unsigned int msix_enabled:1;
223 unsigned int ari_enabled:1; /* ARI forwarding */ 229 unsigned int ari_enabled:1; /* ARI forwarding */
diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h
index 1800f1d6e40d..b6e694454280 100644
--- a/include/linux/pci_ids.h
+++ b/include/linux/pci_ids.h
@@ -2304,6 +2304,10 @@
2304#define PCI_DEVICE_ID_INTEL_PXH_0 0x0329 2304#define PCI_DEVICE_ID_INTEL_PXH_0 0x0329
2305#define PCI_DEVICE_ID_INTEL_PXH_1 0x032A 2305#define PCI_DEVICE_ID_INTEL_PXH_1 0x032A
2306#define PCI_DEVICE_ID_INTEL_PXHV 0x032C 2306#define PCI_DEVICE_ID_INTEL_PXHV 0x032C
2307#define PCI_DEVICE_ID_INTEL_80332_0 0x0330
2308#define PCI_DEVICE_ID_INTEL_80332_1 0x0332
2309#define PCI_DEVICE_ID_INTEL_80333_0 0x0370
2310#define PCI_DEVICE_ID_INTEL_80333_1 0x0372
2307#define PCI_DEVICE_ID_INTEL_82375 0x0482 2311#define PCI_DEVICE_ID_INTEL_82375 0x0482
2308#define PCI_DEVICE_ID_INTEL_82424 0x0483 2312#define PCI_DEVICE_ID_INTEL_82424 0x0483
2309#define PCI_DEVICE_ID_INTEL_82378 0x0484 2313#define PCI_DEVICE_ID_INTEL_82378 0x0484
@@ -2376,6 +2380,7 @@
2376#define PCI_DEVICE_ID_INTEL_ESB_4 0x25a4 2380#define PCI_DEVICE_ID_INTEL_ESB_4 0x25a4
2377#define PCI_DEVICE_ID_INTEL_ESB_5 0x25a6 2381#define PCI_DEVICE_ID_INTEL_ESB_5 0x25a6
2378#define PCI_DEVICE_ID_INTEL_ESB_9 0x25ab 2382#define PCI_DEVICE_ID_INTEL_ESB_9 0x25ab
2383#define PCI_DEVICE_ID_INTEL_ESB_10 0x25ac
2379#define PCI_DEVICE_ID_INTEL_82820_HB 0x2500 2384#define PCI_DEVICE_ID_INTEL_82820_HB 0x2500
2380#define PCI_DEVICE_ID_INTEL_82820_UP_HB 0x2501 2385#define PCI_DEVICE_ID_INTEL_82820_UP_HB 0x2501
2381#define PCI_DEVICE_ID_INTEL_82850_HB 0x2530 2386#define PCI_DEVICE_ID_INTEL_82850_HB 0x2530
diff --git a/include/linux/ratelimit.h b/include/linux/ratelimit.h
index 18a5b9ba9d40..00044b856453 100644
--- a/include/linux/ratelimit.h
+++ b/include/linux/ratelimit.h
@@ -17,11 +17,4 @@ struct ratelimit_state {
17 struct ratelimit_state name = {interval, burst,} 17 struct ratelimit_state name = {interval, burst,}
18 18
19extern int __ratelimit(struct ratelimit_state *rs); 19extern int __ratelimit(struct ratelimit_state *rs);
20
21static inline int ratelimit(void)
22{
23 static DEFINE_RATELIMIT_STATE(rs, DEFAULT_RATELIMIT_INTERVAL,
24 DEFAULT_RATELIMIT_BURST);
25 return __ratelimit(&rs);
26}
27#endif 20#endif
diff --git a/include/linux/ring_buffer.h b/include/linux/ring_buffer.h
index 536b0ca46a03..e097c2e6b6dc 100644
--- a/include/linux/ring_buffer.h
+++ b/include/linux/ring_buffer.h
@@ -120,6 +120,9 @@ unsigned long ring_buffer_overruns(struct ring_buffer *buffer);
120u64 ring_buffer_time_stamp(int cpu); 120u64 ring_buffer_time_stamp(int cpu);
121void ring_buffer_normalize_time_stamp(int cpu, u64 *ts); 121void ring_buffer_normalize_time_stamp(int cpu, u64 *ts);
122 122
123void tracing_on(void);
124void tracing_off(void);
125
123enum ring_buffer_flags { 126enum ring_buffer_flags {
124 RB_FL_OVERWRITE = 1 << 0, 127 RB_FL_OVERWRITE = 1 << 0,
125}; 128};
diff --git a/include/linux/sched.h b/include/linux/sched.h
index 295b7c756ca6..55e30d114477 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -247,6 +247,7 @@ extern void init_idle(struct task_struct *idle, int cpu);
247extern void init_idle_bootup_task(struct task_struct *idle); 247extern void init_idle_bootup_task(struct task_struct *idle);
248 248
249extern int runqueue_is_locked(void); 249extern int runqueue_is_locked(void);
250extern void task_rq_unlock_wait(struct task_struct *p);
250 251
251extern cpumask_t nohz_cpu_mask; 252extern cpumask_t nohz_cpu_mask;
252#if defined(CONFIG_SMP) && defined(CONFIG_NO_HZ) 253#if defined(CONFIG_SMP) && defined(CONFIG_NO_HZ)
@@ -629,6 +630,10 @@ struct user_struct {
629 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? */
630 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? */
631#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
632#ifdef CONFIG_POSIX_MQUEUE 637#ifdef CONFIG_POSIX_MQUEUE
633 /* protected by mq_lock */ 638 /* protected by mq_lock */
634 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
1819static inline int security_vm_enough_memory(long pages) 1819static 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
1824static inline int security_vm_enough_memory_kern(long pages) 1825static 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
1829static inline int security_vm_enough_memory_mm(struct mm_struct *mm, long pages) 1831static 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
1834static inline int security_bprm_alloc(struct linux_binprm *bprm) 1838static inline int security_bprm_alloc(struct linux_binprm *bprm)
diff --git a/include/linux/serial_core.h b/include/linux/serial_core.h
index e27f216361fc..4e4f1277f3bf 100644
--- a/include/linux/serial_core.h
+++ b/include/linux/serial_core.h
@@ -155,6 +155,9 @@
155 155
156#define PORT_SC26XX 82 156#define PORT_SC26XX 82
157 157
158/* SH-SCI */
159#define PORT_SCIFA 83
160
158#ifdef __KERNEL__ 161#ifdef __KERNEL__
159 162
160#include <linux/compiler.h> 163#include <linux/compiler.h>
diff --git a/include/linux/slab.h b/include/linux/slab.h
index ba965c84ae06..000da12b5cf0 100644
--- a/include/linux/slab.h
+++ b/include/linux/slab.h
@@ -23,6 +23,34 @@
23#define SLAB_CACHE_DMA 0x00004000UL /* Use GFP_DMA memory */ 23#define SLAB_CACHE_DMA 0x00004000UL /* Use GFP_DMA memory */
24#define SLAB_STORE_USER 0x00010000UL /* DEBUG: Store the last owner for bug hunting */ 24#define SLAB_STORE_USER 0x00010000UL /* DEBUG: Store the last owner for bug hunting */
25#define SLAB_PANIC 0x00040000UL /* Panic if kmem_cache_create() fails */ 25#define SLAB_PANIC 0x00040000UL /* Panic if kmem_cache_create() fails */
26/*
27 * SLAB_DESTROY_BY_RCU - **WARNING** READ THIS!
28 *
29 * This delays freeing the SLAB page by a grace period, it does _NOT_
30 * delay object freeing. This means that if you do kmem_cache_free()
31 * that memory location is free to be reused at any time. Thus it may
32 * be possible to see another object there in the same RCU grace period.
33 *
34 * This feature only ensures the memory location backing the object
35 * stays valid, the trick to using this is relying on an independent
36 * object validation pass. Something like:
37 *
38 * rcu_read_lock()
39 * again:
40 * obj = lockless_lookup(key);
41 * if (obj) {
42 * if (!try_get_ref(obj)) // might fail for free objects
43 * goto again;
44 *
45 * if (obj->key != key) { // not the object we expected
46 * put_ref(obj);
47 * goto again;
48 * }
49 * }
50 * rcu_read_unlock();
51 *
52 * See also the comment on struct slab_rcu in mm/slab.c.
53 */
26#define SLAB_DESTROY_BY_RCU 0x00080000UL /* Defer freeing slabs to RCU */ 54#define SLAB_DESTROY_BY_RCU 0x00080000UL /* Defer freeing slabs to RCU */
27#define SLAB_MEM_SPREAD 0x00100000UL /* Spread some memory over cpuset */ 55#define SLAB_MEM_SPREAD 0x00100000UL /* Spread some memory over cpuset */
28#define SLAB_TRACE 0x00200000UL /* Trace allocations and frees */ 56#define SLAB_TRACE 0x00200000UL /* Trace allocations and frees */
diff --git a/include/linux/smp.h b/include/linux/smp.h
index 3f9a60043a97..6e7ba16ff454 100644
--- a/include/linux/smp.h
+++ b/include/linux/smp.h
@@ -146,6 +146,8 @@ static inline void smp_send_reschedule(int cpu) { }
146}) 146})
147#define smp_call_function_mask(mask, func, info, wait) \ 147#define smp_call_function_mask(mask, func, info, wait) \
148 (up_smp_call_function(func, info)) 148 (up_smp_call_function(func, info))
149#define smp_call_function_many(mask, func, info, wait) \
150 (up_smp_call_function(func, info))
149static inline void init_call_single_data(void) 151static inline void init_call_single_data(void)
150{ 152{
151} 153}
diff --git a/include/linux/ssb/ssb.h b/include/linux/ssb/ssb.h
index e530026eedf7..17d9b58f6379 100644
--- a/include/linux/ssb/ssb.h
+++ b/include/linux/ssb/ssb.h
@@ -427,12 +427,16 @@ static inline int ssb_dma_mapping_error(struct ssb_device *dev, dma_addr_t addr)
427{ 427{
428 switch (dev->bus->bustype) { 428 switch (dev->bus->bustype) {
429 case SSB_BUSTYPE_PCI: 429 case SSB_BUSTYPE_PCI:
430#ifdef CONFIG_SSB_PCIHOST
430 return pci_dma_mapping_error(dev->bus->host_pci, addr); 431 return pci_dma_mapping_error(dev->bus->host_pci, addr);
432#endif
433 break;
431 case SSB_BUSTYPE_SSB: 434 case SSB_BUSTYPE_SSB:
432 return dma_mapping_error(dev->dev, addr); 435 return dma_mapping_error(dev->dev, addr);
433 default: 436 default:
434 __ssb_dma_not_implemented(dev); 437 break;
435 } 438 }
439 __ssb_dma_not_implemented(dev);
436 return -ENOSYS; 440 return -ENOSYS;
437} 441}
438 442
@@ -441,12 +445,16 @@ static inline dma_addr_t ssb_dma_map_single(struct ssb_device *dev, void *p,
441{ 445{
442 switch (dev->bus->bustype) { 446 switch (dev->bus->bustype) {
443 case SSB_BUSTYPE_PCI: 447 case SSB_BUSTYPE_PCI:
448#ifdef CONFIG_SSB_PCIHOST
444 return pci_map_single(dev->bus->host_pci, p, size, dir); 449 return pci_map_single(dev->bus->host_pci, p, size, dir);
450#endif
451 break;
445 case SSB_BUSTYPE_SSB: 452 case SSB_BUSTYPE_SSB:
446 return dma_map_single(dev->dev, p, size, dir); 453 return dma_map_single(dev->dev, p, size, dir);
447 default: 454 default:
448 __ssb_dma_not_implemented(dev); 455 break;
449 } 456 }
457 __ssb_dma_not_implemented(dev);
450 return 0; 458 return 0;
451} 459}
452 460
@@ -455,14 +463,18 @@ static inline void ssb_dma_unmap_single(struct ssb_device *dev, dma_addr_t dma_a
455{ 463{
456 switch (dev->bus->bustype) { 464 switch (dev->bus->bustype) {
457 case SSB_BUSTYPE_PCI: 465 case SSB_BUSTYPE_PCI:
466#ifdef CONFIG_SSB_PCIHOST
458 pci_unmap_single(dev->bus->host_pci, dma_addr, size, dir); 467 pci_unmap_single(dev->bus->host_pci, dma_addr, size, dir);
459 return; 468 return;
469#endif
470 break;
460 case SSB_BUSTYPE_SSB: 471 case SSB_BUSTYPE_SSB:
461 dma_unmap_single(dev->dev, dma_addr, size, dir); 472 dma_unmap_single(dev->dev, dma_addr, size, dir);
462 return; 473 return;
463 default: 474 default:
464 __ssb_dma_not_implemented(dev); 475 break;
465 } 476 }
477 __ssb_dma_not_implemented(dev);
466} 478}
467 479
468static inline void ssb_dma_sync_single_for_cpu(struct ssb_device *dev, 480static inline void ssb_dma_sync_single_for_cpu(struct ssb_device *dev,
@@ -472,15 +484,19 @@ static inline void ssb_dma_sync_single_for_cpu(struct ssb_device *dev,
472{ 484{
473 switch (dev->bus->bustype) { 485 switch (dev->bus->bustype) {
474 case SSB_BUSTYPE_PCI: 486 case SSB_BUSTYPE_PCI:
487#ifdef CONFIG_SSB_PCIHOST
475 pci_dma_sync_single_for_cpu(dev->bus->host_pci, dma_addr, 488 pci_dma_sync_single_for_cpu(dev->bus->host_pci, dma_addr,
476 size, dir); 489 size, dir);
477 return; 490 return;
491#endif
492 break;
478 case SSB_BUSTYPE_SSB: 493 case SSB_BUSTYPE_SSB:
479 dma_sync_single_for_cpu(dev->dev, dma_addr, size, dir); 494 dma_sync_single_for_cpu(dev->dev, dma_addr, size, dir);
480 return; 495 return;
481 default: 496 default:
482 __ssb_dma_not_implemented(dev); 497 break;
483 } 498 }
499 __ssb_dma_not_implemented(dev);
484} 500}
485 501
486static inline void ssb_dma_sync_single_for_device(struct ssb_device *dev, 502static inline void ssb_dma_sync_single_for_device(struct ssb_device *dev,
@@ -490,15 +506,19 @@ static inline void ssb_dma_sync_single_for_device(struct ssb_device *dev,
490{ 506{
491 switch (dev->bus->bustype) { 507 switch (dev->bus->bustype) {
492 case SSB_BUSTYPE_PCI: 508 case SSB_BUSTYPE_PCI:
509#ifdef CONFIG_SSB_PCIHOST
493 pci_dma_sync_single_for_device(dev->bus->host_pci, dma_addr, 510 pci_dma_sync_single_for_device(dev->bus->host_pci, dma_addr,
494 size, dir); 511 size, dir);
495 return; 512 return;
513#endif
514 break;
496 case SSB_BUSTYPE_SSB: 515 case SSB_BUSTYPE_SSB:
497 dma_sync_single_for_device(dev->dev, dma_addr, size, dir); 516 dma_sync_single_for_device(dev->dev, dma_addr, size, dir);
498 return; 517 return;
499 default: 518 default:
500 __ssb_dma_not_implemented(dev); 519 break;
501 } 520 }
521 __ssb_dma_not_implemented(dev);
502} 522}
503 523
504static inline void ssb_dma_sync_single_range_for_cpu(struct ssb_device *dev, 524static inline void ssb_dma_sync_single_range_for_cpu(struct ssb_device *dev,
@@ -509,17 +529,21 @@ static inline void ssb_dma_sync_single_range_for_cpu(struct ssb_device *dev,
509{ 529{
510 switch (dev->bus->bustype) { 530 switch (dev->bus->bustype) {
511 case SSB_BUSTYPE_PCI: 531 case SSB_BUSTYPE_PCI:
532#ifdef CONFIG_SSB_PCIHOST
512 /* Just sync everything. That's all the PCI API can do. */ 533 /* Just sync everything. That's all the PCI API can do. */
513 pci_dma_sync_single_for_cpu(dev->bus->host_pci, dma_addr, 534 pci_dma_sync_single_for_cpu(dev->bus->host_pci, dma_addr,
514 offset + size, dir); 535 offset + size, dir);
515 return; 536 return;
537#endif
538 break;
516 case SSB_BUSTYPE_SSB: 539 case SSB_BUSTYPE_SSB:
517 dma_sync_single_range_for_cpu(dev->dev, dma_addr, offset, 540 dma_sync_single_range_for_cpu(dev->dev, dma_addr, offset,
518 size, dir); 541 size, dir);
519 return; 542 return;
520 default: 543 default:
521 __ssb_dma_not_implemented(dev); 544 break;
522 } 545 }
546 __ssb_dma_not_implemented(dev);
523} 547}
524 548
525static inline void ssb_dma_sync_single_range_for_device(struct ssb_device *dev, 549static inline void ssb_dma_sync_single_range_for_device(struct ssb_device *dev,
@@ -530,17 +554,21 @@ static inline void ssb_dma_sync_single_range_for_device(struct ssb_device *dev,
530{ 554{
531 switch (dev->bus->bustype) { 555 switch (dev->bus->bustype) {
532 case SSB_BUSTYPE_PCI: 556 case SSB_BUSTYPE_PCI:
557#ifdef CONFIG_SSB_PCIHOST
533 /* Just sync everything. That's all the PCI API can do. */ 558 /* Just sync everything. That's all the PCI API can do. */
534 pci_dma_sync_single_for_device(dev->bus->host_pci, dma_addr, 559 pci_dma_sync_single_for_device(dev->bus->host_pci, dma_addr,
535 offset + size, dir); 560 offset + size, dir);
536 return; 561 return;
562#endif
563 break;
537 case SSB_BUSTYPE_SSB: 564 case SSB_BUSTYPE_SSB:
538 dma_sync_single_range_for_device(dev->dev, dma_addr, offset, 565 dma_sync_single_range_for_device(dev->dev, dma_addr, offset,
539 size, dir); 566 size, dir);
540 return; 567 return;
541 default: 568 default:
542 __ssb_dma_not_implemented(dev); 569 break;
543 } 570 }
571 __ssb_dma_not_implemented(dev);
544} 572}
545 573
546 574
diff --git a/include/linux/syscalls.h b/include/linux/syscalls.h
index d6ff145919ca..04fb47bfb920 100644
--- a/include/linux/syscalls.h
+++ b/include/linux/syscalls.h
@@ -410,8 +410,7 @@ asmlinkage long sys_getsockopt(int fd, int level, int optname,
410asmlinkage long sys_bind(int, struct sockaddr __user *, int); 410asmlinkage long sys_bind(int, struct sockaddr __user *, int);
411asmlinkage long sys_connect(int, struct sockaddr __user *, int); 411asmlinkage long sys_connect(int, struct sockaddr __user *, int);
412asmlinkage long sys_accept(int, struct sockaddr __user *, int __user *); 412asmlinkage long sys_accept(int, struct sockaddr __user *, int __user *);
413asmlinkage long sys_paccept(int, struct sockaddr __user *, int __user *, 413asmlinkage long sys_accept4(int, struct sockaddr __user *, int __user *, int);
414 const __user sigset_t *, size_t, int);
415asmlinkage long sys_getsockname(int, struct sockaddr __user *, int __user *); 414asmlinkage long sys_getsockname(int, struct sockaddr __user *, int __user *);
416asmlinkage long sys_getpeername(int, struct sockaddr __user *, int __user *); 415asmlinkage long sys_getpeername(int, struct sockaddr __user *, int __user *);
417asmlinkage long sys_send(int, void __user *, size_t, unsigned); 416asmlinkage long sys_send(int, void __user *, size_t, unsigned);
diff --git a/include/linux/telephony.h b/include/linux/telephony.h
index 5b2b6261f193..f63afe330add 100644
--- a/include/linux/telephony.h
+++ b/include/linux/telephony.h
@@ -14,7 +14,7 @@
14 * Authors: Ed Okerson, <eokerson@quicknet.net> 14 * Authors: Ed Okerson, <eokerson@quicknet.net>
15 * Greg Herlein, <gherlein@quicknet.net> 15 * Greg Herlein, <gherlein@quicknet.net>
16 * 16 *
17 * Contributors: Alan Cox, <alan@redhat.com> 17 * Contributors: Alan Cox, <alan@lxorguk.ukuu.org.uk>
18 * David W. Erhart, <derhart@quicknet.net> 18 * David W. Erhart, <derhart@quicknet.net>
19 * 19 *
20 * IN NO EVENT SHALL QUICKNET TECHNOLOGIES, INC. BE LIABLE TO ANY PARTY FOR 20 * IN NO EVENT SHALL QUICKNET TECHNOLOGIES, INC. BE LIABLE TO ANY PARTY FOR
diff --git a/include/linux/usb.h b/include/linux/usb.h
index 8fa973bede5e..f72aa51f7bcd 100644
--- a/include/linux/usb.h
+++ b/include/linux/usb.h
@@ -108,6 +108,7 @@ enum usb_interface_condition {
108 * (in probe()), bound to a driver, or unbinding (in disconnect()) 108 * (in probe()), bound to a driver, or unbinding (in disconnect())
109 * @is_active: flag set when the interface is bound and not suspended. 109 * @is_active: flag set when the interface is bound and not suspended.
110 * @sysfs_files_created: sysfs attributes exist 110 * @sysfs_files_created: sysfs attributes exist
111 * @unregistering: flag set when the interface is being unregistered
111 * @needs_remote_wakeup: flag set when the driver requires remote-wakeup 112 * @needs_remote_wakeup: flag set when the driver requires remote-wakeup
112 * capability during autosuspend. 113 * capability during autosuspend.
113 * @needs_altsetting0: flag set when a set-interface request for altsetting 0 114 * @needs_altsetting0: flag set when a set-interface request for altsetting 0
@@ -163,6 +164,7 @@ struct usb_interface {
163 enum usb_interface_condition condition; /* state of binding */ 164 enum usb_interface_condition condition; /* state of binding */
164 unsigned is_active:1; /* the interface is not suspended */ 165 unsigned is_active:1; /* the interface is not suspended */
165 unsigned sysfs_files_created:1; /* the sysfs attributes exist */ 166 unsigned sysfs_files_created:1; /* the sysfs attributes exist */
167 unsigned unregistering:1; /* unregistration is in progress */
166 unsigned needs_remote_wakeup:1; /* driver requires remote wakeup */ 168 unsigned needs_remote_wakeup:1; /* driver requires remote wakeup */
167 unsigned needs_altsetting0:1; /* switch to altsetting 0 is pending */ 169 unsigned needs_altsetting0:1; /* switch to altsetting 0 is pending */
168 unsigned needs_binding:1; /* needs delayed unbind/rebind */ 170 unsigned needs_binding:1; /* needs delayed unbind/rebind */
diff --git a/include/linux/usb/ch9.h b/include/linux/usb/ch9.h
index 73a2f4eb1f7a..9b42baed3900 100644
--- a/include/linux/usb/ch9.h
+++ b/include/linux/usb/ch9.h
@@ -158,8 +158,12 @@ struct usb_ctrlrequest {
158 * (rarely) accepted by SET_DESCRIPTOR. 158 * (rarely) accepted by SET_DESCRIPTOR.
159 * 159 *
160 * Note that all multi-byte values here are encoded in little endian 160 * Note that all multi-byte values here are encoded in little endian
161 * byte order "on the wire". But when exposed through Linux-USB APIs, 161 * byte order "on the wire". Within the kernel and when exposed
162 * they've been converted to cpu byte order. 162 * through the Linux-USB APIs, they are not converted to cpu byte
163 * order; it is the responsibility of the client code to do this.
164 * The single exception is when device and configuration descriptors (but
165 * not other descriptors) are read from usbfs (i.e. /proc/bus/usb/BBB/DDD);
166 * in this case the fields are converted to host endianness by the kernel.
163 */ 167 */
164 168
165/* 169/*