diff options
author | Stephen Rothwell <sfr@canb.auug.org.au> | 2005-11-02 02:15:43 -0500 |
---|---|---|
committer | Stephen Rothwell <sfr@canb.auug.org.au> | 2005-11-02 02:15:43 -0500 |
commit | 2be7a906752abf8dce9350c23b6d1036049a5d3e (patch) | |
tree | ef178fa5801bdce24938819086662bb747d8c0c2 /drivers | |
parent | aaf8a7a2949481482200686c7bd3852e5be2e093 (diff) | |
parent | fbf1769d08a8b085834dceb228540153ac2cd534 (diff) |
Merge Paulus' tree
Diffstat (limited to 'drivers')
124 files changed, 218 insertions, 138 deletions
diff --git a/drivers/base/platform.c b/drivers/base/platform.c index 08d9cc99c7de..d597c922af11 100644 --- a/drivers/base/platform.c +++ b/drivers/base/platform.c | |||
@@ -10,7 +10,7 @@ | |||
10 | * information. | 10 | * information. |
11 | */ | 11 | */ |
12 | 12 | ||
13 | #include <linux/device.h> | 13 | #include <linux/platform_device.h> |
14 | #include <linux/module.h> | 14 | #include <linux/module.h> |
15 | #include <linux/init.h> | 15 | #include <linux/init.h> |
16 | #include <linux/dma-mapping.h> | 16 | #include <linux/dma-mapping.h> |
diff --git a/drivers/block/cfq-iosched.c b/drivers/block/cfq-iosched.c index 5281f8e70510..ecacca9c877e 100644 --- a/drivers/block/cfq-iosched.c +++ b/drivers/block/cfq-iosched.c | |||
@@ -2059,10 +2059,8 @@ static void cfq_put_cfqd(struct cfq_data *cfqd) | |||
2059 | if (!atomic_dec_and_test(&cfqd->ref)) | 2059 | if (!atomic_dec_and_test(&cfqd->ref)) |
2060 | return; | 2060 | return; |
2061 | 2061 | ||
2062 | blk_put_queue(q); | ||
2063 | |||
2064 | cfq_shutdown_timer_wq(cfqd); | 2062 | cfq_shutdown_timer_wq(cfqd); |
2065 | q->elevator->elevator_data = NULL; | 2063 | blk_put_queue(q); |
2066 | 2064 | ||
2067 | mempool_destroy(cfqd->crq_pool); | 2065 | mempool_destroy(cfqd->crq_pool); |
2068 | kfree(cfqd->crq_hash); | 2066 | kfree(cfqd->crq_hash); |
diff --git a/drivers/block/floppy.c b/drivers/block/floppy.c index 00895477155e..5eadbb9d4d71 100644 --- a/drivers/block/floppy.c +++ b/drivers/block/floppy.c | |||
@@ -177,7 +177,7 @@ static int print_unex = 1; | |||
177 | #include <linux/interrupt.h> | 177 | #include <linux/interrupt.h> |
178 | #include <linux/init.h> | 178 | #include <linux/init.h> |
179 | #include <linux/devfs_fs_kernel.h> | 179 | #include <linux/devfs_fs_kernel.h> |
180 | #include <linux/device.h> | 180 | #include <linux/platform_device.h> |
181 | #include <linux/buffer_head.h> /* for invalidate_buffers() */ | 181 | #include <linux/buffer_head.h> /* for invalidate_buffers() */ |
182 | 182 | ||
183 | /* | 183 | /* |
diff --git a/drivers/block/noop-iosched.c b/drivers/block/noop-iosched.c index f56b8edb06e4..e54f006e7e60 100644 --- a/drivers/block/noop-iosched.c +++ b/drivers/block/noop-iosched.c | |||
@@ -9,6 +9,7 @@ | |||
9 | 9 | ||
10 | static void elevator_noop_add_request(request_queue_t *q, struct request *rq) | 10 | static void elevator_noop_add_request(request_queue_t *q, struct request *rq) |
11 | { | 11 | { |
12 | rq->flags |= REQ_NOMERGE; | ||
12 | elv_dispatch_add_tail(q, rq); | 13 | elv_dispatch_add_tail(q, rq); |
13 | } | 14 | } |
14 | 15 | ||
diff --git a/drivers/char/s3c2410-rtc.c b/drivers/char/s3c2410-rtc.c index 887b8b2d7882..d724c0de4f28 100644 --- a/drivers/char/s3c2410-rtc.c +++ b/drivers/char/s3c2410-rtc.c | |||
@@ -20,7 +20,7 @@ | |||
20 | #include <linux/fs.h> | 20 | #include <linux/fs.h> |
21 | #include <linux/string.h> | 21 | #include <linux/string.h> |
22 | #include <linux/init.h> | 22 | #include <linux/init.h> |
23 | #include <linux/device.h> | 23 | #include <linux/platform_device.h> |
24 | #include <linux/interrupt.h> | 24 | #include <linux/interrupt.h> |
25 | #include <linux/rtc.h> | 25 | #include <linux/rtc.h> |
26 | #include <linux/bcd.h> | 26 | #include <linux/bcd.h> |
diff --git a/drivers/char/sonypi.c b/drivers/char/sonypi.c index f86c15587238..d05067dcea01 100644 --- a/drivers/char/sonypi.c +++ b/drivers/char/sonypi.c | |||
@@ -48,6 +48,7 @@ | |||
48 | #include <linux/dmi.h> | 48 | #include <linux/dmi.h> |
49 | #include <linux/err.h> | 49 | #include <linux/err.h> |
50 | #include <linux/kfifo.h> | 50 | #include <linux/kfifo.h> |
51 | #include <linux/platform_device.h> | ||
51 | 52 | ||
52 | #include <asm/uaccess.h> | 53 | #include <asm/uaccess.h> |
53 | #include <asm/io.h> | 54 | #include <asm/io.h> |
diff --git a/drivers/char/tb0219.c b/drivers/char/tb0219.c index eb7058cbf015..24355b23b2ca 100644 --- a/drivers/char/tb0219.c +++ b/drivers/char/tb0219.c | |||
@@ -17,7 +17,7 @@ | |||
17 | * along with this program; if not, write to the Free Software | 17 | * along with this program; if not, write to the Free Software |
18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
19 | */ | 19 | */ |
20 | #include <linux/device.h> | 20 | #include <linux/platform_device.h> |
21 | #include <linux/fs.h> | 21 | #include <linux/fs.h> |
22 | #include <linux/init.h> | 22 | #include <linux/init.h> |
23 | #include <linux/module.h> | 23 | #include <linux/module.h> |
diff --git a/drivers/char/vr41xx_giu.c b/drivers/char/vr41xx_giu.c index 683278bc5241..94641085faf8 100644 --- a/drivers/char/vr41xx_giu.c +++ b/drivers/char/vr41xx_giu.c | |||
@@ -19,7 +19,7 @@ | |||
19 | * along with this program; if not, write to the Free Software | 19 | * along with this program; if not, write to the Free Software |
20 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 20 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
21 | */ | 21 | */ |
22 | #include <linux/device.h> | 22 | #include <linux/platform_device.h> |
23 | #include <linux/errno.h> | 23 | #include <linux/errno.h> |
24 | #include <linux/fs.h> | 24 | #include <linux/fs.h> |
25 | #include <linux/init.h> | 25 | #include <linux/init.h> |
diff --git a/drivers/char/vr41xx_rtc.c b/drivers/char/vr41xx_rtc.c index a6dbe4da030c..5e3292df69d8 100644 --- a/drivers/char/vr41xx_rtc.c +++ b/drivers/char/vr41xx_rtc.c | |||
@@ -17,7 +17,7 @@ | |||
17 | * along with this program; if not, write to the Free Software | 17 | * along with this program; if not, write to the Free Software |
18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
19 | */ | 19 | */ |
20 | #include <linux/device.h> | 20 | #include <linux/platform_device.h> |
21 | #include <linux/fs.h> | 21 | #include <linux/fs.h> |
22 | #include <linux/init.h> | 22 | #include <linux/init.h> |
23 | #include <linux/ioport.h> | 23 | #include <linux/ioport.h> |
diff --git a/drivers/char/watchdog/mpcore_wdt.c b/drivers/char/watchdog/mpcore_wdt.c index 75ca84ed4adf..47a5f6ab4879 100644 --- a/drivers/char/watchdog/mpcore_wdt.c +++ b/drivers/char/watchdog/mpcore_wdt.c | |||
@@ -29,7 +29,7 @@ | |||
29 | #include <linux/reboot.h> | 29 | #include <linux/reboot.h> |
30 | #include <linux/init.h> | 30 | #include <linux/init.h> |
31 | #include <linux/interrupt.h> | 31 | #include <linux/interrupt.h> |
32 | #include <linux/device.h> | 32 | #include <linux/platform_device.h> |
33 | 33 | ||
34 | #include <asm/hardware/arm_twd.h> | 34 | #include <asm/hardware/arm_twd.h> |
35 | #include <asm/uaccess.h> | 35 | #include <asm/uaccess.h> |
diff --git a/drivers/char/watchdog/mv64x60_wdt.c b/drivers/char/watchdog/mv64x60_wdt.c index 6d3ff0836c44..04e0d7e9680d 100644 --- a/drivers/char/watchdog/mv64x60_wdt.c +++ b/drivers/char/watchdog/mv64x60_wdt.c | |||
@@ -22,6 +22,8 @@ | |||
22 | #include <linux/miscdevice.h> | 22 | #include <linux/miscdevice.h> |
23 | #include <linux/module.h> | 23 | #include <linux/module.h> |
24 | #include <linux/watchdog.h> | 24 | #include <linux/watchdog.h> |
25 | #include <linux/platform_device.h> | ||
26 | |||
25 | #include <asm/mv64x60.h> | 27 | #include <asm/mv64x60.h> |
26 | #include <asm/uaccess.h> | 28 | #include <asm/uaccess.h> |
27 | #include <asm/io.h> | 29 | #include <asm/io.h> |
diff --git a/drivers/char/watchdog/s3c2410_wdt.c b/drivers/char/watchdog/s3c2410_wdt.c index b732020acadb..e7e20a6d64b0 100644 --- a/drivers/char/watchdog/s3c2410_wdt.c +++ b/drivers/char/watchdog/s3c2410_wdt.c | |||
@@ -44,7 +44,7 @@ | |||
44 | #include <linux/watchdog.h> | 44 | #include <linux/watchdog.h> |
45 | #include <linux/fs.h> | 45 | #include <linux/fs.h> |
46 | #include <linux/init.h> | 46 | #include <linux/init.h> |
47 | #include <linux/device.h> | 47 | #include <linux/platform_device.h> |
48 | #include <linux/interrupt.h> | 48 | #include <linux/interrupt.h> |
49 | 49 | ||
50 | #include <asm/uaccess.h> | 50 | #include <asm/uaccess.h> |
diff --git a/drivers/eisa/virtual_root.c b/drivers/eisa/virtual_root.c index 15677f20bd85..0f97a0cb0ff4 100644 --- a/drivers/eisa/virtual_root.c +++ b/drivers/eisa/virtual_root.c | |||
@@ -9,7 +9,7 @@ | |||
9 | 9 | ||
10 | #include <linux/config.h> | 10 | #include <linux/config.h> |
11 | #include <linux/kernel.h> | 11 | #include <linux/kernel.h> |
12 | #include <linux/device.h> | 12 | #include <linux/platform_device.h> |
13 | #include <linux/eisa.h> | 13 | #include <linux/eisa.h> |
14 | #include <linux/module.h> | 14 | #include <linux/module.h> |
15 | #include <linux/moduleparam.h> | 15 | #include <linux/moduleparam.h> |
diff --git a/drivers/firmware/dcdbas.c b/drivers/firmware/dcdbas.c index 955537fe9958..8ed6ddbb9c5d 100644 --- a/drivers/firmware/dcdbas.c +++ b/drivers/firmware/dcdbas.c | |||
@@ -20,7 +20,7 @@ | |||
20 | * GNU General Public License for more details. | 20 | * GNU General Public License for more details. |
21 | */ | 21 | */ |
22 | 22 | ||
23 | #include <linux/device.h> | 23 | #include <linux/platform_device.h> |
24 | #include <linux/dma-mapping.h> | 24 | #include <linux/dma-mapping.h> |
25 | #include <linux/errno.h> | 25 | #include <linux/errno.h> |
26 | #include <linux/init.h> | 26 | #include <linux/init.h> |
diff --git a/drivers/firmware/dell_rbu.c b/drivers/firmware/dell_rbu.c index 4f4ba9b6d182..125929c9048f 100644 --- a/drivers/firmware/dell_rbu.c +++ b/drivers/firmware/dell_rbu.c | |||
@@ -41,7 +41,7 @@ | |||
41 | #include <linux/string.h> | 41 | #include <linux/string.h> |
42 | #include <linux/errno.h> | 42 | #include <linux/errno.h> |
43 | #include <linux/blkdev.h> | 43 | #include <linux/blkdev.h> |
44 | #include <linux/device.h> | 44 | #include <linux/platform_device.h> |
45 | #include <linux/spinlock.h> | 45 | #include <linux/spinlock.h> |
46 | #include <linux/moduleparam.h> | 46 | #include <linux/moduleparam.h> |
47 | #include <linux/firmware.h> | 47 | #include <linux/firmware.h> |
diff --git a/drivers/hwmon/hdaps.c b/drivers/hwmon/hdaps.c index 0015da5668a1..1e5dfc7805e2 100644 --- a/drivers/hwmon/hdaps.c +++ b/drivers/hwmon/hdaps.c | |||
@@ -27,7 +27,7 @@ | |||
27 | */ | 27 | */ |
28 | 28 | ||
29 | #include <linux/delay.h> | 29 | #include <linux/delay.h> |
30 | #include <linux/device.h> | 30 | #include <linux/platform_device.h> |
31 | #include <linux/input.h> | 31 | #include <linux/input.h> |
32 | #include <linux/kernel.h> | 32 | #include <linux/kernel.h> |
33 | #include <linux/module.h> | 33 | #include <linux/module.h> |
diff --git a/drivers/i2c/busses/i2c-iop3xx.c b/drivers/i2c/busses/i2c-iop3xx.c index 9888fae1f37a..13752bcb2afd 100644 --- a/drivers/i2c/busses/i2c-iop3xx.c +++ b/drivers/i2c/busses/i2c-iop3xx.c | |||
@@ -35,7 +35,7 @@ | |||
35 | #include <linux/init.h> | 35 | #include <linux/init.h> |
36 | #include <linux/errno.h> | 36 | #include <linux/errno.h> |
37 | #include <linux/sched.h> | 37 | #include <linux/sched.h> |
38 | #include <linux/device.h> | 38 | #include <linux/platform_device.h> |
39 | #include <linux/i2c.h> | 39 | #include <linux/i2c.h> |
40 | 40 | ||
41 | #include <asm/io.h> | 41 | #include <asm/io.h> |
diff --git a/drivers/i2c/busses/i2c-isa.c b/drivers/i2c/busses/i2c-isa.c index 4fdc02411609..03672c9ca409 100644 --- a/drivers/i2c/busses/i2c-isa.c +++ b/drivers/i2c/busses/i2c-isa.c | |||
@@ -38,6 +38,7 @@ | |||
38 | #include <linux/errno.h> | 38 | #include <linux/errno.h> |
39 | #include <linux/i2c.h> | 39 | #include <linux/i2c.h> |
40 | #include <linux/i2c-isa.h> | 40 | #include <linux/i2c-isa.h> |
41 | #include <linux/platform_device.h> | ||
41 | 42 | ||
42 | static u32 isa_func(struct i2c_adapter *adapter); | 43 | static u32 isa_func(struct i2c_adapter *adapter); |
43 | 44 | ||
diff --git a/drivers/i2c/busses/i2c-ixp2000.c b/drivers/i2c/busses/i2c-ixp2000.c index 42016ee6ef13..64552a376f2d 100644 --- a/drivers/i2c/busses/i2c-ixp2000.c +++ b/drivers/i2c/busses/i2c-ixp2000.c | |||
@@ -28,7 +28,7 @@ | |||
28 | 28 | ||
29 | #include <linux/kernel.h> | 29 | #include <linux/kernel.h> |
30 | #include <linux/init.h> | 30 | #include <linux/init.h> |
31 | #include <linux/device.h> | 31 | #include <linux/platform_device.h> |
32 | #include <linux/module.h> | 32 | #include <linux/module.h> |
33 | #include <linux/i2c.h> | 33 | #include <linux/i2c.h> |
34 | #include <linux/i2c-algo-bit.h> | 34 | #include <linux/i2c-algo-bit.h> |
diff --git a/drivers/i2c/busses/i2c-ixp4xx.c b/drivers/i2c/busses/i2c-ixp4xx.c index 69303ab65e04..cc652c350814 100644 --- a/drivers/i2c/busses/i2c-ixp4xx.c +++ b/drivers/i2c/busses/i2c-ixp4xx.c | |||
@@ -28,7 +28,7 @@ | |||
28 | 28 | ||
29 | #include <linux/kernel.h> | 29 | #include <linux/kernel.h> |
30 | #include <linux/init.h> | 30 | #include <linux/init.h> |
31 | #include <linux/device.h> | 31 | #include <linux/platform_device.h> |
32 | #include <linux/module.h> | 32 | #include <linux/module.h> |
33 | #include <linux/i2c.h> | 33 | #include <linux/i2c.h> |
34 | #include <linux/i2c-algo-bit.h> | 34 | #include <linux/i2c-algo-bit.h> |
diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c index 8491633005b8..65b939a059e9 100644 --- a/drivers/i2c/busses/i2c-mpc.c +++ b/drivers/i2c/busses/i2c-mpc.c | |||
@@ -19,6 +19,8 @@ | |||
19 | #include <linux/sched.h> | 19 | #include <linux/sched.h> |
20 | #include <linux/init.h> | 20 | #include <linux/init.h> |
21 | #include <linux/pci.h> | 21 | #include <linux/pci.h> |
22 | #include <linux/platform_device.h> | ||
23 | |||
22 | #include <asm/io.h> | 24 | #include <asm/io.h> |
23 | #include <linux/fsl_devices.h> | 25 | #include <linux/fsl_devices.h> |
24 | #include <linux/i2c.h> | 26 | #include <linux/i2c.h> |
diff --git a/drivers/i2c/busses/i2c-mv64xxx.c b/drivers/i2c/busses/i2c-mv64xxx.c index d0d2a6f1386e..6b48027b2ee3 100644 --- a/drivers/i2c/busses/i2c-mv64xxx.c +++ b/drivers/i2c/busses/i2c-mv64xxx.c | |||
@@ -17,6 +17,8 @@ | |||
17 | #include <linux/i2c.h> | 17 | #include <linux/i2c.h> |
18 | #include <linux/interrupt.h> | 18 | #include <linux/interrupt.h> |
19 | #include <linux/mv643xx.h> | 19 | #include <linux/mv643xx.h> |
20 | #include <linux/platform_device.h> | ||
21 | |||
20 | #include <asm/io.h> | 22 | #include <asm/io.h> |
21 | 23 | ||
22 | /* Register defines */ | 24 | /* Register defines */ |
diff --git a/drivers/i2c/busses/i2c-pxa.c b/drivers/i2c/busses/i2c-pxa.c index 44b595d90a4a..67ccbea24ba4 100644 --- a/drivers/i2c/busses/i2c-pxa.c +++ b/drivers/i2c/busses/i2c-pxa.c | |||
@@ -30,6 +30,7 @@ | |||
30 | #include <linux/errno.h> | 30 | #include <linux/errno.h> |
31 | #include <linux/interrupt.h> | 31 | #include <linux/interrupt.h> |
32 | #include <linux/i2c-pxa.h> | 32 | #include <linux/i2c-pxa.h> |
33 | #include <linux/platform_device.h> | ||
33 | 34 | ||
34 | #include <asm/hardware.h> | 35 | #include <asm/hardware.h> |
35 | #include <asm/irq.h> | 36 | #include <asm/irq.h> |
diff --git a/drivers/i2c/busses/i2c-s3c2410.c b/drivers/i2c/busses/i2c-s3c2410.c index 6ced28e90070..1b582262e677 100644 --- a/drivers/i2c/busses/i2c-s3c2410.c +++ b/drivers/i2c/busses/i2c-s3c2410.c | |||
@@ -33,7 +33,7 @@ | |||
33 | #include <linux/delay.h> | 33 | #include <linux/delay.h> |
34 | #include <linux/errno.h> | 34 | #include <linux/errno.h> |
35 | #include <linux/err.h> | 35 | #include <linux/err.h> |
36 | #include <linux/device.h> | 36 | #include <linux/platform_device.h> |
37 | 37 | ||
38 | #include <asm/hardware.h> | 38 | #include <asm/hardware.h> |
39 | #include <asm/irq.h> | 39 | #include <asm/irq.h> |
@@ -918,8 +918,11 @@ static int __init i2c_adap_s3c_init(void) | |||
918 | int ret; | 918 | int ret; |
919 | 919 | ||
920 | ret = driver_register(&s3c2410_i2c_driver); | 920 | ret = driver_register(&s3c2410_i2c_driver); |
921 | if (ret == 0) | 921 | if (ret == 0) { |
922 | ret = driver_register(&s3c2440_i2c_driver); | 922 | ret = driver_register(&s3c2440_i2c_driver); |
923 | if (ret) | ||
924 | driver_unregister(&s3c2410_i2c_driver); | ||
925 | } | ||
923 | 926 | ||
924 | return ret; | 927 | return ret; |
925 | } | 928 | } |
diff --git a/drivers/i2c/chips/isp1301_omap.c b/drivers/i2c/chips/isp1301_omap.c index eaa4742e04fa..9dbb72fffbe2 100644 --- a/drivers/i2c/chips/isp1301_omap.c +++ b/drivers/i2c/chips/isp1301_omap.c | |||
@@ -27,7 +27,7 @@ | |||
27 | #include <linux/init.h> | 27 | #include <linux/init.h> |
28 | #include <linux/slab.h> | 28 | #include <linux/slab.h> |
29 | #include <linux/interrupt.h> | 29 | #include <linux/interrupt.h> |
30 | #include <linux/device.h> | 30 | #include <linux/platform_device.h> |
31 | #include <linux/usb_ch9.h> | 31 | #include <linux/usb_ch9.h> |
32 | #include <linux/usb_gadget.h> | 32 | #include <linux/usb_gadget.h> |
33 | #include <linux/usb.h> | 33 | #include <linux/usb.h> |
diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c index 02e335a04f09..82ea1b7ec914 100644 --- a/drivers/i2c/i2c-core.c +++ b/drivers/i2c/i2c-core.c | |||
@@ -30,6 +30,7 @@ | |||
30 | #include <linux/init.h> | 30 | #include <linux/init.h> |
31 | #include <linux/idr.h> | 31 | #include <linux/idr.h> |
32 | #include <linux/seq_file.h> | 32 | #include <linux/seq_file.h> |
33 | #include <linux/platform_device.h> | ||
33 | #include <asm/uaccess.h> | 34 | #include <asm/uaccess.h> |
34 | 35 | ||
35 | 36 | ||
diff --git a/drivers/i2c/i2c-dev.c b/drivers/i2c/i2c-dev.c index ea14c8f1c82b..8af0bd1424d2 100644 --- a/drivers/i2c/i2c-dev.c +++ b/drivers/i2c/i2c-dev.c | |||
@@ -34,6 +34,7 @@ | |||
34 | #include <linux/init.h> | 34 | #include <linux/init.h> |
35 | #include <linux/i2c.h> | 35 | #include <linux/i2c.h> |
36 | #include <linux/i2c-dev.h> | 36 | #include <linux/i2c-dev.h> |
37 | #include <linux/platform_device.h> | ||
37 | #include <asm/uaccess.h> | 38 | #include <asm/uaccess.h> |
38 | 39 | ||
39 | static struct i2c_client i2cdev_client_template; | 40 | static struct i2c_client i2cdev_client_template; |
diff --git a/drivers/input/evdev.c b/drivers/input/evdev.c index a4696cd0978c..9f2352bd8348 100644 --- a/drivers/input/evdev.c +++ b/drivers/input/evdev.c | |||
@@ -565,6 +565,7 @@ static long evdev_ioctl_compat(struct file *file, unsigned int cmd, unsigned lon | |||
565 | case EV_LED: bits = dev->ledbit; max = LED_MAX; break; | 565 | case EV_LED: bits = dev->ledbit; max = LED_MAX; break; |
566 | case EV_SND: bits = dev->sndbit; max = SND_MAX; break; | 566 | case EV_SND: bits = dev->sndbit; max = SND_MAX; break; |
567 | case EV_FF: bits = dev->ffbit; max = FF_MAX; break; | 567 | case EV_FF: bits = dev->ffbit; max = FF_MAX; break; |
568 | case EV_SW: bits = dev->swbit; max = SW_MAX; break; | ||
568 | default: return -EINVAL; | 569 | default: return -EINVAL; |
569 | } | 570 | } |
570 | bit_to_user(bits, max); | 571 | bit_to_user(bits, max); |
@@ -579,6 +580,9 @@ static long evdev_ioctl_compat(struct file *file, unsigned int cmd, unsigned lon | |||
579 | if (_IOC_NR(cmd) == _IOC_NR(EVIOCGSND(0))) | 580 | if (_IOC_NR(cmd) == _IOC_NR(EVIOCGSND(0))) |
580 | bit_to_user(dev->snd, SND_MAX); | 581 | bit_to_user(dev->snd, SND_MAX); |
581 | 582 | ||
583 | if (_IOC_NR(cmd) == _IOC_NR(EVIOCGSW(0))) | ||
584 | bit_to_user(dev->sw, SW_MAX); | ||
585 | |||
582 | if (_IOC_NR(cmd) == _IOC_NR(EVIOCGNAME(0))) { | 586 | if (_IOC_NR(cmd) == _IOC_NR(EVIOCGNAME(0))) { |
583 | int len; | 587 | int len; |
584 | if (!dev->name) return -ENOENT; | 588 | if (!dev->name) return -ENOENT; |
diff --git a/drivers/input/input.c b/drivers/input/input.c index 3b1685ff9d10..1a1654caedd5 100644 --- a/drivers/input/input.c +++ b/drivers/input/input.c | |||
@@ -730,7 +730,7 @@ static void input_register_classdevice(struct input_dev *dev) | |||
730 | "input%ld", (unsigned long) atomic_inc_return(&input_no) - 1); | 730 | "input%ld", (unsigned long) atomic_inc_return(&input_no) - 1); |
731 | 731 | ||
732 | path = kobject_get_path(&dev->cdev.class->subsys.kset.kobj, GFP_KERNEL); | 732 | path = kobject_get_path(&dev->cdev.class->subsys.kset.kobj, GFP_KERNEL); |
733 | printk(KERN_INFO "input: %s/%s as %s\n", | 733 | printk(KERN_INFO "input: %s as %s/%s\n", |
734 | dev->name ? dev->name : "Unspecified device", | 734 | dev->name ? dev->name : "Unspecified device", |
735 | path ? path : "", dev->cdev.class_id); | 735 | path ? path : "", dev->cdev.class_id); |
736 | kfree(path); | 736 | kfree(path); |
diff --git a/drivers/input/keyboard/Kconfig b/drivers/input/keyboard/Kconfig index 571a68691a4a..4a917748fd9f 100644 --- a/drivers/input/keyboard/Kconfig +++ b/drivers/input/keyboard/Kconfig | |||
@@ -13,11 +13,11 @@ menuconfig INPUT_KEYBOARD | |||
13 | if INPUT_KEYBOARD | 13 | if INPUT_KEYBOARD |
14 | 14 | ||
15 | config KEYBOARD_ATKBD | 15 | config KEYBOARD_ATKBD |
16 | tristate "AT keyboard" if !PC | 16 | tristate "AT keyboard" if !X86_PC |
17 | default y | 17 | default y |
18 | select SERIO | 18 | select SERIO |
19 | select SERIO_LIBPS2 | 19 | select SERIO_LIBPS2 |
20 | select SERIO_I8042 if PC | 20 | select SERIO_I8042 if X86_PC |
21 | select SERIO_GSCPS2 if GSC | 21 | select SERIO_GSCPS2 if GSC |
22 | help | 22 | help |
23 | Say Y here if you want to use a standard AT or PS/2 keyboard. Usually | 23 | Say Y here if you want to use a standard AT or PS/2 keyboard. Usually |
diff --git a/drivers/input/keyboard/corgikbd.c b/drivers/input/keyboard/corgikbd.c index 3210d298b3bc..d00d14bb637a 100644 --- a/drivers/input/keyboard/corgikbd.c +++ b/drivers/input/keyboard/corgikbd.c | |||
@@ -12,7 +12,7 @@ | |||
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <linux/delay.h> | 14 | #include <linux/delay.h> |
15 | #include <linux/device.h> | 15 | #include <linux/platform_device.h> |
16 | #include <linux/init.h> | 16 | #include <linux/init.h> |
17 | #include <linux/input.h> | 17 | #include <linux/input.h> |
18 | #include <linux/interrupt.h> | 18 | #include <linux/interrupt.h> |
diff --git a/drivers/input/keyboard/lkkbd.c b/drivers/input/keyboard/lkkbd.c index 7f06780a437f..9481132532d0 100644 --- a/drivers/input/keyboard/lkkbd.c +++ b/drivers/input/keyboard/lkkbd.c | |||
@@ -441,7 +441,7 @@ lkkbd_interrupt (struct serio *serio, unsigned char data, unsigned int flags, | |||
441 | input_sync (lk->dev); | 441 | input_sync (lk->dev); |
442 | break; | 442 | break; |
443 | case LK_METRONOME: | 443 | case LK_METRONOME: |
444 | DBG (KERN_INFO "Got %#d and don't " | 444 | DBG (KERN_INFO "Got LK_METRONOME and don't " |
445 | "know how to handle...\n"); | 445 | "know how to handle...\n"); |
446 | break; | 446 | break; |
447 | case LK_OUTPUT_ERROR: | 447 | case LK_OUTPUT_ERROR: |
diff --git a/drivers/input/keyboard/spitzkbd.c b/drivers/input/keyboard/spitzkbd.c index cee9c734a048..0fa38a559cdf 100644 --- a/drivers/input/keyboard/spitzkbd.c +++ b/drivers/input/keyboard/spitzkbd.c | |||
@@ -12,7 +12,7 @@ | |||
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <linux/delay.h> | 14 | #include <linux/delay.h> |
15 | #include <linux/device.h> | 15 | #include <linux/platform_device.h> |
16 | #include <linux/init.h> | 16 | #include <linux/init.h> |
17 | #include <linux/input.h> | 17 | #include <linux/input.h> |
18 | #include <linux/interrupt.h> | 18 | #include <linux/interrupt.h> |
diff --git a/drivers/input/misc/pcspkr.c b/drivers/input/misc/pcspkr.c index e34633c37fdd..68ac97f101b0 100644 --- a/drivers/input/misc/pcspkr.c +++ b/drivers/input/misc/pcspkr.c | |||
@@ -71,7 +71,7 @@ static int __init pcspkr_init(void) | |||
71 | return -ENOMEM; | 71 | return -ENOMEM; |
72 | 72 | ||
73 | pcspkr_dev->name = "PC Speaker"; | 73 | pcspkr_dev->name = "PC Speaker"; |
74 | pcspkr_dev->name = "isa0061/input0"; | 74 | pcspkr_dev->phys = "isa0061/input0"; |
75 | pcspkr_dev->id.bustype = BUS_ISA; | 75 | pcspkr_dev->id.bustype = BUS_ISA; |
76 | pcspkr_dev->id.vendor = 0x001f; | 76 | pcspkr_dev->id.vendor = 0x001f; |
77 | pcspkr_dev->id.product = 0x0001; | 77 | pcspkr_dev->id.product = 0x0001; |
diff --git a/drivers/input/mouse/Kconfig b/drivers/input/mouse/Kconfig index 537154dd7a87..574b18a523af 100644 --- a/drivers/input/mouse/Kconfig +++ b/drivers/input/mouse/Kconfig | |||
@@ -17,7 +17,7 @@ config MOUSE_PS2 | |||
17 | default y | 17 | default y |
18 | select SERIO | 18 | select SERIO |
19 | select SERIO_LIBPS2 | 19 | select SERIO_LIBPS2 |
20 | select SERIO_I8042 if PC | 20 | select SERIO_I8042 if X86_PC |
21 | select SERIO_GSCPS2 if GSC | 21 | select SERIO_GSCPS2 if GSC |
22 | ---help--- | 22 | ---help--- |
23 | Say Y here if you have a PS/2 mouse connected to your system. This | 23 | Say Y here if you have a PS/2 mouse connected to your system. This |
diff --git a/drivers/input/serio/ct82c710.c b/drivers/input/serio/ct82c710.c index dd0f5bd90241..4da6c86b5d76 100644 --- a/drivers/input/serio/ct82c710.c +++ b/drivers/input/serio/ct82c710.c | |||
@@ -37,6 +37,7 @@ | |||
37 | #include <linux/serio.h> | 37 | #include <linux/serio.h> |
38 | #include <linux/errno.h> | 38 | #include <linux/errno.h> |
39 | #include <linux/err.h> | 39 | #include <linux/err.h> |
40 | #include <linux/platform_device.h> | ||
40 | 41 | ||
41 | #include <asm/io.h> | 42 | #include <asm/io.h> |
42 | 43 | ||
diff --git a/drivers/input/serio/i8042.c b/drivers/input/serio/i8042.c index 4bc40f159996..01e186422021 100644 --- a/drivers/input/serio/i8042.c +++ b/drivers/input/serio/i8042.c | |||
@@ -20,6 +20,7 @@ | |||
20 | #include <linux/serio.h> | 20 | #include <linux/serio.h> |
21 | #include <linux/err.h> | 21 | #include <linux/err.h> |
22 | #include <linux/rcupdate.h> | 22 | #include <linux/rcupdate.h> |
23 | #include <linux/platform_device.h> | ||
23 | 24 | ||
24 | #include <asm/io.h> | 25 | #include <asm/io.h> |
25 | 26 | ||
diff --git a/drivers/input/serio/maceps2.c b/drivers/input/serio/maceps2.c index 9880fc145d90..d857f7081adb 100644 --- a/drivers/input/serio/maceps2.c +++ b/drivers/input/serio/maceps2.c | |||
@@ -14,7 +14,7 @@ | |||
14 | #include <linux/interrupt.h> | 14 | #include <linux/interrupt.h> |
15 | #include <linux/ioport.h> | 15 | #include <linux/ioport.h> |
16 | #include <linux/delay.h> | 16 | #include <linux/delay.h> |
17 | #include <linux/device.h> | 17 | #include <linux/platform_device.h> |
18 | #include <linux/slab.h> | 18 | #include <linux/slab.h> |
19 | #include <linux/spinlock.h> | 19 | #include <linux/spinlock.h> |
20 | #include <linux/err.h> | 20 | #include <linux/err.h> |
diff --git a/drivers/input/serio/q40kbd.c b/drivers/input/serio/q40kbd.c index 46093c507988..b44d255596c2 100644 --- a/drivers/input/serio/q40kbd.c +++ b/drivers/input/serio/q40kbd.c | |||
@@ -37,6 +37,7 @@ | |||
37 | #include <linux/interrupt.h> | 37 | #include <linux/interrupt.h> |
38 | #include <linux/err.h> | 38 | #include <linux/err.h> |
39 | #include <linux/bitops.h> | 39 | #include <linux/bitops.h> |
40 | #include <linux/platform_device.h> | ||
40 | 41 | ||
41 | #include <asm/io.h> | 42 | #include <asm/io.h> |
42 | #include <asm/uaccess.h> | 43 | #include <asm/uaccess.h> |
diff --git a/drivers/input/serio/rpckbd.c b/drivers/input/serio/rpckbd.c index 106f5eefd89a..52c49258f8a4 100644 --- a/drivers/input/serio/rpckbd.c +++ b/drivers/input/serio/rpckbd.c | |||
@@ -34,6 +34,7 @@ | |||
34 | #include <linux/init.h> | 34 | #include <linux/init.h> |
35 | #include <linux/serio.h> | 35 | #include <linux/serio.h> |
36 | #include <linux/err.h> | 36 | #include <linux/err.h> |
37 | #include <linux/platform_device.h> | ||
37 | 38 | ||
38 | #include <asm/irq.h> | 39 | #include <asm/irq.h> |
39 | #include <asm/hardware.h> | 40 | #include <asm/hardware.h> |
diff --git a/drivers/input/touchscreen/corgi_ts.c b/drivers/input/touchscreen/corgi_ts.c index 0ba3e6562bff..15e88eeae8d6 100644 --- a/drivers/input/touchscreen/corgi_ts.c +++ b/drivers/input/touchscreen/corgi_ts.c | |||
@@ -11,7 +11,7 @@ | |||
11 | 11 | ||
12 | 12 | ||
13 | #include <linux/delay.h> | 13 | #include <linux/delay.h> |
14 | #include <linux/device.h> | 14 | #include <linux/platform_device.h> |
15 | #include <linux/init.h> | 15 | #include <linux/init.h> |
16 | #include <linux/input.h> | 16 | #include <linux/input.h> |
17 | #include <linux/interrupt.h> | 17 | #include <linux/interrupt.h> |
diff --git a/drivers/macintosh/adbhid.c b/drivers/macintosh/adbhid.c index cdb6d0283195..8f02c155fdc0 100644 --- a/drivers/macintosh/adbhid.c +++ b/drivers/macintosh/adbhid.c | |||
@@ -723,6 +723,7 @@ adbhid_input_register(int id, int default_id, int original_handler_id, | |||
723 | 723 | ||
724 | sprintf(hid->phys, "adb%d:%d.%02x/input", id, default_id, original_handler_id); | 724 | sprintf(hid->phys, "adb%d:%d.%02x/input", id, default_id, original_handler_id); |
725 | 725 | ||
726 | hid->input = input_dev; | ||
726 | hid->id = default_id; | 727 | hid->id = default_id; |
727 | hid->original_handler_id = original_handler_id; | 728 | hid->original_handler_id = original_handler_id; |
728 | hid->current_handler_id = current_handler_id; | 729 | hid->current_handler_id = current_handler_id; |
diff --git a/drivers/mfd/mcp-sa11x0.c b/drivers/mfd/mcp-sa11x0.c index 720e7a326308..7daa0ed7331c 100644 --- a/drivers/mfd/mcp-sa11x0.c +++ b/drivers/mfd/mcp-sa11x0.c | |||
@@ -18,7 +18,7 @@ | |||
18 | #include <linux/delay.h> | 18 | #include <linux/delay.h> |
19 | #include <linux/spinlock.h> | 19 | #include <linux/spinlock.h> |
20 | #include <linux/slab.h> | 20 | #include <linux/slab.h> |
21 | #include <linux/device.h> | 21 | #include <linux/platform_device.h> |
22 | 22 | ||
23 | #include <asm/dma.h> | 23 | #include <asm/dma.h> |
24 | #include <asm/hardware.h> | 24 | #include <asm/hardware.h> |
diff --git a/drivers/misc/hdpuftrs/hdpu_cpustate.c b/drivers/misc/hdpuftrs/hdpu_cpustate.c index 46de5c940555..9c4dd682ac74 100644 --- a/drivers/misc/hdpuftrs/hdpu_cpustate.c +++ b/drivers/misc/hdpuftrs/hdpu_cpustate.c | |||
@@ -21,7 +21,7 @@ | |||
21 | #include <linux/miscdevice.h> | 21 | #include <linux/miscdevice.h> |
22 | #include <linux/pci.h> | 22 | #include <linux/pci.h> |
23 | #include <linux/proc_fs.h> | 23 | #include <linux/proc_fs.h> |
24 | #include <linux/device.h> | 24 | #include <linux/platform_device.h> |
25 | #include <asm/uaccess.h> | 25 | #include <asm/uaccess.h> |
26 | #include <linux/hdpu_features.h> | 26 | #include <linux/hdpu_features.h> |
27 | 27 | ||
diff --git a/drivers/misc/hdpuftrs/hdpu_nexus.c b/drivers/misc/hdpuftrs/hdpu_nexus.c index c203b27269ea..165f3405df27 100644 --- a/drivers/misc/hdpuftrs/hdpu_nexus.c +++ b/drivers/misc/hdpuftrs/hdpu_nexus.c | |||
@@ -21,7 +21,7 @@ | |||
21 | #include <linux/hdpu_features.h> | 21 | #include <linux/hdpu_features.h> |
22 | #include <linux/pci.h> | 22 | #include <linux/pci.h> |
23 | 23 | ||
24 | #include <linux/device.h> | 24 | #include <linux/platform_device.h> |
25 | 25 | ||
26 | static int hdpu_nexus_probe(struct device *ddev); | 26 | static int hdpu_nexus_probe(struct device *ddev); |
27 | static int hdpu_nexus_remove(struct device *ddev); | 27 | static int hdpu_nexus_remove(struct device *ddev); |
diff --git a/drivers/mmc/pxamci.c b/drivers/mmc/pxamci.c index d575e3a018bc..f31e247b2cbe 100644 --- a/drivers/mmc/pxamci.c +++ b/drivers/mmc/pxamci.c | |||
@@ -20,7 +20,7 @@ | |||
20 | #include <linux/module.h> | 20 | #include <linux/module.h> |
21 | #include <linux/init.h> | 21 | #include <linux/init.h> |
22 | #include <linux/ioport.h> | 22 | #include <linux/ioport.h> |
23 | #include <linux/device.h> | 23 | #include <linux/platform_device.h> |
24 | #include <linux/delay.h> | 24 | #include <linux/delay.h> |
25 | #include <linux/interrupt.h> | 25 | #include <linux/interrupt.h> |
26 | #include <linux/dma-mapping.h> | 26 | #include <linux/dma-mapping.h> |
diff --git a/drivers/mmc/wbsd.c b/drivers/mmc/wbsd.c index 3ace875decc4..942668e93a74 100644 --- a/drivers/mmc/wbsd.c +++ b/drivers/mmc/wbsd.c | |||
@@ -26,7 +26,7 @@ | |||
26 | #include <linux/moduleparam.h> | 26 | #include <linux/moduleparam.h> |
27 | #include <linux/init.h> | 27 | #include <linux/init.h> |
28 | #include <linux/ioport.h> | 28 | #include <linux/ioport.h> |
29 | #include <linux/device.h> | 29 | #include <linux/platform_device.h> |
30 | #include <linux/interrupt.h> | 30 | #include <linux/interrupt.h> |
31 | #include <linux/dma-mapping.h> | 31 | #include <linux/dma-mapping.h> |
32 | #include <linux/delay.h> | 32 | #include <linux/delay.h> |
diff --git a/drivers/mtd/maps/bast-flash.c b/drivers/mtd/maps/bast-flash.c index 63104c73ca3c..bfe994e59265 100644 --- a/drivers/mtd/maps/bast-flash.c +++ b/drivers/mtd/maps/bast-flash.c | |||
@@ -34,7 +34,7 @@ | |||
34 | #include <linux/ioport.h> | 34 | #include <linux/ioport.h> |
35 | #include <linux/device.h> | 35 | #include <linux/device.h> |
36 | #include <linux/slab.h> | 36 | #include <linux/slab.h> |
37 | 37 | #include <linux/platform_device.h> | |
38 | #include <linux/mtd/mtd.h> | 38 | #include <linux/mtd/mtd.h> |
39 | #include <linux/mtd/map.h> | 39 | #include <linux/mtd/map.h> |
40 | #include <linux/mtd/partitions.h> | 40 | #include <linux/mtd/partitions.h> |
diff --git a/drivers/mtd/maps/integrator-flash.c b/drivers/mtd/maps/integrator-flash.c index e39a98a0171c..d14a0185b8f4 100644 --- a/drivers/mtd/maps/integrator-flash.c +++ b/drivers/mtd/maps/integrator-flash.c | |||
@@ -32,7 +32,7 @@ | |||
32 | #include <linux/kernel.h> | 32 | #include <linux/kernel.h> |
33 | #include <linux/slab.h> | 33 | #include <linux/slab.h> |
34 | #include <linux/ioport.h> | 34 | #include <linux/ioport.h> |
35 | #include <linux/device.h> | 35 | #include <linux/platform_device.h> |
36 | #include <linux/init.h> | 36 | #include <linux/init.h> |
37 | 37 | ||
38 | #include <linux/mtd/mtd.h> | 38 | #include <linux/mtd/mtd.h> |
diff --git a/drivers/mtd/maps/ixp2000.c b/drivers/mtd/maps/ixp2000.c index 1e5d6e1d05f3..00b9f67580f1 100644 --- a/drivers/mtd/maps/ixp2000.c +++ b/drivers/mtd/maps/ixp2000.c | |||
@@ -25,6 +25,7 @@ | |||
25 | #include <linux/slab.h> | 25 | #include <linux/slab.h> |
26 | #include <linux/ioport.h> | 26 | #include <linux/ioport.h> |
27 | #include <linux/device.h> | 27 | #include <linux/device.h> |
28 | #include <linux/platform_device.h> | ||
28 | 29 | ||
29 | #include <linux/mtd/mtd.h> | 30 | #include <linux/mtd/mtd.h> |
30 | #include <linux/mtd/map.h> | 31 | #include <linux/mtd/map.h> |
diff --git a/drivers/mtd/maps/ixp4xx.c b/drivers/mtd/maps/ixp4xx.c index da316e543237..733a9297a562 100644 --- a/drivers/mtd/maps/ixp4xx.c +++ b/drivers/mtd/maps/ixp4xx.c | |||
@@ -23,6 +23,7 @@ | |||
23 | #include <linux/slab.h> | 23 | #include <linux/slab.h> |
24 | #include <linux/ioport.h> | 24 | #include <linux/ioport.h> |
25 | #include <linux/device.h> | 25 | #include <linux/device.h> |
26 | #include <linux/platform_device.h> | ||
26 | 27 | ||
27 | #include <linux/mtd/mtd.h> | 28 | #include <linux/mtd/mtd.h> |
28 | #include <linux/mtd/map.h> | 29 | #include <linux/mtd/map.h> |
diff --git a/drivers/mtd/maps/omap_nor.c b/drivers/mtd/maps/omap_nor.c index fa84566245a7..7f370bb794fe 100644 --- a/drivers/mtd/maps/omap_nor.c +++ b/drivers/mtd/maps/omap_nor.c | |||
@@ -30,7 +30,7 @@ | |||
30 | * 675 Mass Ave, Cambridge, MA 02139, USA. | 30 | * 675 Mass Ave, Cambridge, MA 02139, USA. |
31 | */ | 31 | */ |
32 | 32 | ||
33 | #include <linux/device.h> | 33 | #include <linux/platform_device.h> |
34 | #include <linux/module.h> | 34 | #include <linux/module.h> |
35 | #include <linux/types.h> | 35 | #include <linux/types.h> |
36 | #include <linux/kernel.h> | 36 | #include <linux/kernel.h> |
diff --git a/drivers/mtd/maps/plat-ram.c b/drivers/mtd/maps/plat-ram.c index a0577ea00c3c..104576b5be34 100644 --- a/drivers/mtd/maps/plat-ram.c +++ b/drivers/mtd/maps/plat-ram.c | |||
@@ -31,6 +31,7 @@ | |||
31 | #include <linux/ioport.h> | 31 | #include <linux/ioport.h> |
32 | #include <linux/device.h> | 32 | #include <linux/device.h> |
33 | #include <linux/slab.h> | 33 | #include <linux/slab.h> |
34 | #include <linux/platform_device.h> | ||
34 | 35 | ||
35 | #include <linux/mtd/mtd.h> | 36 | #include <linux/mtd/mtd.h> |
36 | #include <linux/mtd/map.h> | 37 | #include <linux/mtd/map.h> |
diff --git a/drivers/mtd/maps/sa1100-flash.c b/drivers/mtd/maps/sa1100-flash.c index c81bec7b14d5..c8d0da19d897 100644 --- a/drivers/mtd/maps/sa1100-flash.c +++ b/drivers/mtd/maps/sa1100-flash.c | |||
@@ -13,7 +13,7 @@ | |||
13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
14 | #include <linux/errno.h> | 14 | #include <linux/errno.h> |
15 | #include <linux/slab.h> | 15 | #include <linux/slab.h> |
16 | #include <linux/device.h> | 16 | #include <linux/platform_device.h> |
17 | #include <linux/err.h> | 17 | #include <linux/err.h> |
18 | 18 | ||
19 | #include <linux/mtd/mtd.h> | 19 | #include <linux/mtd/mtd.h> |
diff --git a/drivers/mtd/nand/s3c2410.c b/drivers/mtd/nand/s3c2410.c index b58ba236a9eb..2df5e47d1f5c 100644 --- a/drivers/mtd/nand/s3c2410.c +++ b/drivers/mtd/nand/s3c2410.c | |||
@@ -48,7 +48,7 @@ | |||
48 | #include <linux/kernel.h> | 48 | #include <linux/kernel.h> |
49 | #include <linux/string.h> | 49 | #include <linux/string.h> |
50 | #include <linux/ioport.h> | 50 | #include <linux/ioport.h> |
51 | #include <linux/device.h> | 51 | #include <linux/platform_device.h> |
52 | #include <linux/delay.h> | 52 | #include <linux/delay.h> |
53 | #include <linux/err.h> | 53 | #include <linux/err.h> |
54 | #include <linux/slab.h> | 54 | #include <linux/slab.h> |
diff --git a/drivers/net/depca.c b/drivers/net/depca.c index c4aa5fe2840e..4d26e5e7d18b 100644 --- a/drivers/net/depca.c +++ b/drivers/net/depca.c | |||
@@ -254,7 +254,7 @@ | |||
254 | #include <linux/unistd.h> | 254 | #include <linux/unistd.h> |
255 | #include <linux/ctype.h> | 255 | #include <linux/ctype.h> |
256 | #include <linux/moduleparam.h> | 256 | #include <linux/moduleparam.h> |
257 | #include <linux/device.h> | 257 | #include <linux/platform_device.h> |
258 | #include <linux/bitops.h> | 258 | #include <linux/bitops.h> |
259 | 259 | ||
260 | #include <asm/uaccess.h> | 260 | #include <asm/uaccess.h> |
diff --git a/drivers/net/dm9000.c b/drivers/net/dm9000.c index abce1f730d00..c0af6fb1fbba 100644 --- a/drivers/net/dm9000.c +++ b/drivers/net/dm9000.c | |||
@@ -66,6 +66,7 @@ | |||
66 | #include <linux/mii.h> | 66 | #include <linux/mii.h> |
67 | #include <linux/dm9000.h> | 67 | #include <linux/dm9000.h> |
68 | #include <linux/delay.h> | 68 | #include <linux/delay.h> |
69 | #include <linux/platform_device.h> | ||
69 | 70 | ||
70 | #include <asm/delay.h> | 71 | #include <asm/delay.h> |
71 | #include <asm/irq.h> | 72 | #include <asm/irq.h> |
diff --git a/drivers/net/gianfar.c b/drivers/net/gianfar.c index ae5a2ed3b264..962580f2c4ab 100644 --- a/drivers/net/gianfar.c +++ b/drivers/net/gianfar.c | |||
@@ -81,7 +81,7 @@ | |||
81 | #include <linux/if_vlan.h> | 81 | #include <linux/if_vlan.h> |
82 | #include <linux/spinlock.h> | 82 | #include <linux/spinlock.h> |
83 | #include <linux/mm.h> | 83 | #include <linux/mm.h> |
84 | #include <linux/device.h> | 84 | #include <linux/platform_device.h> |
85 | #include <linux/ip.h> | 85 | #include <linux/ip.h> |
86 | #include <linux/tcp.h> | 86 | #include <linux/tcp.h> |
87 | #include <linux/udp.h> | 87 | #include <linux/udp.h> |
diff --git a/drivers/net/gianfar_mii.c b/drivers/net/gianfar_mii.c index 1eca1dbca7f1..5a74d3d3dbe1 100644 --- a/drivers/net/gianfar_mii.c +++ b/drivers/net/gianfar_mii.c | |||
@@ -33,6 +33,7 @@ | |||
33 | #include <linux/mm.h> | 33 | #include <linux/mm.h> |
34 | #include <linux/module.h> | 34 | #include <linux/module.h> |
35 | #include <linux/version.h> | 35 | #include <linux/version.h> |
36 | #include <linux/platform_device.h> | ||
36 | #include <asm/ocp.h> | 37 | #include <asm/ocp.h> |
37 | #include <linux/crc32.h> | 38 | #include <linux/crc32.h> |
38 | #include <linux/mii.h> | 39 | #include <linux/mii.h> |
diff --git a/drivers/net/irda/pxaficp_ir.c b/drivers/net/irda/pxaficp_ir.c index b886b07412a6..e1aa9910503b 100644 --- a/drivers/net/irda/pxaficp_ir.c +++ b/drivers/net/irda/pxaficp_ir.c | |||
@@ -22,6 +22,7 @@ | |||
22 | #include <linux/rtnetlink.h> | 22 | #include <linux/rtnetlink.h> |
23 | #include <linux/interrupt.h> | 23 | #include <linux/interrupt.h> |
24 | #include <linux/dma-mapping.h> | 24 | #include <linux/dma-mapping.h> |
25 | #include <linux/platform_device.h> | ||
25 | #include <linux/pm.h> | 26 | #include <linux/pm.h> |
26 | 27 | ||
27 | #include <net/irda/irda.h> | 28 | #include <net/irda/irda.h> |
diff --git a/drivers/net/irda/sa1100_ir.c b/drivers/net/irda/sa1100_ir.c index 06883309916d..76e0b9fb5e96 100644 --- a/drivers/net/irda/sa1100_ir.c +++ b/drivers/net/irda/sa1100_ir.c | |||
@@ -29,7 +29,7 @@ | |||
29 | #include <linux/rtnetlink.h> | 29 | #include <linux/rtnetlink.h> |
30 | #include <linux/interrupt.h> | 30 | #include <linux/interrupt.h> |
31 | #include <linux/delay.h> | 31 | #include <linux/delay.h> |
32 | #include <linux/device.h> | 32 | #include <linux/platform_device.h> |
33 | #include <linux/dma-mapping.h> | 33 | #include <linux/dma-mapping.h> |
34 | 34 | ||
35 | #include <net/irda/irda.h> | 35 | #include <net/irda/irda.h> |
diff --git a/drivers/net/irda/smsc-ircc2.c b/drivers/net/irda/smsc-ircc2.c index 140b7cdb1f7e..a1d207f2fa68 100644 --- a/drivers/net/irda/smsc-ircc2.c +++ b/drivers/net/irda/smsc-ircc2.c | |||
@@ -53,6 +53,7 @@ | |||
53 | #include <linux/rtnetlink.h> | 53 | #include <linux/rtnetlink.h> |
54 | #include <linux/serial_reg.h> | 54 | #include <linux/serial_reg.h> |
55 | #include <linux/dma-mapping.h> | 55 | #include <linux/dma-mapping.h> |
56 | #include <linux/platform_device.h> | ||
56 | 57 | ||
57 | #include <asm/io.h> | 58 | #include <asm/io.h> |
58 | #include <asm/dma.h> | 59 | #include <asm/dma.h> |
diff --git a/drivers/net/jazzsonic.c b/drivers/net/jazzsonic.c index 8423cb6875f0..a74a5cfaf5bc 100644 --- a/drivers/net/jazzsonic.c +++ b/drivers/net/jazzsonic.c | |||
@@ -33,7 +33,7 @@ | |||
33 | #include <linux/netdevice.h> | 33 | #include <linux/netdevice.h> |
34 | #include <linux/etherdevice.h> | 34 | #include <linux/etherdevice.h> |
35 | #include <linux/skbuff.h> | 35 | #include <linux/skbuff.h> |
36 | #include <linux/device.h> | 36 | #include <linux/platform_device.h> |
37 | #include <linux/dma-mapping.h> | 37 | #include <linux/dma-mapping.h> |
38 | 38 | ||
39 | #include <asm/bootinfo.h> | 39 | #include <asm/bootinfo.h> |
diff --git a/drivers/net/macsonic.c b/drivers/net/macsonic.c index 405e18365ede..e9c999d7eb39 100644 --- a/drivers/net/macsonic.c +++ b/drivers/net/macsonic.c | |||
@@ -47,7 +47,7 @@ | |||
47 | #include <linux/netdevice.h> | 47 | #include <linux/netdevice.h> |
48 | #include <linux/etherdevice.h> | 48 | #include <linux/etherdevice.h> |
49 | #include <linux/skbuff.h> | 49 | #include <linux/skbuff.h> |
50 | #include <linux/device.h> | 50 | #include <linux/platform_device.h> |
51 | #include <linux/dma-mapping.h> | 51 | #include <linux/dma-mapping.h> |
52 | 52 | ||
53 | #include <asm/bootinfo.h> | 53 | #include <asm/bootinfo.h> |
diff --git a/drivers/net/mipsnet.c b/drivers/net/mipsnet.c index f79f7ee72ab8..bbffb585b3b3 100644 --- a/drivers/net/mipsnet.c +++ b/drivers/net/mipsnet.c | |||
@@ -13,6 +13,7 @@ | |||
13 | #include <linux/sched.h> | 13 | #include <linux/sched.h> |
14 | #include <linux/etherdevice.h> | 14 | #include <linux/etherdevice.h> |
15 | #include <linux/netdevice.h> | 15 | #include <linux/netdevice.h> |
16 | #include <linux/platform_device.h> | ||
16 | #include <asm/io.h> | 17 | #include <asm/io.h> |
17 | #include <asm/mips-boards/simint.h> | 18 | #include <asm/mips-boards/simint.h> |
18 | 19 | ||
diff --git a/drivers/net/mv643xx_eth.c b/drivers/net/mv643xx_eth.c index 8fbba21d975b..71f2c6705bc3 100644 --- a/drivers/net/mv643xx_eth.c +++ b/drivers/net/mv643xx_eth.c | |||
@@ -39,6 +39,8 @@ | |||
39 | #include <linux/bitops.h> | 39 | #include <linux/bitops.h> |
40 | #include <linux/delay.h> | 40 | #include <linux/delay.h> |
41 | #include <linux/ethtool.h> | 41 | #include <linux/ethtool.h> |
42 | #include <linux/platform_device.h> | ||
43 | |||
42 | #include <asm/io.h> | 44 | #include <asm/io.h> |
43 | #include <asm/types.h> | 45 | #include <asm/types.h> |
44 | #include <asm/pgtable.h> | 46 | #include <asm/pgtable.h> |
diff --git a/drivers/net/smc91x.c b/drivers/net/smc91x.c index c573bb351d4c..74d5f1a6fdea 100644 --- a/drivers/net/smc91x.c +++ b/drivers/net/smc91x.c | |||
@@ -77,7 +77,7 @@ static const char version[] = | |||
77 | #include <linux/errno.h> | 77 | #include <linux/errno.h> |
78 | #include <linux/ioport.h> | 78 | #include <linux/ioport.h> |
79 | #include <linux/crc32.h> | 79 | #include <linux/crc32.h> |
80 | #include <linux/device.h> | 80 | #include <linux/platform_device.h> |
81 | #include <linux/spinlock.h> | 81 | #include <linux/spinlock.h> |
82 | #include <linux/ethtool.h> | 82 | #include <linux/ethtool.h> |
83 | #include <linux/mii.h> | 83 | #include <linux/mii.h> |
diff --git a/drivers/net/tokenring/proteon.c b/drivers/net/tokenring/proteon.c index eb1423ede75c..d04c918ebef8 100644 --- a/drivers/net/tokenring/proteon.c +++ b/drivers/net/tokenring/proteon.c | |||
@@ -29,6 +29,7 @@ static const char version[] = "proteon.c: v1.00 02/01/2003 by Jochen Friedrich\n | |||
29 | #include <linux/init.h> | 29 | #include <linux/init.h> |
30 | #include <linux/netdevice.h> | 30 | #include <linux/netdevice.h> |
31 | #include <linux/trdevice.h> | 31 | #include <linux/trdevice.h> |
32 | #include <linux/platform_device.h> | ||
32 | 33 | ||
33 | #include <asm/system.h> | 34 | #include <asm/system.h> |
34 | #include <asm/io.h> | 35 | #include <asm/io.h> |
diff --git a/drivers/net/tokenring/skisa.c b/drivers/net/tokenring/skisa.c index 3c7c66204f74..72cf708396be 100644 --- a/drivers/net/tokenring/skisa.c +++ b/drivers/net/tokenring/skisa.c | |||
@@ -36,6 +36,7 @@ static const char version[] = "skisa.c: v1.03 09/12/2002 by Jochen Friedrich\n"; | |||
36 | #include <linux/init.h> | 36 | #include <linux/init.h> |
37 | #include <linux/netdevice.h> | 37 | #include <linux/netdevice.h> |
38 | #include <linux/trdevice.h> | 38 | #include <linux/trdevice.h> |
39 | #include <linux/platform_device.h> | ||
39 | 40 | ||
40 | #include <asm/system.h> | 41 | #include <asm/system.h> |
41 | #include <asm/io.h> | 42 | #include <asm/io.h> |
diff --git a/drivers/pcmcia/au1000_generic.c b/drivers/pcmcia/au1000_generic.c index ba48cef3a9dc..87302c548c24 100644 --- a/drivers/pcmcia/au1000_generic.c +++ b/drivers/pcmcia/au1000_generic.c | |||
@@ -42,7 +42,7 @@ | |||
42 | #include <linux/notifier.h> | 42 | #include <linux/notifier.h> |
43 | #include <linux/interrupt.h> | 43 | #include <linux/interrupt.h> |
44 | #include <linux/spinlock.h> | 44 | #include <linux/spinlock.h> |
45 | #include <linux/device.h> | 45 | #include <linux/platform_device.h> |
46 | 46 | ||
47 | #include <asm/io.h> | 47 | #include <asm/io.h> |
48 | #include <asm/irq.h> | 48 | #include <asm/irq.h> |
diff --git a/drivers/pcmcia/hd64465_ss.c b/drivers/pcmcia/hd64465_ss.c index b57a0b98b4d6..561706ba4499 100644 --- a/drivers/pcmcia/hd64465_ss.c +++ b/drivers/pcmcia/hd64465_ss.c | |||
@@ -37,7 +37,7 @@ | |||
37 | #include <asm/errno.h> | 37 | #include <asm/errno.h> |
38 | #include <linux/irq.h> | 38 | #include <linux/irq.h> |
39 | #include <linux/interrupt.h> | 39 | #include <linux/interrupt.h> |
40 | #include <linux/device.h> | 40 | #include <linux/platform_device.h> |
41 | 41 | ||
42 | #include <asm/io.h> | 42 | #include <asm/io.h> |
43 | #include <asm/hd64465/hd64465.h> | 43 | #include <asm/hd64465/hd64465.h> |
diff --git a/drivers/pcmcia/i82365.c b/drivers/pcmcia/i82365.c index 4a41f67d185d..7ce455d01cc9 100644 --- a/drivers/pcmcia/i82365.c +++ b/drivers/pcmcia/i82365.c | |||
@@ -47,7 +47,7 @@ | |||
47 | #include <linux/delay.h> | 47 | #include <linux/delay.h> |
48 | #include <linux/workqueue.h> | 48 | #include <linux/workqueue.h> |
49 | #include <linux/interrupt.h> | 49 | #include <linux/interrupt.h> |
50 | #include <linux/device.h> | 50 | #include <linux/platform_device.h> |
51 | #include <linux/bitops.h> | 51 | #include <linux/bitops.h> |
52 | #include <asm/irq.h> | 52 | #include <asm/irq.h> |
53 | #include <asm/io.h> | 53 | #include <asm/io.h> |
diff --git a/drivers/pcmcia/m32r_cfc.c b/drivers/pcmcia/m32r_cfc.c index c6ed70ea4812..2c22b4b3619d 100644 --- a/drivers/pcmcia/m32r_cfc.c +++ b/drivers/pcmcia/m32r_cfc.c | |||
@@ -23,7 +23,7 @@ | |||
23 | #include <linux/delay.h> | 23 | #include <linux/delay.h> |
24 | #include <linux/workqueue.h> | 24 | #include <linux/workqueue.h> |
25 | #include <linux/interrupt.h> | 25 | #include <linux/interrupt.h> |
26 | #include <linux/device.h> | 26 | #include <linux/platform_device.h> |
27 | #include <linux/bitops.h> | 27 | #include <linux/bitops.h> |
28 | #include <asm/irq.h> | 28 | #include <asm/irq.h> |
29 | #include <asm/io.h> | 29 | #include <asm/io.h> |
diff --git a/drivers/pcmcia/m32r_pcc.c b/drivers/pcmcia/m32r_pcc.c index 3397ff28de6a..356a6fb416a1 100644 --- a/drivers/pcmcia/m32r_pcc.c +++ b/drivers/pcmcia/m32r_pcc.c | |||
@@ -23,7 +23,7 @@ | |||
23 | #include <linux/delay.h> | 23 | #include <linux/delay.h> |
24 | #include <linux/workqueue.h> | 24 | #include <linux/workqueue.h> |
25 | #include <linux/interrupt.h> | 25 | #include <linux/interrupt.h> |
26 | #include <linux/device.h> | 26 | #include <linux/platform_device.h> |
27 | #include <asm/irq.h> | 27 | #include <asm/irq.h> |
28 | #include <asm/io.h> | 28 | #include <asm/io.h> |
29 | #include <asm/bitops.h> | 29 | #include <asm/bitops.h> |
diff --git a/drivers/pcmcia/omap_cf.c b/drivers/pcmcia/omap_cf.c index 2558c3cc91ec..47b5ade95bde 100644 --- a/drivers/pcmcia/omap_cf.c +++ b/drivers/pcmcia/omap_cf.c | |||
@@ -12,7 +12,7 @@ | |||
12 | #include <linux/module.h> | 12 | #include <linux/module.h> |
13 | #include <linux/kernel.h> | 13 | #include <linux/kernel.h> |
14 | #include <linux/sched.h> | 14 | #include <linux/sched.h> |
15 | #include <linux/device.h> | 15 | #include <linux/platform_device.h> |
16 | #include <linux/errno.h> | 16 | #include <linux/errno.h> |
17 | #include <linux/init.h> | 17 | #include <linux/init.h> |
18 | #include <linux/delay.h> | 18 | #include <linux/delay.h> |
diff --git a/drivers/pcmcia/pxa2xx_base.c b/drivers/pcmcia/pxa2xx_base.c index c2a12d53f6c7..7fa18fb814bc 100644 --- a/drivers/pcmcia/pxa2xx_base.c +++ b/drivers/pcmcia/pxa2xx_base.c | |||
@@ -23,6 +23,7 @@ | |||
23 | #include <linux/ioport.h> | 23 | #include <linux/ioport.h> |
24 | #include <linux/kernel.h> | 24 | #include <linux/kernel.h> |
25 | #include <linux/spinlock.h> | 25 | #include <linux/spinlock.h> |
26 | #include <linux/platform_device.h> | ||
26 | 27 | ||
27 | #include <asm/hardware.h> | 28 | #include <asm/hardware.h> |
28 | #include <asm/io.h> | 29 | #include <asm/io.h> |
diff --git a/drivers/pcmcia/pxa2xx_mainstone.c b/drivers/pcmcia/pxa2xx_mainstone.c index bbe69b07ce50..5209d8c7764f 100644 --- a/drivers/pcmcia/pxa2xx_mainstone.c +++ b/drivers/pcmcia/pxa2xx_mainstone.c | |||
@@ -17,7 +17,7 @@ | |||
17 | #include <linux/kernel.h> | 17 | #include <linux/kernel.h> |
18 | #include <linux/errno.h> | 18 | #include <linux/errno.h> |
19 | #include <linux/interrupt.h> | 19 | #include <linux/interrupt.h> |
20 | #include <linux/device.h> | 20 | #include <linux/platform_device.h> |
21 | 21 | ||
22 | #include <pcmcia/ss.h> | 22 | #include <pcmcia/ss.h> |
23 | 23 | ||
diff --git a/drivers/pcmcia/pxa2xx_sharpsl.c b/drivers/pcmcia/pxa2xx_sharpsl.c index bd924336a49f..fe5ea36e7de3 100644 --- a/drivers/pcmcia/pxa2xx_sharpsl.c +++ b/drivers/pcmcia/pxa2xx_sharpsl.c | |||
@@ -16,7 +16,7 @@ | |||
16 | #include <linux/kernel.h> | 16 | #include <linux/kernel.h> |
17 | #include <linux/errno.h> | 17 | #include <linux/errno.h> |
18 | #include <linux/interrupt.h> | 18 | #include <linux/interrupt.h> |
19 | #include <linux/device.h> | 19 | #include <linux/platform_device.h> |
20 | 20 | ||
21 | #include <asm/mach-types.h> | 21 | #include <asm/mach-types.h> |
22 | #include <asm/hardware.h> | 22 | #include <asm/hardware.h> |
diff --git a/drivers/pcmcia/sa1100_generic.c b/drivers/pcmcia/sa1100_generic.c index acf60ffc8a12..6d441ec75c6a 100644 --- a/drivers/pcmcia/sa1100_generic.c +++ b/drivers/pcmcia/sa1100_generic.c | |||
@@ -33,6 +33,7 @@ | |||
33 | #include <linux/module.h> | 33 | #include <linux/module.h> |
34 | #include <linux/init.h> | 34 | #include <linux/init.h> |
35 | #include <linux/config.h> | 35 | #include <linux/config.h> |
36 | #include <linux/platform_device.h> | ||
36 | 37 | ||
37 | #include <pcmcia/cs_types.h> | 38 | #include <pcmcia/cs_types.h> |
38 | #include <pcmcia/cs.h> | 39 | #include <pcmcia/cs.h> |
diff --git a/drivers/pcmcia/tcic.c b/drivers/pcmcia/tcic.c index f158b67f6610..e31263864377 100644 --- a/drivers/pcmcia/tcic.c +++ b/drivers/pcmcia/tcic.c | |||
@@ -44,7 +44,7 @@ | |||
44 | #include <linux/ioport.h> | 44 | #include <linux/ioport.h> |
45 | #include <linux/delay.h> | 45 | #include <linux/delay.h> |
46 | #include <linux/workqueue.h> | 46 | #include <linux/workqueue.h> |
47 | #include <linux/device.h> | 47 | #include <linux/platform_device.h> |
48 | #include <linux/bitops.h> | 48 | #include <linux/bitops.h> |
49 | 49 | ||
50 | #include <asm/io.h> | 50 | #include <asm/io.h> |
diff --git a/drivers/pcmcia/vrc4171_card.c b/drivers/pcmcia/vrc4171_card.c index 3d2dca675e02..38a028c725d4 100644 --- a/drivers/pcmcia/vrc4171_card.c +++ b/drivers/pcmcia/vrc4171_card.c | |||
@@ -24,6 +24,7 @@ | |||
24 | #include <linux/spinlock.h> | 24 | #include <linux/spinlock.h> |
25 | #include <linux/sched.h> | 25 | #include <linux/sched.h> |
26 | #include <linux/types.h> | 26 | #include <linux/types.h> |
27 | #include <linux/platform_device.h> | ||
27 | 28 | ||
28 | #include <asm/io.h> | 29 | #include <asm/io.h> |
29 | 30 | ||
diff --git a/drivers/scsi/hosts.c b/drivers/scsi/hosts.c index f24d84538fd5..71dd1ebbe58f 100644 --- a/drivers/scsi/hosts.c +++ b/drivers/scsi/hosts.c | |||
@@ -30,6 +30,7 @@ | |||
30 | #include <linux/init.h> | 30 | #include <linux/init.h> |
31 | #include <linux/completion.h> | 31 | #include <linux/completion.h> |
32 | #include <linux/transport_class.h> | 32 | #include <linux/transport_class.h> |
33 | #include <linux/platform_device.h> | ||
33 | 34 | ||
34 | #include <scsi/scsi_device.h> | 35 | #include <scsi/scsi_device.h> |
35 | #include <scsi/scsi_host.h> | 36 | #include <scsi/scsi_host.h> |
diff --git a/drivers/scsi/ide-scsi.c b/drivers/scsi/ide-scsi.c index 00d6a6657ebc..a440ea38efaa 100644 --- a/drivers/scsi/ide-scsi.c +++ b/drivers/scsi/ide-scsi.c | |||
@@ -180,12 +180,22 @@ static void idescsi_input_buffers (ide_drive_t *drive, idescsi_pc_t *pc, unsigne | |||
180 | return; | 180 | return; |
181 | } | 181 | } |
182 | count = min(pc->sg->length - pc->b_count, bcount); | 182 | count = min(pc->sg->length - pc->b_count, bcount); |
183 | buf = kmap_atomic(pc->sg->page, KM_IRQ0); | 183 | if (PageHighMem(pc->sg->page)) { |
184 | drive->hwif->atapi_input_bytes(drive, | 184 | unsigned long flags; |
185 | buf + pc->b_count + pc->sg->offset, count); | 185 | |
186 | kunmap_atomic(buf, KM_IRQ0); | 186 | local_irq_save(flags); |
187 | bcount -= count; | 187 | buf = kmap_atomic(pc->sg->page, KM_IRQ0) + |
188 | pc->b_count += count; | 188 | pc->sg->offset; |
189 | drive->hwif->atapi_input_bytes(drive, | ||
190 | buf + pc->b_count, count); | ||
191 | kunmap_atomic(buf - pc->sg->offset, KM_IRQ0); | ||
192 | local_irq_restore(flags); | ||
193 | } else { | ||
194 | buf = page_address(pc->sg->page) + pc->sg->offset; | ||
195 | drive->hwif->atapi_input_bytes(drive, | ||
196 | buf + pc->b_count, count); | ||
197 | } | ||
198 | bcount -= count; pc->b_count += count; | ||
189 | if (pc->b_count == pc->sg->length) { | 199 | if (pc->b_count == pc->sg->length) { |
190 | pc->sg++; | 200 | pc->sg++; |
191 | pc->b_count = 0; | 201 | pc->b_count = 0; |
@@ -205,12 +215,22 @@ static void idescsi_output_buffers (ide_drive_t *drive, idescsi_pc_t *pc, unsign | |||
205 | return; | 215 | return; |
206 | } | 216 | } |
207 | count = min(pc->sg->length - pc->b_count, bcount); | 217 | count = min(pc->sg->length - pc->b_count, bcount); |
208 | buf = kmap_atomic(pc->sg->page, KM_IRQ0); | 218 | if (PageHighMem(pc->sg->page)) { |
209 | drive->hwif->atapi_output_bytes(drive, | 219 | unsigned long flags; |
210 | buf + pc->b_count + pc->sg->offset, count); | 220 | |
211 | kunmap_atomic(buf, KM_IRQ0); | 221 | local_irq_save(flags); |
212 | bcount -= count; | 222 | buf = kmap_atomic(pc->sg->page, KM_IRQ0) + |
213 | pc->b_count += count; | 223 | pc->sg->offset; |
224 | drive->hwif->atapi_output_bytes(drive, | ||
225 | buf + pc->b_count, count); | ||
226 | kunmap_atomic(buf - pc->sg->offset, KM_IRQ0); | ||
227 | local_irq_restore(flags); | ||
228 | } else { | ||
229 | buf = page_address(pc->sg->page) + pc->sg->offset; | ||
230 | drive->hwif->atapi_output_bytes(drive, | ||
231 | buf + pc->b_count, count); | ||
232 | } | ||
233 | bcount -= count; pc->b_count += count; | ||
214 | if (pc->b_count == pc->sg->length) { | 234 | if (pc->b_count == pc->sg->length) { |
215 | pc->sg++; | 235 | pc->sg++; |
216 | pc->b_count = 0; | 236 | pc->b_count = 0; |
diff --git a/drivers/scsi/libata-core.c b/drivers/scsi/libata-core.c index 8be7dc0b47b8..ff18fa7044c5 100644 --- a/drivers/scsi/libata-core.c +++ b/drivers/scsi/libata-core.c | |||
@@ -295,28 +295,6 @@ void ata_exec_command(struct ata_port *ap, const struct ata_taskfile *tf) | |||
295 | } | 295 | } |
296 | 296 | ||
297 | /** | 297 | /** |
298 | * ata_exec - issue ATA command to host controller | ||
299 | * @ap: port to which command is being issued | ||
300 | * @tf: ATA taskfile register set | ||
301 | * | ||
302 | * Issues PIO/MMIO write to ATA command register, with proper | ||
303 | * synchronization with interrupt handler / other threads. | ||
304 | * | ||
305 | * LOCKING: | ||
306 | * Obtains host_set lock. | ||
307 | */ | ||
308 | |||
309 | static inline void ata_exec(struct ata_port *ap, const struct ata_taskfile *tf) | ||
310 | { | ||
311 | unsigned long flags; | ||
312 | |||
313 | DPRINTK("ata%u: cmd 0x%X\n", ap->id, tf->command); | ||
314 | spin_lock_irqsave(&ap->host_set->lock, flags); | ||
315 | ap->ops->exec_command(ap, tf); | ||
316 | spin_unlock_irqrestore(&ap->host_set->lock, flags); | ||
317 | } | ||
318 | |||
319 | /** | ||
320 | * ata_tf_to_host - issue ATA taskfile to host controller | 298 | * ata_tf_to_host - issue ATA taskfile to host controller |
321 | * @ap: port to which command is being issued | 299 | * @ap: port to which command is being issued |
322 | * @tf: ATA taskfile register set | 300 | * @tf: ATA taskfile register set |
@@ -326,30 +304,11 @@ static inline void ata_exec(struct ata_port *ap, const struct ata_taskfile *tf) | |||
326 | * other threads. | 304 | * other threads. |
327 | * | 305 | * |
328 | * LOCKING: | 306 | * LOCKING: |
329 | * Obtains host_set lock. | ||
330 | */ | ||
331 | |||
332 | static void ata_tf_to_host(struct ata_port *ap, const struct ata_taskfile *tf) | ||
333 | { | ||
334 | ap->ops->tf_load(ap, tf); | ||
335 | |||
336 | ata_exec(ap, tf); | ||
337 | } | ||
338 | |||
339 | /** | ||
340 | * ata_tf_to_host_nolock - issue ATA taskfile to host controller | ||
341 | * @ap: port to which command is being issued | ||
342 | * @tf: ATA taskfile register set | ||
343 | * | ||
344 | * Issues ATA taskfile register set to ATA host controller, | ||
345 | * with proper synchronization with interrupt handler and | ||
346 | * other threads. | ||
347 | * | ||
348 | * LOCKING: | ||
349 | * spin_lock_irqsave(host_set lock) | 307 | * spin_lock_irqsave(host_set lock) |
350 | */ | 308 | */ |
351 | 309 | ||
352 | void ata_tf_to_host_nolock(struct ata_port *ap, const struct ata_taskfile *tf) | 310 | static inline void ata_tf_to_host(struct ata_port *ap, |
311 | const struct ata_taskfile *tf) | ||
353 | { | 312 | { |
354 | ap->ops->tf_load(ap, tf); | 313 | ap->ops->tf_load(ap, tf); |
355 | ap->ops->exec_command(ap, tf); | 314 | ap->ops->exec_command(ap, tf); |
@@ -1912,12 +1871,14 @@ static void ata_bus_post_reset(struct ata_port *ap, unsigned int devmask) | |||
1912 | * | 1871 | * |
1913 | * LOCKING: | 1872 | * LOCKING: |
1914 | * PCI/etc. bus probe sem. | 1873 | * PCI/etc. bus probe sem. |
1874 | * Obtains host_set lock. | ||
1915 | * | 1875 | * |
1916 | */ | 1876 | */ |
1917 | 1877 | ||
1918 | static unsigned int ata_bus_edd(struct ata_port *ap) | 1878 | static unsigned int ata_bus_edd(struct ata_port *ap) |
1919 | { | 1879 | { |
1920 | struct ata_taskfile tf; | 1880 | struct ata_taskfile tf; |
1881 | unsigned long flags; | ||
1921 | 1882 | ||
1922 | /* set up execute-device-diag (bus reset) taskfile */ | 1883 | /* set up execute-device-diag (bus reset) taskfile */ |
1923 | /* also, take interrupts to a known state (disabled) */ | 1884 | /* also, take interrupts to a known state (disabled) */ |
@@ -1928,7 +1889,9 @@ static unsigned int ata_bus_edd(struct ata_port *ap) | |||
1928 | tf.protocol = ATA_PROT_NODATA; | 1889 | tf.protocol = ATA_PROT_NODATA; |
1929 | 1890 | ||
1930 | /* do bus reset */ | 1891 | /* do bus reset */ |
1892 | spin_lock_irqsave(&ap->host_set->lock, flags); | ||
1931 | ata_tf_to_host(ap, &tf); | 1893 | ata_tf_to_host(ap, &tf); |
1894 | spin_unlock_irqrestore(&ap->host_set->lock, flags); | ||
1932 | 1895 | ||
1933 | /* spec says at least 2ms. but who knows with those | 1896 | /* spec says at least 2ms. but who knows with those |
1934 | * crazy ATAPI devices... | 1897 | * crazy ATAPI devices... |
@@ -3555,7 +3518,7 @@ int ata_qc_issue_prot(struct ata_queued_cmd *qc) | |||
3555 | 3518 | ||
3556 | switch (qc->tf.protocol) { | 3519 | switch (qc->tf.protocol) { |
3557 | case ATA_PROT_NODATA: | 3520 | case ATA_PROT_NODATA: |
3558 | ata_tf_to_host_nolock(ap, &qc->tf); | 3521 | ata_tf_to_host(ap, &qc->tf); |
3559 | break; | 3522 | break; |
3560 | 3523 | ||
3561 | case ATA_PROT_DMA: | 3524 | case ATA_PROT_DMA: |
@@ -3566,20 +3529,20 @@ int ata_qc_issue_prot(struct ata_queued_cmd *qc) | |||
3566 | 3529 | ||
3567 | case ATA_PROT_PIO: /* load tf registers, initiate polling pio */ | 3530 | case ATA_PROT_PIO: /* load tf registers, initiate polling pio */ |
3568 | ata_qc_set_polling(qc); | 3531 | ata_qc_set_polling(qc); |
3569 | ata_tf_to_host_nolock(ap, &qc->tf); | 3532 | ata_tf_to_host(ap, &qc->tf); |
3570 | ap->hsm_task_state = HSM_ST; | 3533 | ap->hsm_task_state = HSM_ST; |
3571 | queue_work(ata_wq, &ap->pio_task); | 3534 | queue_work(ata_wq, &ap->pio_task); |
3572 | break; | 3535 | break; |
3573 | 3536 | ||
3574 | case ATA_PROT_ATAPI: | 3537 | case ATA_PROT_ATAPI: |
3575 | ata_qc_set_polling(qc); | 3538 | ata_qc_set_polling(qc); |
3576 | ata_tf_to_host_nolock(ap, &qc->tf); | 3539 | ata_tf_to_host(ap, &qc->tf); |
3577 | queue_work(ata_wq, &ap->packet_task); | 3540 | queue_work(ata_wq, &ap->packet_task); |
3578 | break; | 3541 | break; |
3579 | 3542 | ||
3580 | case ATA_PROT_ATAPI_NODATA: | 3543 | case ATA_PROT_ATAPI_NODATA: |
3581 | ap->flags |= ATA_FLAG_NOINTR; | 3544 | ap->flags |= ATA_FLAG_NOINTR; |
3582 | ata_tf_to_host_nolock(ap, &qc->tf); | 3545 | ata_tf_to_host(ap, &qc->tf); |
3583 | queue_work(ata_wq, &ap->packet_task); | 3546 | queue_work(ata_wq, &ap->packet_task); |
3584 | break; | 3547 | break; |
3585 | 3548 | ||
@@ -4126,8 +4089,6 @@ static void ata_host_init(struct ata_port *ap, struct Scsi_Host *host, | |||
4126 | host->unique_id = ata_unique_id++; | 4089 | host->unique_id = ata_unique_id++; |
4127 | host->max_cmd_len = 12; | 4090 | host->max_cmd_len = 12; |
4128 | 4091 | ||
4129 | scsi_assign_lock(host, &host_set->lock); | ||
4130 | |||
4131 | ap->flags = ATA_FLAG_PORT_DISABLED; | 4092 | ap->flags = ATA_FLAG_PORT_DISABLED; |
4132 | ap->id = host->unique_id; | 4093 | ap->id = host->unique_id; |
4133 | ap->host = host; | 4094 | ap->host = host; |
diff --git a/drivers/scsi/libata-scsi.c b/drivers/scsi/libata-scsi.c index 1e3792f86fcf..248baae96486 100644 --- a/drivers/scsi/libata-scsi.c +++ b/drivers/scsi/libata-scsi.c | |||
@@ -39,6 +39,7 @@ | |||
39 | #include <scsi/scsi.h> | 39 | #include <scsi/scsi.h> |
40 | #include "scsi.h" | 40 | #include "scsi.h" |
41 | #include <scsi/scsi_host.h> | 41 | #include <scsi/scsi_host.h> |
42 | #include <scsi/scsi_device.h> | ||
42 | #include <linux/libata.h> | 43 | #include <linux/libata.h> |
43 | #include <linux/hdreg.h> | 44 | #include <linux/hdreg.h> |
44 | #include <asm/uaccess.h> | 45 | #include <asm/uaccess.h> |
@@ -2405,8 +2406,12 @@ int ata_scsi_queuecmd(struct scsi_cmnd *cmd, void (*done)(struct scsi_cmnd *)) | |||
2405 | struct ata_port *ap; | 2406 | struct ata_port *ap; |
2406 | struct ata_device *dev; | 2407 | struct ata_device *dev; |
2407 | struct scsi_device *scsidev = cmd->device; | 2408 | struct scsi_device *scsidev = cmd->device; |
2409 | struct Scsi_Host *shost = scsidev->host; | ||
2408 | 2410 | ||
2409 | ap = (struct ata_port *) &scsidev->host->hostdata[0]; | 2411 | ap = (struct ata_port *) &shost->hostdata[0]; |
2412 | |||
2413 | spin_unlock(shost->host_lock); | ||
2414 | spin_lock(&ap->host_set->lock); | ||
2410 | 2415 | ||
2411 | ata_scsi_dump_cdb(ap, cmd); | 2416 | ata_scsi_dump_cdb(ap, cmd); |
2412 | 2417 | ||
@@ -2429,6 +2434,8 @@ int ata_scsi_queuecmd(struct scsi_cmnd *cmd, void (*done)(struct scsi_cmnd *)) | |||
2429 | ata_scsi_translate(ap, dev, cmd, done, atapi_xlat); | 2434 | ata_scsi_translate(ap, dev, cmd, done, atapi_xlat); |
2430 | 2435 | ||
2431 | out_unlock: | 2436 | out_unlock: |
2437 | spin_unlock(&ap->host_set->lock); | ||
2438 | spin_lock(shost->host_lock); | ||
2432 | return 0; | 2439 | return 0; |
2433 | } | 2440 | } |
2434 | 2441 | ||
diff --git a/drivers/scsi/libata.h b/drivers/scsi/libata.h index 10ecd9e15e4f..fad051ca4672 100644 --- a/drivers/scsi/libata.h +++ b/drivers/scsi/libata.h | |||
@@ -48,7 +48,6 @@ extern int ata_qc_issue(struct ata_queued_cmd *qc); | |||
48 | extern int ata_check_atapi_dma(struct ata_queued_cmd *qc); | 48 | extern int ata_check_atapi_dma(struct ata_queued_cmd *qc); |
49 | extern void ata_dev_select(struct ata_port *ap, unsigned int device, | 49 | extern void ata_dev_select(struct ata_port *ap, unsigned int device, |
50 | unsigned int wait, unsigned int can_sleep); | 50 | unsigned int wait, unsigned int can_sleep); |
51 | extern void ata_tf_to_host_nolock(struct ata_port *ap, const struct ata_taskfile *tf); | ||
52 | extern void swap_buf_le16(u16 *buf, unsigned int buf_words); | 51 | extern void swap_buf_le16(u16 *buf, unsigned int buf_words); |
53 | extern int ata_task_ioctl(struct scsi_device *scsidev, void __user *arg); | 52 | extern int ata_task_ioctl(struct scsi_device *scsidev, void __user *arg); |
54 | extern int ata_cmd_ioctl(struct scsi_device *scsidev, void __user *arg); | 53 | extern int ata_cmd_ioctl(struct scsi_device *scsidev, void __user *arg); |
diff --git a/drivers/serial/8250.c b/drivers/serial/8250.c index afb7ddf200e0..f47d2c454e33 100644 --- a/drivers/serial/8250.c +++ b/drivers/serial/8250.c | |||
@@ -33,7 +33,7 @@ | |||
33 | #include <linux/sysrq.h> | 33 | #include <linux/sysrq.h> |
34 | #include <linux/mca.h> | 34 | #include <linux/mca.h> |
35 | #include <linux/delay.h> | 35 | #include <linux/delay.h> |
36 | #include <linux/device.h> | 36 | #include <linux/platform_device.h> |
37 | #include <linux/tty.h> | 37 | #include <linux/tty.h> |
38 | #include <linux/tty_flip.h> | 38 | #include <linux/tty_flip.h> |
39 | #include <linux/serial_reg.h> | 39 | #include <linux/serial_reg.h> |
diff --git a/drivers/serial/imx.c b/drivers/serial/imx.c index 5b3933b0c997..4a54ff584700 100644 --- a/drivers/serial/imx.c +++ b/drivers/serial/imx.c | |||
@@ -36,7 +36,7 @@ | |||
36 | #include <linux/init.h> | 36 | #include <linux/init.h> |
37 | #include <linux/console.h> | 37 | #include <linux/console.h> |
38 | #include <linux/sysrq.h> | 38 | #include <linux/sysrq.h> |
39 | #include <linux/device.h> | 39 | #include <linux/platform_device.h> |
40 | #include <linux/tty.h> | 40 | #include <linux/tty.h> |
41 | #include <linux/tty_flip.h> | 41 | #include <linux/tty_flip.h> |
42 | #include <linux/serial_core.h> | 42 | #include <linux/serial_core.h> |
@@ -995,6 +995,7 @@ static int __init imx_serial_init(void) | |||
995 | static void __exit imx_serial_exit(void) | 995 | static void __exit imx_serial_exit(void) |
996 | { | 996 | { |
997 | uart_unregister_driver(&imx_reg); | 997 | uart_unregister_driver(&imx_reg); |
998 | driver_unregister(&serial_imx_driver); | ||
998 | } | 999 | } |
999 | 1000 | ||
1000 | module_init(imx_serial_init); | 1001 | module_init(imx_serial_init); |
diff --git a/drivers/serial/mpc52xx_uart.c b/drivers/serial/mpc52xx_uart.c index 8a79968f8ce1..0dd08a09e7e6 100644 --- a/drivers/serial/mpc52xx_uart.c +++ b/drivers/serial/mpc52xx_uart.c | |||
@@ -45,7 +45,7 @@ | |||
45 | */ | 45 | */ |
46 | 46 | ||
47 | #include <linux/config.h> | 47 | #include <linux/config.h> |
48 | #include <linux/device.h> | 48 | #include <linux/platform_device.h> |
49 | #include <linux/module.h> | 49 | #include <linux/module.h> |
50 | #include <linux/tty.h> | 50 | #include <linux/tty.h> |
51 | #include <linux/serial.h> | 51 | #include <linux/serial.h> |
diff --git a/drivers/serial/mpsc.c b/drivers/serial/mpsc.c index aec83f577ce6..ba8838b234da 100644 --- a/drivers/serial/mpsc.c +++ b/drivers/serial/mpsc.c | |||
@@ -52,6 +52,8 @@ | |||
52 | * 4) AFAICT, hardware flow control isn't supported by the controller --MAG. | 52 | * 4) AFAICT, hardware flow control isn't supported by the controller --MAG. |
53 | */ | 53 | */ |
54 | 54 | ||
55 | #include <linux/platform_device.h> | ||
56 | |||
55 | #include "mpsc.h" | 57 | #include "mpsc.h" |
56 | 58 | ||
57 | /* | 59 | /* |
diff --git a/drivers/serial/pxa.c b/drivers/serial/pxa.c index 8cc4cedadd99..16b2f9417af9 100644 --- a/drivers/serial/pxa.c +++ b/drivers/serial/pxa.c | |||
@@ -39,7 +39,7 @@ | |||
39 | #include <linux/circ_buf.h> | 39 | #include <linux/circ_buf.h> |
40 | #include <linux/delay.h> | 40 | #include <linux/delay.h> |
41 | #include <linux/interrupt.h> | 41 | #include <linux/interrupt.h> |
42 | #include <linux/device.h> | 42 | #include <linux/platform_device.h> |
43 | #include <linux/tty.h> | 43 | #include <linux/tty.h> |
44 | #include <linux/tty_flip.h> | 44 | #include <linux/tty_flip.h> |
45 | #include <linux/serial_core.h> | 45 | #include <linux/serial_core.h> |
diff --git a/drivers/serial/s3c2410.c b/drivers/serial/s3c2410.c index 06a17dff1a73..036792328d49 100644 --- a/drivers/serial/s3c2410.c +++ b/drivers/serial/s3c2410.c | |||
@@ -63,7 +63,7 @@ | |||
63 | 63 | ||
64 | #include <linux/module.h> | 64 | #include <linux/module.h> |
65 | #include <linux/ioport.h> | 65 | #include <linux/ioport.h> |
66 | #include <linux/device.h> | 66 | #include <linux/platform_device.h> |
67 | #include <linux/init.h> | 67 | #include <linux/init.h> |
68 | #include <linux/sysrq.h> | 68 | #include <linux/sysrq.h> |
69 | #include <linux/console.h> | 69 | #include <linux/console.h> |
diff --git a/drivers/serial/sa1100.c b/drivers/serial/sa1100.c index c4a789e6af44..ed618cc7ae96 100644 --- a/drivers/serial/sa1100.c +++ b/drivers/serial/sa1100.c | |||
@@ -35,7 +35,7 @@ | |||
35 | #include <linux/init.h> | 35 | #include <linux/init.h> |
36 | #include <linux/console.h> | 36 | #include <linux/console.h> |
37 | #include <linux/sysrq.h> | 37 | #include <linux/sysrq.h> |
38 | #include <linux/device.h> | 38 | #include <linux/platform_device.h> |
39 | #include <linux/tty.h> | 39 | #include <linux/tty.h> |
40 | #include <linux/tty_flip.h> | 40 | #include <linux/tty_flip.h> |
41 | #include <linux/serial_core.h> | 41 | #include <linux/serial_core.h> |
diff --git a/drivers/serial/vr41xx_siu.c b/drivers/serial/vr41xx_siu.c index 2b623ab0e36e..01696b3e3f61 100644 --- a/drivers/serial/vr41xx_siu.c +++ b/drivers/serial/vr41xx_siu.c | |||
@@ -26,7 +26,7 @@ | |||
26 | #endif | 26 | #endif |
27 | 27 | ||
28 | #include <linux/console.h> | 28 | #include <linux/console.h> |
29 | #include <linux/device.h> | 29 | #include <linux/platform_device.h> |
30 | #include <linux/err.h> | 30 | #include <linux/err.h> |
31 | #include <linux/ioport.h> | 31 | #include <linux/ioport.h> |
32 | #include <linux/init.h> | 32 | #include <linux/init.h> |
diff --git a/drivers/usb/gadget/dummy_hcd.c b/drivers/usb/gadget/dummy_hcd.c index 02106bebd5c1..975ace3f5b1e 100644 --- a/drivers/usb/gadget/dummy_hcd.c +++ b/drivers/usb/gadget/dummy_hcd.c | |||
@@ -50,7 +50,7 @@ | |||
50 | #include <linux/list.h> | 50 | #include <linux/list.h> |
51 | #include <linux/interrupt.h> | 51 | #include <linux/interrupt.h> |
52 | #include <linux/version.h> | 52 | #include <linux/version.h> |
53 | 53 | #include <linux/platform_device.h> | |
54 | #include <linux/usb.h> | 54 | #include <linux/usb.h> |
55 | #include <linux/usb_gadget.h> | 55 | #include <linux/usb_gadget.h> |
56 | 56 | ||
diff --git a/drivers/usb/gadget/lh7a40x_udc.c b/drivers/usb/gadget/lh7a40x_udc.c index 9b3673904daf..bc6269f10cbb 100644 --- a/drivers/usb/gadget/lh7a40x_udc.c +++ b/drivers/usb/gadget/lh7a40x_udc.c | |||
@@ -21,6 +21,8 @@ | |||
21 | * | 21 | * |
22 | */ | 22 | */ |
23 | 23 | ||
24 | #include <linux/platform_device.h> | ||
25 | |||
24 | #include "lh7a40x_udc.h" | 26 | #include "lh7a40x_udc.h" |
25 | 27 | ||
26 | //#define DEBUG printk | 28 | //#define DEBUG printk |
diff --git a/drivers/usb/gadget/omap_udc.c b/drivers/usb/gadget/omap_udc.c index 41c96b0afbb3..387692a3611e 100644 --- a/drivers/usb/gadget/omap_udc.c +++ b/drivers/usb/gadget/omap_udc.c | |||
@@ -38,7 +38,7 @@ | |||
38 | #include <linux/proc_fs.h> | 38 | #include <linux/proc_fs.h> |
39 | #include <linux/mm.h> | 39 | #include <linux/mm.h> |
40 | #include <linux/moduleparam.h> | 40 | #include <linux/moduleparam.h> |
41 | #include <linux/device.h> | 41 | #include <linux/platform_device.h> |
42 | #include <linux/usb_ch9.h> | 42 | #include <linux/usb_ch9.h> |
43 | #include <linux/usb_gadget.h> | 43 | #include <linux/usb_gadget.h> |
44 | #include <linux/usb_otg.h> | 44 | #include <linux/usb_otg.h> |
diff --git a/drivers/usb/gadget/pxa2xx_udc.c b/drivers/usb/gadget/pxa2xx_udc.c index f83a9262f953..ee9cd7869d92 100644 --- a/drivers/usb/gadget/pxa2xx_udc.c +++ b/drivers/usb/gadget/pxa2xx_udc.c | |||
@@ -43,7 +43,7 @@ | |||
43 | #include <linux/interrupt.h> | 43 | #include <linux/interrupt.h> |
44 | #include <linux/proc_fs.h> | 44 | #include <linux/proc_fs.h> |
45 | #include <linux/mm.h> | 45 | #include <linux/mm.h> |
46 | #include <linux/device.h> | 46 | #include <linux/platform_device.h> |
47 | #include <linux/dma-mapping.h> | 47 | #include <linux/dma-mapping.h> |
48 | 48 | ||
49 | #include <asm/byteorder.h> | 49 | #include <asm/byteorder.h> |
diff --git a/drivers/usb/host/isp116x-hcd.c b/drivers/usb/host/isp116x-hcd.c index ddb8fc591466..f9c3f5b8dd1c 100644 --- a/drivers/usb/host/isp116x-hcd.c +++ b/drivers/usb/host/isp116x-hcd.c | |||
@@ -70,6 +70,7 @@ | |||
70 | #include <linux/interrupt.h> | 70 | #include <linux/interrupt.h> |
71 | #include <linux/usb.h> | 71 | #include <linux/usb.h> |
72 | #include <linux/usb_isp116x.h> | 72 | #include <linux/usb_isp116x.h> |
73 | #include <linux/platform_device.h> | ||
73 | 74 | ||
74 | #include <asm/io.h> | 75 | #include <asm/io.h> |
75 | #include <asm/irq.h> | 76 | #include <asm/irq.h> |
diff --git a/drivers/usb/host/ohci-au1xxx.c b/drivers/usb/host/ohci-au1xxx.c index a277e258eb6c..f0c78cf14b6c 100644 --- a/drivers/usb/host/ohci-au1xxx.c +++ b/drivers/usb/host/ohci-au1xxx.c | |||
@@ -18,6 +18,8 @@ | |||
18 | * This file is licenced under the GPL. | 18 | * This file is licenced under the GPL. |
19 | */ | 19 | */ |
20 | 20 | ||
21 | #include <linux/platform_device.h> | ||
22 | |||
21 | #include <asm/mach-au1x00/au1000.h> | 23 | #include <asm/mach-au1x00/au1000.h> |
22 | 24 | ||
23 | #define USBH_ENABLE_BE (1<<0) | 25 | #define USBH_ENABLE_BE (1<<0) |
diff --git a/drivers/usb/host/ohci-lh7a404.c b/drivers/usb/host/ohci-lh7a404.c index 238fa4ade615..336c766c6e29 100644 --- a/drivers/usb/host/ohci-lh7a404.c +++ b/drivers/usb/host/ohci-lh7a404.c | |||
@@ -16,6 +16,8 @@ | |||
16 | * This file is licenced under the GPL. | 16 | * This file is licenced under the GPL. |
17 | */ | 17 | */ |
18 | 18 | ||
19 | #include <linux/platform_device.h> | ||
20 | |||
19 | #include <asm/hardware.h> | 21 | #include <asm/hardware.h> |
20 | 22 | ||
21 | 23 | ||
diff --git a/drivers/usb/host/ohci-omap.c b/drivers/usb/host/ohci-omap.c index 49815ec4b842..e46cc540cf4d 100644 --- a/drivers/usb/host/ohci-omap.c +++ b/drivers/usb/host/ohci-omap.c | |||
@@ -16,6 +16,7 @@ | |||
16 | 16 | ||
17 | #include <linux/signal.h> /* SA_INTERRUPT */ | 17 | #include <linux/signal.h> /* SA_INTERRUPT */ |
18 | #include <linux/jiffies.h> | 18 | #include <linux/jiffies.h> |
19 | #include <linux/platform_device.h> | ||
19 | 20 | ||
20 | #include <asm/hardware.h> | 21 | #include <asm/hardware.h> |
21 | #include <asm/io.h> | 22 | #include <asm/io.h> |
diff --git a/drivers/usb/host/ohci-ppc-soc.c b/drivers/usb/host/ohci-ppc-soc.c index 4832e57ae579..92cf6f4a1374 100644 --- a/drivers/usb/host/ohci-ppc-soc.c +++ b/drivers/usb/host/ohci-ppc-soc.c | |||
@@ -14,6 +14,8 @@ | |||
14 | * This file is licenced under the GPL. | 14 | * This file is licenced under the GPL. |
15 | */ | 15 | */ |
16 | 16 | ||
17 | #include <linux/platform_device.h> | ||
18 | |||
17 | /* configure so an HC device and id are always provided */ | 19 | /* configure so an HC device and id are always provided */ |
18 | /* always called with process context; sleeping is OK */ | 20 | /* always called with process context; sleeping is OK */ |
19 | 21 | ||
diff --git a/drivers/usb/host/ohci-pxa27x.c b/drivers/usb/host/ohci-pxa27x.c index f4a4aeda40b7..59e20568e8f9 100644 --- a/drivers/usb/host/ohci-pxa27x.c +++ b/drivers/usb/host/ohci-pxa27x.c | |||
@@ -21,6 +21,8 @@ | |||
21 | 21 | ||
22 | #include <linux/device.h> | 22 | #include <linux/device.h> |
23 | #include <linux/signal.h> | 23 | #include <linux/signal.h> |
24 | #include <linux/platform_device.h> | ||
25 | |||
24 | #include <asm/mach-types.h> | 26 | #include <asm/mach-types.h> |
25 | #include <asm/hardware.h> | 27 | #include <asm/hardware.h> |
26 | #include <asm/arch/pxa-regs.h> | 28 | #include <asm/arch/pxa-regs.h> |
diff --git a/drivers/usb/host/ohci-s3c2410.c b/drivers/usb/host/ohci-s3c2410.c index fab420a2ce71..ee1fc605b402 100644 --- a/drivers/usb/host/ohci-s3c2410.c +++ b/drivers/usb/host/ohci-s3c2410.c | |||
@@ -19,6 +19,8 @@ | |||
19 | * This file is licenced under the GPL. | 19 | * This file is licenced under the GPL. |
20 | */ | 20 | */ |
21 | 21 | ||
22 | #include <linux/platform_device.h> | ||
23 | |||
22 | #include <asm/hardware.h> | 24 | #include <asm/hardware.h> |
23 | #include <asm/hardware/clock.h> | 25 | #include <asm/hardware/clock.h> |
24 | #include <asm/arch/usb-control.h> | 26 | #include <asm/arch/usb-control.h> |
diff --git a/drivers/usb/host/pci-quirks.c b/drivers/usb/host/pci-quirks.c index b7fd3f644e1e..b1aa350fd32f 100644 --- a/drivers/usb/host/pci-quirks.c +++ b/drivers/usb/host/pci-quirks.c | |||
@@ -138,11 +138,23 @@ reset_needed: | |||
138 | } | 138 | } |
139 | EXPORT_SYMBOL_GPL(uhci_check_and_reset_hc); | 139 | EXPORT_SYMBOL_GPL(uhci_check_and_reset_hc); |
140 | 140 | ||
141 | static inline int io_type_enabled(struct pci_dev *pdev, unsigned int mask) | ||
142 | { | ||
143 | u16 cmd; | ||
144 | return !pci_read_config_word(pdev, PCI_COMMAND, &cmd) && (cmd & mask); | ||
145 | } | ||
146 | |||
147 | #define pio_enabled(dev) io_type_enabled(dev, PCI_COMMAND_IO) | ||
148 | #define mmio_enabled(dev) io_type_enabled(dev, PCI_COMMAND_MEMORY) | ||
149 | |||
141 | static void __devinit quirk_usb_handoff_uhci(struct pci_dev *pdev) | 150 | static void __devinit quirk_usb_handoff_uhci(struct pci_dev *pdev) |
142 | { | 151 | { |
143 | unsigned long base = 0; | 152 | unsigned long base = 0; |
144 | int i; | 153 | int i; |
145 | 154 | ||
155 | if (!pio_enabled(pdev)) | ||
156 | return; | ||
157 | |||
146 | for (i = 0; i < PCI_ROM_RESOURCE; i++) | 158 | for (i = 0; i < PCI_ROM_RESOURCE; i++) |
147 | if ((pci_resource_flags(pdev, i) & IORESOURCE_IO)) { | 159 | if ((pci_resource_flags(pdev, i) & IORESOURCE_IO)) { |
148 | base = pci_resource_start(pdev, i); | 160 | base = pci_resource_start(pdev, i); |
@@ -153,12 +165,20 @@ static void __devinit quirk_usb_handoff_uhci(struct pci_dev *pdev) | |||
153 | uhci_check_and_reset_hc(pdev, base); | 165 | uhci_check_and_reset_hc(pdev, base); |
154 | } | 166 | } |
155 | 167 | ||
168 | static int __devinit mmio_resource_enabled(struct pci_dev *pdev, int idx) | ||
169 | { | ||
170 | return pci_resource_start(pdev, idx) && mmio_enabled(pdev); | ||
171 | } | ||
172 | |||
156 | static void __devinit quirk_usb_handoff_ohci(struct pci_dev *pdev) | 173 | static void __devinit quirk_usb_handoff_ohci(struct pci_dev *pdev) |
157 | { | 174 | { |
158 | void __iomem *base; | 175 | void __iomem *base; |
159 | int wait_time; | 176 | int wait_time; |
160 | u32 control; | 177 | u32 control; |
161 | 178 | ||
179 | if (!mmio_resource_enabled(pdev, 0)) | ||
180 | return; | ||
181 | |||
162 | base = ioremap_nocache(pci_resource_start(pdev, 0), | 182 | base = ioremap_nocache(pci_resource_start(pdev, 0), |
163 | pci_resource_len(pdev, 0)); | 183 | pci_resource_len(pdev, 0)); |
164 | if (base == NULL) return; | 184 | if (base == NULL) return; |
@@ -201,6 +221,9 @@ static void __devinit quirk_usb_disable_ehci(struct pci_dev *pdev) | |||
201 | u32 hcc_params, val, temp; | 221 | u32 hcc_params, val, temp; |
202 | u8 cap_length; | 222 | u8 cap_length; |
203 | 223 | ||
224 | if (!mmio_resource_enabled(pdev, 0)) | ||
225 | return; | ||
226 | |||
204 | base = ioremap_nocache(pci_resource_start(pdev, 0), | 227 | base = ioremap_nocache(pci_resource_start(pdev, 0), |
205 | pci_resource_len(pdev, 0)); | 228 | pci_resource_len(pdev, 0)); |
206 | if (base == NULL) return; | 229 | if (base == NULL) return; |
diff --git a/drivers/usb/host/sl811-hcd.c b/drivers/usb/host/sl811-hcd.c index 40169d9cf2b1..5607c0ae6835 100644 --- a/drivers/usb/host/sl811-hcd.c +++ b/drivers/usb/host/sl811-hcd.c | |||
@@ -54,6 +54,7 @@ | |||
54 | #include <linux/interrupt.h> | 54 | #include <linux/interrupt.h> |
55 | #include <linux/usb.h> | 55 | #include <linux/usb.h> |
56 | #include <linux/usb_sl811.h> | 56 | #include <linux/usb_sl811.h> |
57 | #include <linux/platform_device.h> | ||
57 | 58 | ||
58 | #include <asm/io.h> | 59 | #include <asm/io.h> |
59 | #include <asm/irq.h> | 60 | #include <asm/irq.h> |
diff --git a/drivers/usb/host/sl811_cs.c b/drivers/usb/host/sl811_cs.c index 38aebe361ca1..e73faf831b24 100644 --- a/drivers/usb/host/sl811_cs.c +++ b/drivers/usb/host/sl811_cs.c | |||
@@ -19,6 +19,7 @@ | |||
19 | #include <linux/string.h> | 19 | #include <linux/string.h> |
20 | #include <linux/timer.h> | 20 | #include <linux/timer.h> |
21 | #include <linux/ioport.h> | 21 | #include <linux/ioport.h> |
22 | #include <linux/platform_device.h> | ||
22 | 23 | ||
23 | #include <pcmcia/cs_types.h> | 24 | #include <pcmcia/cs_types.h> |
24 | #include <pcmcia/cs.h> | 25 | #include <pcmcia/cs.h> |
diff --git a/drivers/video/acornfb.c b/drivers/video/acornfb.c index f02965f39501..9b6a39348f81 100644 --- a/drivers/video/acornfb.c +++ b/drivers/video/acornfb.c | |||
@@ -26,7 +26,7 @@ | |||
26 | #include <linux/slab.h> | 26 | #include <linux/slab.h> |
27 | #include <linux/init.h> | 27 | #include <linux/init.h> |
28 | #include <linux/fb.h> | 28 | #include <linux/fb.h> |
29 | #include <linux/device.h> | 29 | #include <linux/platform_device.h> |
30 | #include <linux/dma-mapping.h> | 30 | #include <linux/dma-mapping.h> |
31 | 31 | ||
32 | #include <asm/hardware.h> | 32 | #include <asm/hardware.h> |
diff --git a/drivers/video/arcfb.c b/drivers/video/arcfb.c index d28457e0c063..126daff1c848 100644 --- a/drivers/video/arcfb.c +++ b/drivers/video/arcfb.c | |||
@@ -47,6 +47,7 @@ | |||
47 | #include <linux/fb.h> | 47 | #include <linux/fb.h> |
48 | #include <linux/init.h> | 48 | #include <linux/init.h> |
49 | #include <linux/arcfb.h> | 49 | #include <linux/arcfb.h> |
50 | #include <linux/platform_device.h> | ||
50 | 51 | ||
51 | #include <asm/uaccess.h> | 52 | #include <asm/uaccess.h> |
52 | 53 | ||
diff --git a/drivers/video/backlight/corgi_bl.c b/drivers/video/backlight/corgi_bl.c index 1991fdb32dfb..4867498f68e8 100644 --- a/drivers/video/backlight/corgi_bl.c +++ b/drivers/video/backlight/corgi_bl.c | |||
@@ -14,7 +14,7 @@ | |||
14 | #include <linux/module.h> | 14 | #include <linux/module.h> |
15 | #include <linux/kernel.h> | 15 | #include <linux/kernel.h> |
16 | #include <linux/init.h> | 16 | #include <linux/init.h> |
17 | #include <linux/device.h> | 17 | #include <linux/platform_device.h> |
18 | #include <linux/spinlock.h> | 18 | #include <linux/spinlock.h> |
19 | #include <linux/fb.h> | 19 | #include <linux/fb.h> |
20 | #include <linux/backlight.h> | 20 | #include <linux/backlight.h> |
diff --git a/drivers/video/dnfb.c b/drivers/video/dnfb.c index 1dbb82dca40b..1785686a7f11 100644 --- a/drivers/video/dnfb.c +++ b/drivers/video/dnfb.c | |||
@@ -6,6 +6,8 @@ | |||
6 | #include <linux/slab.h> | 6 | #include <linux/slab.h> |
7 | #include <linux/delay.h> | 7 | #include <linux/delay.h> |
8 | #include <linux/interrupt.h> | 8 | #include <linux/interrupt.h> |
9 | #include <linux/platform_device.h> | ||
10 | |||
9 | #include <asm/setup.h> | 11 | #include <asm/setup.h> |
10 | #include <asm/system.h> | 12 | #include <asm/system.h> |
11 | #include <asm/irq.h> | 13 | #include <asm/irq.h> |
diff --git a/drivers/video/epson1355fb.c b/drivers/video/epson1355fb.c index 116e808d71cd..7363d0b25fdf 100644 --- a/drivers/video/epson1355fb.c +++ b/drivers/video/epson1355fb.c | |||
@@ -54,6 +54,8 @@ | |||
54 | #include <linux/fb.h> | 54 | #include <linux/fb.h> |
55 | #include <linux/init.h> | 55 | #include <linux/init.h> |
56 | #include <linux/ioport.h> | 56 | #include <linux/ioport.h> |
57 | #include <linux/platform_device.h> | ||
58 | |||
57 | #include <asm/types.h> | 59 | #include <asm/types.h> |
58 | #include <asm/io.h> | 60 | #include <asm/io.h> |
59 | #include <asm/uaccess.h> | 61 | #include <asm/uaccess.h> |
diff --git a/drivers/video/gbefb.c b/drivers/video/gbefb.c index 485604cd4462..316bfe994811 100644 --- a/drivers/video/gbefb.c +++ b/drivers/video/gbefb.c | |||
@@ -11,7 +11,7 @@ | |||
11 | 11 | ||
12 | #include <linux/config.h> | 12 | #include <linux/config.h> |
13 | #include <linux/delay.h> | 13 | #include <linux/delay.h> |
14 | #include <linux/device.h> | 14 | #include <linux/platform_device.h> |
15 | #include <linux/dma-mapping.h> | 15 | #include <linux/dma-mapping.h> |
16 | #include <linux/errno.h> | 16 | #include <linux/errno.h> |
17 | #include <linux/fb.h> | 17 | #include <linux/fb.h> |
diff --git a/drivers/video/imxfb.c b/drivers/video/imxfb.c index 0b9301facbd3..64d9bcc38da3 100644 --- a/drivers/video/imxfb.c +++ b/drivers/video/imxfb.c | |||
@@ -31,7 +31,7 @@ | |||
31 | #include <linux/init.h> | 31 | #include <linux/init.h> |
32 | #include <linux/ioport.h> | 32 | #include <linux/ioport.h> |
33 | #include <linux/cpufreq.h> | 33 | #include <linux/cpufreq.h> |
34 | #include <linux/device.h> | 34 | #include <linux/platform_device.h> |
35 | #include <linux/dma-mapping.h> | 35 | #include <linux/dma-mapping.h> |
36 | 36 | ||
37 | #include <asm/hardware.h> | 37 | #include <asm/hardware.h> |
diff --git a/drivers/video/pxafb.c b/drivers/video/pxafb.c index 6206da9dd5da..efd9333b05c2 100644 --- a/drivers/video/pxafb.c +++ b/drivers/video/pxafb.c | |||
@@ -36,7 +36,7 @@ | |||
36 | #include <linux/init.h> | 36 | #include <linux/init.h> |
37 | #include <linux/ioport.h> | 37 | #include <linux/ioport.h> |
38 | #include <linux/cpufreq.h> | 38 | #include <linux/cpufreq.h> |
39 | #include <linux/device.h> | 39 | #include <linux/platform_device.h> |
40 | #include <linux/dma-mapping.h> | 40 | #include <linux/dma-mapping.h> |
41 | 41 | ||
42 | #include <asm/hardware.h> | 42 | #include <asm/hardware.h> |
diff --git a/drivers/video/q40fb.c b/drivers/video/q40fb.c index 162012bb9264..8416b2e2b501 100644 --- a/drivers/video/q40fb.c +++ b/drivers/video/q40fb.c | |||
@@ -18,6 +18,7 @@ | |||
18 | #include <linux/slab.h> | 18 | #include <linux/slab.h> |
19 | #include <linux/delay.h> | 19 | #include <linux/delay.h> |
20 | #include <linux/interrupt.h> | 20 | #include <linux/interrupt.h> |
21 | #include <linux/platform_device.h> | ||
21 | 22 | ||
22 | #include <asm/uaccess.h> | 23 | #include <asm/uaccess.h> |
23 | #include <asm/setup.h> | 24 | #include <asm/setup.h> |
diff --git a/drivers/video/s1d13xxxfb.c b/drivers/video/s1d13xxxfb.c index cb2f7a1de947..f4437430dc5f 100644 --- a/drivers/video/s1d13xxxfb.c +++ b/drivers/video/s1d13xxxfb.c | |||
@@ -30,7 +30,7 @@ | |||
30 | 30 | ||
31 | #include <linux/config.h> | 31 | #include <linux/config.h> |
32 | #include <linux/module.h> | 32 | #include <linux/module.h> |
33 | #include <linux/device.h> | 33 | #include <linux/platform_device.h> |
34 | #include <linux/delay.h> | 34 | #include <linux/delay.h> |
35 | 35 | ||
36 | #include <linux/types.h> | 36 | #include <linux/types.h> |
diff --git a/drivers/video/s3c2410fb.c b/drivers/video/s3c2410fb.c index 3862d3cb1fb2..3cef90456a4b 100644 --- a/drivers/video/s3c2410fb.c +++ b/drivers/video/s3c2410fb.c | |||
@@ -86,6 +86,7 @@ | |||
86 | #include <linux/interrupt.h> | 86 | #include <linux/interrupt.h> |
87 | #include <linux/workqueue.h> | 87 | #include <linux/workqueue.h> |
88 | #include <linux/wait.h> | 88 | #include <linux/wait.h> |
89 | #include <linux/platform_device.h> | ||
89 | 90 | ||
90 | #include <asm/io.h> | 91 | #include <asm/io.h> |
91 | #include <asm/uaccess.h> | 92 | #include <asm/uaccess.h> |
diff --git a/drivers/video/sa1100fb.c b/drivers/video/sa1100fb.c index 78e5f194b0df..3d35b28aaac7 100644 --- a/drivers/video/sa1100fb.c +++ b/drivers/video/sa1100fb.c | |||
@@ -173,7 +173,7 @@ | |||
173 | #include <linux/init.h> | 173 | #include <linux/init.h> |
174 | #include <linux/ioport.h> | 174 | #include <linux/ioport.h> |
175 | #include <linux/cpufreq.h> | 175 | #include <linux/cpufreq.h> |
176 | #include <linux/device.h> | 176 | #include <linux/platform_device.h> |
177 | #include <linux/dma-mapping.h> | 177 | #include <linux/dma-mapping.h> |
178 | 178 | ||
179 | #include <asm/hardware.h> | 179 | #include <asm/hardware.h> |
diff --git a/drivers/video/sgivwfb.c b/drivers/video/sgivwfb.c index 8413907b379a..cf5106eab2d5 100644 --- a/drivers/video/sgivwfb.c +++ b/drivers/video/sgivwfb.c | |||
@@ -18,6 +18,8 @@ | |||
18 | #include <linux/fb.h> | 18 | #include <linux/fb.h> |
19 | #include <linux/init.h> | 19 | #include <linux/init.h> |
20 | #include <linux/ioport.h> | 20 | #include <linux/ioport.h> |
21 | #include <linux/platform_device.h> | ||
22 | |||
21 | #include <asm/io.h> | 23 | #include <asm/io.h> |
22 | #include <asm/mtrr.h> | 24 | #include <asm/mtrr.h> |
23 | 25 | ||
diff --git a/drivers/video/vesafb.c b/drivers/video/vesafb.c index b1243da55fc5..3cc23106641d 100644 --- a/drivers/video/vesafb.c +++ b/drivers/video/vesafb.c | |||
@@ -19,6 +19,8 @@ | |||
19 | #include <linux/fb.h> | 19 | #include <linux/fb.h> |
20 | #include <linux/ioport.h> | 20 | #include <linux/ioport.h> |
21 | #include <linux/init.h> | 21 | #include <linux/init.h> |
22 | #include <linux/platform_device.h> | ||
23 | |||
22 | #include <video/vga.h> | 24 | #include <video/vga.h> |
23 | #include <asm/io.h> | 25 | #include <asm/io.h> |
24 | #include <asm/mtrr.h> | 26 | #include <asm/mtrr.h> |
diff --git a/drivers/video/vfb.c b/drivers/video/vfb.c index b137a3fe0752..92d46555dd86 100644 --- a/drivers/video/vfb.c +++ b/drivers/video/vfb.c | |||
@@ -20,6 +20,8 @@ | |||
20 | #include <linux/vmalloc.h> | 20 | #include <linux/vmalloc.h> |
21 | #include <linux/delay.h> | 21 | #include <linux/delay.h> |
22 | #include <linux/interrupt.h> | 22 | #include <linux/interrupt.h> |
23 | #include <linux/platform_device.h> | ||
24 | |||
23 | #include <asm/uaccess.h> | 25 | #include <asm/uaccess.h> |
24 | #include <linux/fb.h> | 26 | #include <linux/fb.h> |
25 | #include <linux/init.h> | 27 | #include <linux/init.h> |
diff --git a/drivers/video/w100fb.c b/drivers/video/w100fb.c index 752bf88906a9..cf8cdb108fd9 100644 --- a/drivers/video/w100fb.c +++ b/drivers/video/w100fb.c | |||
@@ -25,7 +25,7 @@ | |||
25 | #include <linux/init.h> | 25 | #include <linux/init.h> |
26 | #include <linux/kernel.h> | 26 | #include <linux/kernel.h> |
27 | #include <linux/mm.h> | 27 | #include <linux/mm.h> |
28 | #include <linux/device.h> | 28 | #include <linux/platform_device.h> |
29 | #include <linux/string.h> | 29 | #include <linux/string.h> |
30 | #include <linux/vmalloc.h> | 30 | #include <linux/vmalloc.h> |
31 | #include <asm/io.h> | 31 | #include <asm/io.h> |