diff options
384 files changed, 569 insertions, 676 deletions
@@ -73,8 +73,7 @@ Linas Vepstas <linas@austin.ibm.com> | |||
73 | Mark Brown <broonie@sirena.org.uk> | 73 | Mark Brown <broonie@sirena.org.uk> |
74 | Matthieu CASTET <castet.matthieu@free.fr> | 74 | Matthieu CASTET <castet.matthieu@free.fr> |
75 | Mayuresh Janorkar <mayur@ti.com> | 75 | Mayuresh Janorkar <mayur@ti.com> |
76 | Michael Buesch <mb@bu3sch.de> | 76 | Michael Buesch <m@bues.ch> |
77 | Michael Buesch <mbuesch@freenet.de> | ||
78 | Michel Dänzer <michel@tungstengraphics.com> | 77 | Michel Dänzer <michel@tungstengraphics.com> |
79 | Mitesh shah <mshah@teja.com> | 78 | Mitesh shah <mshah@teja.com> |
80 | Morten Welinder <terra@gnome.org> | 79 | Morten Welinder <terra@gnome.org> |
diff --git a/Documentation/DocBook/v4l/io.xml b/Documentation/DocBook/v4l/io.xml index 227e7ac45a06..c57d1ec6291c 100644 --- a/Documentation/DocBook/v4l/io.xml +++ b/Documentation/DocBook/v4l/io.xml | |||
@@ -210,7 +210,7 @@ for (i = 0; i < reqbuf.count; i++) | |||
210 | <programlisting> | 210 | <programlisting> |
211 | &v4l2-requestbuffers; reqbuf; | 211 | &v4l2-requestbuffers; reqbuf; |
212 | /* Our current format uses 3 planes per buffer */ | 212 | /* Our current format uses 3 planes per buffer */ |
213 | #define FMT_NUM_PLANES = 3; | 213 | #define FMT_NUM_PLANES = 3 |
214 | 214 | ||
215 | struct { | 215 | struct { |
216 | void *start[FMT_NUM_PLANES]; | 216 | void *start[FMT_NUM_PLANES]; |
diff --git a/Documentation/RCU/NMI-RCU.txt b/Documentation/RCU/NMI-RCU.txt index a8536cb88091..bf82851a0e57 100644 --- a/Documentation/RCU/NMI-RCU.txt +++ b/Documentation/RCU/NMI-RCU.txt | |||
@@ -5,8 +5,8 @@ Although RCU is usually used to protect read-mostly data structures, | |||
5 | it is possible to use RCU to provide dynamic non-maskable interrupt | 5 | it is possible to use RCU to provide dynamic non-maskable interrupt |
6 | handlers, as well as dynamic irq handlers. This document describes | 6 | handlers, as well as dynamic irq handlers. This document describes |
7 | how to do this, drawing loosely from Zwane Mwaikambo's NMI-timer | 7 | how to do this, drawing loosely from Zwane Mwaikambo's NMI-timer |
8 | work in "arch/i386/oprofile/nmi_timer_int.c" and in | 8 | work in "arch/x86/oprofile/nmi_timer_int.c" and in |
9 | "arch/i386/kernel/traps.c". | 9 | "arch/x86/kernel/traps.c". |
10 | 10 | ||
11 | The relevant pieces of code are listed below, each followed by a | 11 | The relevant pieces of code are listed below, each followed by a |
12 | brief explanation. | 12 | brief explanation. |
diff --git a/Documentation/blockdev/README.DAC960 b/Documentation/blockdev/README.DAC960 index 0e8f618ab534..bd85fb9dc6e5 100644 --- a/Documentation/blockdev/README.DAC960 +++ b/Documentation/blockdev/README.DAC960 | |||
@@ -214,7 +214,7 @@ replacing "/usr/src" with wherever you keep your Linux kernel source tree: | |||
214 | make config | 214 | make config |
215 | make bzImage (or zImage) | 215 | make bzImage (or zImage) |
216 | 216 | ||
217 | Then install "arch/i386/boot/bzImage" or "arch/i386/boot/zImage" as your | 217 | Then install "arch/x86/boot/bzImage" or "arch/x86/boot/zImage" as your |
218 | standard kernel, run lilo if appropriate, and reboot. | 218 | standard kernel, run lilo if appropriate, and reboot. |
219 | 219 | ||
220 | To create the necessary devices in /dev, the "make_rd" script included in | 220 | To create the necessary devices in /dev, the "make_rd" script included in |
diff --git a/Documentation/blockdev/ramdisk.txt b/Documentation/blockdev/ramdisk.txt index 6c820baa19a6..fa72e97dd669 100644 --- a/Documentation/blockdev/ramdisk.txt +++ b/Documentation/blockdev/ramdisk.txt | |||
@@ -64,9 +64,9 @@ the RAM disk dynamically grows as data is being written into it, a size field | |||
64 | is not required. Bits 11 to 13 are not currently used and may as well be zero. | 64 | is not required. Bits 11 to 13 are not currently used and may as well be zero. |
65 | These numbers are no magical secrets, as seen below: | 65 | These numbers are no magical secrets, as seen below: |
66 | 66 | ||
67 | ./arch/i386/kernel/setup.c:#define RAMDISK_IMAGE_START_MASK 0x07FF | 67 | ./arch/x86/kernel/setup.c:#define RAMDISK_IMAGE_START_MASK 0x07FF |
68 | ./arch/i386/kernel/setup.c:#define RAMDISK_PROMPT_FLAG 0x8000 | 68 | ./arch/x86/kernel/setup.c:#define RAMDISK_PROMPT_FLAG 0x8000 |
69 | ./arch/i386/kernel/setup.c:#define RAMDISK_LOAD_FLAG 0x4000 | 69 | ./arch/x86/kernel/setup.c:#define RAMDISK_LOAD_FLAG 0x4000 |
70 | 70 | ||
71 | Consider a typical two floppy disk setup, where you will have the | 71 | Consider a typical two floppy disk setup, where you will have the |
72 | kernel on disk one, and have already put a RAM disk image onto disk #2. | 72 | kernel on disk one, and have already put a RAM disk image onto disk #2. |
@@ -85,7 +85,7 @@ The command line equivalent is: "prompt_ramdisk=1" | |||
85 | Putting that together gives 2^15 + 2^14 + 0 = 49152 for an rdev word. | 85 | Putting that together gives 2^15 + 2^14 + 0 = 49152 for an rdev word. |
86 | So to create disk one of the set, you would do: | 86 | So to create disk one of the set, you would do: |
87 | 87 | ||
88 | /usr/src/linux# cat arch/i386/boot/zImage > /dev/fd0 | 88 | /usr/src/linux# cat arch/x86/boot/zImage > /dev/fd0 |
89 | /usr/src/linux# rdev /dev/fd0 /dev/fd0 | 89 | /usr/src/linux# rdev /dev/fd0 /dev/fd0 |
90 | /usr/src/linux# rdev -r /dev/fd0 49152 | 90 | /usr/src/linux# rdev -r /dev/fd0 49152 |
91 | 91 | ||
diff --git a/Documentation/cpu-freq/cpu-drivers.txt b/Documentation/cpu-freq/cpu-drivers.txt index 6c30e930c122..c436096351f8 100644 --- a/Documentation/cpu-freq/cpu-drivers.txt +++ b/Documentation/cpu-freq/cpu-drivers.txt | |||
@@ -168,7 +168,7 @@ in-chipset dynamic frequency switching to policy->min, the upper limit | |||
168 | to policy->max, and -if supported- select a performance-oriented | 168 | to policy->max, and -if supported- select a performance-oriented |
169 | setting when policy->policy is CPUFREQ_POLICY_PERFORMANCE, and a | 169 | setting when policy->policy is CPUFREQ_POLICY_PERFORMANCE, and a |
170 | powersaving-oriented setting when CPUFREQ_POLICY_POWERSAVE. Also check | 170 | powersaving-oriented setting when CPUFREQ_POLICY_POWERSAVE. Also check |
171 | the reference implementation in arch/i386/kernel/cpu/cpufreq/longrun.c | 171 | the reference implementation in drivers/cpufreq/longrun.c |
172 | 172 | ||
173 | 173 | ||
174 | 174 | ||
diff --git a/Documentation/devicetree/bindings/net/can/fsl-flexcan.txt b/Documentation/devicetree/bindings/net/can/fsl-flexcan.txt index 1a729f089866..1a729f089866 100755..100644 --- a/Documentation/devicetree/bindings/net/can/fsl-flexcan.txt +++ b/Documentation/devicetree/bindings/net/can/fsl-flexcan.txt | |||
diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt index d59e71df5c5c..c8616f741746 100644 --- a/Documentation/feature-removal-schedule.txt +++ b/Documentation/feature-removal-schedule.txt | |||
@@ -199,7 +199,7 @@ Files: drivers/staging/cs5535_gpio/* | |||
199 | Check: drivers/staging/cs5535_gpio/cs5535_gpio.c | 199 | Check: drivers/staging/cs5535_gpio/cs5535_gpio.c |
200 | Why: A newer driver replaces this; it is drivers/gpio/cs5535-gpio.c, and | 200 | Why: A newer driver replaces this; it is drivers/gpio/cs5535-gpio.c, and |
201 | integrates with the Linux GPIO subsystem. The old driver has been | 201 | integrates with the Linux GPIO subsystem. The old driver has been |
202 | moved to staging, and will be removed altogether around 2.6.40. | 202 | moved to staging, and will be removed altogether around 3.0. |
203 | Please test the new driver, and ensure that the functionality you | 203 | Please test the new driver, and ensure that the functionality you |
204 | need and any bugfixes from the old driver are available in the new | 204 | need and any bugfixes from the old driver are available in the new |
205 | one. | 205 | one. |
@@ -294,7 +294,7 @@ When: The schedule was July 2008, but it was decided that we are going to keep t | |||
294 | Why: The support code for the old firmware hurts code readability/maintainability | 294 | Why: The support code for the old firmware hurts code readability/maintainability |
295 | and slightly hurts runtime performance. Bugfixes for the old firmware | 295 | and slightly hurts runtime performance. Bugfixes for the old firmware |
296 | are not provided by Broadcom anymore. | 296 | are not provided by Broadcom anymore. |
297 | Who: Michael Buesch <mb@bu3sch.de> | 297 | Who: Michael Buesch <m@bues.ch> |
298 | 298 | ||
299 | --------------------------- | 299 | --------------------------- |
300 | 300 | ||
@@ -430,7 +430,7 @@ Who: Avi Kivity <avi@redhat.com> | |||
430 | ---------------------------- | 430 | ---------------------------- |
431 | 431 | ||
432 | What: iwlwifi 50XX module parameters | 432 | What: iwlwifi 50XX module parameters |
433 | When: 2.6.40 | 433 | When: 3.0 |
434 | Why: The "..50" modules parameters were used to configure 5000 series and | 434 | Why: The "..50" modules parameters were used to configure 5000 series and |
435 | up devices; different set of module parameters also available for 4965 | 435 | up devices; different set of module parameters also available for 4965 |
436 | with same functionalities. Consolidate both set into single place | 436 | with same functionalities. Consolidate both set into single place |
@@ -441,7 +441,7 @@ Who: Wey-Yi Guy <wey-yi.w.guy@intel.com> | |||
441 | ---------------------------- | 441 | ---------------------------- |
442 | 442 | ||
443 | What: iwl4965 alias support | 443 | What: iwl4965 alias support |
444 | When: 2.6.40 | 444 | When: 3.0 |
445 | Why: Internal alias support has been present in module-init-tools for some | 445 | Why: Internal alias support has been present in module-init-tools for some |
446 | time, the MODULE_ALIAS("iwl4965") boilerplate aliases can be removed | 446 | time, the MODULE_ALIAS("iwl4965") boilerplate aliases can be removed |
447 | with no impact. | 447 | with no impact. |
@@ -482,7 +482,7 @@ Who: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | |||
482 | ---------------------------- | 482 | ---------------------------- |
483 | 483 | ||
484 | What: iwlwifi disable_hw_scan module parameters | 484 | What: iwlwifi disable_hw_scan module parameters |
485 | When: 2.6.40 | 485 | When: 3.0 |
486 | Why: Hareware scan is the prefer method for iwlwifi devices for | 486 | Why: Hareware scan is the prefer method for iwlwifi devices for |
487 | scanning operation. Remove software scan support for all the | 487 | scanning operation. Remove software scan support for all the |
488 | iwlwifi devices. | 488 | iwlwifi devices. |
@@ -493,7 +493,7 @@ Who: Wey-Yi Guy <wey-yi.w.guy@intel.com> | |||
493 | 493 | ||
494 | What: access to nfsd auth cache through sys_nfsservctl or '.' files | 494 | What: access to nfsd auth cache through sys_nfsservctl or '.' files |
495 | in the 'nfsd' filesystem. | 495 | in the 'nfsd' filesystem. |
496 | When: 2.6.40 | 496 | When: 3.0 |
497 | Why: This is a legacy interface which have been replaced by a more | 497 | Why: This is a legacy interface which have been replaced by a more |
498 | dynamic cache. Continuing to maintain this interface is an | 498 | dynamic cache. Continuing to maintain this interface is an |
499 | unnecessary burden. | 499 | unnecessary burden. |
@@ -519,7 +519,7 @@ Files: net/netfilter/xt_connlimit.c | |||
519 | ---------------------------- | 519 | ---------------------------- |
520 | 520 | ||
521 | What: noswapaccount kernel command line parameter | 521 | What: noswapaccount kernel command line parameter |
522 | When: 2.6.40 | 522 | When: 3.0 |
523 | Why: The original implementation of memsw feature enabled by | 523 | Why: The original implementation of memsw feature enabled by |
524 | CONFIG_CGROUP_MEM_RES_CTLR_SWAP could be disabled by the noswapaccount | 524 | CONFIG_CGROUP_MEM_RES_CTLR_SWAP could be disabled by the noswapaccount |
525 | kernel parameter (introduced in 2.6.29-rc1). Later on, this decision | 525 | kernel parameter (introduced in 2.6.29-rc1). Later on, this decision |
@@ -552,7 +552,7 @@ Who: Jean Delvare <khali@linux-fr.org> | |||
552 | ---------------------------- | 552 | ---------------------------- |
553 | 553 | ||
554 | What: Support for UVCIOC_CTRL_ADD in the uvcvideo driver | 554 | What: Support for UVCIOC_CTRL_ADD in the uvcvideo driver |
555 | When: 2.6.42 | 555 | When: 3.2 |
556 | Why: The information passed to the driver by this ioctl is now queried | 556 | Why: The information passed to the driver by this ioctl is now queried |
557 | dynamically from the device. | 557 | dynamically from the device. |
558 | Who: Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 558 | Who: Laurent Pinchart <laurent.pinchart@ideasonboard.com> |
@@ -560,7 +560,7 @@ Who: Laurent Pinchart <laurent.pinchart@ideasonboard.com> | |||
560 | ---------------------------- | 560 | ---------------------------- |
561 | 561 | ||
562 | What: Support for UVCIOC_CTRL_MAP_OLD in the uvcvideo driver | 562 | What: Support for UVCIOC_CTRL_MAP_OLD in the uvcvideo driver |
563 | When: 2.6.42 | 563 | When: 3.2 |
564 | Why: Used only by applications compiled against older driver versions. | 564 | Why: Used only by applications compiled against older driver versions. |
565 | Superseded by UVCIOC_CTRL_MAP which supports V4L2 menu controls. | 565 | Superseded by UVCIOC_CTRL_MAP which supports V4L2 menu controls. |
566 | Who: Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 566 | Who: Laurent Pinchart <laurent.pinchart@ideasonboard.com> |
@@ -568,7 +568,7 @@ Who: Laurent Pinchart <laurent.pinchart@ideasonboard.com> | |||
568 | ---------------------------- | 568 | ---------------------------- |
569 | 569 | ||
570 | What: Support for UVCIOC_CTRL_GET and UVCIOC_CTRL_SET in the uvcvideo driver | 570 | What: Support for UVCIOC_CTRL_GET and UVCIOC_CTRL_SET in the uvcvideo driver |
571 | When: 2.6.42 | 571 | When: 3.2 |
572 | Why: Superseded by the UVCIOC_CTRL_QUERY ioctl. | 572 | Why: Superseded by the UVCIOC_CTRL_QUERY ioctl. |
573 | Who: Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 573 | Who: Laurent Pinchart <laurent.pinchart@ideasonboard.com> |
574 | 574 | ||
diff --git a/Documentation/filesystems/nfs/nfsroot.txt b/Documentation/filesystems/nfs/nfsroot.txt index 90c71c6f0d00..ffdd9d866ad7 100644 --- a/Documentation/filesystems/nfs/nfsroot.txt +++ b/Documentation/filesystems/nfs/nfsroot.txt | |||
@@ -226,7 +226,7 @@ They depend on various facilities being available: | |||
226 | cdrecord. | 226 | cdrecord. |
227 | 227 | ||
228 | e.g. | 228 | e.g. |
229 | cdrecord dev=ATAPI:1,0,0 arch/i386/boot/image.iso | 229 | cdrecord dev=ATAPI:1,0,0 arch/x86/boot/image.iso |
230 | 230 | ||
231 | For more information on isolinux, including how to create bootdisks | 231 | For more information on isolinux, including how to create bootdisks |
232 | for prebuilt kernels, see http://syslinux.zytor.com/ | 232 | for prebuilt kernels, see http://syslinux.zytor.com/ |
diff --git a/Documentation/i2o/ioctl b/Documentation/i2o/ioctl index 1e77fac4e120..22ca53a67e23 100644 --- a/Documentation/i2o/ioctl +++ b/Documentation/i2o/ioctl | |||
@@ -110,7 +110,7 @@ V. Getting Logical Configuration Table | |||
110 | ENOBUFS Buffer not large enough. If this occurs, the required | 110 | ENOBUFS Buffer not large enough. If this occurs, the required |
111 | buffer length is written into *(lct->reslen) | 111 | buffer length is written into *(lct->reslen) |
112 | 112 | ||
113 | VI. Settting Parameters | 113 | VI. Setting Parameters |
114 | 114 | ||
115 | SYNOPSIS | 115 | SYNOPSIS |
116 | 116 | ||
diff --git a/Documentation/isdn/README.HiSax b/Documentation/isdn/README.HiSax index 99e87a61897d..b1a573cf4472 100644 --- a/Documentation/isdn/README.HiSax +++ b/Documentation/isdn/README.HiSax | |||
@@ -506,7 +506,7 @@ to e.g. the Internet: | |||
506 | <ISDN subsystem - ISDN support -- HiSax> | 506 | <ISDN subsystem - ISDN support -- HiSax> |
507 | make clean; make zImage; make modules; make modules_install | 507 | make clean; make zImage; make modules; make modules_install |
508 | 2. Install the new kernel | 508 | 2. Install the new kernel |
509 | cp /usr/src/linux/arch/i386/boot/zImage /etc/kernel/linux.isdn | 509 | cp /usr/src/linux/arch/x86/boot/zImage /etc/kernel/linux.isdn |
510 | vi /etc/lilo.conf | 510 | vi /etc/lilo.conf |
511 | <add new kernel in the bootable image section> | 511 | <add new kernel in the bootable image section> |
512 | lilo | 512 | lilo |
diff --git a/Documentation/kbuild/makefiles.txt b/Documentation/kbuild/makefiles.txt index 47435e56c5da..f47cdefb4d1e 100644 --- a/Documentation/kbuild/makefiles.txt +++ b/Documentation/kbuild/makefiles.txt | |||
@@ -441,7 +441,7 @@ more details, with real examples. | |||
441 | specified if first option are not supported. | 441 | specified if first option are not supported. |
442 | 442 | ||
443 | Example: | 443 | Example: |
444 | #arch/i386/kernel/Makefile | 444 | #arch/x86/kernel/Makefile |
445 | vsyscall-flags += $(call cc-ldoption, -Wl$(comma)--hash-style=sysv) | 445 | vsyscall-flags += $(call cc-ldoption, -Wl$(comma)--hash-style=sysv) |
446 | 446 | ||
447 | In the above example, vsyscall-flags will be assigned the option | 447 | In the above example, vsyscall-flags will be assigned the option |
@@ -460,7 +460,7 @@ more details, with real examples. | |||
460 | supported to use an optional second option. | 460 | supported to use an optional second option. |
461 | 461 | ||
462 | Example: | 462 | Example: |
463 | #arch/i386/Makefile | 463 | #arch/x86/Makefile |
464 | cflags-y += $(call cc-option,-march=pentium-mmx,-march=i586) | 464 | cflags-y += $(call cc-option,-march=pentium-mmx,-march=i586) |
465 | 465 | ||
466 | In the above example, cflags-y will be assigned the option | 466 | In the above example, cflags-y will be assigned the option |
@@ -522,7 +522,7 @@ more details, with real examples. | |||
522 | even though the option was accepted by gcc. | 522 | even though the option was accepted by gcc. |
523 | 523 | ||
524 | Example: | 524 | Example: |
525 | #arch/i386/Makefile | 525 | #arch/x86/Makefile |
526 | cflags-y += $(shell \ | 526 | cflags-y += $(shell \ |
527 | if [ $(call cc-version) -ge 0300 ] ; then \ | 527 | if [ $(call cc-version) -ge 0300 ] ; then \ |
528 | echo "-mregparm=3"; fi ;) | 528 | echo "-mregparm=3"; fi ;) |
@@ -802,7 +802,7 @@ but in the architecture makefiles where the kbuild infrastructure | |||
802 | is not sufficient this sometimes needs to be explicit. | 802 | is not sufficient this sometimes needs to be explicit. |
803 | 803 | ||
804 | Example: | 804 | Example: |
805 | #arch/i386/boot/Makefile | 805 | #arch/x86/boot/Makefile |
806 | subdir- := compressed/ | 806 | subdir- := compressed/ |
807 | 807 | ||
808 | The above assignment instructs kbuild to descend down in the | 808 | The above assignment instructs kbuild to descend down in the |
@@ -812,12 +812,12 @@ To support the clean infrastructure in the Makefiles that builds the | |||
812 | final bootimage there is an optional target named archclean: | 812 | final bootimage there is an optional target named archclean: |
813 | 813 | ||
814 | Example: | 814 | Example: |
815 | #arch/i386/Makefile | 815 | #arch/x86/Makefile |
816 | archclean: | 816 | archclean: |
817 | $(Q)$(MAKE) $(clean)=arch/i386/boot | 817 | $(Q)$(MAKE) $(clean)=arch/x86/boot |
818 | 818 | ||
819 | When "make clean" is executed, make will descend down in arch/i386/boot, | 819 | When "make clean" is executed, make will descend down in arch/x86/boot, |
820 | and clean as usual. The Makefile located in arch/i386/boot/ may use | 820 | and clean as usual. The Makefile located in arch/x86/boot/ may use |
821 | the subdir- trick to descend further down. | 821 | the subdir- trick to descend further down. |
822 | 822 | ||
823 | Note 1: arch/$(ARCH)/Makefile cannot use "subdir-", because that file is | 823 | Note 1: arch/$(ARCH)/Makefile cannot use "subdir-", because that file is |
@@ -882,7 +882,7 @@ When kbuild executes, the following steps are followed (roughly): | |||
882 | LDFLAGS_vmlinux uses the LDFLAGS_$@ support. | 882 | LDFLAGS_vmlinux uses the LDFLAGS_$@ support. |
883 | 883 | ||
884 | Example: | 884 | Example: |
885 | #arch/i386/Makefile | 885 | #arch/x86/Makefile |
886 | LDFLAGS_vmlinux := -e stext | 886 | LDFLAGS_vmlinux := -e stext |
887 | 887 | ||
888 | OBJCOPYFLAGS objcopy flags | 888 | OBJCOPYFLAGS objcopy flags |
@@ -920,14 +920,14 @@ When kbuild executes, the following steps are followed (roughly): | |||
920 | Often, the KBUILD_CFLAGS variable depends on the configuration. | 920 | Often, the KBUILD_CFLAGS variable depends on the configuration. |
921 | 921 | ||
922 | Example: | 922 | Example: |
923 | #arch/i386/Makefile | 923 | #arch/x86/Makefile |
924 | cflags-$(CONFIG_M386) += -march=i386 | 924 | cflags-$(CONFIG_M386) += -march=i386 |
925 | KBUILD_CFLAGS += $(cflags-y) | 925 | KBUILD_CFLAGS += $(cflags-y) |
926 | 926 | ||
927 | Many arch Makefiles dynamically run the target C compiler to | 927 | Many arch Makefiles dynamically run the target C compiler to |
928 | probe supported options: | 928 | probe supported options: |
929 | 929 | ||
930 | #arch/i386/Makefile | 930 | #arch/x86/Makefile |
931 | 931 | ||
932 | ... | 932 | ... |
933 | cflags-$(CONFIG_MPENTIUMII) += $(call cc-option,\ | 933 | cflags-$(CONFIG_MPENTIUMII) += $(call cc-option,\ |
@@ -1038,8 +1038,8 @@ When kbuild executes, the following steps are followed (roughly): | |||
1038 | into the arch/$(ARCH)/boot/Makefile. | 1038 | into the arch/$(ARCH)/boot/Makefile. |
1039 | 1039 | ||
1040 | Example: | 1040 | Example: |
1041 | #arch/i386/Makefile | 1041 | #arch/x86/Makefile |
1042 | boot := arch/i386/boot | 1042 | boot := arch/x86/boot |
1043 | bzImage: vmlinux | 1043 | bzImage: vmlinux |
1044 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ | 1044 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ |
1045 | 1045 | ||
@@ -1051,7 +1051,7 @@ When kbuild executes, the following steps are followed (roughly): | |||
1051 | To support this, $(archhelp) must be defined. | 1051 | To support this, $(archhelp) must be defined. |
1052 | 1052 | ||
1053 | Example: | 1053 | Example: |
1054 | #arch/i386/Makefile | 1054 | #arch/x86/Makefile |
1055 | define archhelp | 1055 | define archhelp |
1056 | echo '* bzImage - Image (arch/$(ARCH)/boot/bzImage)' | 1056 | echo '* bzImage - Image (arch/$(ARCH)/boot/bzImage)' |
1057 | endif | 1057 | endif |
@@ -1065,7 +1065,7 @@ When kbuild executes, the following steps are followed (roughly): | |||
1065 | from vmlinux. | 1065 | from vmlinux. |
1066 | 1066 | ||
1067 | Example: | 1067 | Example: |
1068 | #arch/i386/Makefile | 1068 | #arch/x86/Makefile |
1069 | all: bzImage | 1069 | all: bzImage |
1070 | 1070 | ||
1071 | When "make" is executed without arguments, bzImage will be built. | 1071 | When "make" is executed without arguments, bzImage will be built. |
@@ -1083,7 +1083,7 @@ When kbuild executes, the following steps are followed (roughly): | |||
1083 | 2) kbuild knows what files to delete during "make clean" | 1083 | 2) kbuild knows what files to delete during "make clean" |
1084 | 1084 | ||
1085 | Example: | 1085 | Example: |
1086 | #arch/i386/kernel/Makefile | 1086 | #arch/x86/kernel/Makefile |
1087 | extra-y := head.o init_task.o | 1087 | extra-y := head.o init_task.o |
1088 | 1088 | ||
1089 | In this example, extra-y is used to list object files that | 1089 | In this example, extra-y is used to list object files that |
@@ -1133,7 +1133,7 @@ When kbuild executes, the following steps are followed (roughly): | |||
1133 | Compress target. Use maximum compression to compress target. | 1133 | Compress target. Use maximum compression to compress target. |
1134 | 1134 | ||
1135 | Example: | 1135 | Example: |
1136 | #arch/i386/boot/Makefile | 1136 | #arch/x86/boot/Makefile |
1137 | LDFLAGS_bootsect := -Ttext 0x0 -s --oformat binary | 1137 | LDFLAGS_bootsect := -Ttext 0x0 -s --oformat binary |
1138 | LDFLAGS_setup := -Ttext 0x0 -s --oformat binary -e begtext | 1138 | LDFLAGS_setup := -Ttext 0x0 -s --oformat binary -e begtext |
1139 | 1139 | ||
@@ -1193,7 +1193,7 @@ When kbuild executes, the following steps are followed (roughly): | |||
1193 | 1193 | ||
1194 | When updating the $(obj)/bzImage target, the line | 1194 | When updating the $(obj)/bzImage target, the line |
1195 | 1195 | ||
1196 | BUILD arch/i386/boot/bzImage | 1196 | BUILD arch/x86/boot/bzImage |
1197 | 1197 | ||
1198 | will be displayed with "make KBUILD_VERBOSE=0". | 1198 | will be displayed with "make KBUILD_VERBOSE=0". |
1199 | 1199 | ||
@@ -1207,7 +1207,7 @@ When kbuild executes, the following steps are followed (roughly): | |||
1207 | kbuild knows .lds files and includes a rule *lds.S -> *lds. | 1207 | kbuild knows .lds files and includes a rule *lds.S -> *lds. |
1208 | 1208 | ||
1209 | Example: | 1209 | Example: |
1210 | #arch/i386/kernel/Makefile | 1210 | #arch/x86/kernel/Makefile |
1211 | always := vmlinux.lds | 1211 | always := vmlinux.lds |
1212 | 1212 | ||
1213 | #Makefile | 1213 | #Makefile |
diff --git a/Documentation/magic-number.txt b/Documentation/magic-number.txt index 4b12abcb2ad3..abf481f780ec 100644 --- a/Documentation/magic-number.txt +++ b/Documentation/magic-number.txt | |||
@@ -66,7 +66,7 @@ MKISS_DRIVER_MAGIC 0x04bf mkiss_channel drivers/net/mkiss.h | |||
66 | RISCOM8_MAGIC 0x0907 riscom_port drivers/char/riscom8.h | 66 | RISCOM8_MAGIC 0x0907 riscom_port drivers/char/riscom8.h |
67 | SPECIALIX_MAGIC 0x0907 specialix_port drivers/char/specialix_io8.h | 67 | SPECIALIX_MAGIC 0x0907 specialix_port drivers/char/specialix_io8.h |
68 | HDLC_MAGIC 0x239e n_hdlc drivers/char/n_hdlc.c | 68 | HDLC_MAGIC 0x239e n_hdlc drivers/char/n_hdlc.c |
69 | APM_BIOS_MAGIC 0x4101 apm_user arch/i386/kernel/apm.c | 69 | APM_BIOS_MAGIC 0x4101 apm_user arch/x86/kernel/apm_32.c |
70 | CYCLADES_MAGIC 0x4359 cyclades_port include/linux/cyclades.h | 70 | CYCLADES_MAGIC 0x4359 cyclades_port include/linux/cyclades.h |
71 | DB_MAGIC 0x4442 fc_info drivers/net/iph5526_novram.c | 71 | DB_MAGIC 0x4442 fc_info drivers/net/iph5526_novram.c |
72 | DL_MAGIC 0x444d fc_info drivers/net/iph5526_novram.c | 72 | DL_MAGIC 0x444d fc_info drivers/net/iph5526_novram.c |
diff --git a/Documentation/mca.txt b/Documentation/mca.txt index 510375d4209a..dfd130c2207d 100644 --- a/Documentation/mca.txt +++ b/Documentation/mca.txt | |||
@@ -11,7 +11,7 @@ Adapter Detection | |||
11 | 11 | ||
12 | The ideal MCA adapter detection is done through the use of the | 12 | The ideal MCA adapter detection is done through the use of the |
13 | Programmable Option Select registers. Generic functions for doing | 13 | Programmable Option Select registers. Generic functions for doing |
14 | this have been added in include/linux/mca.h and arch/i386/kernel/mca.c. | 14 | this have been added in include/linux/mca.h and arch/x86/kernel/mca_32.c. |
15 | Everything needed to detect adapters and read (and write) configuration | 15 | Everything needed to detect adapters and read (and write) configuration |
16 | information is there. A number of MCA-specific drivers already use | 16 | information is there. A number of MCA-specific drivers already use |
17 | this. The typical probe code looks like the following: | 17 | this. The typical probe code looks like the following: |
@@ -81,7 +81,7 @@ more people use shared IRQs on PCI machines. | |||
81 | In general, an interrupt must be acknowledged not only at the ICU (which | 81 | In general, an interrupt must be acknowledged not only at the ICU (which |
82 | is done automagically by the kernel), but at the device level. In | 82 | is done automagically by the kernel), but at the device level. In |
83 | particular, IRQ 0 must be reset after a timer interrupt (now done in | 83 | particular, IRQ 0 must be reset after a timer interrupt (now done in |
84 | arch/i386/kernel/time.c) or the first timer interrupt hangs the system. | 84 | arch/x86/kernel/time.c) or the first timer interrupt hangs the system. |
85 | There were also problems with the 1.3.x floppy drivers, but that seems | 85 | There were also problems with the 1.3.x floppy drivers, but that seems |
86 | to have been fixed. | 86 | to have been fixed. |
87 | 87 | ||
diff --git a/Documentation/scheduler/sched-arch.txt b/Documentation/scheduler/sched-arch.txt index d43dbcbd163b..28aa1075e291 100644 --- a/Documentation/scheduler/sched-arch.txt +++ b/Documentation/scheduler/sched-arch.txt | |||
@@ -66,7 +66,7 @@ Your cpu_idle routines need to obey the following rules: | |||
66 | barrier issued (followed by a test of need_resched with | 66 | barrier issued (followed by a test of need_resched with |
67 | interrupts disabled, as explained in 3). | 67 | interrupts disabled, as explained in 3). |
68 | 68 | ||
69 | arch/i386/kernel/process.c has examples of both polling and | 69 | arch/x86/kernel/process.c has examples of both polling and |
70 | sleeping idle functions. | 70 | sleeping idle functions. |
71 | 71 | ||
72 | 72 | ||
diff --git a/Documentation/scsi/BusLogic.txt b/Documentation/scsi/BusLogic.txt index d7fbc9488b98..48e982cd6fe7 100644 --- a/Documentation/scsi/BusLogic.txt +++ b/Documentation/scsi/BusLogic.txt | |||
@@ -553,7 +553,7 @@ replacing "/usr/src" with wherever you keep your Linux kernel source tree: | |||
553 | make config | 553 | make config |
554 | make zImage | 554 | make zImage |
555 | 555 | ||
556 | Then install "arch/i386/boot/zImage" as your standard kernel, run lilo if | 556 | Then install "arch/x86/boot/zImage" as your standard kernel, run lilo if |
557 | appropriate, and reboot. | 557 | appropriate, and reboot. |
558 | 558 | ||
559 | 559 | ||
diff --git a/Documentation/serial/computone.txt b/Documentation/serial/computone.txt index c57ea4781e5d..60a6f657c37d 100644 --- a/Documentation/serial/computone.txt +++ b/Documentation/serial/computone.txt | |||
@@ -87,7 +87,7 @@ c) Set address on ISA cards then: | |||
87 | edit /usr/src/linux/drivers/char/ip2.c | 87 | edit /usr/src/linux/drivers/char/ip2.c |
88 | (Optional - may be specified on kernel command line now) | 88 | (Optional - may be specified on kernel command line now) |
89 | d) Run "make zImage" or whatever target you prefer. | 89 | d) Run "make zImage" or whatever target you prefer. |
90 | e) mv /usr/src/linux/arch/i386/boot/zImage to /boot. | 90 | e) mv /usr/src/linux/arch/x86/boot/zImage to /boot. |
91 | f) Add new config for this kernel into /etc/lilo.conf, run "lilo" | 91 | f) Add new config for this kernel into /etc/lilo.conf, run "lilo" |
92 | or copy to a floppy disk and boot from that floppy disk. | 92 | or copy to a floppy disk and boot from that floppy disk. |
93 | g) Reboot using this kernel | 93 | g) Reboot using this kernel |
diff --git a/Documentation/zh_CN/magic-number.txt b/Documentation/zh_CN/magic-number.txt index 4c4ce853577b..c278f412dc65 100644 --- a/Documentation/zh_CN/magic-number.txt +++ b/Documentation/zh_CN/magic-number.txt | |||
@@ -66,7 +66,7 @@ MKISS_DRIVER_MAGIC 0x04bf mkiss_channel drivers/net/mkiss.h | |||
66 | RISCOM8_MAGIC 0x0907 riscom_port drivers/char/riscom8.h | 66 | RISCOM8_MAGIC 0x0907 riscom_port drivers/char/riscom8.h |
67 | SPECIALIX_MAGIC 0x0907 specialix_port drivers/char/specialix_io8.h | 67 | SPECIALIX_MAGIC 0x0907 specialix_port drivers/char/specialix_io8.h |
68 | HDLC_MAGIC 0x239e n_hdlc drivers/char/n_hdlc.c | 68 | HDLC_MAGIC 0x239e n_hdlc drivers/char/n_hdlc.c |
69 | APM_BIOS_MAGIC 0x4101 apm_user arch/i386/kernel/apm.c | 69 | APM_BIOS_MAGIC 0x4101 apm_user arch/x86/kernel/apm_32.c |
70 | CYCLADES_MAGIC 0x4359 cyclades_port include/linux/cyclades.h | 70 | CYCLADES_MAGIC 0x4359 cyclades_port include/linux/cyclades.h |
71 | DB_MAGIC 0x4442 fc_info drivers/net/iph5526_novram.c | 71 | DB_MAGIC 0x4442 fc_info drivers/net/iph5526_novram.c |
72 | DL_MAGIC 0x444d fc_info drivers/net/iph5526_novram.c | 72 | DL_MAGIC 0x444d fc_info drivers/net/iph5526_novram.c |
diff --git a/MAINTAINERS b/MAINTAINERS index 39d8822c3dae..efe0a4b07159 100644 --- a/MAINTAINERS +++ b/MAINTAINERS | |||
@@ -696,7 +696,7 @@ T: git git://git.infradead.org/users/cbou/linux-cns3xxx.git | |||
696 | 696 | ||
697 | ARM/CIRRUS LOGIC EP93XX ARM ARCHITECTURE | 697 | ARM/CIRRUS LOGIC EP93XX ARM ARCHITECTURE |
698 | M: Hartley Sweeten <hsweeten@visionengravers.com> | 698 | M: Hartley Sweeten <hsweeten@visionengravers.com> |
699 | M: Ryan Mallon <ryan@bluewatersys.com> | 699 | M: Ryan Mallon <rmallon@gmail.com> |
700 | L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) | 700 | L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) |
701 | S: Maintained | 701 | S: Maintained |
702 | F: arch/arm/mach-ep93xx/ | 702 | F: arch/arm/mach-ep93xx/ |
@@ -1588,7 +1588,7 @@ F: Documentation/sound/alsa/Bt87x.txt | |||
1588 | F: sound/pci/bt87x.c | 1588 | F: sound/pci/bt87x.c |
1589 | 1589 | ||
1590 | BT8XXGPIO DRIVER | 1590 | BT8XXGPIO DRIVER |
1591 | M: Michael Buesch <mb@bu3sch.de> | 1591 | M: Michael Buesch <m@bues.ch> |
1592 | W: http://bu3sch.de/btgpio.php | 1592 | W: http://bu3sch.de/btgpio.php |
1593 | S: Maintained | 1593 | S: Maintained |
1594 | F: drivers/gpio/bt8xxgpio.c | 1594 | F: drivers/gpio/bt8xxgpio.c |
@@ -5910,7 +5910,7 @@ S: Maintained | |||
5910 | F: drivers/net/sonic.* | 5910 | F: drivers/net/sonic.* |
5911 | 5911 | ||
5912 | SONICS SILICON BACKPLANE DRIVER (SSB) | 5912 | SONICS SILICON BACKPLANE DRIVER (SSB) |
5913 | M: Michael Buesch <mb@bu3sch.de> | 5913 | M: Michael Buesch <m@bues.ch> |
5914 | L: netdev@vger.kernel.org | 5914 | L: netdev@vger.kernel.org |
5915 | S: Maintained | 5915 | S: Maintained |
5916 | F: drivers/ssb/ | 5916 | F: drivers/ssb/ |
diff --git a/arch/alpha/include/asm/floppy.h b/arch/alpha/include/asm/floppy.h index 0be50413b2b5..46cefbd50e73 100644 --- a/arch/alpha/include/asm/floppy.h +++ b/arch/alpha/include/asm/floppy.h | |||
@@ -27,7 +27,7 @@ | |||
27 | #define fd_cacheflush(addr,size) /* nothing */ | 27 | #define fd_cacheflush(addr,size) /* nothing */ |
28 | #define fd_request_irq() request_irq(FLOPPY_IRQ, floppy_interrupt,\ | 28 | #define fd_request_irq() request_irq(FLOPPY_IRQ, floppy_interrupt,\ |
29 | IRQF_DISABLED, "floppy", NULL) | 29 | IRQF_DISABLED, "floppy", NULL) |
30 | #define fd_free_irq() free_irq(FLOPPY_IRQ, NULL); | 30 | #define fd_free_irq() free_irq(FLOPPY_IRQ, NULL) |
31 | 31 | ||
32 | #ifdef CONFIG_PCI | 32 | #ifdef CONFIG_PCI |
33 | 33 | ||
diff --git a/arch/arm/common/scoop.c b/arch/arm/common/scoop.c index c11af1e4bad3..a07b0e763a80 100644 --- a/arch/arm/common/scoop.c +++ b/arch/arm/common/scoop.c | |||
@@ -193,7 +193,7 @@ static int __devinit scoop_probe(struct platform_device *pdev) | |||
193 | spin_lock_init(&devptr->scoop_lock); | 193 | spin_lock_init(&devptr->scoop_lock); |
194 | 194 | ||
195 | inf = pdev->dev.platform_data; | 195 | inf = pdev->dev.platform_data; |
196 | devptr->base = ioremap(mem->start, mem->end - mem->start + 1); | 196 | devptr->base = ioremap(mem->start, resource_size(mem)); |
197 | 197 | ||
198 | if (!devptr->base) { | 198 | if (!devptr->base) { |
199 | ret = -ENOMEM; | 199 | ret = -ENOMEM; |
diff --git a/arch/arm/mach-at91/at91sam9261_devices.c b/arch/arm/mach-at91/at91sam9261_devices.c index 5004bf0a05f2..0f917928eeb7 100644 --- a/arch/arm/mach-at91/at91sam9261_devices.c +++ b/arch/arm/mach-at91/at91sam9261_devices.c | |||
@@ -525,7 +525,7 @@ void __init at91_add_device_lcdc(struct atmel_lcdfb_info *data) | |||
525 | if (ARRAY_SIZE(lcdc_resources) > 2) { | 525 | if (ARRAY_SIZE(lcdc_resources) > 2) { |
526 | void __iomem *fb; | 526 | void __iomem *fb; |
527 | struct resource *fb_res = &lcdc_resources[2]; | 527 | struct resource *fb_res = &lcdc_resources[2]; |
528 | size_t fb_len = fb_res->end - fb_res->start + 1; | 528 | size_t fb_len = resource_size(fb_res); |
529 | 529 | ||
530 | fb = ioremap(fb_res->start, fb_len); | 530 | fb = ioremap(fb_res->start, fb_len); |
531 | if (fb) { | 531 | if (fb) { |
diff --git a/arch/arm/mach-at91/board-snapper9260.c b/arch/arm/mach-at91/board-snapper9260.c index 3eb0a1153cc8..6010ce16b3cf 100644 --- a/arch/arm/mach-at91/board-snapper9260.c +++ b/arch/arm/mach-at91/board-snapper9260.c | |||
@@ -4,7 +4,7 @@ | |||
4 | * Copyright (C) 2010 Bluewater System Ltd | 4 | * Copyright (C) 2010 Bluewater System Ltd |
5 | * | 5 | * |
6 | * Author: Andre Renaud <andre@bluewatersys.com> | 6 | * Author: Andre Renaud <andre@bluewatersys.com> |
7 | * Author: Ryan Mallon <ryan@bluewatersys.com> | 7 | * Author: Ryan Mallon |
8 | * | 8 | * |
9 | * This program is free software; you can redistribute it and/or modify | 9 | * This program is free software; you can redistribute it and/or modify |
10 | * it under the terms of the GNU General Public License as published by | 10 | * it under the terms of the GNU General Public License as published by |
diff --git a/arch/arm/mach-dove/common.c b/arch/arm/mach-dove/common.c index 5ed51b84c1b2..83dce859886d 100644 --- a/arch/arm/mach-dove/common.c +++ b/arch/arm/mach-dove/common.c | |||
@@ -13,11 +13,9 @@ | |||
13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
14 | #include <linux/platform_device.h> | 14 | #include <linux/platform_device.h> |
15 | #include <linux/pci.h> | 15 | #include <linux/pci.h> |
16 | #include <linux/serial_8250.h> | ||
17 | #include <linux/clk.h> | 16 | #include <linux/clk.h> |
18 | #include <linux/mbus.h> | 17 | #include <linux/mbus.h> |
19 | #include <linux/ata_platform.h> | 18 | #include <linux/ata_platform.h> |
20 | #include <linux/serial_8250.h> | ||
21 | #include <linux/gpio.h> | 19 | #include <linux/gpio.h> |
22 | #include <asm/page.h> | 20 | #include <asm/page.h> |
23 | #include <asm/setup.h> | 21 | #include <asm/setup.h> |
diff --git a/arch/arm/mach-ep93xx/simone.c b/arch/arm/mach-ep93xx/simone.c index d96dc1c5da20..8392e95d7cea 100644 --- a/arch/arm/mach-ep93xx/simone.c +++ b/arch/arm/mach-ep93xx/simone.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * arch/arm/mach-ep93xx/simone.c | 2 | * arch/arm/mach-ep93xx/simone.c |
3 | * Simplemachines Sim.One support. | 3 | * Simplemachines Sim.One support. |
4 | * | 4 | * |
5 | * Copyright (C) 2010 Ryan Mallon <ryan@bluewatersys.com> | 5 | * Copyright (C) 2010 Ryan Mallon |
6 | * | 6 | * |
7 | * Based on the 2.6.24.7 support: | 7 | * Based on the 2.6.24.7 support: |
8 | * Copyright (C) 2009 Simplemachines | 8 | * Copyright (C) 2009 Simplemachines |
@@ -65,7 +65,7 @@ static void __init simone_init_machine(void) | |||
65 | } | 65 | } |
66 | 66 | ||
67 | MACHINE_START(SIM_ONE, "Simplemachines Sim.One Board") | 67 | MACHINE_START(SIM_ONE, "Simplemachines Sim.One Board") |
68 | /* Maintainer: Ryan Mallon <ryan@bluewatersys.com> */ | 68 | /* Maintainer: Ryan Mallon */ |
69 | .boot_params = EP93XX_SDCE0_PHYS_BASE + 0x100, | 69 | .boot_params = EP93XX_SDCE0_PHYS_BASE + 0x100, |
70 | .map_io = ep93xx_map_io, | 70 | .map_io = ep93xx_map_io, |
71 | .init_irq = ep93xx_init_irq, | 71 | .init_irq = ep93xx_init_irq, |
diff --git a/arch/arm/mach-ep93xx/snappercl15.c b/arch/arm/mach-ep93xx/snappercl15.c index ac601fe2b448..2e9c614757e4 100644 --- a/arch/arm/mach-ep93xx/snappercl15.c +++ b/arch/arm/mach-ep93xx/snappercl15.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * Bluewater Systems Snapper CL15 system module | 3 | * Bluewater Systems Snapper CL15 system module |
4 | * | 4 | * |
5 | * Copyright (C) 2009 Bluewater Systems Ltd | 5 | * Copyright (C) 2009 Bluewater Systems Ltd |
6 | * Author: Ryan Mallon <ryan@bluewatersys.com> | 6 | * Author: Ryan Mallon |
7 | * | 7 | * |
8 | * NAND code adapted from driver by: | 8 | * NAND code adapted from driver by: |
9 | * Andre Renaud <andre@bluewatersys.com> | 9 | * Andre Renaud <andre@bluewatersys.com> |
@@ -162,7 +162,7 @@ static void __init snappercl15_init_machine(void) | |||
162 | } | 162 | } |
163 | 163 | ||
164 | MACHINE_START(SNAPPER_CL15, "Bluewater Systems Snapper CL15") | 164 | MACHINE_START(SNAPPER_CL15, "Bluewater Systems Snapper CL15") |
165 | /* Maintainer: Ryan Mallon <ryan@bluewatersys.com> */ | 165 | /* Maintainer: Ryan Mallon */ |
166 | .boot_params = EP93XX_SDCE0_PHYS_BASE + 0x100, | 166 | .boot_params = EP93XX_SDCE0_PHYS_BASE + 0x100, |
167 | .map_io = ep93xx_map_io, | 167 | .map_io = ep93xx_map_io, |
168 | .init_irq = ep93xx_init_irq, | 168 | .init_irq = ep93xx_init_irq, |
diff --git a/arch/arm/mach-mv78xx0/pcie.c b/arch/arm/mach-mv78xx0/pcie.c index a560439dcc3c..f27c7d2fa9f7 100644 --- a/arch/arm/mach-mv78xx0/pcie.c +++ b/arch/arm/mach-mv78xx0/pcie.c | |||
@@ -129,12 +129,12 @@ static void __init mv78xx0_pcie_preinit(void) | |||
129 | struct pcie_port *pp = pcie_port + i; | 129 | struct pcie_port *pp = pcie_port + i; |
130 | 130 | ||
131 | mv78xx0_setup_pcie_io_win(win++, pp->res[0].start, | 131 | mv78xx0_setup_pcie_io_win(win++, pp->res[0].start, |
132 | pp->res[0].end - pp->res[0].start + 1, | 132 | resource_size(&pp->res[0]), |
133 | pp->maj, pp->min); | 133 | pp->maj, pp->min); |
134 | 134 | ||
135 | mv78xx0_setup_pcie_mem_win(win++, pp->res[1].start, | 135 | mv78xx0_setup_pcie_mem_win(win++, pp->res[1].start, |
136 | pp->res[1].end - pp->res[1].start + 1, | 136 | resource_size(&pp->res[1]), |
137 | pp->maj, pp->min); | 137 | pp->maj, pp->min); |
138 | } | 138 | } |
139 | } | 139 | } |
140 | 140 | ||
diff --git a/arch/arm/mach-pxa/include/mach/corgi.h b/arch/arm/mach-pxa/include/mach/corgi.h index 0011055bc3f9..5dfd1195a5a7 100644 --- a/arch/arm/mach-pxa/include/mach/corgi.h +++ b/arch/arm/mach-pxa/include/mach/corgi.h | |||
@@ -34,7 +34,7 @@ | |||
34 | #define CORGI_GPIO_LCDCON_CS (19) /* LCD Control Chip Select */ | 34 | #define CORGI_GPIO_LCDCON_CS (19) /* LCD Control Chip Select */ |
35 | #define CORGI_GPIO_MAX1111_CS (20) /* MAX1111 Chip Select */ | 35 | #define CORGI_GPIO_MAX1111_CS (20) /* MAX1111 Chip Select */ |
36 | #define CORGI_GPIO_ADC_TEMP_ON (21) /* Select battery voltage or temperature */ | 36 | #define CORGI_GPIO_ADC_TEMP_ON (21) /* Select battery voltage or temperature */ |
37 | #define CORGI_GPIO_IR_ON (22) /* Enable IR Transciever */ | 37 | #define CORGI_GPIO_IR_ON (22) /* Enable IR Transceiver */ |
38 | #define CORGI_GPIO_ADS7846_CS (24) /* ADS7846 Chip Select */ | 38 | #define CORGI_GPIO_ADS7846_CS (24) /* ADS7846 Chip Select */ |
39 | #define CORGI_GPIO_SD_PWR (33) /* MMC/SD Power */ | 39 | #define CORGI_GPIO_SD_PWR (33) /* MMC/SD Power */ |
40 | #define CORGI_GPIO_CHRG_ON (38) /* Enable battery Charging */ | 40 | #define CORGI_GPIO_CHRG_ON (38) /* Enable battery Charging */ |
diff --git a/arch/arm/mach-pxa/include/mach/pxa27x-udc.h b/arch/arm/mach-pxa/include/mach/pxa27x-udc.h index ab1443f8bd89..4cf28f670706 100644 --- a/arch/arm/mach-pxa/include/mach/pxa27x-udc.h +++ b/arch/arm/mach-pxa/include/mach/pxa27x-udc.h | |||
@@ -56,9 +56,9 @@ | |||
56 | #define UDCFNR __REG(0x40600014) /* UDC Frame Number Register */ | 56 | #define UDCFNR __REG(0x40600014) /* UDC Frame Number Register */ |
57 | #define UDCOTGICR __REG(0x40600018) /* UDC On-The-Go interrupt control */ | 57 | #define UDCOTGICR __REG(0x40600018) /* UDC On-The-Go interrupt control */ |
58 | #define UDCOTGICR_IESF (1 << 24) /* OTG SET_FEATURE command recvd */ | 58 | #define UDCOTGICR_IESF (1 << 24) /* OTG SET_FEATURE command recvd */ |
59 | #define UDCOTGICR_IEXR (1 << 17) /* Extra Transciever Interrupt | 59 | #define UDCOTGICR_IEXR (1 << 17) /* Extra Transceiver Interrupt |
60 | Rising Edge Interrupt Enable */ | 60 | Rising Edge Interrupt Enable */ |
61 | #define UDCOTGICR_IEXF (1 << 16) /* Extra Transciever Interrupt | 61 | #define UDCOTGICR_IEXF (1 << 16) /* Extra Transceiver Interrupt |
62 | Falling Edge Interrupt Enable */ | 62 | Falling Edge Interrupt Enable */ |
63 | #define UDCOTGICR_IEVV40R (1 << 9) /* OTG Vbus Valid 4.0V Rising Edge | 63 | #define UDCOTGICR_IEVV40R (1 << 9) /* OTG Vbus Valid 4.0V Rising Edge |
64 | Interrupt Enable */ | 64 | Interrupt Enable */ |
diff --git a/arch/arm/mach-s3c2410/h1940-bluetooth.c b/arch/arm/mach-s3c2410/h1940-bluetooth.c index 2c126bbca08d..a5eeb62ce1c2 100644 --- a/arch/arm/mach-s3c2410/h1940-bluetooth.c +++ b/arch/arm/mach-s3c2410/h1940-bluetooth.c | |||
@@ -18,7 +18,6 @@ | |||
18 | #include <linux/leds.h> | 18 | #include <linux/leds.h> |
19 | #include <linux/gpio.h> | 19 | #include <linux/gpio.h> |
20 | #include <linux/rfkill.h> | 20 | #include <linux/rfkill.h> |
21 | #include <linux/leds.h> | ||
22 | 21 | ||
23 | #include <mach/regs-gpio.h> | 22 | #include <mach/regs-gpio.h> |
24 | #include <mach/hardware.h> | 23 | #include <mach/hardware.h> |
diff --git a/arch/arm/mach-shmobile/board-ap4evb.c b/arch/arm/mach-shmobile/board-ap4evb.c index b473b8efac68..837138e369bc 100644 --- a/arch/arm/mach-shmobile/board-ap4evb.c +++ b/arch/arm/mach-shmobile/board-ap4evb.c | |||
@@ -443,7 +443,7 @@ static struct platform_device usb1_host_device = { | |||
443 | .resource = usb1_host_resources, | 443 | .resource = usb1_host_resources, |
444 | }; | 444 | }; |
445 | 445 | ||
446 | const static struct fb_videomode ap4evb_lcdc_modes[] = { | 446 | static const struct fb_videomode ap4evb_lcdc_modes[] = { |
447 | { | 447 | { |
448 | #ifdef CONFIG_AP4EVB_QHD | 448 | #ifdef CONFIG_AP4EVB_QHD |
449 | .name = "R63302(QHD)", | 449 | .name = "R63302(QHD)", |
diff --git a/arch/arm/mach-u300/core.c b/arch/arm/mach-u300/core.c index 513d6abec1f5..399c89f14dfb 100644 --- a/arch/arm/mach-u300/core.c +++ b/arch/arm/mach-u300/core.c | |||
@@ -1791,7 +1791,7 @@ static void __init u300_assign_physmem(void) | |||
1791 | 0 == res->start) { | 1791 | 0 == res->start) { |
1792 | res->start = curr_start; | 1792 | res->start = curr_start; |
1793 | res->end += curr_start; | 1793 | res->end += curr_start; |
1794 | curr_start += (res->end - res->start + 1); | 1794 | curr_start += resource_size(res); |
1795 | 1795 | ||
1796 | printk(KERN_INFO "core.c: Mapping RAM " \ | 1796 | printk(KERN_INFO "core.c: Mapping RAM " \ |
1797 | "%#x-%#x to device %s:%s\n", | 1797 | "%#x-%#x to device %s:%s\n", |
diff --git a/arch/arm/mach-ux500/board-mop500-regulators.c b/arch/arm/mach-ux500/board-mop500-regulators.c index 9ed0f90cfe23..0f2e522f387d 100644 --- a/arch/arm/mach-ux500/board-mop500-regulators.c +++ b/arch/arm/mach-ux500/board-mop500-regulators.c | |||
@@ -77,7 +77,7 @@ static struct regulator_consumer_supply ab8500_vtvout_consumers[] = { | |||
77 | static struct regulator_consumer_supply ab8500_vintcore_consumers[] = { | 77 | static struct regulator_consumer_supply ab8500_vintcore_consumers[] = { |
78 | /* SoC core supply, no device */ | 78 | /* SoC core supply, no device */ |
79 | REGULATOR_SUPPLY("v-intcore", NULL), | 79 | REGULATOR_SUPPLY("v-intcore", NULL), |
80 | /* USB Transciever */ | 80 | /* USB Transceiver */ |
81 | REGULATOR_SUPPLY("vddulpivio18", "ab8500-usb.0"), | 81 | REGULATOR_SUPPLY("vddulpivio18", "ab8500-usb.0"), |
82 | }; | 82 | }; |
83 | 83 | ||
diff --git a/arch/arm/plat-s5p/sysmmu.c b/arch/arm/plat-s5p/sysmmu.c index 54f5eddc921d..e1cbc728c775 100644 --- a/arch/arm/plat-s5p/sysmmu.c +++ b/arch/arm/plat-s5p/sysmmu.c | |||
@@ -232,8 +232,8 @@ static int s5p_sysmmu_probe(struct platform_device *pdev) | |||
232 | goto err_res; | 232 | goto err_res; |
233 | } | 233 | } |
234 | 234 | ||
235 | mem = request_mem_region(res->start, | 235 | mem = request_mem_region(res->start, resource_size(res), |
236 | ((res->end) - (res->start)) + 1, pdev->name); | 236 | pdev->name); |
237 | if (!mem) { | 237 | if (!mem) { |
238 | dev_err(dev, "Failed to request the memory region of %s.\n", | 238 | dev_err(dev, "Failed to request the memory region of %s.\n", |
239 | sysmmu_ips_name[i]); | 239 | sysmmu_ips_name[i]); |
@@ -241,7 +241,7 @@ static int s5p_sysmmu_probe(struct platform_device *pdev) | |||
241 | goto err_res; | 241 | goto err_res; |
242 | } | 242 | } |
243 | 243 | ||
244 | sysmmusfrs[i] = ioremap(res->start, res->end - res->start + 1); | 244 | sysmmusfrs[i] = ioremap(res->start, resource_size(res)); |
245 | if (!sysmmusfrs[i]) { | 245 | if (!sysmmusfrs[i]) { |
246 | dev_err(dev, "Failed to ioremap() for %s.\n", | 246 | dev_err(dev, "Failed to ioremap() for %s.\n", |
247 | sysmmu_ips_name[i]); | 247 | sysmmu_ips_name[i]); |
diff --git a/arch/arm/plat-samsung/pm-check.c b/arch/arm/plat-samsung/pm-check.c index 6b733fafe7cd..3cbd62666b1e 100644 --- a/arch/arm/plat-samsung/pm-check.c +++ b/arch/arm/plat-samsung/pm-check.c | |||
@@ -72,7 +72,7 @@ static void s3c_pm_run_sysram(run_fn_t fn, u32 *arg) | |||
72 | 72 | ||
73 | static u32 *s3c_pm_countram(struct resource *res, u32 *val) | 73 | static u32 *s3c_pm_countram(struct resource *res, u32 *val) |
74 | { | 74 | { |
75 | u32 size = (u32)(res->end - res->start)+1; | 75 | u32 size = (u32)resource_size(res); |
76 | 76 | ||
77 | size += CHECK_CHUNKSIZE-1; | 77 | size += CHECK_CHUNKSIZE-1; |
78 | size /= CHECK_CHUNKSIZE; | 78 | size /= CHECK_CHUNKSIZE; |
diff --git a/arch/avr32/kernel/setup.c b/arch/avr32/kernel/setup.c index bb0974cce4ac..b4247f478065 100644 --- a/arch/avr32/kernel/setup.c +++ b/arch/avr32/kernel/setup.c | |||
@@ -444,7 +444,7 @@ static unsigned long __init | |||
444 | find_bootmap_pfn(const struct resource *mem) | 444 | find_bootmap_pfn(const struct resource *mem) |
445 | { | 445 | { |
446 | unsigned long bootmap_pages, bootmap_len; | 446 | unsigned long bootmap_pages, bootmap_len; |
447 | unsigned long node_pages = PFN_UP(mem->end - mem->start + 1); | 447 | unsigned long node_pages = PFN_UP(resource_size(mem)); |
448 | unsigned long bootmap_start; | 448 | unsigned long bootmap_start; |
449 | 449 | ||
450 | bootmap_pages = bootmem_bootmap_pages(node_pages); | 450 | bootmap_pages = bootmem_bootmap_pages(node_pages); |
@@ -541,10 +541,10 @@ static void __init setup_bootmem(void) | |||
541 | */ | 541 | */ |
542 | if (res->start >= PFN_PHYS(first_pfn) | 542 | if (res->start >= PFN_PHYS(first_pfn) |
543 | && res->end < PFN_PHYS(max_pfn)) | 543 | && res->end < PFN_PHYS(max_pfn)) |
544 | reserve_bootmem_node( | 544 | reserve_bootmem_node(NODE_DATA(node), |
545 | NODE_DATA(node), res->start, | 545 | res->start, |
546 | res->end - res->start + 1, | 546 | resource_size(res), |
547 | BOOTMEM_DEFAULT); | 547 | BOOTMEM_DEFAULT); |
548 | } | 548 | } |
549 | 549 | ||
550 | node_set_online(node); | 550 | node_set_online(node); |
diff --git a/arch/avr32/mach-at32ap/extint.c b/arch/avr32/mach-at32ap/extint.c index fbc2aeaebddb..cfb298d66305 100644 --- a/arch/avr32/mach-at32ap/extint.c +++ b/arch/avr32/mach-at32ap/extint.c | |||
@@ -204,7 +204,7 @@ static int __init eic_probe(struct platform_device *pdev) | |||
204 | } | 204 | } |
205 | 205 | ||
206 | eic->first_irq = EIM_IRQ_BASE + 32 * pdev->id; | 206 | eic->first_irq = EIM_IRQ_BASE + 32 * pdev->id; |
207 | eic->regs = ioremap(regs->start, regs->end - regs->start + 1); | 207 | eic->regs = ioremap(regs->start, resource_size(regs)); |
208 | if (!eic->regs) { | 208 | if (!eic->regs) { |
209 | dev_dbg(&pdev->dev, "failed to map regs\n"); | 209 | dev_dbg(&pdev->dev, "failed to map regs\n"); |
210 | goto err_ioremap; | 210 | goto err_ioremap; |
diff --git a/arch/avr32/mach-at32ap/hsmc.c b/arch/avr32/mach-at32ap/hsmc.c index f7672d3e86b8..f66245e6e63e 100644 --- a/arch/avr32/mach-at32ap/hsmc.c +++ b/arch/avr32/mach-at32ap/hsmc.c | |||
@@ -245,7 +245,7 @@ static int hsmc_probe(struct platform_device *pdev) | |||
245 | 245 | ||
246 | hsmc->pclk = pclk; | 246 | hsmc->pclk = pclk; |
247 | hsmc->mck = mck; | 247 | hsmc->mck = mck; |
248 | hsmc->regs = ioremap(regs->start, regs->end - regs->start + 1); | 248 | hsmc->regs = ioremap(regs->start, resource_size(regs)); |
249 | if (!hsmc->regs) | 249 | if (!hsmc->regs) |
250 | goto out_disable_clocks; | 250 | goto out_disable_clocks; |
251 | 251 | ||
diff --git a/arch/avr32/mach-at32ap/intc.c b/arch/avr32/mach-at32ap/intc.c index c9ac2f8e8f64..258682bc1278 100644 --- a/arch/avr32/mach-at32ap/intc.c +++ b/arch/avr32/mach-at32ap/intc.c | |||
@@ -107,7 +107,7 @@ void __init init_IRQ(void) | |||
107 | 107 | ||
108 | clk_enable(pclk); | 108 | clk_enable(pclk); |
109 | 109 | ||
110 | intc0.regs = ioremap(regs->start, regs->end - regs->start + 1); | 110 | intc0.regs = ioremap(regs->start, resource_size(regs)); |
111 | if (!intc0.regs) { | 111 | if (!intc0.regs) { |
112 | printk(KERN_EMERG "intc: failed to map registers (0x%08lx)\n", | 112 | printk(KERN_EMERG "intc: failed to map registers (0x%08lx)\n", |
113 | (unsigned long)regs->start); | 113 | (unsigned long)regs->start); |
diff --git a/arch/avr32/mach-at32ap/pio.c b/arch/avr32/mach-at32ap/pio.c index 2e0aa853a4bc..9b39dea6682f 100644 --- a/arch/avr32/mach-at32ap/pio.c +++ b/arch/avr32/mach-at32ap/pio.c | |||
@@ -461,7 +461,7 @@ void __init at32_init_pio(struct platform_device *pdev) | |||
461 | clk_enable(pio->clk); | 461 | clk_enable(pio->clk); |
462 | 462 | ||
463 | pio->pdev = pdev; | 463 | pio->pdev = pdev; |
464 | pio->regs = ioremap(regs->start, regs->end - regs->start + 1); | 464 | pio->regs = ioremap(regs->start, resource_size(regs)); |
465 | 465 | ||
466 | /* start with irqs disabled and acked */ | 466 | /* start with irqs disabled and acked */ |
467 | pio_writel(pio, IDR, ~0UL); | 467 | pio_writel(pio, IDR, ~0UL); |
diff --git a/arch/h8300/kernel/setup.c b/arch/h8300/kernel/setup.c index 7fda657110eb..68d651081bd3 100644 --- a/arch/h8300/kernel/setup.c +++ b/arch/h8300/kernel/setup.c | |||
@@ -46,7 +46,7 @@ | |||
46 | #include <asm/regs267x.h> | 46 | #include <asm/regs267x.h> |
47 | #endif | 47 | #endif |
48 | 48 | ||
49 | #define STUBSIZE 0xc000; | 49 | #define STUBSIZE 0xc000 |
50 | 50 | ||
51 | unsigned long rom_length; | 51 | unsigned long rom_length; |
52 | unsigned long memory_start; | 52 | unsigned long memory_start; |
diff --git a/arch/ia64/include/asm/sn/tioce.h b/arch/ia64/include/asm/sn/tioce.h index 893468e1b41b..6eae8ada90f0 100644 --- a/arch/ia64/include/asm/sn/tioce.h +++ b/arch/ia64/include/asm/sn/tioce.h | |||
@@ -467,7 +467,7 @@ typedef volatile struct tioce { | |||
467 | #define CE_LSI_GB_CFG1_RXL0S_THS_SHFT 0 | 467 | #define CE_LSI_GB_CFG1_RXL0S_THS_SHFT 0 |
468 | #define CE_LSI_GB_CFG1_RXL0S_THS_MASK (0xffULL << 0) | 468 | #define CE_LSI_GB_CFG1_RXL0S_THS_MASK (0xffULL << 0) |
469 | #define CE_LSI_GB_CFG1_RXL0S_SMP_SHFT 8 | 469 | #define CE_LSI_GB_CFG1_RXL0S_SMP_SHFT 8 |
470 | #define CE_LSI_GB_CFG1_RXL0S_SMP_MASK (0xfULL << 8); | 470 | #define CE_LSI_GB_CFG1_RXL0S_SMP_MASK (0xfULL << 8) |
471 | #define CE_LSI_GB_CFG1_RXL0S_ADJ_SHFT 12 | 471 | #define CE_LSI_GB_CFG1_RXL0S_ADJ_SHFT 12 |
472 | #define CE_LSI_GB_CFG1_RXL0S_ADJ_MASK (0x7ULL << 12) | 472 | #define CE_LSI_GB_CFG1_RXL0S_ADJ_MASK (0x7ULL << 12) |
473 | #define CE_LSI_GB_CFG1_RXL0S_FLT_SHFT 15 | 473 | #define CE_LSI_GB_CFG1_RXL0S_FLT_SHFT 15 |
diff --git a/arch/microblaze/pci/pci-common.c b/arch/microblaze/pci/pci-common.c index 041b1d86d75b..4cfae20f1067 100644 --- a/arch/microblaze/pci/pci-common.c +++ b/arch/microblaze/pci/pci-common.c | |||
@@ -94,7 +94,7 @@ void pcibios_free_controller(struct pci_controller *phb) | |||
94 | 94 | ||
95 | static resource_size_t pcibios_io_size(const struct pci_controller *hose) | 95 | static resource_size_t pcibios_io_size(const struct pci_controller *hose) |
96 | { | 96 | { |
97 | return hose->io_resource.end - hose->io_resource.start + 1; | 97 | return resource_size(&hose->io_resource); |
98 | } | 98 | } |
99 | 99 | ||
100 | int pcibios_vaddr_is_ioport(void __iomem *address) | 100 | int pcibios_vaddr_is_ioport(void __iomem *address) |
diff --git a/arch/mips/bcm47xx/setup.c b/arch/mips/bcm47xx/setup.c index 73b529b57433..cfae81571ded 100644 --- a/arch/mips/bcm47xx/setup.c +++ b/arch/mips/bcm47xx/setup.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (C) 2004 Florian Schirmer <jolt@tuxbox.org> | 2 | * Copyright (C) 2004 Florian Schirmer <jolt@tuxbox.org> |
3 | * Copyright (C) 2006 Felix Fietkau <nbd@openwrt.org> | 3 | * Copyright (C) 2006 Felix Fietkau <nbd@openwrt.org> |
4 | * Copyright (C) 2006 Michael Buesch <mb@bu3sch.de> | 4 | * Copyright (C) 2006 Michael Buesch <m@bues.ch> |
5 | * Copyright (C) 2010 Waldemar Brodkorb <wbx@openadk.org> | 5 | * Copyright (C) 2010 Waldemar Brodkorb <wbx@openadk.org> |
6 | * Copyright (C) 2010-2011 Hauke Mehrtens <hauke@hauke-m.de> | 6 | * Copyright (C) 2010-2011 Hauke Mehrtens <hauke@hauke-m.de> |
7 | * | 7 | * |
diff --git a/arch/mips/include/asm/floppy.h b/arch/mips/include/asm/floppy.h index c5c7c0e6064c..4456c9c47e21 100644 --- a/arch/mips/include/asm/floppy.h +++ b/arch/mips/include/asm/floppy.h | |||
@@ -29,7 +29,7 @@ static inline void fd_cacheflush(char * addr, long size) | |||
29 | #define FLOPPY0_TYPE fd_drive_type(0) | 29 | #define FLOPPY0_TYPE fd_drive_type(0) |
30 | #define FLOPPY1_TYPE fd_drive_type(1) | 30 | #define FLOPPY1_TYPE fd_drive_type(1) |
31 | 31 | ||
32 | #define FDC1 fd_getfdaddr1(); | 32 | #define FDC1 fd_getfdaddr1() |
33 | 33 | ||
34 | #define N_FDC 1 /* do you *really* want a second controller? */ | 34 | #define N_FDC 1 /* do you *really* want a second controller? */ |
35 | #define N_DRIVE 8 | 35 | #define N_DRIVE 8 |
diff --git a/arch/mips/include/asm/mach-jz4740/gpio.h b/arch/mips/include/asm/mach-jz4740/gpio.h index 7b74703745bb..1a6482ea0bb3 100644 --- a/arch/mips/include/asm/mach-jz4740/gpio.h +++ b/arch/mips/include/asm/mach-jz4740/gpio.h | |||
@@ -25,14 +25,13 @@ enum jz_gpio_function { | |||
25 | JZ_GPIO_FUNC3, | 25 | JZ_GPIO_FUNC3, |
26 | }; | 26 | }; |
27 | 27 | ||
28 | |||
29 | /* | 28 | /* |
30 | Usually a driver for a SoC component has to request several gpio pins and | 29 | Usually a driver for a SoC component has to request several gpio pins and |
31 | configure them as funcion pins. | 30 | configure them as funcion pins. |
32 | jz_gpio_bulk_request can be used to ease this process. | 31 | jz_gpio_bulk_request can be used to ease this process. |
33 | Usually one would do something like: | 32 | Usually one would do something like: |
34 | 33 | ||
35 | const static struct jz_gpio_bulk_request i2c_pins[] = { | 34 | static const struct jz_gpio_bulk_request i2c_pins[] = { |
36 | JZ_GPIO_BULK_PIN(I2C_SDA), | 35 | JZ_GPIO_BULK_PIN(I2C_SDA), |
37 | JZ_GPIO_BULK_PIN(I2C_SCK), | 36 | JZ_GPIO_BULK_PIN(I2C_SCK), |
38 | }; | 37 | }; |
@@ -47,8 +46,8 @@ enum jz_gpio_function { | |||
47 | 46 | ||
48 | jz_gpio_bulk_free(i2c_pins, ARRAY_SIZE(i2c_pins)); | 47 | jz_gpio_bulk_free(i2c_pins, ARRAY_SIZE(i2c_pins)); |
49 | 48 | ||
50 | |||
51 | */ | 49 | */ |
50 | |||
52 | struct jz_gpio_bulk_request { | 51 | struct jz_gpio_bulk_request { |
53 | int gpio; | 52 | int gpio; |
54 | const char *name; | 53 | const char *name; |
diff --git a/arch/mips/lantiq/devices.c b/arch/mips/lantiq/devices.c index 7b82c34cb169..44a36771c819 100644 --- a/arch/mips/lantiq/devices.c +++ b/arch/mips/lantiq/devices.c | |||
@@ -15,11 +15,9 @@ | |||
15 | #include <linux/platform_device.h> | 15 | #include <linux/platform_device.h> |
16 | #include <linux/leds.h> | 16 | #include <linux/leds.h> |
17 | #include <linux/etherdevice.h> | 17 | #include <linux/etherdevice.h> |
18 | #include <linux/reboot.h> | ||
19 | #include <linux/time.h> | 18 | #include <linux/time.h> |
20 | #include <linux/io.h> | 19 | #include <linux/io.h> |
21 | #include <linux/gpio.h> | 20 | #include <linux/gpio.h> |
22 | #include <linux/leds.h> | ||
23 | 21 | ||
24 | #include <asm/bootinfo.h> | 22 | #include <asm/bootinfo.h> |
25 | #include <asm/irq.h> | 23 | #include <asm/irq.h> |
diff --git a/arch/mips/lantiq/xway/devices.c b/arch/mips/lantiq/xway/devices.c index e09e789dfc27..d0e32ab2ea07 100644 --- a/arch/mips/lantiq/xway/devices.c +++ b/arch/mips/lantiq/xway/devices.c | |||
@@ -16,11 +16,9 @@ | |||
16 | #include <linux/platform_device.h> | 16 | #include <linux/platform_device.h> |
17 | #include <linux/leds.h> | 17 | #include <linux/leds.h> |
18 | #include <linux/etherdevice.h> | 18 | #include <linux/etherdevice.h> |
19 | #include <linux/reboot.h> | ||
20 | #include <linux/time.h> | 19 | #include <linux/time.h> |
21 | #include <linux/io.h> | 20 | #include <linux/io.h> |
22 | #include <linux/gpio.h> | 21 | #include <linux/gpio.h> |
23 | #include <linux/leds.h> | ||
24 | 22 | ||
25 | #include <asm/bootinfo.h> | 23 | #include <asm/bootinfo.h> |
26 | #include <asm/irq.h> | 24 | #include <asm/irq.h> |
diff --git a/arch/mips/pci/pci-rc32434.c b/arch/mips/pci/pci-rc32434.c index f31218e17d3c..764362ce5e40 100644 --- a/arch/mips/pci/pci-rc32434.c +++ b/arch/mips/pci/pci-rc32434.c | |||
@@ -215,7 +215,7 @@ static int __init rc32434_pci_init(void) | |||
215 | rc32434_pcibridge_init(); | 215 | rc32434_pcibridge_init(); |
216 | 216 | ||
217 | io_map_base = ioremap(rc32434_res_pci_io1.start, | 217 | io_map_base = ioremap(rc32434_res_pci_io1.start, |
218 | rc32434_res_pci_io1.end - rc32434_res_pci_io1.start + 1); | 218 | resource_size(&rcrc32434_res_pci_io1)); |
219 | 219 | ||
220 | if (!io_map_base) | 220 | if (!io_map_base) |
221 | return -ENOMEM; | 221 | return -ENOMEM; |
diff --git a/arch/mips/pci/pci-vr41xx.c b/arch/mips/pci/pci-vr41xx.c index 56525711f8b7..444b8d8004ad 100644 --- a/arch/mips/pci/pci-vr41xx.c +++ b/arch/mips/pci/pci-vr41xx.c | |||
@@ -305,7 +305,7 @@ static int __init vr41xx_pciu_init(void) | |||
305 | struct resource *res = vr41xx_pci_controller.io_resource; | 305 | struct resource *res = vr41xx_pci_controller.io_resource; |
306 | master = setup->master_io; | 306 | master = setup->master_io; |
307 | io_map_base = ioremap(master->bus_base_address, | 307 | io_map_base = ioremap(master->bus_base_address, |
308 | res->end - res->start + 1); | 308 | resource_size(res)); |
309 | if (!io_map_base) | 309 | if (!io_map_base) |
310 | return -EBUSY; | 310 | return -EBUSY; |
311 | 311 | ||
diff --git a/arch/mips/powertv/asic/asic_devices.c b/arch/mips/powertv/asic/asic_devices.c index e56fa61b3991..bce1872249ba 100644 --- a/arch/mips/powertv/asic/asic_devices.c +++ b/arch/mips/powertv/asic/asic_devices.c | |||
@@ -394,23 +394,21 @@ void __init platform_alloc_bootmem(void) | |||
394 | 394 | ||
395 | /* Loop through looking for resources that want a particular address */ | 395 | /* Loop through looking for resources that want a particular address */ |
396 | for (i = 0; gp_resources[i].flags != 0; i++) { | 396 | for (i = 0; gp_resources[i].flags != 0; i++) { |
397 | int size = gp_resources[i].end - gp_resources[i].start + 1; | 397 | int size = resource_size(&gp_resources[i]); |
398 | if ((gp_resources[i].start != 0) && | 398 | if ((gp_resources[i].start != 0) && |
399 | ((gp_resources[i].flags & IORESOURCE_MEM) != 0)) { | 399 | ((gp_resources[i].flags & IORESOURCE_MEM) != 0)) { |
400 | reserve_bootmem(dma_to_phys(gp_resources[i].start), | 400 | reserve_bootmem(dma_to_phys(gp_resources[i].start), |
401 | size, 0); | 401 | size, 0); |
402 | total += gp_resources[i].end - | 402 | total += resource_size(&gp_resources[i]); |
403 | gp_resources[i].start + 1; | ||
404 | pr_info("reserve resource %s at %08x (%u bytes)\n", | 403 | pr_info("reserve resource %s at %08x (%u bytes)\n", |
405 | gp_resources[i].name, gp_resources[i].start, | 404 | gp_resources[i].name, gp_resources[i].start, |
406 | gp_resources[i].end - | 405 | resource_size(&gp_resources[i])); |
407 | gp_resources[i].start + 1); | ||
408 | } | 406 | } |
409 | } | 407 | } |
410 | 408 | ||
411 | /* Loop through assigning addresses for those that are left */ | 409 | /* Loop through assigning addresses for those that are left */ |
412 | for (i = 0; gp_resources[i].flags != 0; i++) { | 410 | for (i = 0; gp_resources[i].flags != 0; i++) { |
413 | int size = gp_resources[i].end - gp_resources[i].start + 1; | 411 | int size = resource_size(&gp_resources[i]); |
414 | if ((gp_resources[i].start == 0) && | 412 | if ((gp_resources[i].start == 0) && |
415 | ((gp_resources[i].flags & IORESOURCE_MEM) != 0)) { | 413 | ((gp_resources[i].flags & IORESOURCE_MEM) != 0)) { |
416 | void *mem = alloc_bootmem_pages(size); | 414 | void *mem = alloc_bootmem_pages(size); |
diff --git a/arch/parisc/include/asm/dma-mapping.h b/arch/parisc/include/asm/dma-mapping.h index 4ef73b09b168..890531e32fe8 100644 --- a/arch/parisc/include/asm/dma-mapping.h +++ b/arch/parisc/include/asm/dma-mapping.h | |||
@@ -210,7 +210,7 @@ parisc_walk_tree(struct device *dev) | |||
210 | return dev->platform_data; | 210 | return dev->platform_data; |
211 | } | 211 | } |
212 | 212 | ||
213 | #define GET_IOC(dev) (HBA_DATA(parisc_walk_tree(dev))->iommu); | 213 | #define GET_IOC(dev) (HBA_DATA(parisc_walk_tree(dev))->iommu) |
214 | 214 | ||
215 | 215 | ||
216 | #ifdef CONFIG_IOMMU_CCIO | 216 | #ifdef CONFIG_IOMMU_CCIO |
diff --git a/arch/parisc/math-emu/decode_exc.c b/arch/parisc/math-emu/decode_exc.c index 27a7492ddb0d..04e550e76ae8 100644 --- a/arch/parisc/math-emu/decode_exc.c +++ b/arch/parisc/math-emu/decode_exc.c | |||
@@ -56,7 +56,7 @@ | |||
56 | /* General definitions */ | 56 | /* General definitions */ |
57 | #define DOESTRAP 1 | 57 | #define DOESTRAP 1 |
58 | #define NOTRAP 0 | 58 | #define NOTRAP 0 |
59 | #define SIGNALCODE(signal, code) ((signal) << 24 | (code)); | 59 | #define SIGNALCODE(signal, code) ((signal) << 24 | (code)) |
60 | #define copropbit 1<<31-2 /* bit position 2 */ | 60 | #define copropbit 1<<31-2 /* bit position 2 */ |
61 | #define opclass 9 /* bits 21 & 22 */ | 61 | #define opclass 9 /* bits 21 & 22 */ |
62 | #define fmt 11 /* bits 19 & 20 */ | 62 | #define fmt 11 /* bits 19 & 20 */ |
diff --git a/arch/powerpc/include/asm/elf.h b/arch/powerpc/include/asm/elf.h index 2b917c69ed15..3bf9cca35147 100644 --- a/arch/powerpc/include/asm/elf.h +++ b/arch/powerpc/include/asm/elf.h | |||
@@ -267,7 +267,7 @@ extern int ucache_bsize; | |||
267 | struct linux_binprm; | 267 | struct linux_binprm; |
268 | extern int arch_setup_additional_pages(struct linux_binprm *bprm, | 268 | extern int arch_setup_additional_pages(struct linux_binprm *bprm, |
269 | int uses_interp); | 269 | int uses_interp); |
270 | #define VDSO_AUX_ENT(a,b) NEW_AUX_ENT(a,b); | 270 | #define VDSO_AUX_ENT(a,b) NEW_AUX_ENT(a,b) |
271 | 271 | ||
272 | /* 1GB for 64bit, 8MB for 32bit */ | 272 | /* 1GB for 64bit, 8MB for 32bit */ |
273 | #define STACK_RND_MASK (is_32bit_task() ? \ | 273 | #define STACK_RND_MASK (is_32bit_task() ? \ |
@@ -298,7 +298,7 @@ do { \ | |||
298 | NEW_AUX_ENT(AT_DCACHEBSIZE, dcache_bsize); \ | 298 | NEW_AUX_ENT(AT_DCACHEBSIZE, dcache_bsize); \ |
299 | NEW_AUX_ENT(AT_ICACHEBSIZE, icache_bsize); \ | 299 | NEW_AUX_ENT(AT_ICACHEBSIZE, icache_bsize); \ |
300 | NEW_AUX_ENT(AT_UCACHEBSIZE, ucache_bsize); \ | 300 | NEW_AUX_ENT(AT_UCACHEBSIZE, ucache_bsize); \ |
301 | VDSO_AUX_ENT(AT_SYSINFO_EHDR, current->mm->context.vdso_base) \ | 301 | VDSO_AUX_ENT(AT_SYSINFO_EHDR, current->mm->context.vdso_base); \ |
302 | } while (0) | 302 | } while (0) |
303 | 303 | ||
304 | /* PowerPC64 relocations defined by the ABIs */ | 304 | /* PowerPC64 relocations defined by the ABIs */ |
diff --git a/arch/powerpc/include/asm/macio.h b/arch/powerpc/include/asm/macio.h index 7ab82c825a03..27af7f8bbb8d 100644 --- a/arch/powerpc/include/asm/macio.h +++ b/arch/powerpc/include/asm/macio.h | |||
@@ -76,7 +76,7 @@ static inline unsigned long macio_resource_len(struct macio_dev *dev, int resour | |||
76 | struct resource *res = &dev->resource[resource_no]; | 76 | struct resource *res = &dev->resource[resource_no]; |
77 | if (res->start == 0 || res->end == 0 || res->end < res->start) | 77 | if (res->start == 0 || res->end == 0 || res->end < res->start) |
78 | return 0; | 78 | return 0; |
79 | return res->end - res->start + 1; | 79 | return resource_size(res); |
80 | } | 80 | } |
81 | 81 | ||
82 | extern int macio_enable_devres(struct macio_dev *dev); | 82 | extern int macio_enable_devres(struct macio_dev *dev); |
diff --git a/arch/powerpc/include/asm/smu.h b/arch/powerpc/include/asm/smu.h index e3bdada8c542..ae20ce1af4c7 100644 --- a/arch/powerpc/include/asm/smu.h +++ b/arch/powerpc/include/asm/smu.h | |||
@@ -547,7 +547,7 @@ struct smu_sdbp_header { | |||
547 | * (currently, afaik, this concerns only the FVT partition | 547 | * (currently, afaik, this concerns only the FVT partition |
548 | * (0x12) | 548 | * (0x12) |
549 | */ | 549 | */ |
550 | #define SMU_U16_MIX(x) le16_to_cpu(x); | 550 | #define SMU_U16_MIX(x) le16_to_cpu(x) |
551 | #define SMU_U32_MIX(x) ((((x) & 0xff00ff00u) >> 8)|(((x) & 0x00ff00ffu) << 8)) | 551 | #define SMU_U32_MIX(x) ((((x) & 0xff00ff00u) >> 8)|(((x) & 0x00ff00ffu) << 8)) |
552 | 552 | ||
553 | 553 | ||
diff --git a/arch/powerpc/kernel/machine_kexec.c b/arch/powerpc/kernel/machine_kexec.c index 7ee50f0547cb..6658a1589955 100644 --- a/arch/powerpc/kernel/machine_kexec.c +++ b/arch/powerpc/kernel/machine_kexec.c | |||
@@ -126,7 +126,7 @@ void __init reserve_crashkernel(void) | |||
126 | /* We might have got these values via the command line or the | 126 | /* We might have got these values via the command line or the |
127 | * device tree, either way sanitise them now. */ | 127 | * device tree, either way sanitise them now. */ |
128 | 128 | ||
129 | crash_size = crashk_res.end - crashk_res.start + 1; | 129 | crash_size = resource_size(&crashk_res); |
130 | 130 | ||
131 | #ifndef CONFIG_RELOCATABLE | 131 | #ifndef CONFIG_RELOCATABLE |
132 | if (crashk_res.start != KDUMP_KERNELBASE) | 132 | if (crashk_res.start != KDUMP_KERNELBASE) |
@@ -222,7 +222,7 @@ static void __init export_crashk_values(struct device_node *node) | |||
222 | 222 | ||
223 | if (crashk_res.start != 0) { | 223 | if (crashk_res.start != 0) { |
224 | prom_add_property(node, &crashk_base_prop); | 224 | prom_add_property(node, &crashk_base_prop); |
225 | crashk_size = crashk_res.end - crashk_res.start + 1; | 225 | crashk_size = resource_size(&crashk_res); |
226 | prom_add_property(node, &crashk_size_prop); | 226 | prom_add_property(node, &crashk_size_prop); |
227 | } | 227 | } |
228 | } | 228 | } |
diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c index a3c92770e422..45ebb14c5c27 100644 --- a/arch/powerpc/kernel/pci-common.c +++ b/arch/powerpc/kernel/pci-common.c | |||
@@ -107,7 +107,7 @@ static resource_size_t pcibios_io_size(const struct pci_controller *hose) | |||
107 | #ifdef CONFIG_PPC64 | 107 | #ifdef CONFIG_PPC64 |
108 | return hose->pci_io_size; | 108 | return hose->pci_io_size; |
109 | #else | 109 | #else |
110 | return hose->io_resource.end - hose->io_resource.start + 1; | 110 | return resource_size(&hose->io_resource); |
111 | #endif | 111 | #endif |
112 | } | 112 | } |
113 | 113 | ||
diff --git a/arch/powerpc/platforms/52xx/mpc52xx_pci.c b/arch/powerpc/platforms/52xx/mpc52xx_pci.c index da110bd88346..5f5e69309080 100644 --- a/arch/powerpc/platforms/52xx/mpc52xx_pci.c +++ b/arch/powerpc/platforms/52xx/mpc52xx_pci.c | |||
@@ -264,7 +264,7 @@ mpc52xx_pci_setup(struct pci_controller *hose, | |||
264 | (unsigned long long)res->flags); | 264 | (unsigned long long)res->flags); |
265 | out_be32(&pci_regs->iw0btar, | 265 | out_be32(&pci_regs->iw0btar, |
266 | MPC52xx_PCI_IWBTAR_TRANSLATION(res->start, res->start, | 266 | MPC52xx_PCI_IWBTAR_TRANSLATION(res->start, res->start, |
267 | res->end - res->start + 1)); | 267 | resource_size(res))); |
268 | iwcr0 = MPC52xx_PCI_IWCR_ENABLE | MPC52xx_PCI_IWCR_MEM; | 268 | iwcr0 = MPC52xx_PCI_IWCR_ENABLE | MPC52xx_PCI_IWCR_MEM; |
269 | if (res->flags & IORESOURCE_PREFETCH) | 269 | if (res->flags & IORESOURCE_PREFETCH) |
270 | iwcr0 |= MPC52xx_PCI_IWCR_READ_MULTI; | 270 | iwcr0 |= MPC52xx_PCI_IWCR_READ_MULTI; |
@@ -278,7 +278,7 @@ mpc52xx_pci_setup(struct pci_controller *hose, | |||
278 | res->start, res->end, res->flags); | 278 | res->start, res->end, res->flags); |
279 | out_be32(&pci_regs->iw1btar, | 279 | out_be32(&pci_regs->iw1btar, |
280 | MPC52xx_PCI_IWBTAR_TRANSLATION(res->start, res->start, | 280 | MPC52xx_PCI_IWBTAR_TRANSLATION(res->start, res->start, |
281 | res->end - res->start + 1)); | 281 | resource_size(res))); |
282 | iwcr1 = MPC52xx_PCI_IWCR_ENABLE | MPC52xx_PCI_IWCR_MEM; | 282 | iwcr1 = MPC52xx_PCI_IWCR_ENABLE | MPC52xx_PCI_IWCR_MEM; |
283 | if (res->flags & IORESOURCE_PREFETCH) | 283 | if (res->flags & IORESOURCE_PREFETCH) |
284 | iwcr1 |= MPC52xx_PCI_IWCR_READ_MULTI; | 284 | iwcr1 |= MPC52xx_PCI_IWCR_READ_MULTI; |
@@ -300,7 +300,7 @@ mpc52xx_pci_setup(struct pci_controller *hose, | |||
300 | out_be32(&pci_regs->iw2btar, | 300 | out_be32(&pci_regs->iw2btar, |
301 | MPC52xx_PCI_IWBTAR_TRANSLATION(hose->io_base_phys, | 301 | MPC52xx_PCI_IWBTAR_TRANSLATION(hose->io_base_phys, |
302 | res->start, | 302 | res->start, |
303 | res->end - res->start + 1)); | 303 | resource_size(res))); |
304 | iwcr2 = MPC52xx_PCI_IWCR_ENABLE | MPC52xx_PCI_IWCR_IO; | 304 | iwcr2 = MPC52xx_PCI_IWCR_ENABLE | MPC52xx_PCI_IWCR_IO; |
305 | 305 | ||
306 | /* Set all the IWCR fields at once; they're in the same reg */ | 306 | /* Set all the IWCR fields at once; they're in the same reg */ |
@@ -402,7 +402,7 @@ mpc52xx_add_bridge(struct device_node *node) | |||
402 | 402 | ||
403 | hose->ops = &mpc52xx_pci_ops; | 403 | hose->ops = &mpc52xx_pci_ops; |
404 | 404 | ||
405 | pci_regs = ioremap(rsrc.start, rsrc.end - rsrc.start + 1); | 405 | pci_regs = ioremap(rsrc.start, resource_size(&rsrc)); |
406 | if (!pci_regs) | 406 | if (!pci_regs) |
407 | return -ENOMEM; | 407 | return -ENOMEM; |
408 | 408 | ||
diff --git a/arch/powerpc/platforms/83xx/km83xx.c b/arch/powerpc/platforms/83xx/km83xx.c index a2b9b9ef1240..f8fa2fc3129f 100644 --- a/arch/powerpc/platforms/83xx/km83xx.c +++ b/arch/powerpc/platforms/83xx/km83xx.c | |||
@@ -101,7 +101,7 @@ static void __init mpc83xx_km_setup_arch(void) | |||
101 | __func__); | 101 | __func__); |
102 | return; | 102 | return; |
103 | } | 103 | } |
104 | base = ioremap(res.start, res.end - res.start + 1); | 104 | base = ioremap(res.start, resource_size(&res)); |
105 | 105 | ||
106 | /* | 106 | /* |
107 | * IMMR + 0x14A8[4:5] = 11 (clk delay for UCC 2) | 107 | * IMMR + 0x14A8[4:5] = 11 (clk delay for UCC 2) |
diff --git a/arch/powerpc/platforms/83xx/mpc832x_mds.c b/arch/powerpc/platforms/83xx/mpc832x_mds.c index ec0b401bc9cf..93e60f1f21a9 100644 --- a/arch/powerpc/platforms/83xx/mpc832x_mds.c +++ b/arch/powerpc/platforms/83xx/mpc832x_mds.c | |||
@@ -68,7 +68,7 @@ static void __init mpc832x_sys_setup_arch(void) | |||
68 | struct resource res; | 68 | struct resource res; |
69 | 69 | ||
70 | of_address_to_resource(np, 0, &res); | 70 | of_address_to_resource(np, 0, &res); |
71 | bcsr_regs = ioremap(res.start, res.end - res.start +1); | 71 | bcsr_regs = ioremap(res.start, resource_size(&res)); |
72 | of_node_put(np); | 72 | of_node_put(np); |
73 | } | 73 | } |
74 | 74 | ||
diff --git a/arch/powerpc/platforms/83xx/mpc834x_mds.c b/arch/powerpc/platforms/83xx/mpc834x_mds.c index d0a634b056ca..c1b1dc50b32a 100644 --- a/arch/powerpc/platforms/83xx/mpc834x_mds.c +++ b/arch/powerpc/platforms/83xx/mpc834x_mds.c | |||
@@ -53,7 +53,7 @@ static int mpc834xemds_usb_cfg(void) | |||
53 | struct resource res; | 53 | struct resource res; |
54 | 54 | ||
55 | of_address_to_resource(np, 0, &res); | 55 | of_address_to_resource(np, 0, &res); |
56 | bcsr_regs = ioremap(res.start, res.end - res.start + 1); | 56 | bcsr_regs = ioremap(res.start, resource_size(&res)); |
57 | of_node_put(np); | 57 | of_node_put(np); |
58 | } | 58 | } |
59 | if (!bcsr_regs) | 59 | if (!bcsr_regs) |
diff --git a/arch/powerpc/platforms/83xx/mpc836x_mds.c b/arch/powerpc/platforms/83xx/mpc836x_mds.c index 09e9d6fb7411..81c052b1353e 100644 --- a/arch/powerpc/platforms/83xx/mpc836x_mds.c +++ b/arch/powerpc/platforms/83xx/mpc836x_mds.c | |||
@@ -76,7 +76,7 @@ static void __init mpc836x_mds_setup_arch(void) | |||
76 | struct resource res; | 76 | struct resource res; |
77 | 77 | ||
78 | of_address_to_resource(np, 0, &res); | 78 | of_address_to_resource(np, 0, &res); |
79 | bcsr_regs = ioremap(res.start, res.end - res.start +1); | 79 | bcsr_regs = ioremap(res.start, resource_size(&res)); |
80 | of_node_put(np); | 80 | of_node_put(np); |
81 | } | 81 | } |
82 | 82 | ||
diff --git a/arch/powerpc/platforms/83xx/usb.c b/arch/powerpc/platforms/83xx/usb.c index 2c64164722d0..1ad748bb39b4 100644 --- a/arch/powerpc/platforms/83xx/usb.c +++ b/arch/powerpc/platforms/83xx/usb.c | |||
@@ -171,7 +171,7 @@ int mpc831x_usb_cfg(void) | |||
171 | of_node_put(np); | 171 | of_node_put(np); |
172 | return ret; | 172 | return ret; |
173 | } | 173 | } |
174 | usb_regs = ioremap(res.start, res.end - res.start + 1); | 174 | usb_regs = ioremap(res.start, resource_size(&res)); |
175 | 175 | ||
176 | /* Using on-chip PHY */ | 176 | /* Using on-chip PHY */ |
177 | if (prop && (!strcmp(prop, "utmi_wide") || | 177 | if (prop && (!strcmp(prop, "utmi_wide") || |
diff --git a/arch/powerpc/platforms/85xx/sbc8560.c b/arch/powerpc/platforms/85xx/sbc8560.c index d2dfd465fbf6..09ced7221750 100644 --- a/arch/powerpc/platforms/85xx/sbc8560.c +++ b/arch/powerpc/platforms/85xx/sbc8560.c | |||
@@ -285,7 +285,7 @@ static int __init sbc8560_bdrstcr_init(void) | |||
285 | 285 | ||
286 | printk(KERN_INFO "sbc8560: Found BRSTCR at i/o 0x%x\n", res.start); | 286 | printk(KERN_INFO "sbc8560: Found BRSTCR at i/o 0x%x\n", res.start); |
287 | 287 | ||
288 | brstcr = ioremap(res.start, res.end - res.start); | 288 | brstcr = ioremap(res.start, resource_size(&res)); |
289 | if(!brstcr) | 289 | if(!brstcr) |
290 | printk(KERN_WARNING "sbc8560: ioremap of brstcr failed.\n"); | 290 | printk(KERN_WARNING "sbc8560: ioremap of brstcr failed.\n"); |
291 | 291 | ||
diff --git a/arch/powerpc/platforms/85xx/xes_mpc85xx.c b/arch/powerpc/platforms/85xx/xes_mpc85xx.c index 0125604d096e..a9dc5e795123 100644 --- a/arch/powerpc/platforms/85xx/xes_mpc85xx.c +++ b/arch/powerpc/platforms/85xx/xes_mpc85xx.c | |||
@@ -123,7 +123,7 @@ static void xes_mpc85xx_fixups(void) | |||
123 | continue; | 123 | continue; |
124 | } | 124 | } |
125 | 125 | ||
126 | l2_base = ioremap(r[0].start, r[0].end - r[0].start + 1); | 126 | l2_base = ioremap(r[0].start, resource_size(&r[0])); |
127 | 127 | ||
128 | xes_mpc85xx_configure_l2(l2_base); | 128 | xes_mpc85xx_configure_l2(l2_base); |
129 | } | 129 | } |
diff --git a/arch/powerpc/platforms/cell/celleb_scc_epci.c b/arch/powerpc/platforms/cell/celleb_scc_epci.c index 05b0db3ef638..844c0facb4f7 100644 --- a/arch/powerpc/platforms/cell/celleb_scc_epci.c +++ b/arch/powerpc/platforms/cell/celleb_scc_epci.c | |||
@@ -393,19 +393,19 @@ static int __init celleb_setup_epci(struct device_node *node, | |||
393 | 393 | ||
394 | if (of_address_to_resource(node, 0, &r)) | 394 | if (of_address_to_resource(node, 0, &r)) |
395 | goto error; | 395 | goto error; |
396 | hose->cfg_addr = ioremap(r.start, (r.end - r.start + 1)); | 396 | hose->cfg_addr = ioremap(r.start, resource_size(&r)); |
397 | if (!hose->cfg_addr) | 397 | if (!hose->cfg_addr) |
398 | goto error; | 398 | goto error; |
399 | pr_debug("EPCI: cfg_addr map 0x%016llx->0x%016lx + 0x%016llx\n", | 399 | pr_debug("EPCI: cfg_addr map 0x%016llx->0x%016lx + 0x%016llx\n", |
400 | r.start, (unsigned long)hose->cfg_addr, (r.end - r.start + 1)); | 400 | r.start, (unsigned long)hose->cfg_addr, resource_size(&r)); |
401 | 401 | ||
402 | if (of_address_to_resource(node, 2, &r)) | 402 | if (of_address_to_resource(node, 2, &r)) |
403 | goto error; | 403 | goto error; |
404 | hose->cfg_data = ioremap(r.start, (r.end - r.start + 1)); | 404 | hose->cfg_data = ioremap(r.start, resource_size(&r)); |
405 | if (!hose->cfg_data) | 405 | if (!hose->cfg_data) |
406 | goto error; | 406 | goto error; |
407 | pr_debug("EPCI: cfg_data map 0x%016llx->0x%016lx + 0x%016llx\n", | 407 | pr_debug("EPCI: cfg_data map 0x%016llx->0x%016lx + 0x%016llx\n", |
408 | r.start, (unsigned long)hose->cfg_data, (r.end - r.start + 1)); | 408 | r.start, (unsigned long)hose->cfg_data, resource_size(&r)); |
409 | 409 | ||
410 | hose->ops = &celleb_epci_ops; | 410 | hose->ops = &celleb_epci_ops; |
411 | celleb_epci_init(hose); | 411 | celleb_epci_init(hose); |
diff --git a/arch/powerpc/platforms/cell/celleb_scc_pciex.c b/arch/powerpc/platforms/cell/celleb_scc_pciex.c index a881bbee8de0..ae790ac4a589 100644 --- a/arch/powerpc/platforms/cell/celleb_scc_pciex.c +++ b/arch/powerpc/platforms/cell/celleb_scc_pciex.c | |||
@@ -494,7 +494,7 @@ static __init int celleb_setup_pciex(struct device_node *node, | |||
494 | pr_err("PCIEXC:Failed to get config resource.\n"); | 494 | pr_err("PCIEXC:Failed to get config resource.\n"); |
495 | return 1; | 495 | return 1; |
496 | } | 496 | } |
497 | phb->cfg_addr = ioremap(r.start, r.end - r.start + 1); | 497 | phb->cfg_addr = ioremap(r.start, resource_size(&r)); |
498 | if (!phb->cfg_addr) { | 498 | if (!phb->cfg_addr) { |
499 | pr_err("PCIEXC:Failed to remap SMMIO region.\n"); | 499 | pr_err("PCIEXC:Failed to remap SMMIO region.\n"); |
500 | return 1; | 500 | return 1; |
diff --git a/arch/powerpc/platforms/cell/spu_manage.c b/arch/powerpc/platforms/cell/spu_manage.c index f465d474ad9b..4e5c91489c02 100644 --- a/arch/powerpc/platforms/cell/spu_manage.c +++ b/arch/powerpc/platforms/cell/spu_manage.c | |||
@@ -222,7 +222,7 @@ static int spu_map_resource(struct spu *spu, int nr, | |||
222 | return ret; | 222 | return ret; |
223 | if (phys) | 223 | if (phys) |
224 | *phys = resource.start; | 224 | *phys = resource.start; |
225 | len = resource.end - resource.start + 1; | 225 | len = resource_size(&resource); |
226 | *virt = ioremap(resource.start, len); | 226 | *virt = ioremap(resource.start, len); |
227 | if (!*virt) | 227 | if (!*virt) |
228 | return -EINVAL; | 228 | return -EINVAL; |
diff --git a/arch/powerpc/platforms/chrp/pci.c b/arch/powerpc/platforms/chrp/pci.c index 8f67a394b2d0..3f65443f1714 100644 --- a/arch/powerpc/platforms/chrp/pci.c +++ b/arch/powerpc/platforms/chrp/pci.c | |||
@@ -142,7 +142,7 @@ hydra_init(void) | |||
142 | return 0; | 142 | return 0; |
143 | } | 143 | } |
144 | of_node_put(np); | 144 | of_node_put(np); |
145 | Hydra = ioremap(r.start, r.end-r.start); | 145 | Hydra = ioremap(r.start, resource_size(&r)); |
146 | printk("Hydra Mac I/O at %llx\n", (unsigned long long)r.start); | 146 | printk("Hydra Mac I/O at %llx\n", (unsigned long long)r.start); |
147 | printk("Hydra Feature_Control was %x", | 147 | printk("Hydra Feature_Control was %x", |
148 | in_le32(&Hydra->Feature_Control)); | 148 | in_le32(&Hydra->Feature_Control)); |
diff --git a/arch/powerpc/platforms/pasemi/dma_lib.c b/arch/powerpc/platforms/pasemi/dma_lib.c index 321a9b3a2d00..756123bf06ac 100644 --- a/arch/powerpc/platforms/pasemi/dma_lib.c +++ b/arch/powerpc/platforms/pasemi/dma_lib.c | |||
@@ -576,7 +576,7 @@ int pasemi_dma_init(void) | |||
576 | res.start = 0xfd800000; | 576 | res.start = 0xfd800000; |
577 | res.end = res.start + 0x1000; | 577 | res.end = res.start + 0x1000; |
578 | } | 578 | } |
579 | dma_status = __ioremap(res.start, res.end-res.start, 0); | 579 | dma_status = __ioremap(res.start, resource_size(&res), 0); |
580 | pci_dev_put(iob_pdev); | 580 | pci_dev_put(iob_pdev); |
581 | 581 | ||
582 | for (i = 0; i < MAX_TXCH; i++) | 582 | for (i = 0; i < MAX_TXCH; i++) |
diff --git a/arch/powerpc/platforms/powermac/nvram.c b/arch/powerpc/platforms/powermac/nvram.c index b1cdcf94aa8e..695443bfdb08 100644 --- a/arch/powerpc/platforms/powermac/nvram.c +++ b/arch/powerpc/platforms/powermac/nvram.c | |||
@@ -580,10 +580,10 @@ int __init pmac_nvram_init(void) | |||
580 | /* Try to obtain an address */ | 580 | /* Try to obtain an address */ |
581 | if (of_address_to_resource(dp, 0, &r1) == 0) { | 581 | if (of_address_to_resource(dp, 0, &r1) == 0) { |
582 | nvram_naddrs = 1; | 582 | nvram_naddrs = 1; |
583 | s1 = (r1.end - r1.start) + 1; | 583 | s1 = resource_size(&r1); |
584 | if (of_address_to_resource(dp, 1, &r2) == 0) { | 584 | if (of_address_to_resource(dp, 1, &r2) == 0) { |
585 | nvram_naddrs = 2; | 585 | nvram_naddrs = 2; |
586 | s2 = (r2.end - r2.start) + 1; | 586 | s2 = resource_size(&r2); |
587 | } | 587 | } |
588 | } | 588 | } |
589 | 589 | ||
diff --git a/arch/powerpc/platforms/powermac/pci.c b/arch/powerpc/platforms/powermac/pci.c index abe8d7e2ebeb..41a80a4fb97e 100644 --- a/arch/powerpc/platforms/powermac/pci.c +++ b/arch/powerpc/platforms/powermac/pci.c | |||
@@ -839,8 +839,7 @@ static void __init setup_u3_ht(struct pci_controller* hose) | |||
839 | * into cfg_addr | 839 | * into cfg_addr |
840 | */ | 840 | */ |
841 | hose->cfg_data = ioremap(cfg_res.start, 0x02000000); | 841 | hose->cfg_data = ioremap(cfg_res.start, 0x02000000); |
842 | hose->cfg_addr = ioremap(self_res.start, | 842 | hose->cfg_addr = ioremap(self_res.start, resource_size(&self_res)); |
843 | self_res.end - self_res.start + 1); | ||
844 | 843 | ||
845 | /* | 844 | /* |
846 | * /ht node doesn't expose a "ranges" property, we read the register | 845 | * /ht node doesn't expose a "ranges" property, we read the register |
@@ -1324,8 +1323,7 @@ static void fixup_u4_pcie(struct pci_dev* dev) | |||
1324 | */ | 1323 | */ |
1325 | if (r->start >= 0xf0000000 && r->start < 0xf3000000) | 1324 | if (r->start >= 0xf0000000 && r->start < 0xf3000000) |
1326 | continue; | 1325 | continue; |
1327 | if (!region || (r->end - r->start) > | 1326 | if (!region || resource_size(r) > resource_size(region)) |
1328 | (region->end - region->start)) | ||
1329 | region = r; | 1327 | region = r; |
1330 | } | 1328 | } |
1331 | /* Nothing found, bail */ | 1329 | /* Nothing found, bail */ |
diff --git a/arch/powerpc/platforms/powermac/time.c b/arch/powerpc/platforms/powermac/time.c index 48211ca134c3..11c9fce43b5b 100644 --- a/arch/powerpc/platforms/powermac/time.c +++ b/arch/powerpc/platforms/powermac/time.c | |||
@@ -274,7 +274,7 @@ int __init via_calibrate_decr(void) | |||
274 | return 0; | 274 | return 0; |
275 | } | 275 | } |
276 | of_node_put(vias); | 276 | of_node_put(vias); |
277 | via = ioremap(rsrc.start, rsrc.end - rsrc.start + 1); | 277 | via = ioremap(rsrc.start, resource_size(&rsrc)); |
278 | if (via == NULL) { | 278 | if (via == NULL) { |
279 | printk(KERN_ERR "Failed to map VIA for timer calibration !\n"); | 279 | printk(KERN_ERR "Failed to map VIA for timer calibration !\n"); |
280 | return 0; | 280 | return 0; |
diff --git a/arch/powerpc/platforms/pseries/smp.c b/arch/powerpc/platforms/pseries/smp.c index fbffd7e47ab8..cd70be5ff27e 100644 --- a/arch/powerpc/platforms/pseries/smp.c +++ b/arch/powerpc/platforms/pseries/smp.c | |||
@@ -44,7 +44,6 @@ | |||
44 | #include <asm/mpic.h> | 44 | #include <asm/mpic.h> |
45 | #include <asm/vdso_datapage.h> | 45 | #include <asm/vdso_datapage.h> |
46 | #include <asm/cputhreads.h> | 46 | #include <asm/cputhreads.h> |
47 | #include <asm/mpic.h> | ||
48 | #include <asm/xics.h> | 47 | #include <asm/xics.h> |
49 | 48 | ||
50 | #include "plpar_wrappers.h" | 49 | #include "plpar_wrappers.h" |
diff --git a/arch/powerpc/sysdev/axonram.c b/arch/powerpc/sysdev/axonram.c index bd0d54060b94..265f0f09395a 100644 --- a/arch/powerpc/sysdev/axonram.c +++ b/arch/powerpc/sysdev/axonram.c | |||
@@ -203,7 +203,7 @@ static int axon_ram_probe(struct platform_device *device) | |||
203 | goto failed; | 203 | goto failed; |
204 | } | 204 | } |
205 | 205 | ||
206 | bank->size = resource.end - resource.start + 1; | 206 | bank->size = resource_size(&resource); |
207 | 207 | ||
208 | if (bank->size == 0) { | 208 | if (bank->size == 0) { |
209 | dev_err(&device->dev, "No DDR2 memory found for %s%d\n", | 209 | dev_err(&device->dev, "No DDR2 memory found for %s%d\n", |
diff --git a/arch/powerpc/sysdev/cpm1.c b/arch/powerpc/sysdev/cpm1.c index 350787c83e22..5d7d59a43c4c 100644 --- a/arch/powerpc/sysdev/cpm1.c +++ b/arch/powerpc/sysdev/cpm1.c | |||
@@ -148,7 +148,7 @@ unsigned int cpm_pic_init(void) | |||
148 | if (ret) | 148 | if (ret) |
149 | goto end; | 149 | goto end; |
150 | 150 | ||
151 | cpic_reg = ioremap(res.start, res.end - res.start + 1); | 151 | cpic_reg = ioremap(res.start, resource_size(&res)); |
152 | if (cpic_reg == NULL) | 152 | if (cpic_reg == NULL) |
153 | goto end; | 153 | goto end; |
154 | 154 | ||
diff --git a/arch/powerpc/sysdev/cpm_common.c b/arch/powerpc/sysdev/cpm_common.c index 2b69aa0315b3..d55d0ad0deab 100644 --- a/arch/powerpc/sysdev/cpm_common.c +++ b/arch/powerpc/sysdev/cpm_common.c | |||
@@ -115,7 +115,7 @@ int cpm_muram_init(void) | |||
115 | max = r.end; | 115 | max = r.end; |
116 | 116 | ||
117 | rh_attach_region(&cpm_muram_info, r.start - muram_pbase, | 117 | rh_attach_region(&cpm_muram_info, r.start - muram_pbase, |
118 | r.end - r.start + 1); | 118 | resource_size(&r)); |
119 | } | 119 | } |
120 | 120 | ||
121 | muram_vbase = ioremap(muram_pbase, max - muram_pbase + 1); | 121 | muram_vbase = ioremap(muram_pbase, max - muram_pbase + 1); |
diff --git a/arch/powerpc/sysdev/dart_iommu.c b/arch/powerpc/sysdev/dart_iommu.c index 8e9e06a7ca59..4f2680f431b5 100644 --- a/arch/powerpc/sysdev/dart_iommu.c +++ b/arch/powerpc/sysdev/dart_iommu.c | |||
@@ -239,7 +239,7 @@ static int __init dart_init(struct device_node *dart_node) | |||
239 | DARTMAP_RPNMASK); | 239 | DARTMAP_RPNMASK); |
240 | 240 | ||
241 | /* Map in DART registers */ | 241 | /* Map in DART registers */ |
242 | dart = ioremap(r.start, r.end - r.start + 1); | 242 | dart = ioremap(r.start, resource_size(&r)); |
243 | if (dart == NULL) | 243 | if (dart == NULL) |
244 | panic("DART: Cannot map registers!"); | 244 | panic("DART: Cannot map registers!"); |
245 | 245 | ||
diff --git a/arch/powerpc/sysdev/fsl_msi.c b/arch/powerpc/sysdev/fsl_msi.c index 92e78333c47c..419a77239bd7 100644 --- a/arch/powerpc/sysdev/fsl_msi.c +++ b/arch/powerpc/sysdev/fsl_msi.c | |||
@@ -349,7 +349,7 @@ static int __devinit fsl_of_msi_probe(struct platform_device *dev) | |||
349 | goto error_out; | 349 | goto error_out; |
350 | } | 350 | } |
351 | 351 | ||
352 | msi->msi_regs = ioremap(res.start, res.end - res.start + 1); | 352 | msi->msi_regs = ioremap(res.start, resource_size(&res)); |
353 | if (!msi->msi_regs) { | 353 | if (!msi->msi_regs) { |
354 | dev_err(&dev->dev, "ioremap problem failed\n"); | 354 | dev_err(&dev->dev, "ioremap problem failed\n"); |
355 | goto error_out; | 355 | goto error_out; |
diff --git a/arch/powerpc/sysdev/fsl_pci.c b/arch/powerpc/sysdev/fsl_pci.c index 68ca9290df94..ba5cb3fa7074 100644 --- a/arch/powerpc/sysdev/fsl_pci.c +++ b/arch/powerpc/sysdev/fsl_pci.c | |||
@@ -64,7 +64,7 @@ static int __init setup_one_atmu(struct ccsr_pci __iomem *pci, | |||
64 | { | 64 | { |
65 | resource_size_t pci_addr = res->start - offset; | 65 | resource_size_t pci_addr = res->start - offset; |
66 | resource_size_t phys_addr = res->start; | 66 | resource_size_t phys_addr = res->start; |
67 | resource_size_t size = res->end - res->start + 1; | 67 | resource_size_t size = resource_size(res); |
68 | u32 flags = 0x80044000; /* enable & mem R/W */ | 68 | u32 flags = 0x80044000; /* enable & mem R/W */ |
69 | unsigned int i; | 69 | unsigned int i; |
70 | 70 | ||
@@ -108,7 +108,7 @@ static void __init setup_pci_atmu(struct pci_controller *hose, | |||
108 | char *name = hose->dn->full_name; | 108 | char *name = hose->dn->full_name; |
109 | 109 | ||
110 | pr_debug("PCI memory map start 0x%016llx, size 0x%016llx\n", | 110 | pr_debug("PCI memory map start 0x%016llx, size 0x%016llx\n", |
111 | (u64)rsrc->start, (u64)rsrc->end - (u64)rsrc->start + 1); | 111 | (u64)rsrc->start, (u64)resource_size(rsrc)); |
112 | 112 | ||
113 | if (of_device_is_compatible(hose->dn, "fsl,qoriq-pcie-v2.2")) { | 113 | if (of_device_is_compatible(hose->dn, "fsl,qoriq-pcie-v2.2")) { |
114 | win_idx = 2; | 114 | win_idx = 2; |
@@ -116,7 +116,7 @@ static void __init setup_pci_atmu(struct pci_controller *hose, | |||
116 | end_idx = 3; | 116 | end_idx = 3; |
117 | } | 117 | } |
118 | 118 | ||
119 | pci = ioremap(rsrc->start, rsrc->end - rsrc->start + 1); | 119 | pci = ioremap(rsrc->start, resource_size(rsrc)); |
120 | if (!pci) { | 120 | if (!pci) { |
121 | dev_err(hose->parent, "Unable to map ATMU registers\n"); | 121 | dev_err(hose->parent, "Unable to map ATMU registers\n"); |
122 | return; | 122 | return; |
@@ -153,9 +153,9 @@ static void __init setup_pci_atmu(struct pci_controller *hose, | |||
153 | } else { | 153 | } else { |
154 | pr_debug("PCI IO resource start 0x%016llx, size 0x%016llx, " | 154 | pr_debug("PCI IO resource start 0x%016llx, size 0x%016llx, " |
155 | "phy base 0x%016llx.\n", | 155 | "phy base 0x%016llx.\n", |
156 | (u64)hose->io_resource.start, | 156 | (u64)hose->io_resource.start, |
157 | (u64)hose->io_resource.end - (u64)hose->io_resource.start + 1, | 157 | (u64)resource_size(&hose->io_resource), |
158 | (u64)hose->io_base_phys); | 158 | (u64)hose->io_base_phys); |
159 | out_be32(&pci->pow[j].potar, (hose->io_resource.start >> 12)); | 159 | out_be32(&pci->pow[j].potar, (hose->io_resource.start >> 12)); |
160 | out_be32(&pci->pow[j].potear, 0); | 160 | out_be32(&pci->pow[j].potear, 0); |
161 | out_be32(&pci->pow[j].powbar, (hose->io_base_phys >> 12)); | 161 | out_be32(&pci->pow[j].powbar, (hose->io_base_phys >> 12)); |
diff --git a/arch/powerpc/sysdev/fsl_rio.c b/arch/powerpc/sysdev/fsl_rio.c index b3fd081d56f5..2de8551df40f 100644 --- a/arch/powerpc/sysdev/fsl_rio.c +++ b/arch/powerpc/sysdev/fsl_rio.c | |||
@@ -1524,7 +1524,7 @@ int fsl_rio_setup(struct platform_device *dev) | |||
1524 | port->priv = priv; | 1524 | port->priv = priv; |
1525 | port->phys_efptr = 0x100; | 1525 | port->phys_efptr = 0x100; |
1526 | 1526 | ||
1527 | priv->regs_win = ioremap(regs.start, regs.end - regs.start + 1); | 1527 | priv->regs_win = ioremap(regs.start, resource_size(®s)); |
1528 | rio_regs_win = priv->regs_win; | 1528 | rio_regs_win = priv->regs_win; |
1529 | 1529 | ||
1530 | /* Probe the master port phy type */ | 1530 | /* Probe the master port phy type */ |
diff --git a/arch/powerpc/sysdev/ipic.c b/arch/powerpc/sysdev/ipic.c index 7367d17364cb..95da897f05a7 100644 --- a/arch/powerpc/sysdev/ipic.c +++ b/arch/powerpc/sysdev/ipic.c | |||
@@ -736,7 +736,7 @@ struct ipic * __init ipic_init(struct device_node *node, unsigned int flags) | |||
736 | return NULL; | 736 | return NULL; |
737 | } | 737 | } |
738 | 738 | ||
739 | ipic->regs = ioremap(res.start, res.end - res.start + 1); | 739 | ipic->regs = ioremap(res.start, resource_size(&res)); |
740 | 740 | ||
741 | ipic->irqhost->host_data = ipic; | 741 | ipic->irqhost->host_data = ipic; |
742 | 742 | ||
diff --git a/arch/powerpc/sysdev/mmio_nvram.c b/arch/powerpc/sysdev/mmio_nvram.c index ddc877a3a23a..69f5814ae6d4 100644 --- a/arch/powerpc/sysdev/mmio_nvram.c +++ b/arch/powerpc/sysdev/mmio_nvram.c | |||
@@ -129,7 +129,7 @@ int __init mmio_nvram_init(void) | |||
129 | goto out; | 129 | goto out; |
130 | } | 130 | } |
131 | nvram_addr = r.start; | 131 | nvram_addr = r.start; |
132 | mmio_nvram_len = r.end - r.start + 1; | 132 | mmio_nvram_len = resource_size(&r); |
133 | if ( (!mmio_nvram_len) || (!nvram_addr) ) { | 133 | if ( (!mmio_nvram_len) || (!nvram_addr) ) { |
134 | printk(KERN_WARNING "nvram: address or length is 0\n"); | 134 | printk(KERN_WARNING "nvram: address or length is 0\n"); |
135 | ret = -EIO; | 135 | ret = -EIO; |
diff --git a/arch/powerpc/sysdev/mpc8xx_pic.c b/arch/powerpc/sysdev/mpc8xx_pic.c index 20924f2246f0..22e48e2d71f1 100644 --- a/arch/powerpc/sysdev/mpc8xx_pic.c +++ b/arch/powerpc/sysdev/mpc8xx_pic.c | |||
@@ -166,7 +166,7 @@ int mpc8xx_pic_init(void) | |||
166 | if (ret) | 166 | if (ret) |
167 | goto out; | 167 | goto out; |
168 | 168 | ||
169 | siu_reg = ioremap(res.start, res.end - res.start + 1); | 169 | siu_reg = ioremap(res.start, resource_size(&res)); |
170 | if (siu_reg == NULL) { | 170 | if (siu_reg == NULL) { |
171 | ret = -EINVAL; | 171 | ret = -EINVAL; |
172 | goto out; | 172 | goto out; |
diff --git a/arch/powerpc/sysdev/mv64x60_udbg.c b/arch/powerpc/sysdev/mv64x60_udbg.c index 2792dc8b038c..50a81387e9b1 100644 --- a/arch/powerpc/sysdev/mv64x60_udbg.c +++ b/arch/powerpc/sysdev/mv64x60_udbg.c | |||
@@ -125,11 +125,11 @@ static void mv64x60_udbg_init(void) | |||
125 | 125 | ||
126 | of_node_put(np); | 126 | of_node_put(np); |
127 | 127 | ||
128 | mpsc_base = ioremap(r[0].start, r[0].end - r[0].start + 1); | 128 | mpsc_base = ioremap(r[0].start, resource_size(&r[0])); |
129 | if (!mpsc_base) | 129 | if (!mpsc_base) |
130 | return; | 130 | return; |
131 | 131 | ||
132 | mpsc_intr_cause = ioremap(r[1].start, r[1].end - r[1].start + 1); | 132 | mpsc_intr_cause = ioremap(r[1].start, resource_size(&r[1])); |
133 | if (!mpsc_intr_cause) { | 133 | if (!mpsc_intr_cause) { |
134 | iounmap(mpsc_base); | 134 | iounmap(mpsc_base); |
135 | return; | 135 | return; |
diff --git a/arch/powerpc/sysdev/ppc4xx_pci.c b/arch/powerpc/sysdev/ppc4xx_pci.c index 156aa7d36258..deda60a7f996 100644 --- a/arch/powerpc/sysdev/ppc4xx_pci.c +++ b/arch/powerpc/sysdev/ppc4xx_pci.c | |||
@@ -265,7 +265,7 @@ static void __init ppc4xx_configure_pci_PMMs(struct pci_controller *hose, | |||
265 | if (ppc4xx_setup_one_pci_PMM(hose, reg, | 265 | if (ppc4xx_setup_one_pci_PMM(hose, reg, |
266 | res->start, | 266 | res->start, |
267 | res->start - hose->pci_mem_offset, | 267 | res->start - hose->pci_mem_offset, |
268 | res->end + 1 - res->start, | 268 | resource_size(res), |
269 | res->flags, | 269 | res->flags, |
270 | j) == 0) { | 270 | j) == 0) { |
271 | j++; | 271 | j++; |
@@ -290,7 +290,7 @@ static void __init ppc4xx_configure_pci_PTMs(struct pci_controller *hose, | |||
290 | void __iomem *reg, | 290 | void __iomem *reg, |
291 | const struct resource *res) | 291 | const struct resource *res) |
292 | { | 292 | { |
293 | resource_size_t size = res->end - res->start + 1; | 293 | resource_size_t size = resource_size(res); |
294 | u32 sa; | 294 | u32 sa; |
295 | 295 | ||
296 | /* Calculate window size */ | 296 | /* Calculate window size */ |
@@ -349,7 +349,7 @@ static void __init ppc4xx_probe_pci_bridge(struct device_node *np) | |||
349 | bus_range = of_get_property(np, "bus-range", NULL); | 349 | bus_range = of_get_property(np, "bus-range", NULL); |
350 | 350 | ||
351 | /* Map registers */ | 351 | /* Map registers */ |
352 | reg = ioremap(rsrc_reg.start, rsrc_reg.end + 1 - rsrc_reg.start); | 352 | reg = ioremap(rsrc_reg.start, resource_size(&rsrc_reg)); |
353 | if (reg == NULL) { | 353 | if (reg == NULL) { |
354 | printk(KERN_ERR "%s: Can't map registers !", np->full_name); | 354 | printk(KERN_ERR "%s: Can't map registers !", np->full_name); |
355 | goto fail; | 355 | goto fail; |
@@ -465,7 +465,7 @@ static void __init ppc4xx_configure_pcix_POMs(struct pci_controller *hose, | |||
465 | if (ppc4xx_setup_one_pcix_POM(hose, reg, | 465 | if (ppc4xx_setup_one_pcix_POM(hose, reg, |
466 | res->start, | 466 | res->start, |
467 | res->start - hose->pci_mem_offset, | 467 | res->start - hose->pci_mem_offset, |
468 | res->end + 1 - res->start, | 468 | resource_size(res), |
469 | res->flags, | 469 | res->flags, |
470 | j) == 0) { | 470 | j) == 0) { |
471 | j++; | 471 | j++; |
@@ -492,7 +492,7 @@ static void __init ppc4xx_configure_pcix_PIMs(struct pci_controller *hose, | |||
492 | int big_pim, | 492 | int big_pim, |
493 | int enable_msi_hole) | 493 | int enable_msi_hole) |
494 | { | 494 | { |
495 | resource_size_t size = res->end - res->start + 1; | 495 | resource_size_t size = resource_size(res); |
496 | u32 sa; | 496 | u32 sa; |
497 | 497 | ||
498 | /* RAM is always at 0 */ | 498 | /* RAM is always at 0 */ |
@@ -555,7 +555,7 @@ static void __init ppc4xx_probe_pcix_bridge(struct device_node *np) | |||
555 | bus_range = of_get_property(np, "bus-range", NULL); | 555 | bus_range = of_get_property(np, "bus-range", NULL); |
556 | 556 | ||
557 | /* Map registers */ | 557 | /* Map registers */ |
558 | reg = ioremap(rsrc_reg.start, rsrc_reg.end + 1 - rsrc_reg.start); | 558 | reg = ioremap(rsrc_reg.start, resource_size(&rsrc_reg)); |
559 | if (reg == NULL) { | 559 | if (reg == NULL) { |
560 | printk(KERN_ERR "%s: Can't map registers !", np->full_name); | 560 | printk(KERN_ERR "%s: Can't map registers !", np->full_name); |
561 | goto fail; | 561 | goto fail; |
@@ -1604,7 +1604,7 @@ static void __init ppc4xx_configure_pciex_POMs(struct ppc4xx_pciex_port *port, | |||
1604 | if (ppc4xx_setup_one_pciex_POM(port, hose, mbase, | 1604 | if (ppc4xx_setup_one_pciex_POM(port, hose, mbase, |
1605 | res->start, | 1605 | res->start, |
1606 | res->start - hose->pci_mem_offset, | 1606 | res->start - hose->pci_mem_offset, |
1607 | res->end + 1 - res->start, | 1607 | resource_size(res), |
1608 | res->flags, | 1608 | res->flags, |
1609 | j) == 0) { | 1609 | j) == 0) { |
1610 | j++; | 1610 | j++; |
@@ -1639,7 +1639,7 @@ static void __init ppc4xx_configure_pciex_PIMs(struct ppc4xx_pciex_port *port, | |||
1639 | void __iomem *mbase, | 1639 | void __iomem *mbase, |
1640 | struct resource *res) | 1640 | struct resource *res) |
1641 | { | 1641 | { |
1642 | resource_size_t size = res->end - res->start + 1; | 1642 | resource_size_t size = resource_size(res); |
1643 | u64 sa; | 1643 | u64 sa; |
1644 | 1644 | ||
1645 | if (port->endpoint) { | 1645 | if (port->endpoint) { |
diff --git a/arch/powerpc/sysdev/qe_lib/qe_ic.c b/arch/powerpc/sysdev/qe_lib/qe_ic.c index b2acda07220d..18e75ca19fe6 100644 --- a/arch/powerpc/sysdev/qe_lib/qe_ic.c +++ b/arch/powerpc/sysdev/qe_lib/qe_ic.c | |||
@@ -347,7 +347,7 @@ void __init qe_ic_init(struct device_node *node, unsigned int flags, | |||
347 | return; | 347 | return; |
348 | } | 348 | } |
349 | 349 | ||
350 | qe_ic->regs = ioremap(res.start, res.end - res.start + 1); | 350 | qe_ic->regs = ioremap(res.start, resource_size(&res)); |
351 | 351 | ||
352 | qe_ic->irqhost->host_data = qe_ic; | 352 | qe_ic->irqhost->host_data = qe_ic; |
353 | qe_ic->hc_irq = qe_ic_irq_chip; | 353 | qe_ic->hc_irq = qe_ic_irq_chip; |
diff --git a/arch/powerpc/sysdev/qe_lib/qe_io.c b/arch/powerpc/sysdev/qe_lib/qe_io.c index 77e4934b88c5..fd1a6c3b1721 100644 --- a/arch/powerpc/sysdev/qe_lib/qe_io.c +++ b/arch/powerpc/sysdev/qe_lib/qe_io.c | |||
@@ -41,7 +41,7 @@ int par_io_init(struct device_node *np) | |||
41 | ret = of_address_to_resource(np, 0, &res); | 41 | ret = of_address_to_resource(np, 0, &res); |
42 | if (ret) | 42 | if (ret) |
43 | return ret; | 43 | return ret; |
44 | par_io = ioremap(res.start, res.end - res.start + 1); | 44 | par_io = ioremap(res.start, resource_size(&res)); |
45 | 45 | ||
46 | num_ports = of_get_property(np, "num-ports", NULL); | 46 | num_ports = of_get_property(np, "num-ports", NULL); |
47 | if (num_ports) | 47 | if (num_ports) |
diff --git a/arch/powerpc/sysdev/xics/icp-native.c b/arch/powerpc/sysdev/xics/icp-native.c index ba382b59b926..50e32afe392e 100644 --- a/arch/powerpc/sysdev/xics/icp-native.c +++ b/arch/powerpc/sysdev/xics/icp-native.c | |||
@@ -256,7 +256,7 @@ static int __init icp_native_init_one_node(struct device_node *np, | |||
256 | return -1; | 256 | return -1; |
257 | } | 257 | } |
258 | 258 | ||
259 | if (icp_native_map_one_cpu(*indx, r.start, r.end - r.start)) | 259 | if (icp_native_map_one_cpu(*indx, r.start, resource_size(&r))) |
260 | return -1; | 260 | return -1; |
261 | 261 | ||
262 | (*indx)++; | 262 | (*indx)++; |
diff --git a/arch/s390/oprofile/init.c b/arch/s390/oprofile/init.c index 0e358c2cffeb..6efc18b5e60a 100644 --- a/arch/s390/oprofile/init.c +++ b/arch/s390/oprofile/init.c | |||
@@ -13,8 +13,6 @@ | |||
13 | #include <linux/oprofile.h> | 13 | #include <linux/oprofile.h> |
14 | #include <linux/init.h> | 14 | #include <linux/init.h> |
15 | #include <linux/errno.h> | 15 | #include <linux/errno.h> |
16 | #include <linux/oprofile.h> | ||
17 | #include <linux/errno.h> | ||
18 | #include <linux/fs.h> | 16 | #include <linux/fs.h> |
19 | 17 | ||
20 | #include "../../../drivers/oprofile/oprof.h" | 18 | #include "../../../drivers/oprofile/oprof.h" |
diff --git a/arch/sh/boards/mach-ap325rxa/setup.c b/arch/sh/boards/mach-ap325rxa/setup.c index 969421f64a15..1dc924b2f508 100644 --- a/arch/sh/boards/mach-ap325rxa/setup.c +++ b/arch/sh/boards/mach-ap325rxa/setup.c | |||
@@ -188,7 +188,7 @@ static void ap320_wvga_power_off(void *board_data) | |||
188 | __raw_writew(0, FPGA_LCDREG); | 188 | __raw_writew(0, FPGA_LCDREG); |
189 | } | 189 | } |
190 | 190 | ||
191 | const static struct fb_videomode ap325rxa_lcdc_modes[] = { | 191 | static const struct fb_videomode ap325rxa_lcdc_modes[] = { |
192 | { | 192 | { |
193 | .name = "LB070WV1", | 193 | .name = "LB070WV1", |
194 | .xres = 800, | 194 | .xres = 800, |
diff --git a/arch/sh/boards/mach-ecovec24/setup.c b/arch/sh/boards/mach-ecovec24/setup.c index 513cb1a2e6c8..b24d69d509e7 100644 --- a/arch/sh/boards/mach-ecovec24/setup.c +++ b/arch/sh/boards/mach-ecovec24/setup.c | |||
@@ -280,7 +280,7 @@ static struct platform_device usbhs_device = { | |||
280 | }; | 280 | }; |
281 | 281 | ||
282 | /* LCDC */ | 282 | /* LCDC */ |
283 | const static struct fb_videomode ecovec_lcd_modes[] = { | 283 | static const struct fb_videomode ecovec_lcd_modes[] = { |
284 | { | 284 | { |
285 | .name = "Panel", | 285 | .name = "Panel", |
286 | .xres = 800, | 286 | .xres = 800, |
@@ -295,7 +295,7 @@ const static struct fb_videomode ecovec_lcd_modes[] = { | |||
295 | }, | 295 | }, |
296 | }; | 296 | }; |
297 | 297 | ||
298 | const static struct fb_videomode ecovec_dvi_modes[] = { | 298 | static const struct fb_videomode ecovec_dvi_modes[] = { |
299 | { | 299 | { |
300 | .name = "DVI", | 300 | .name = "DVI", |
301 | .xres = 1280, | 301 | .xres = 1280, |
diff --git a/arch/sh/boards/mach-kfr2r09/setup.c b/arch/sh/boards/mach-kfr2r09/setup.c index 8b4abbbd1477..f65271a8d075 100644 --- a/arch/sh/boards/mach-kfr2r09/setup.c +++ b/arch/sh/boards/mach-kfr2r09/setup.c | |||
@@ -127,7 +127,7 @@ static struct platform_device kfr2r09_sh_keysc_device = { | |||
127 | }, | 127 | }, |
128 | }; | 128 | }; |
129 | 129 | ||
130 | const static struct fb_videomode kfr2r09_lcdc_modes[] = { | 130 | static const struct fb_videomode kfr2r09_lcdc_modes[] = { |
131 | { | 131 | { |
132 | .name = "TX07D34VM0AAA", | 132 | .name = "TX07D34VM0AAA", |
133 | .xres = 240, | 133 | .xres = 240, |
diff --git a/arch/sh/boards/mach-migor/setup.c b/arch/sh/boards/mach-migor/setup.c index 184fde169132..2d4c9c8c6664 100644 --- a/arch/sh/boards/mach-migor/setup.c +++ b/arch/sh/boards/mach-migor/setup.c | |||
@@ -214,7 +214,7 @@ static struct platform_device migor_nand_flash_device = { | |||
214 | } | 214 | } |
215 | }; | 215 | }; |
216 | 216 | ||
217 | const static struct fb_videomode migor_lcd_modes[] = { | 217 | static const struct fb_videomode migor_lcd_modes[] = { |
218 | { | 218 | { |
219 | #if defined(CONFIG_SH_MIGOR_RTA_WVGA) | 219 | #if defined(CONFIG_SH_MIGOR_RTA_WVGA) |
220 | .name = "LB070WV1", | 220 | .name = "LB070WV1", |
diff --git a/arch/sh/boards/mach-se/7724/setup.c b/arch/sh/boards/mach-se/7724/setup.c index 12357671023e..d00756728bd2 100644 --- a/arch/sh/boards/mach-se/7724/setup.c +++ b/arch/sh/boards/mach-se/7724/setup.c | |||
@@ -145,7 +145,7 @@ static struct platform_device nor_flash_device = { | |||
145 | }; | 145 | }; |
146 | 146 | ||
147 | /* LCDC */ | 147 | /* LCDC */ |
148 | const static struct fb_videomode lcdc_720p_modes[] = { | 148 | static const struct fb_videomode lcdc_720p_modes[] = { |
149 | { | 149 | { |
150 | .name = "LB070WV1", | 150 | .name = "LB070WV1", |
151 | .sync = 0, /* hsync and vsync are active low */ | 151 | .sync = 0, /* hsync and vsync are active low */ |
@@ -160,7 +160,7 @@ const static struct fb_videomode lcdc_720p_modes[] = { | |||
160 | }, | 160 | }, |
161 | }; | 161 | }; |
162 | 162 | ||
163 | const static struct fb_videomode lcdc_vga_modes[] = { | 163 | static const struct fb_videomode lcdc_vga_modes[] = { |
164 | { | 164 | { |
165 | .name = "LB070WV1", | 165 | .name = "LB070WV1", |
166 | .sync = 0, /* hsync and vsync are active low */ | 166 | .sync = 0, /* hsync and vsync are active low */ |
diff --git a/arch/sh/kernel/io_trapped.c b/arch/sh/kernel/io_trapped.c index 32c385ef1011..0f62f4672754 100644 --- a/arch/sh/kernel/io_trapped.c +++ b/arch/sh/kernel/io_trapped.c | |||
@@ -58,7 +58,7 @@ int register_trapped_io(struct trapped_io *tiop) | |||
58 | 58 | ||
59 | for (k = 0; k < tiop->num_resources; k++) { | 59 | for (k = 0; k < tiop->num_resources; k++) { |
60 | res = tiop->resource + k; | 60 | res = tiop->resource + k; |
61 | len += roundup((res->end - res->start) + 1, PAGE_SIZE); | 61 | len += roundup(resource_size(res), PAGE_SIZE); |
62 | flags |= res->flags; | 62 | flags |= res->flags; |
63 | } | 63 | } |
64 | 64 | ||
@@ -85,7 +85,7 @@ int register_trapped_io(struct trapped_io *tiop) | |||
85 | (unsigned long)(tiop->virt_base + len), | 85 | (unsigned long)(tiop->virt_base + len), |
86 | res->flags & IORESOURCE_IO ? "io" : "mmio", | 86 | res->flags & IORESOURCE_IO ? "io" : "mmio", |
87 | (unsigned long)res->start); | 87 | (unsigned long)res->start); |
88 | len += roundup((res->end - res->start) + 1, PAGE_SIZE); | 88 | len += roundup(resource_size(res), PAGE_SIZE); |
89 | } | 89 | } |
90 | 90 | ||
91 | tiop->magic = IO_TRAPPED_MAGIC; | 91 | tiop->magic = IO_TRAPPED_MAGIC; |
@@ -128,7 +128,7 @@ void __iomem *match_trapped_io_handler(struct list_head *list, | |||
128 | return tiop->virt_base + voffs; | 128 | return tiop->virt_base + voffs; |
129 | } | 129 | } |
130 | 130 | ||
131 | len = (res->end - res->start) + 1; | 131 | len = resource_size(res); |
132 | voffs += roundup(len, PAGE_SIZE); | 132 | voffs += roundup(len, PAGE_SIZE); |
133 | } | 133 | } |
134 | } | 134 | } |
@@ -173,7 +173,7 @@ static unsigned long lookup_address(struct trapped_io *tiop, | |||
173 | 173 | ||
174 | for (k = 0; k < tiop->num_resources; k++) { | 174 | for (k = 0; k < tiop->num_resources; k++) { |
175 | res = tiop->resource + k; | 175 | res = tiop->resource + k; |
176 | len = roundup((res->end - res->start) + 1, PAGE_SIZE); | 176 | len = roundup(resource_size(res), PAGE_SIZE); |
177 | if (address < (vaddr + len)) | 177 | if (address < (vaddr + len)) |
178 | return res->start + (address - vaddr); | 178 | return res->start + (address - vaddr); |
179 | vaddr += len; | 179 | vaddr += len; |
diff --git a/arch/sh/kernel/machine_kexec.c b/arch/sh/kernel/machine_kexec.c index e2a3af31ff99..c5a33f007f88 100644 --- a/arch/sh/kernel/machine_kexec.c +++ b/arch/sh/kernel/machine_kexec.c | |||
@@ -170,7 +170,7 @@ void __init reserve_crashkernel(void) | |||
170 | if (crashk_res.end == crashk_res.start) | 170 | if (crashk_res.end == crashk_res.start) |
171 | goto disable; | 171 | goto disable; |
172 | 172 | ||
173 | crash_size = PAGE_ALIGN(crashk_res.end - crashk_res.start + 1); | 173 | crash_size = PAGE_ALIGN(resource_size(&crashk_res)); |
174 | if (!crashk_res.start) { | 174 | if (!crashk_res.start) { |
175 | unsigned long max = memblock_end_of_DRAM() - memory_limit; | 175 | unsigned long max = memblock_end_of_DRAM() - memory_limit; |
176 | crashk_res.start = __memblock_alloc_base(crash_size, PAGE_SIZE, max); | 176 | crashk_res.start = __memblock_alloc_base(crash_size, PAGE_SIZE, max); |
diff --git a/arch/sparc/include/asm/elf_64.h b/arch/sparc/include/asm/elf_64.h index e67880381b84..cfa9cd2e5519 100644 --- a/arch/sparc/include/asm/elf_64.h +++ b/arch/sparc/include/asm/elf_64.h | |||
@@ -186,7 +186,7 @@ static inline unsigned int sparc64_elf_hwcap(void) | |||
186 | return cap; | 186 | return cap; |
187 | } | 187 | } |
188 | 188 | ||
189 | #define ELF_HWCAP sparc64_elf_hwcap(); | 189 | #define ELF_HWCAP sparc64_elf_hwcap() |
190 | 190 | ||
191 | /* This yields a string that ld.so will use to load implementation | 191 | /* This yields a string that ld.so will use to load implementation |
192 | specific libraries for optimization. This is more specific in | 192 | specific libraries for optimization. This is more specific in |
diff --git a/arch/sparc/kernel/ioport.c b/arch/sparc/kernel/ioport.c index 1c9c80a1a86a..6ffccd6e0156 100644 --- a/arch/sparc/kernel/ioport.c +++ b/arch/sparc/kernel/ioport.c | |||
@@ -228,7 +228,7 @@ _sparc_ioremap(struct resource *res, u32 bus, u32 pa, int sz) | |||
228 | } | 228 | } |
229 | 229 | ||
230 | pa &= PAGE_MASK; | 230 | pa &= PAGE_MASK; |
231 | sparc_mapiorange(bus, pa, res->start, res->end - res->start + 1); | 231 | sparc_mapiorange(bus, pa, res->start, resource_size(res)); |
232 | 232 | ||
233 | return (void __iomem *)(unsigned long)(res->start + offset); | 233 | return (void __iomem *)(unsigned long)(res->start + offset); |
234 | } | 234 | } |
@@ -240,7 +240,7 @@ static void _sparc_free_io(struct resource *res) | |||
240 | { | 240 | { |
241 | unsigned long plen; | 241 | unsigned long plen; |
242 | 242 | ||
243 | plen = res->end - res->start + 1; | 243 | plen = resource_size(res); |
244 | BUG_ON((plen & (PAGE_SIZE-1)) != 0); | 244 | BUG_ON((plen & (PAGE_SIZE-1)) != 0); |
245 | sparc_unmapiorange(res->start, plen); | 245 | sparc_unmapiorange(res->start, plen); |
246 | release_resource(res); | 246 | release_resource(res); |
@@ -331,9 +331,9 @@ static void sbus_free_coherent(struct device *dev, size_t n, void *p, | |||
331 | } | 331 | } |
332 | 332 | ||
333 | n = PAGE_ALIGN(n); | 333 | n = PAGE_ALIGN(n); |
334 | if ((res->end-res->start)+1 != n) { | 334 | if (resource_size(res) != n) { |
335 | printk("sbus_free_consistent: region 0x%lx asked 0x%zx\n", | 335 | printk("sbus_free_consistent: region 0x%lx asked 0x%zx\n", |
336 | (long)((res->end-res->start)+1), n); | 336 | (long)resource_size(res), n); |
337 | return; | 337 | return; |
338 | } | 338 | } |
339 | 339 | ||
@@ -504,9 +504,9 @@ static void pci32_free_coherent(struct device *dev, size_t n, void *p, | |||
504 | } | 504 | } |
505 | 505 | ||
506 | n = PAGE_ALIGN(n); | 506 | n = PAGE_ALIGN(n); |
507 | if ((res->end-res->start)+1 != n) { | 507 | if (resource_size(res) != n) { |
508 | printk("pci_free_consistent: region 0x%lx asked 0x%lx\n", | 508 | printk("pci_free_consistent: region 0x%lx asked 0x%lx\n", |
509 | (long)((res->end-res->start)+1), (long)n); | 509 | (long)resource_size(res), (long)n); |
510 | return; | 510 | return; |
511 | } | 511 | } |
512 | 512 | ||
diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c index 80a87e2a3e7c..1e94f946570e 100644 --- a/arch/sparc/kernel/pci.c +++ b/arch/sparc/kernel/pci.c | |||
@@ -820,11 +820,9 @@ static int __pci_mmap_make_offset_bus(struct pci_dev *pdev, struct vm_area_struc | |||
820 | unsigned long space_size, user_offset, user_size; | 820 | unsigned long space_size, user_offset, user_size; |
821 | 821 | ||
822 | if (mmap_state == pci_mmap_io) { | 822 | if (mmap_state == pci_mmap_io) { |
823 | space_size = (pbm->io_space.end - | 823 | space_size = resource_size(&pbm->io_space); |
824 | pbm->io_space.start) + 1; | ||
825 | } else { | 824 | } else { |
826 | space_size = (pbm->mem_space.end - | 825 | space_size = resource_size(&pbm->mem_space); |
827 | pbm->mem_space.start) + 1; | ||
828 | } | 826 | } |
829 | 827 | ||
830 | /* Make sure the request is in range. */ | 828 | /* Make sure the request is in range. */ |
diff --git a/arch/tile/kernel/setup.c b/arch/tile/kernel/setup.c index 6cdc9ba55fe0..5f85d8b34dbb 100644 --- a/arch/tile/kernel/setup.c +++ b/arch/tile/kernel/setup.c | |||
@@ -553,8 +553,7 @@ static void __init setup_bootmem_allocator(void) | |||
553 | 553 | ||
554 | #ifdef CONFIG_KEXEC | 554 | #ifdef CONFIG_KEXEC |
555 | if (crashk_res.start != crashk_res.end) | 555 | if (crashk_res.start != crashk_res.end) |
556 | reserve_bootmem(crashk_res.start, | 556 | reserve_bootmem(crashk_res.start, resource_size(&crashk_res), 0); |
557 | crashk_res.end - crashk_res.start + 1, 0); | ||
558 | #endif | 557 | #endif |
559 | } | 558 | } |
560 | 559 | ||
diff --git a/arch/um/sys-i386/signal.c b/arch/um/sys-i386/signal.c index 129647375a6c..89a46626bfd8 100644 --- a/arch/um/sys-i386/signal.c +++ b/arch/um/sys-i386/signal.c | |||
@@ -58,7 +58,7 @@ static inline unsigned long twd_fxsr_to_i387(struct user_fxsr_struct *fxsave) | |||
58 | unsigned long ret = 0xffff0000; | 58 | unsigned long ret = 0xffff0000; |
59 | int i; | 59 | int i; |
60 | 60 | ||
61 | #define FPREG_ADDR(f, n) ((char *)&(f)->st_space + (n) * 16); | 61 | #define FPREG_ADDR(f, n) ((char *)&(f)->st_space + (n) * 16) |
62 | 62 | ||
63 | for (i = 0; i < 8; i++) { | 63 | for (i = 0; i < 8; i++) { |
64 | if (twd & 0x1) { | 64 | if (twd & 0x1) { |
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index a67e014e4e44..78fe57dcfc56 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig | |||
@@ -1737,8 +1737,8 @@ menuconfig APM | |||
1737 | machines with more than one CPU. | 1737 | machines with more than one CPU. |
1738 | 1738 | ||
1739 | In order to use APM, you will need supporting software. For location | 1739 | In order to use APM, you will need supporting software. For location |
1740 | and more information, read <file:Documentation/power/pm.txt> and the | 1740 | and more information, read <file:Documentation/power/apm-acpi.txt> |
1741 | Battery Powered Linux mini-HOWTO, available from | 1741 | and the Battery Powered Linux mini-HOWTO, available from |
1742 | <http://www.tldp.org/docs.html#howto>. | 1742 | <http://www.tldp.org/docs.html#howto>. |
1743 | 1743 | ||
1744 | This driver does not spin down disk drives (see the hdparm(8) | 1744 | This driver does not spin down disk drives (see the hdparm(8) |
diff --git a/arch/x86/kernel/i387.c b/arch/x86/kernel/i387.c index 12aff2537682..739d8598f789 100644 --- a/arch/x86/kernel/i387.c +++ b/arch/x86/kernel/i387.c | |||
@@ -321,7 +321,7 @@ static inline unsigned short twd_i387_to_fxsr(unsigned short twd) | |||
321 | return tmp; | 321 | return tmp; |
322 | } | 322 | } |
323 | 323 | ||
324 | #define FPREG_ADDR(f, n) ((void *)&(f)->st_space + (n) * 16); | 324 | #define FPREG_ADDR(f, n) ((void *)&(f)->st_space + (n) * 16) |
325 | #define FP_EXP_TAG_VALID 0 | 325 | #define FP_EXP_TAG_VALID 0 |
326 | #define FP_EXP_TAG_ZERO 1 | 326 | #define FP_EXP_TAG_ZERO 1 |
327 | #define FP_EXP_TAG_SPECIAL 2 | 327 | #define FP_EXP_TAG_SPECIAL 2 |
diff --git a/arch/x86/kernel/pci-calgary_64.c b/arch/x86/kernel/pci-calgary_64.c index e8c33a302006..726494b58345 100644 --- a/arch/x86/kernel/pci-calgary_64.c +++ b/arch/x86/kernel/pci-calgary_64.c | |||
@@ -1553,7 +1553,7 @@ static void __init calgary_fixup_one_tce_space(struct pci_dev *dev) | |||
1553 | continue; | 1553 | continue; |
1554 | 1554 | ||
1555 | /* cover the whole region */ | 1555 | /* cover the whole region */ |
1556 | npages = (r->end - r->start) >> PAGE_SHIFT; | 1556 | npages = resource_size(r) >> PAGE_SHIFT; |
1557 | npages++; | 1557 | npages++; |
1558 | 1558 | ||
1559 | iommu_range_reserve(tbl, r->start, npages); | 1559 | iommu_range_reserve(tbl, r->start, npages); |
diff --git a/arch/x86/kernel/probe_roms.c b/arch/x86/kernel/probe_roms.c index ba0a4cce53be..63228035f9d7 100644 --- a/arch/x86/kernel/probe_roms.c +++ b/arch/x86/kernel/probe_roms.c | |||
@@ -234,7 +234,7 @@ void __init probe_roms(void) | |||
234 | /* check for extension rom (ignore length byte!) */ | 234 | /* check for extension rom (ignore length byte!) */ |
235 | rom = isa_bus_to_virt(extension_rom_resource.start); | 235 | rom = isa_bus_to_virt(extension_rom_resource.start); |
236 | if (romsignature(rom)) { | 236 | if (romsignature(rom)) { |
237 | length = extension_rom_resource.end - extension_rom_resource.start + 1; | 237 | length = resource_size(&extension_rom_resource); |
238 | if (romchecksum(rom, length)) { | 238 | if (romchecksum(rom, length)) { |
239 | request_resource(&iomem_resource, &extension_rom_resource); | 239 | request_resource(&iomem_resource, &extension_rom_resource); |
240 | upper = extension_rom_resource.start; | 240 | upper = extension_rom_resource.start; |
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c index 9335e1bf72ad..1c5b69373a00 100644 --- a/arch/x86/kvm/mmu.c +++ b/arch/x86/kvm/mmu.c | |||
@@ -22,7 +22,6 @@ | |||
22 | #include "mmu.h" | 22 | #include "mmu.h" |
23 | #include "x86.h" | 23 | #include "x86.h" |
24 | #include "kvm_cache_regs.h" | 24 | #include "kvm_cache_regs.h" |
25 | #include "x86.h" | ||
26 | 25 | ||
27 | #include <linux/kvm_host.h> | 26 | #include <linux/kvm_host.h> |
28 | #include <linux/types.h> | 27 | #include <linux/types.h> |
diff --git a/arch/xtensa/include/asm/uaccess.h b/arch/xtensa/include/asm/uaccess.h index 5b0c18c1cce1..82d4e3815c89 100644 --- a/arch/xtensa/include/asm/uaccess.h +++ b/arch/xtensa/include/asm/uaccess.h | |||
@@ -17,6 +17,7 @@ | |||
17 | #define _XTENSA_UACCESS_H | 17 | #define _XTENSA_UACCESS_H |
18 | 18 | ||
19 | #include <linux/errno.h> | 19 | #include <linux/errno.h> |
20 | #include <asm/types.h> | ||
20 | 21 | ||
21 | #define VERIFY_READ 0 | 22 | #define VERIFY_READ 0 |
22 | #define VERIFY_WRITE 1 | 23 | #define VERIFY_WRITE 1 |
@@ -26,7 +27,6 @@ | |||
26 | #include <asm/current.h> | 27 | #include <asm/current.h> |
27 | #include <asm/asm-offsets.h> | 28 | #include <asm/asm-offsets.h> |
28 | #include <asm/processor.h> | 29 | #include <asm/processor.h> |
29 | #include <asm/types.h> | ||
30 | 30 | ||
31 | /* | 31 | /* |
32 | * These assembly macros mirror the C macros that follow below. They | 32 | * These assembly macros mirror the C macros that follow below. They |
@@ -157,7 +157,6 @@ | |||
157 | #else /* __ASSEMBLY__ not defined */ | 157 | #else /* __ASSEMBLY__ not defined */ |
158 | 158 | ||
159 | #include <linux/sched.h> | 159 | #include <linux/sched.h> |
160 | #include <asm/types.h> | ||
161 | 160 | ||
162 | /* | 161 | /* |
163 | * The fs value determines whether argument validity checking should | 162 | * The fs value determines whether argument validity checking should |
diff --git a/arch/xtensa/variants/s6000/include/variant/dmac.h b/arch/xtensa/variants/s6000/include/variant/dmac.h index 89ab9484fb71..e81735b2a206 100644 --- a/arch/xtensa/variants/s6000/include/variant/dmac.h +++ b/arch/xtensa/variants/s6000/include/variant/dmac.h | |||
@@ -357,7 +357,7 @@ static inline u32 s6dmac_channel_enabled(u32 dmac, int chan) | |||
357 | static inline void s6dmac_dp_setup_group(u32 dmac, int port, | 357 | static inline void s6dmac_dp_setup_group(u32 dmac, int port, |
358 | int nrch, int frrep) | 358 | int nrch, int frrep) |
359 | { | 359 | { |
360 | const static u8 mask[4] = {0, 3, 1, 2}; | 360 | static const u8 mask[4] = {0, 3, 1, 2}; |
361 | BUG_ON(dmac != S6_REG_DPDMA); | 361 | BUG_ON(dmac != S6_REG_DPDMA); |
362 | if ((port < 0) || (port > 3) || (nrch < 1) || (nrch > 4)) | 362 | if ((port < 0) || (port > 3) || (nrch < 1) || (nrch > 4)) |
363 | return; | 363 | return; |
diff --git a/crypto/Kconfig b/crypto/Kconfig index 2af81552d65b..ae27b7534ea7 100644 --- a/crypto/Kconfig +++ b/crypto/Kconfig | |||
@@ -354,7 +354,7 @@ config CRYPTO_RMD128 | |||
354 | RIPEMD-128 (ISO/IEC 10118-3:2004). | 354 | RIPEMD-128 (ISO/IEC 10118-3:2004). |
355 | 355 | ||
356 | RIPEMD-128 is a 128-bit cryptographic hash function. It should only | 356 | RIPEMD-128 is a 128-bit cryptographic hash function. It should only |
357 | to be used as a secure replacement for RIPEMD. For other use cases | 357 | be used as a secure replacement for RIPEMD. For other use cases, |
358 | RIPEMD-160 should be used. | 358 | RIPEMD-160 should be used. |
359 | 359 | ||
360 | Developed by Hans Dobbertin, Antoon Bosselaers and Bart Preneel. | 360 | Developed by Hans Dobbertin, Antoon Bosselaers and Bart Preneel. |
diff --git a/drivers/acpi/ac.c b/drivers/acpi/ac.c index 58c3f74bd84c..6512b20aeccd 100644 --- a/drivers/acpi/ac.c +++ b/drivers/acpi/ac.c | |||
@@ -89,7 +89,7 @@ struct acpi_ac { | |||
89 | unsigned long long state; | 89 | unsigned long long state; |
90 | }; | 90 | }; |
91 | 91 | ||
92 | #define to_acpi_ac(x) container_of(x, struct acpi_ac, charger); | 92 | #define to_acpi_ac(x) container_of(x, struct acpi_ac, charger) |
93 | 93 | ||
94 | #ifdef CONFIG_ACPI_PROCFS_POWER | 94 | #ifdef CONFIG_ACPI_PROCFS_POWER |
95 | static const struct file_operations acpi_ac_fops = { | 95 | static const struct file_operations acpi_ac_fops = { |
diff --git a/drivers/acpi/battery.c b/drivers/acpi/battery.c index fcc13ac0aa18..2c661353e8f2 100644 --- a/drivers/acpi/battery.c +++ b/drivers/acpi/battery.c | |||
@@ -132,7 +132,7 @@ struct acpi_battery { | |||
132 | unsigned long flags; | 132 | unsigned long flags; |
133 | }; | 133 | }; |
134 | 134 | ||
135 | #define to_acpi_battery(x) container_of(x, struct acpi_battery, bat); | 135 | #define to_acpi_battery(x) container_of(x, struct acpi_battery, bat) |
136 | 136 | ||
137 | inline int acpi_battery_present(struct acpi_battery *battery) | 137 | inline int acpi_battery_present(struct acpi_battery *battery) |
138 | { | 138 | { |
diff --git a/drivers/acpi/sbs.c b/drivers/acpi/sbs.c index 51ae3794ec7f..50658ff887d9 100644 --- a/drivers/acpi/sbs.c +++ b/drivers/acpi/sbs.c | |||
@@ -112,7 +112,7 @@ struct acpi_battery { | |||
112 | u8 have_sysfs_alarm:1; | 112 | u8 have_sysfs_alarm:1; |
113 | }; | 113 | }; |
114 | 114 | ||
115 | #define to_acpi_battery(x) container_of(x, struct acpi_battery, bat); | 115 | #define to_acpi_battery(x) container_of(x, struct acpi_battery, bat) |
116 | 116 | ||
117 | struct acpi_sbs { | 117 | struct acpi_sbs { |
118 | struct power_supply charger; | 118 | struct power_supply charger; |
diff --git a/drivers/bcma/driver_chipcommon.c b/drivers/bcma/driver_chipcommon.c index fb543024df2f..851e05bc948a 100644 --- a/drivers/bcma/driver_chipcommon.c +++ b/drivers/bcma/driver_chipcommon.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * ChipCommon core driver | 3 | * ChipCommon core driver |
4 | * | 4 | * |
5 | * Copyright 2005, Broadcom Corporation | 5 | * Copyright 2005, Broadcom Corporation |
6 | * Copyright 2006, 2007, Michael Buesch <mb@bu3sch.de> | 6 | * Copyright 2006, 2007, Michael Buesch <m@bues.ch> |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
9 | */ | 9 | */ |
diff --git a/drivers/bcma/driver_chipcommon_pmu.c b/drivers/bcma/driver_chipcommon_pmu.c index dd5846bef029..fcc63db0ce75 100644 --- a/drivers/bcma/driver_chipcommon_pmu.c +++ b/drivers/bcma/driver_chipcommon_pmu.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * Broadcom specific AMBA | 2 | * Broadcom specific AMBA |
3 | * ChipCommon Power Management Unit driver | 3 | * ChipCommon Power Management Unit driver |
4 | * | 4 | * |
5 | * Copyright 2009, Michael Buesch <mb@bu3sch.de> | 5 | * Copyright 2009, Michael Buesch <m@bues.ch> |
6 | * Copyright 2007, Broadcom Corporation | 6 | * Copyright 2007, Broadcom Corporation |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
diff --git a/drivers/bcma/driver_pci.c b/drivers/bcma/driver_pci.c index 745d26491291..25f3ddf33823 100644 --- a/drivers/bcma/driver_pci.c +++ b/drivers/bcma/driver_pci.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * PCI Core | 3 | * PCI Core |
4 | * | 4 | * |
5 | * Copyright 2005, Broadcom Corporation | 5 | * Copyright 2005, Broadcom Corporation |
6 | * Copyright 2006, 2007, Michael Buesch <mb@bu3sch.de> | 6 | * Copyright 2006, 2007, Michael Buesch <m@bues.ch> |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
9 | */ | 9 | */ |
diff --git a/drivers/char/bsr.c b/drivers/char/bsr.c index cf39bc08ce08..0c688232aab3 100644 --- a/drivers/char/bsr.c +++ b/drivers/char/bsr.c | |||
@@ -212,7 +212,7 @@ static int bsr_add_node(struct device_node *bn) | |||
212 | 212 | ||
213 | cur->bsr_minor = i + total_bsr_devs; | 213 | cur->bsr_minor = i + total_bsr_devs; |
214 | cur->bsr_addr = res.start; | 214 | cur->bsr_addr = res.start; |
215 | cur->bsr_len = res.end - res.start + 1; | 215 | cur->bsr_len = resource_size(&res); |
216 | cur->bsr_bytes = bsr_bytes[i]; | 216 | cur->bsr_bytes = bsr_bytes[i]; |
217 | cur->bsr_stride = bsr_stride[i]; | 217 | cur->bsr_stride = bsr_stride[i]; |
218 | cur->bsr_dev = MKDEV(bsr_major, i + total_bsr_devs); | 218 | cur->bsr_dev = MKDEV(bsr_major, i + total_bsr_devs); |
diff --git a/drivers/char/hw_random/core.c b/drivers/char/hw_random/core.c index 2016aad85203..1bafb40ec8a2 100644 --- a/drivers/char/hw_random/core.c +++ b/drivers/char/hw_random/core.c | |||
@@ -19,7 +19,7 @@ | |||
19 | Copyright 2000,2001 Philipp Rumpf <prumpf@mandrakesoft.com> | 19 | Copyright 2000,2001 Philipp Rumpf <prumpf@mandrakesoft.com> |
20 | 20 | ||
21 | Added generic RNG API | 21 | Added generic RNG API |
22 | Copyright 2006 Michael Buesch <mbuesch@freenet.de> | 22 | Copyright 2006 Michael Buesch <m@bues.ch> |
23 | Copyright 2005 (c) MontaVista Software, Inc. | 23 | Copyright 2005 (c) MontaVista Software, Inc. |
24 | 24 | ||
25 | Please read Documentation/hw_random.txt for details on use. | 25 | Please read Documentation/hw_random.txt for details on use. |
diff --git a/drivers/char/xilinx_hwicap/xilinx_hwicap.c b/drivers/char/xilinx_hwicap/xilinx_hwicap.c index 39ccdeada791..e90e1c74fd4c 100644 --- a/drivers/char/xilinx_hwicap/xilinx_hwicap.c +++ b/drivers/char/xilinx_hwicap/xilinx_hwicap.c | |||
@@ -621,7 +621,7 @@ static int __devinit hwicap_setup(struct device *dev, int id, | |||
621 | 621 | ||
622 | drvdata->mem_start = regs_res->start; | 622 | drvdata->mem_start = regs_res->start; |
623 | drvdata->mem_end = regs_res->end; | 623 | drvdata->mem_end = regs_res->end; |
624 | drvdata->mem_size = regs_res->end - regs_res->start + 1; | 624 | drvdata->mem_size = resource_size(regs_res); |
625 | 625 | ||
626 | if (!request_mem_region(drvdata->mem_start, | 626 | if (!request_mem_region(drvdata->mem_start, |
627 | drvdata->mem_size, DRIVER_NAME)) { | 627 | drvdata->mem_size, DRIVER_NAME)) { |
diff --git a/drivers/dma/mv_xor.c b/drivers/dma/mv_xor.c index 954e334e01bb..06f9f27dbe7c 100644 --- a/drivers/dma/mv_xor.c +++ b/drivers/dma/mv_xor.c | |||
@@ -1304,8 +1304,7 @@ static int mv_xor_shared_probe(struct platform_device *pdev) | |||
1304 | if (!res) | 1304 | if (!res) |
1305 | return -ENODEV; | 1305 | return -ENODEV; |
1306 | 1306 | ||
1307 | msp->xor_base = devm_ioremap(&pdev->dev, res->start, | 1307 | msp->xor_base = devm_ioremap(&pdev->dev, res->start, resource_size(res)); |
1308 | res->end - res->start + 1); | ||
1309 | if (!msp->xor_base) | 1308 | if (!msp->xor_base) |
1310 | return -EBUSY; | 1309 | return -EBUSY; |
1311 | 1310 | ||
@@ -1314,7 +1313,7 @@ static int mv_xor_shared_probe(struct platform_device *pdev) | |||
1314 | return -ENODEV; | 1313 | return -ENODEV; |
1315 | 1314 | ||
1316 | msp->xor_high_base = devm_ioremap(&pdev->dev, res->start, | 1315 | msp->xor_high_base = devm_ioremap(&pdev->dev, res->start, |
1317 | res->end - res->start + 1); | 1316 | resource_size(res)); |
1318 | if (!msp->xor_high_base) | 1317 | if (!msp->xor_high_base) |
1319 | return -EBUSY; | 1318 | return -EBUSY; |
1320 | 1319 | ||
diff --git a/drivers/edac/cell_edac.c b/drivers/edac/cell_edac.c index db1df59ae2b6..9a6a274e6925 100644 --- a/drivers/edac/cell_edac.c +++ b/drivers/edac/cell_edac.c | |||
@@ -140,7 +140,7 @@ static void __devinit cell_edac_init_csrows(struct mem_ctl_info *mci) | |||
140 | if (of_node_to_nid(np) != priv->node) | 140 | if (of_node_to_nid(np) != priv->node) |
141 | continue; | 141 | continue; |
142 | csrow->first_page = r.start >> PAGE_SHIFT; | 142 | csrow->first_page = r.start >> PAGE_SHIFT; |
143 | csrow->nr_pages = (r.end - r.start + 1) >> PAGE_SHIFT; | 143 | csrow->nr_pages = resource_size(&r) >> PAGE_SHIFT; |
144 | csrow->last_page = csrow->first_page + csrow->nr_pages - 1; | 144 | csrow->last_page = csrow->first_page + csrow->nr_pages - 1; |
145 | csrow->mtype = MEM_XDR; | 145 | csrow->mtype = MEM_XDR; |
146 | csrow->edac_mode = EDAC_SECDED; | 146 | csrow->edac_mode = EDAC_SECDED; |
diff --git a/drivers/edac/mpc85xx_edac.c b/drivers/edac/mpc85xx_edac.c index 38ab8e2cd7f4..11e1a5dad96f 100644 --- a/drivers/edac/mpc85xx_edac.c +++ b/drivers/edac/mpc85xx_edac.c | |||
@@ -538,15 +538,15 @@ static int __devinit mpc85xx_l2_err_probe(struct platform_device *op) | |||
538 | /* we only need the error registers */ | 538 | /* we only need the error registers */ |
539 | r.start += 0xe00; | 539 | r.start += 0xe00; |
540 | 540 | ||
541 | if (!devm_request_mem_region(&op->dev, r.start, | 541 | if (!devm_request_mem_region(&op->dev, r.start, resource_size(&r), |
542 | r.end - r.start + 1, pdata->name)) { | 542 | pdata->name)) { |
543 | printk(KERN_ERR "%s: Error while requesting mem region\n", | 543 | printk(KERN_ERR "%s: Error while requesting mem region\n", |
544 | __func__); | 544 | __func__); |
545 | res = -EBUSY; | 545 | res = -EBUSY; |
546 | goto err; | 546 | goto err; |
547 | } | 547 | } |
548 | 548 | ||
549 | pdata->l2_vbase = devm_ioremap(&op->dev, r.start, r.end - r.start + 1); | 549 | pdata->l2_vbase = devm_ioremap(&op->dev, r.start, resource_size(&r)); |
550 | if (!pdata->l2_vbase) { | 550 | if (!pdata->l2_vbase) { |
551 | printk(KERN_ERR "%s: Unable to setup L2 err regs\n", __func__); | 551 | printk(KERN_ERR "%s: Unable to setup L2 err regs\n", __func__); |
552 | res = -ENOMEM; | 552 | res = -ENOMEM; |
@@ -987,15 +987,15 @@ static int __devinit mpc85xx_mc_err_probe(struct platform_device *op) | |||
987 | goto err; | 987 | goto err; |
988 | } | 988 | } |
989 | 989 | ||
990 | if (!devm_request_mem_region(&op->dev, r.start, | 990 | if (!devm_request_mem_region(&op->dev, r.start, resource_size(&r), |
991 | r.end - r.start + 1, pdata->name)) { | 991 | pdata->name)) { |
992 | printk(KERN_ERR "%s: Error while requesting mem region\n", | 992 | printk(KERN_ERR "%s: Error while requesting mem region\n", |
993 | __func__); | 993 | __func__); |
994 | res = -EBUSY; | 994 | res = -EBUSY; |
995 | goto err; | 995 | goto err; |
996 | } | 996 | } |
997 | 997 | ||
998 | pdata->mc_vbase = devm_ioremap(&op->dev, r.start, r.end - r.start + 1); | 998 | pdata->mc_vbase = devm_ioremap(&op->dev, r.start, resource_size(&r)); |
999 | if (!pdata->mc_vbase) { | 999 | if (!pdata->mc_vbase) { |
1000 | printk(KERN_ERR "%s: Unable to setup MC err regs\n", __func__); | 1000 | printk(KERN_ERR "%s: Unable to setup MC err regs\n", __func__); |
1001 | res = -ENOMEM; | 1001 | res = -ENOMEM; |
diff --git a/drivers/gpio/gpio-ab8500.c b/drivers/gpio/gpio-ab8500.c index 970053c89ff7..ed795e64eea7 100644 --- a/drivers/gpio/gpio-ab8500.c +++ b/drivers/gpio/gpio-ab8500.c | |||
@@ -15,7 +15,6 @@ | |||
15 | #include <linux/module.h> | 15 | #include <linux/module.h> |
16 | #include <linux/err.h> | 16 | #include <linux/err.h> |
17 | #include <linux/platform_device.h> | 17 | #include <linux/platform_device.h> |
18 | #include <linux/slab.h> | ||
19 | #include <linux/gpio.h> | 18 | #include <linux/gpio.h> |
20 | #include <linux/irq.h> | 19 | #include <linux/irq.h> |
21 | #include <linux/interrupt.h> | 20 | #include <linux/interrupt.h> |
diff --git a/drivers/gpio/gpio-bt8xx.c b/drivers/gpio/gpio-bt8xx.c index aa4f09ad3ced..ec57936aef62 100644 --- a/drivers/gpio/gpio-bt8xx.c +++ b/drivers/gpio/gpio-bt8xx.c | |||
@@ -2,7 +2,7 @@ | |||
2 | 2 | ||
3 | bt8xx GPIO abuser | 3 | bt8xx GPIO abuser |
4 | 4 | ||
5 | Copyright (C) 2008 Michael Buesch <mb@bu3sch.de> | 5 | Copyright (C) 2008 Michael Buesch <m@bues.ch> |
6 | 6 | ||
7 | Please do _only_ contact the people listed _above_ with issues related to this driver. | 7 | Please do _only_ contact the people listed _above_ with issues related to this driver. |
8 | All the other people listed below are not related to this driver. Their names | 8 | All the other people listed below are not related to this driver. Their names |
diff --git a/drivers/gpio/gpio-ep93xx.c b/drivers/gpio/gpio-ep93xx.c index 3bfd3417ab11..72fb9c665320 100644 --- a/drivers/gpio/gpio-ep93xx.c +++ b/drivers/gpio/gpio-ep93xx.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * Generic EP93xx GPIO handling | 2 | * Generic EP93xx GPIO handling |
3 | * | 3 | * |
4 | * Copyright (c) 2008 Ryan Mallon <ryan@bluewatersys.com> | 4 | * Copyright (c) 2008 Ryan Mallon |
5 | * Copyright (c) 2011 H Hartley Sweeten <hsweeten@visionengravers.com> | 5 | * Copyright (c) 2011 H Hartley Sweeten <hsweeten@visionengravers.com> |
6 | * | 6 | * |
7 | * Based on code originally from: | 7 | * Based on code originally from: |
diff --git a/drivers/gpio/gpio-u300.c b/drivers/gpio/gpio-u300.c index fd2dfeeefdf3..53e8255cb0ba 100644 --- a/drivers/gpio/gpio-u300.c +++ b/drivers/gpio/gpio-u300.c | |||
@@ -578,8 +578,8 @@ static int __init gpio_probe(struct platform_device *pdev) | |||
578 | if (!memres) | 578 | if (!memres) |
579 | goto err_no_resource; | 579 | goto err_no_resource; |
580 | 580 | ||
581 | if (request_mem_region(memres->start, memres->end - memres->start, "GPIO Controller") | 581 | if (!request_mem_region(memres->start, resource_size(memres), |
582 | == NULL) { | 582 | "GPIO Controller")) { |
583 | err = -ENODEV; | 583 | err = -ENODEV; |
584 | goto err_no_ioregion; | 584 | goto err_no_ioregion; |
585 | } | 585 | } |
@@ -637,7 +637,7 @@ static int __init gpio_probe(struct platform_device *pdev) | |||
637 | free_irq(gpio_ports[i].irq, &gpio_ports[i]); | 637 | free_irq(gpio_ports[i].irq, &gpio_ports[i]); |
638 | iounmap(virtbase); | 638 | iounmap(virtbase); |
639 | err_no_ioremap: | 639 | err_no_ioremap: |
640 | release_mem_region(memres->start, memres->end - memres->start); | 640 | release_mem_region(memres->start, resource_size(memres)); |
641 | err_no_ioregion: | 641 | err_no_ioregion: |
642 | err_no_resource: | 642 | err_no_resource: |
643 | clk_disable(clk); | 643 | clk_disable(clk); |
@@ -657,7 +657,7 @@ static int __exit gpio_remove(struct platform_device *pdev) | |||
657 | for (i = 0 ; i < U300_GPIO_NUM_PORTS; i++) | 657 | for (i = 0 ; i < U300_GPIO_NUM_PORTS; i++) |
658 | free_irq(gpio_ports[i].irq, &gpio_ports[i]); | 658 | free_irq(gpio_ports[i].irq, &gpio_ports[i]); |
659 | iounmap(virtbase); | 659 | iounmap(virtbase); |
660 | release_mem_region(memres->start, memres->end - memres->start); | 660 | release_mem_region(memres->start, resource_size(memres)); |
661 | clk_disable(clk); | 661 | clk_disable(clk); |
662 | clk_put(clk); | 662 | clk_put(clk); |
663 | return 0; | 663 | return 0; |
diff --git a/drivers/gpu/drm/nouveau/nv50_graph.c b/drivers/gpu/drm/nouveau/nv50_graph.c index e25cbb46789a..40680f2b4231 100644 --- a/drivers/gpu/drm/nouveau/nv50_graph.c +++ b/drivers/gpu/drm/nouveau/nv50_graph.c | |||
@@ -31,7 +31,6 @@ | |||
31 | #include "nouveau_grctx.h" | 31 | #include "nouveau_grctx.h" |
32 | #include "nouveau_dma.h" | 32 | #include "nouveau_dma.h" |
33 | #include "nouveau_vm.h" | 33 | #include "nouveau_vm.h" |
34 | #include "nouveau_ramht.h" | ||
35 | #include "nv50_evo.h" | 34 | #include "nv50_evo.h" |
36 | 35 | ||
37 | struct nv50_graph_engine { | 36 | struct nv50_graph_engine { |
diff --git a/drivers/gpu/drm/sis/sis_drv.h b/drivers/gpu/drm/sis/sis_drv.h index ef940bad63f7..194303c177ad 100644 --- a/drivers/gpu/drm/sis/sis_drv.h +++ b/drivers/gpu/drm/sis/sis_drv.h | |||
@@ -48,8 +48,8 @@ enum sis_family { | |||
48 | 48 | ||
49 | 49 | ||
50 | #define SIS_BASE (dev_priv->mmio) | 50 | #define SIS_BASE (dev_priv->mmio) |
51 | #define SIS_READ(reg) DRM_READ32(SIS_BASE, reg); | 51 | #define SIS_READ(reg) DRM_READ32(SIS_BASE, reg) |
52 | #define SIS_WRITE(reg, val) DRM_WRITE32(SIS_BASE, reg, val); | 52 | #define SIS_WRITE(reg, val) DRM_WRITE32(SIS_BASE, reg, val) |
53 | 53 | ||
54 | typedef struct drm_sis_private { | 54 | typedef struct drm_sis_private { |
55 | drm_local_map_t *mmio; | 55 | drm_local_map_t *mmio; |
diff --git a/drivers/hwmon/gl520sm.c b/drivers/hwmon/gl520sm.c index ec588026f0a9..131ea8625f08 100644 --- a/drivers/hwmon/gl520sm.c +++ b/drivers/hwmon/gl520sm.c | |||
@@ -273,7 +273,7 @@ static SENSOR_DEVICE_ATTR(in4_max, S_IRUGO | S_IWUSR, | |||
273 | 273 | ||
274 | #define DIV_FROM_REG(val) (1 << (val)) | 274 | #define DIV_FROM_REG(val) (1 << (val)) |
275 | #define FAN_FROM_REG(val,div) ((val)==0 ? 0 : (480000/((val) << (div)))) | 275 | #define FAN_FROM_REG(val,div) ((val)==0 ? 0 : (480000/((val) << (div)))) |
276 | #define FAN_TO_REG(val,div) ((val)<=0?0:SENSORS_LIMIT((480000 + ((val) << ((div)-1))) / ((val) << (div)), 1, 255)); | 276 | #define FAN_TO_REG(val,div) ((val)<=0?0:SENSORS_LIMIT((480000 + ((val) << ((div)-1))) / ((val) << (div)), 1, 255)) |
277 | 277 | ||
278 | static ssize_t get_fan_input(struct device *dev, struct device_attribute *attr, | 278 | static ssize_t get_fan_input(struct device *dev, struct device_attribute *attr, |
279 | char *buf) | 279 | char *buf) |
diff --git a/drivers/i2c/Kconfig b/drivers/i2c/Kconfig index 30f06e956bfb..5f13c62e64b4 100644 --- a/drivers/i2c/Kconfig +++ b/drivers/i2c/Kconfig | |||
@@ -7,7 +7,7 @@ menuconfig I2C | |||
7 | depends on HAS_IOMEM | 7 | depends on HAS_IOMEM |
8 | select RT_MUTEXES | 8 | select RT_MUTEXES |
9 | ---help--- | 9 | ---help--- |
10 | I2C (pronounce: I-square-C) is a slow serial bus protocol used in | 10 | I2C (pronounce: I-squared-C) is a slow serial bus protocol used in |
11 | many micro controller applications and developed by Philips. SMBus, | 11 | many micro controller applications and developed by Philips. SMBus, |
12 | or System Management Bus is a subset of the I2C protocol. More | 12 | or System Management Bus is a subset of the I2C protocol. More |
13 | information is contained in the directory <file:Documentation/i2c/>, | 13 | information is contained in the directory <file:Documentation/i2c/>, |
diff --git a/drivers/i2c/busses/i2c-highlander.c b/drivers/i2c/busses/i2c-highlander.c index 3df1bc80f37a..3876a2478bd7 100644 --- a/drivers/i2c/busses/i2c-highlander.c +++ b/drivers/i2c/busses/i2c-highlander.c | |||
@@ -227,7 +227,7 @@ static int highlander_i2c_read(struct highlander_i2c_dev *dev) | |||
227 | 227 | ||
228 | /* | 228 | /* |
229 | * The R0P7780LC0011RL FPGA needs a significant delay between | 229 | * The R0P7780LC0011RL FPGA needs a significant delay between |
230 | * data read cycles, otherwise the transciever gets confused and | 230 | * data read cycles, otherwise the transceiver gets confused and |
231 | * garbage is returned when the read is subsequently aborted. | 231 | * garbage is returned when the read is subsequently aborted. |
232 | * | 232 | * |
233 | * It is not sufficient to wait for BBSY. | 233 | * It is not sufficient to wait for BBSY. |
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c index 58a58c7eaa17..1a766cf74f6b 100644 --- a/drivers/i2c/busses/i2c-omap.c +++ b/drivers/i2c/busses/i2c-omap.c | |||
@@ -204,7 +204,7 @@ struct omap_i2c_dev { | |||
204 | u16 errata; | 204 | u16 errata; |
205 | }; | 205 | }; |
206 | 206 | ||
207 | const static u8 reg_map[] = { | 207 | static const u8 reg_map[] = { |
208 | [OMAP_I2C_REV_REG] = 0x00, | 208 | [OMAP_I2C_REV_REG] = 0x00, |
209 | [OMAP_I2C_IE_REG] = 0x01, | 209 | [OMAP_I2C_IE_REG] = 0x01, |
210 | [OMAP_I2C_STAT_REG] = 0x02, | 210 | [OMAP_I2C_STAT_REG] = 0x02, |
@@ -225,7 +225,7 @@ const static u8 reg_map[] = { | |||
225 | [OMAP_I2C_BUFSTAT_REG] = 0x10, | 225 | [OMAP_I2C_BUFSTAT_REG] = 0x10, |
226 | }; | 226 | }; |
227 | 227 | ||
228 | const static u8 omap4_reg_map[] = { | 228 | static const u8 omap4_reg_map[] = { |
229 | [OMAP_I2C_REV_REG] = 0x04, | 229 | [OMAP_I2C_REV_REG] = 0x04, |
230 | [OMAP_I2C_IE_REG] = 0x2c, | 230 | [OMAP_I2C_IE_REG] = 0x2c, |
231 | [OMAP_I2C_STAT_REG] = 0x28, | 231 | [OMAP_I2C_STAT_REG] = 0x28, |
diff --git a/drivers/ide/palm_bk3710.c b/drivers/ide/palm_bk3710.c index 9e8f4e1b0cc9..712c7904d03e 100644 --- a/drivers/ide/palm_bk3710.c +++ b/drivers/ide/palm_bk3710.c | |||
@@ -342,7 +342,7 @@ static int __init palm_bk3710_probe(struct platform_device *pdev) | |||
342 | return -ENODEV; | 342 | return -ENODEV; |
343 | } | 343 | } |
344 | 344 | ||
345 | mem_size = mem->end - mem->start + 1; | 345 | mem_size = resource_size(mem); |
346 | if (request_mem_region(mem->start, mem_size, "palm_bk3710") == NULL) { | 346 | if (request_mem_region(mem->start, mem_size, "palm_bk3710") == NULL) { |
347 | printk(KERN_ERR "failed to request memory region\n"); | 347 | printk(KERN_ERR "failed to request memory region\n"); |
348 | return -EBUSY; | 348 | return -EBUSY; |
diff --git a/drivers/ide/tx4939ide.c b/drivers/ide/tx4939ide.c index bed3e39aac96..71c231954972 100644 --- a/drivers/ide/tx4939ide.c +++ b/drivers/ide/tx4939ide.c | |||
@@ -551,10 +551,10 @@ static int __init tx4939ide_probe(struct platform_device *pdev) | |||
551 | return -ENODEV; | 551 | return -ENODEV; |
552 | 552 | ||
553 | if (!devm_request_mem_region(&pdev->dev, res->start, | 553 | if (!devm_request_mem_region(&pdev->dev, res->start, |
554 | res->end - res->start + 1, "tx4938ide")) | 554 | resource_size(res), "tx4938ide")) |
555 | return -EBUSY; | 555 | return -EBUSY; |
556 | mapbase = (unsigned long)devm_ioremap(&pdev->dev, res->start, | 556 | mapbase = (unsigned long)devm_ioremap(&pdev->dev, res->start, |
557 | res->end - res->start + 1); | 557 | resource_size(res)); |
558 | if (!mapbase) | 558 | if (!mapbase) |
559 | return -EBUSY; | 559 | return -EBUSY; |
560 | memset(&hw, 0, sizeof(hw)); | 560 | memset(&hw, 0, sizeof(hw)); |
diff --git a/drivers/input/serio/libps2.c b/drivers/input/serio/libps2.c index 980af94ba9c8..07a8363f3c5c 100644 --- a/drivers/input/serio/libps2.c +++ b/drivers/input/serio/libps2.c | |||
@@ -210,7 +210,7 @@ int __ps2_command(struct ps2dev *ps2dev, unsigned char *param, int command) | |||
210 | /* | 210 | /* |
211 | * Some devices (Synaptics) peform the reset before | 211 | * Some devices (Synaptics) peform the reset before |
212 | * ACKing the reset command, and so it can take a long | 212 | * ACKing the reset command, and so it can take a long |
213 | * time before the ACK arrrives. | 213 | * time before the ACK arrives. |
214 | */ | 214 | */ |
215 | if (ps2_sendbyte(ps2dev, command & 0xff, | 215 | if (ps2_sendbyte(ps2dev, command & 0xff, |
216 | command == PS2_CMD_RESET_BAT ? 1000 : 200)) | 216 | command == PS2_CMD_RESET_BAT ? 1000 : 200)) |
diff --git a/drivers/input/serio/sa1111ps2.c b/drivers/input/serio/sa1111ps2.c index d55874e5d1c2..44fc8b4bcd81 100644 --- a/drivers/input/serio/sa1111ps2.c +++ b/drivers/input/serio/sa1111ps2.c | |||
@@ -300,8 +300,7 @@ static int __devinit ps2_probe(struct sa1111_dev *dev) | |||
300 | 300 | ||
301 | out: | 301 | out: |
302 | sa1111_disable_device(ps2if->dev); | 302 | sa1111_disable_device(ps2if->dev); |
303 | release_mem_region(dev->res.start, | 303 | release_mem_region(dev->res.start, resource_size(&dev->res)); |
304 | dev->res.end - dev->res.start + 1); | ||
305 | free: | 304 | free: |
306 | sa1111_set_drvdata(dev, NULL); | 305 | sa1111_set_drvdata(dev, NULL); |
307 | kfree(ps2if); | 306 | kfree(ps2if); |
@@ -317,8 +316,7 @@ static int __devexit ps2_remove(struct sa1111_dev *dev) | |||
317 | struct ps2if *ps2if = sa1111_get_drvdata(dev); | 316 | struct ps2if *ps2if = sa1111_get_drvdata(dev); |
318 | 317 | ||
319 | serio_unregister_port(ps2if->io); | 318 | serio_unregister_port(ps2if->io); |
320 | release_mem_region(dev->res.start, | 319 | release_mem_region(dev->res.start, resource_size(&dev->res)); |
321 | dev->res.end - dev->res.start + 1); | ||
322 | sa1111_set_drvdata(dev, NULL); | 320 | sa1111_set_drvdata(dev, NULL); |
323 | 321 | ||
324 | kfree(ps2if); | 322 | kfree(ps2if); |
diff --git a/drivers/isdn/i4l/isdn_bsdcomp.c b/drivers/isdn/i4l/isdn_bsdcomp.c index 02d9918705dd..aa0b6a6f5ef4 100644 --- a/drivers/isdn/i4l/isdn_bsdcomp.c +++ b/drivers/isdn/i4l/isdn_bsdcomp.c | |||
@@ -155,7 +155,7 @@ struct bsd_db { | |||
155 | #define LAST 255 | 155 | #define LAST 255 |
156 | 156 | ||
157 | #define MAXCODE(b) ((1 << (b)) - 1) | 157 | #define MAXCODE(b) ((1 << (b)) - 1) |
158 | #define BADCODEM1 MAXCODE(MAX_BSD_BITS); | 158 | #define BADCODEM1 MAXCODE(MAX_BSD_BITS) |
159 | 159 | ||
160 | #define BSD_HASH(prefix,suffix,hshift) ((((unsigned long)(suffix))<<(hshift)) \ | 160 | #define BSD_HASH(prefix,suffix,hshift) ((((unsigned long)(suffix))<<(hshift)) \ |
161 | ^ (unsigned long)(prefix)) | 161 | ^ (unsigned long)(prefix)) |
diff --git a/drivers/media/rc/ite-cir.c b/drivers/media/rc/ite-cir.c index ecd3d0280768..d20168fe4c40 100644 --- a/drivers/media/rc/ite-cir.c +++ b/drivers/media/rc/ite-cir.c | |||
@@ -42,7 +42,6 @@ | |||
42 | #include <linux/bitops.h> | 42 | #include <linux/bitops.h> |
43 | #include <media/rc-core.h> | 43 | #include <media/rc-core.h> |
44 | #include <linux/pci_ids.h> | 44 | #include <linux/pci_ids.h> |
45 | #include <linux/delay.h> | ||
46 | 45 | ||
47 | #include "ite-cir.h" | 46 | #include "ite-cir.h" |
48 | 47 | ||
diff --git a/drivers/media/video/davinci/vpif.c b/drivers/media/video/davinci/vpif.c index 9f3bfc1eb240..af9680273ff9 100644 --- a/drivers/media/video/davinci/vpif.c +++ b/drivers/media/video/davinci/vpif.c | |||
@@ -422,7 +422,7 @@ static int __init vpif_probe(struct platform_device *pdev) | |||
422 | if (!res) | 422 | if (!res) |
423 | return -ENOENT; | 423 | return -ENOENT; |
424 | 424 | ||
425 | res_len = res->end - res->start + 1; | 425 | res_len = resource_size(res); |
426 | 426 | ||
427 | res = request_mem_region(res->start, res_len, res->name); | 427 | res = request_mem_region(res->start, res_len, res->name); |
428 | if (!res) | 428 | if (!res) |
diff --git a/drivers/media/video/m5mols/m5mols_capture.c b/drivers/media/video/m5mols/m5mols_capture.c index d9471928369d..a45d8f098e02 100644 --- a/drivers/media/video/m5mols/m5mols_capture.c +++ b/drivers/media/video/m5mols/m5mols_capture.c | |||
@@ -22,7 +22,6 @@ | |||
22 | #include <linux/gpio.h> | 22 | #include <linux/gpio.h> |
23 | #include <linux/regulator/consumer.h> | 23 | #include <linux/regulator/consumer.h> |
24 | #include <linux/videodev2.h> | 24 | #include <linux/videodev2.h> |
25 | #include <linux/version.h> | ||
26 | #include <media/v4l2-ctrls.h> | 25 | #include <media/v4l2-ctrls.h> |
27 | #include <media/v4l2-device.h> | 26 | #include <media/v4l2-device.h> |
28 | #include <media/v4l2-subdev.h> | 27 | #include <media/v4l2-subdev.h> |
diff --git a/drivers/media/video/omap/omap_vout.c b/drivers/media/video/omap/omap_vout.c index 4d07c5844402..a647894d3a71 100644 --- a/drivers/media/video/omap/omap_vout.c +++ b/drivers/media/video/omap/omap_vout.c | |||
@@ -129,7 +129,7 @@ module_param(debug, bool, S_IRUGO); | |||
129 | MODULE_PARM_DESC(debug, "Debug level (0-1)"); | 129 | MODULE_PARM_DESC(debug, "Debug level (0-1)"); |
130 | 130 | ||
131 | /* list of image formats supported by OMAP2 video pipelines */ | 131 | /* list of image formats supported by OMAP2 video pipelines */ |
132 | const static struct v4l2_fmtdesc omap_formats[] = { | 132 | static const struct v4l2_fmtdesc omap_formats[] = { |
133 | { | 133 | { |
134 | /* Note: V4L2 defines RGB565 as: | 134 | /* Note: V4L2 defines RGB565 as: |
135 | * | 135 | * |
diff --git a/drivers/media/video/omap24xxcam.c b/drivers/media/video/omap24xxcam.c index f6626e87dbc5..69b60ba5dd7a 100644 --- a/drivers/media/video/omap24xxcam.c +++ b/drivers/media/video/omap24xxcam.c | |||
@@ -1768,14 +1768,13 @@ static int __devinit omap24xxcam_probe(struct platform_device *pdev) | |||
1768 | dev_err(cam->dev, "no mem resource?\n"); | 1768 | dev_err(cam->dev, "no mem resource?\n"); |
1769 | goto err; | 1769 | goto err; |
1770 | } | 1770 | } |
1771 | if (!request_mem_region(mem->start, (mem->end - mem->start) + 1, | 1771 | if (!request_mem_region(mem->start, resource_size(mem), pdev->name)) { |
1772 | pdev->name)) { | ||
1773 | dev_err(cam->dev, | 1772 | dev_err(cam->dev, |
1774 | "cannot reserve camera register I/O region\n"); | 1773 | "cannot reserve camera register I/O region\n"); |
1775 | goto err; | 1774 | goto err; |
1776 | } | 1775 | } |
1777 | cam->mmio_base_phys = mem->start; | 1776 | cam->mmio_base_phys = mem->start; |
1778 | cam->mmio_size = (mem->end - mem->start) + 1; | 1777 | cam->mmio_size = resource_size(mem); |
1779 | 1778 | ||
1780 | /* map the region */ | 1779 | /* map the region */ |
1781 | cam->mmio_base = (unsigned long) | 1780 | cam->mmio_base = (unsigned long) |
diff --git a/drivers/media/video/videobuf2-memops.c b/drivers/media/video/videobuf2-memops.c index 5370a3a7ee25..b03c3aea5bea 100644 --- a/drivers/media/video/videobuf2-memops.c +++ b/drivers/media/video/videobuf2-memops.c | |||
@@ -18,7 +18,6 @@ | |||
18 | #include <linux/mm.h> | 18 | #include <linux/mm.h> |
19 | #include <linux/sched.h> | 19 | #include <linux/sched.h> |
20 | #include <linux/file.h> | 20 | #include <linux/file.h> |
21 | #include <linux/slab.h> | ||
22 | 21 | ||
23 | #include <media/videobuf2-core.h> | 22 | #include <media/videobuf2-core.h> |
24 | #include <media/videobuf2-memops.h> | 23 | #include <media/videobuf2-memops.h> |
diff --git a/drivers/message/i2o/iop.c b/drivers/message/i2o/iop.c index 090d2a3a6548..a8c08f332da0 100644 --- a/drivers/message/i2o/iop.c +++ b/drivers/message/i2o/iop.c | |||
@@ -681,11 +681,11 @@ static int i2o_iop_systab_set(struct i2o_controller *c) | |||
681 | if (root && allocate_resource(root, res, sb->desired_mem_size, sb->desired_mem_size, sb->desired_mem_size, 1 << 20, /* Unspecified, so use 1Mb and play safe */ | 681 | if (root && allocate_resource(root, res, sb->desired_mem_size, sb->desired_mem_size, sb->desired_mem_size, 1 << 20, /* Unspecified, so use 1Mb and play safe */ |
682 | NULL, NULL) >= 0) { | 682 | NULL, NULL) >= 0) { |
683 | c->mem_alloc = 1; | 683 | c->mem_alloc = 1; |
684 | sb->current_mem_size = 1 + res->end - res->start; | 684 | sb->current_mem_size = resource_size(res); |
685 | sb->current_mem_base = res->start; | 685 | sb->current_mem_base = res->start; |
686 | osm_info("%s: allocated %llu bytes of PCI memory at " | 686 | osm_info("%s: allocated %llu bytes of PCI memory at " |
687 | "0x%016llX.\n", c->name, | 687 | "0x%016llX.\n", c->name, |
688 | (unsigned long long)(1 + res->end - res->start), | 688 | (unsigned long long)resource_size(res), |
689 | (unsigned long long)res->start); | 689 | (unsigned long long)res->start); |
690 | } | 690 | } |
691 | } | 691 | } |
@@ -703,11 +703,11 @@ static int i2o_iop_systab_set(struct i2o_controller *c) | |||
703 | if (root && allocate_resource(root, res, sb->desired_io_size, sb->desired_io_size, sb->desired_io_size, 1 << 20, /* Unspecified, so use 1Mb and play safe */ | 703 | if (root && allocate_resource(root, res, sb->desired_io_size, sb->desired_io_size, sb->desired_io_size, 1 << 20, /* Unspecified, so use 1Mb and play safe */ |
704 | NULL, NULL) >= 0) { | 704 | NULL, NULL) >= 0) { |
705 | c->io_alloc = 1; | 705 | c->io_alloc = 1; |
706 | sb->current_io_size = 1 + res->end - res->start; | 706 | sb->current_io_size = resource_size(res); |
707 | sb->current_mem_base = res->start; | 707 | sb->current_mem_base = res->start; |
708 | osm_info("%s: allocated %llu bytes of PCI I/O at " | 708 | osm_info("%s: allocated %llu bytes of PCI I/O at " |
709 | "0x%016llX.\n", c->name, | 709 | "0x%016llX.\n", c->name, |
710 | (unsigned long long)(1 + res->end - res->start), | 710 | (unsigned long long)resource_size(res), |
711 | (unsigned long long)res->start); | 711 | (unsigned long long)res->start); |
712 | } | 712 | } |
713 | } | 713 | } |
diff --git a/drivers/mfd/tc6387xb.c b/drivers/mfd/tc6387xb.c index ad715bf49cac..71bc835324d8 100644 --- a/drivers/mfd/tc6387xb.c +++ b/drivers/mfd/tc6387xb.c | |||
@@ -177,7 +177,7 @@ static int __devinit tc6387xb_probe(struct platform_device *dev) | |||
177 | if (ret) | 177 | if (ret) |
178 | goto err_resource; | 178 | goto err_resource; |
179 | 179 | ||
180 | tc6387xb->scr = ioremap(rscr->start, rscr->end - rscr->start + 1); | 180 | tc6387xb->scr = ioremap(rscr->start, resource_size(rscr)); |
181 | if (!tc6387xb->scr) { | 181 | if (!tc6387xb->scr) { |
182 | ret = -ENOMEM; | 182 | ret = -ENOMEM; |
183 | goto err_ioremap; | 183 | goto err_ioremap; |
diff --git a/drivers/misc/atmel-ssc.c b/drivers/misc/atmel-ssc.c index 4afffe610f99..769a4e8e10dc 100644 --- a/drivers/misc/atmel-ssc.c +++ b/drivers/misc/atmel-ssc.c | |||
@@ -95,7 +95,7 @@ static int __init ssc_probe(struct platform_device *pdev) | |||
95 | } | 95 | } |
96 | 96 | ||
97 | ssc->pdev = pdev; | 97 | ssc->pdev = pdev; |
98 | ssc->regs = ioremap(regs->start, regs->end - regs->start + 1); | 98 | ssc->regs = ioremap(regs->start, resource_size(regs)); |
99 | if (!ssc->regs) { | 99 | if (!ssc->regs) { |
100 | dev_dbg(&pdev->dev, "ioremap failed\n"); | 100 | dev_dbg(&pdev->dev, "ioremap failed\n"); |
101 | retval = -EINVAL; | 101 | retval = -EINVAL; |
diff --git a/drivers/misc/atmel_pwm.c b/drivers/misc/atmel_pwm.c index 0f3fb4f03bdf..28f5aaa19d4a 100644 --- a/drivers/misc/atmel_pwm.c +++ b/drivers/misc/atmel_pwm.c | |||
@@ -329,7 +329,7 @@ static int __init pwm_probe(struct platform_device *pdev) | |||
329 | p->pdev = pdev; | 329 | p->pdev = pdev; |
330 | p->mask = *mp; | 330 | p->mask = *mp; |
331 | p->irq = irq; | 331 | p->irq = irq; |
332 | p->base = ioremap(r->start, r->end - r->start + 1); | 332 | p->base = ioremap(r->start, resource_size(r)); |
333 | if (!p->base) | 333 | if (!p->base) |
334 | goto fail; | 334 | goto fail; |
335 | p->clk = clk_get(&pdev->dev, "pwm_clk"); | 335 | p->clk = clk_get(&pdev->dev, "pwm_clk"); |
diff --git a/drivers/mmc/host/dw_mmc.c b/drivers/mmc/host/dw_mmc.c index 0c839d3338db..77f0b6b1681d 100644 --- a/drivers/mmc/host/dw_mmc.c +++ b/drivers/mmc/host/dw_mmc.c | |||
@@ -1825,7 +1825,7 @@ static int dw_mci_probe(struct platform_device *pdev) | |||
1825 | INIT_LIST_HEAD(&host->queue); | 1825 | INIT_LIST_HEAD(&host->queue); |
1826 | 1826 | ||
1827 | ret = -ENOMEM; | 1827 | ret = -ENOMEM; |
1828 | host->regs = ioremap(regs->start, regs->end - regs->start + 1); | 1828 | host->regs = ioremap(regs->start, resource_size(regs)); |
1829 | if (!host->regs) | 1829 | if (!host->regs) |
1830 | goto err_freehost; | 1830 | goto err_freehost; |
1831 | 1831 | ||
diff --git a/drivers/mmc/host/vub300.c b/drivers/mmc/host/vub300.c index d4455ffbefd8..e8f6e65183d7 100644 --- a/drivers/mmc/host/vub300.c +++ b/drivers/mmc/host/vub300.c | |||
@@ -1625,8 +1625,8 @@ static void __vub300_command_response(struct vub300_mmc_host *vub300, | |||
1625 | cmd->error = respretval; | 1625 | cmd->error = respretval; |
1626 | } else if (cmd->error) { | 1626 | } else if (cmd->error) { |
1627 | /* | 1627 | /* |
1628 | * the error occured sending the command | 1628 | * the error occurred sending the command |
1629 | * or recieving the response | 1629 | * or receiving the response |
1630 | */ | 1630 | */ |
1631 | } else if (vub300->command_out_urb->status) { | 1631 | } else if (vub300->command_out_urb->status) { |
1632 | vub300->usb_transport_fail = vub300->command_out_urb->status; | 1632 | vub300->usb_transport_fail = vub300->command_out_urb->status; |
diff --git a/drivers/mtd/devices/sst25l.c b/drivers/mtd/devices/sst25l.c index 1e2c430aaad2..83e80c65d6e7 100644 --- a/drivers/mtd/devices/sst25l.c +++ b/drivers/mtd/devices/sst25l.c | |||
@@ -5,7 +5,7 @@ | |||
5 | * | 5 | * |
6 | * Copyright © 2009 Bluewater Systems Ltd | 6 | * Copyright © 2009 Bluewater Systems Ltd |
7 | * Author: Andre Renaud <andre@bluewatersys.com> | 7 | * Author: Andre Renaud <andre@bluewatersys.com> |
8 | * Author: Ryan Mallon <ryan@bluewatersys.com> | 8 | * Author: Ryan Mallon |
9 | * | 9 | * |
10 | * Based on m25p80.c | 10 | * Based on m25p80.c |
11 | * | 11 | * |
@@ -498,5 +498,5 @@ module_exit(sst25l_exit); | |||
498 | 498 | ||
499 | MODULE_DESCRIPTION("MTD SPI driver for SST25L Flash chips"); | 499 | MODULE_DESCRIPTION("MTD SPI driver for SST25L Flash chips"); |
500 | MODULE_AUTHOR("Andre Renaud <andre@bluewatersys.com>, " | 500 | MODULE_AUTHOR("Andre Renaud <andre@bluewatersys.com>, " |
501 | "Ryan Mallon <ryan@bluewatersys.com>"); | 501 | "Ryan Mallon"); |
502 | MODULE_LICENSE("GPL"); | 502 | MODULE_LICENSE("GPL"); |
diff --git a/drivers/mtd/maps/bfin-async-flash.c b/drivers/mtd/maps/bfin-async-flash.c index d4297a97e100..67815eed2f00 100644 --- a/drivers/mtd/maps/bfin-async-flash.c +++ b/drivers/mtd/maps/bfin-async-flash.c | |||
@@ -142,7 +142,7 @@ static int __devinit bfin_flash_probe(struct platform_device *pdev) | |||
142 | state->map.write = bfin_flash_write; | 142 | state->map.write = bfin_flash_write; |
143 | state->map.copy_to = bfin_flash_copy_to; | 143 | state->map.copy_to = bfin_flash_copy_to; |
144 | state->map.bankwidth = pdata->width; | 144 | state->map.bankwidth = pdata->width; |
145 | state->map.size = memory->end - memory->start + 1; | 145 | state->map.size = resource_size(memory); |
146 | state->map.virt = (void __iomem *)memory->start; | 146 | state->map.virt = (void __iomem *)memory->start; |
147 | state->map.phys = memory->start; | 147 | state->map.phys = memory->start; |
148 | state->map.map_priv_1 = (unsigned long)state; | 148 | state->map.map_priv_1 = (unsigned long)state; |
diff --git a/drivers/mtd/maps/ixp2000.c b/drivers/mtd/maps/ixp2000.c index c00b9175ba9e..1594a802631d 100644 --- a/drivers/mtd/maps/ixp2000.c +++ b/drivers/mtd/maps/ixp2000.c | |||
@@ -155,7 +155,7 @@ static int ixp2000_flash_probe(struct platform_device *dev) | |||
155 | if (!plat) | 155 | if (!plat) |
156 | return -ENODEV; | 156 | return -ENODEV; |
157 | 157 | ||
158 | window_size = dev->resource->end - dev->resource->start + 1; | 158 | window_size = resource_size(dev->resource); |
159 | dev_info(&dev->dev, "Probe of IXP2000 flash(%d banks x %dMiB)\n", | 159 | dev_info(&dev->dev, "Probe of IXP2000 flash(%d banks x %dMiB)\n", |
160 | ixp_data->nr_banks, ((u32)window_size >> 20)); | 160 | ixp_data->nr_banks, ((u32)window_size >> 20)); |
161 | 161 | ||
@@ -194,16 +194,17 @@ static int ixp2000_flash_probe(struct platform_device *dev) | |||
194 | info->map.copy_to = ixp2000_flash_copy_to; | 194 | info->map.copy_to = ixp2000_flash_copy_to; |
195 | 195 | ||
196 | info->res = request_mem_region(dev->resource->start, | 196 | info->res = request_mem_region(dev->resource->start, |
197 | dev->resource->end - dev->resource->start + 1, | 197 | resource_size(dev->resource), |
198 | dev_name(&dev->dev)); | 198 | dev_name(&dev->dev)); |
199 | if (!info->res) { | 199 | if (!info->res) { |
200 | dev_err(&dev->dev, "Could not reserve memory region\n"); | 200 | dev_err(&dev->dev, "Could not reserve memory region\n"); |
201 | err = -ENOMEM; | 201 | err = -ENOMEM; |
202 | goto Error; | 202 | goto Error; |
203 | } | 203 | } |
204 | 204 | ||
205 | info->map.map_priv_1 = (unsigned long) ioremap(dev->resource->start, | 205 | info->map.map_priv_1 = |
206 | dev->resource->end - dev->resource->start + 1); | 206 | (unsigned long)ioremap(dev->resource->start, |
207 | resource_size(dev->resource)); | ||
207 | if (!info->map.map_priv_1) { | 208 | if (!info->map.map_priv_1) { |
208 | dev_err(&dev->dev, "Failed to ioremap flash region\n"); | 209 | dev_err(&dev->dev, "Failed to ioremap flash region\n"); |
209 | err = -EIO; | 210 | err = -EIO; |
diff --git a/drivers/mtd/maps/pxa2xx-flash.c b/drivers/mtd/maps/pxa2xx-flash.c index f59d62f74d44..7ae137d4b998 100644 --- a/drivers/mtd/maps/pxa2xx-flash.c +++ b/drivers/mtd/maps/pxa2xx-flash.c | |||
@@ -70,7 +70,7 @@ static int __devinit pxa2xx_flash_probe(struct platform_device *pdev) | |||
70 | info->map.name = (char *) flash->name; | 70 | info->map.name = (char *) flash->name; |
71 | info->map.bankwidth = flash->width; | 71 | info->map.bankwidth = flash->width; |
72 | info->map.phys = res->start; | 72 | info->map.phys = res->start; |
73 | info->map.size = res->end - res->start + 1; | 73 | info->map.size = resource_size(res); |
74 | info->parts = flash->parts; | 74 | info->parts = flash->parts; |
75 | info->nr_parts = flash->nr_parts; | 75 | info->nr_parts = flash->nr_parts; |
76 | 76 | ||
diff --git a/drivers/mtd/nand/atmel_nand.c b/drivers/mtd/nand/atmel_nand.c index 1b90fd56bef1..55da20ccc7a8 100644 --- a/drivers/mtd/nand/atmel_nand.c +++ b/drivers/mtd/nand/atmel_nand.c | |||
@@ -514,7 +514,7 @@ static int __init atmel_nand_probe(struct platform_device *pdev) | |||
514 | 514 | ||
515 | host->io_phys = (dma_addr_t)mem->start; | 515 | host->io_phys = (dma_addr_t)mem->start; |
516 | 516 | ||
517 | host->io_base = ioremap(mem->start, mem->end - mem->start + 1); | 517 | host->io_base = ioremap(mem->start, resource_size(mem)); |
518 | if (host->io_base == NULL) { | 518 | if (host->io_base == NULL) { |
519 | printk(KERN_ERR "atmel_nand: ioremap failed\n"); | 519 | printk(KERN_ERR "atmel_nand: ioremap failed\n"); |
520 | res = -EIO; | 520 | res = -EIO; |
@@ -548,7 +548,7 @@ static int __init atmel_nand_probe(struct platform_device *pdev) | |||
548 | if (no_ecc) | 548 | if (no_ecc) |
549 | nand_chip->ecc.mode = NAND_ECC_NONE; | 549 | nand_chip->ecc.mode = NAND_ECC_NONE; |
550 | if (hard_ecc && regs) { | 550 | if (hard_ecc && regs) { |
551 | host->ecc = ioremap(regs->start, regs->end - regs->start + 1); | 551 | host->ecc = ioremap(regs->start, resource_size(regs)); |
552 | if (host->ecc == NULL) { | 552 | if (host->ecc == NULL) { |
553 | printk(KERN_ERR "atmel_nand: ioremap failed\n"); | 553 | printk(KERN_ERR "atmel_nand: ioremap failed\n"); |
554 | res = -EIO; | 554 | res = -EIO; |
diff --git a/drivers/mtd/nand/bcm_umi_nand.c b/drivers/mtd/nand/bcm_umi_nand.c index 9ec280738a9a..8c569e454dc5 100644 --- a/drivers/mtd/nand/bcm_umi_nand.c +++ b/drivers/mtd/nand/bcm_umi_nand.c | |||
@@ -380,7 +380,7 @@ static int __devinit bcm_umi_nand_probe(struct platform_device *pdev) | |||
380 | return -ENXIO; | 380 | return -ENXIO; |
381 | 381 | ||
382 | /* map physical address */ | 382 | /* map physical address */ |
383 | bcm_umi_io_base = ioremap(r->start, r->end - r->start + 1); | 383 | bcm_umi_io_base = ioremap(r->start, resource_size(r)); |
384 | 384 | ||
385 | if (!bcm_umi_io_base) { | 385 | if (!bcm_umi_io_base) { |
386 | printk(KERN_ERR "ioremap to access BCM UMI NAND chip failed\n"); | 386 | printk(KERN_ERR "ioremap to access BCM UMI NAND chip failed\n"); |
diff --git a/drivers/mtd/nand/mpc5121_nfc.c b/drivers/mtd/nand/mpc5121_nfc.c index 2f7c930872f9..eb1fbac63eb6 100644 --- a/drivers/mtd/nand/mpc5121_nfc.c +++ b/drivers/mtd/nand/mpc5121_nfc.c | |||
@@ -713,7 +713,7 @@ static int __devinit mpc5121_nfc_probe(struct platform_device *op) | |||
713 | } | 713 | } |
714 | 714 | ||
715 | regs_paddr = res.start; | 715 | regs_paddr = res.start; |
716 | regs_size = res.end - res.start + 1; | 716 | regs_size = resource_size(&res); |
717 | 717 | ||
718 | if (!devm_request_mem_region(dev, regs_paddr, regs_size, DRV_NAME)) { | 718 | if (!devm_request_mem_region(dev, regs_paddr, regs_size, DRV_NAME)) { |
719 | dev_err(dev, "Error requesting memory region!\n"); | 719 | dev_err(dev, "Error requesting memory region!\n"); |
diff --git a/drivers/net/b44.c b/drivers/net/b44.c index 6c4ef966ca58..41ea84e3f69c 100644 --- a/drivers/net/b44.c +++ b/drivers/net/b44.c | |||
@@ -5,7 +5,7 @@ | |||
5 | * Copyright (C) 2004 Florian Schirmer (jolt@tuxbox.org) | 5 | * Copyright (C) 2004 Florian Schirmer (jolt@tuxbox.org) |
6 | * Copyright (C) 2006 Felix Fietkau (nbd@openwrt.org) | 6 | * Copyright (C) 2006 Felix Fietkau (nbd@openwrt.org) |
7 | * Copyright (C) 2006 Broadcom Corporation. | 7 | * Copyright (C) 2006 Broadcom Corporation. |
8 | * Copyright (C) 2007 Michael Buesch <mb@bu3sch.de> | 8 | * Copyright (C) 2007 Michael Buesch <m@bues.ch> |
9 | * | 9 | * |
10 | * Distribute under GPL. | 10 | * Distribute under GPL. |
11 | */ | 11 | */ |
diff --git a/drivers/net/bcm63xx_enet.c b/drivers/net/bcm63xx_enet.c index 4753bb9731f5..1d9b9858067c 100644 --- a/drivers/net/bcm63xx_enet.c +++ b/drivers/net/bcm63xx_enet.c | |||
@@ -1647,7 +1647,7 @@ static int __devinit bcm_enet_probe(struct platform_device *pdev) | |||
1647 | if (ret) | 1647 | if (ret) |
1648 | goto out; | 1648 | goto out; |
1649 | 1649 | ||
1650 | iomem_size = res_mem->end - res_mem->start + 1; | 1650 | iomem_size = resource_size(res_mem); |
1651 | if (!request_mem_region(res_mem->start, iomem_size, "bcm63xx_enet")) { | 1651 | if (!request_mem_region(res_mem->start, iomem_size, "bcm63xx_enet")) { |
1652 | ret = -EBUSY; | 1652 | ret = -EBUSY; |
1653 | goto out; | 1653 | goto out; |
@@ -1862,7 +1862,7 @@ static int __devexit bcm_enet_remove(struct platform_device *pdev) | |||
1862 | /* release device resources */ | 1862 | /* release device resources */ |
1863 | iounmap(priv->base); | 1863 | iounmap(priv->base); |
1864 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | 1864 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
1865 | release_mem_region(res->start, res->end - res->start + 1); | 1865 | release_mem_region(res->start, resource_size(res)); |
1866 | 1866 | ||
1867 | /* disable hw block clocks */ | 1867 | /* disable hw block clocks */ |
1868 | if (priv->phy_clk) { | 1868 | if (priv->phy_clk) { |
@@ -1898,7 +1898,7 @@ static int __devinit bcm_enet_shared_probe(struct platform_device *pdev) | |||
1898 | if (!res) | 1898 | if (!res) |
1899 | return -ENODEV; | 1899 | return -ENODEV; |
1900 | 1900 | ||
1901 | iomem_size = res->end - res->start + 1; | 1901 | iomem_size = resource_size(res); |
1902 | if (!request_mem_region(res->start, iomem_size, "bcm63xx_enet_dma")) | 1902 | if (!request_mem_region(res->start, iomem_size, "bcm63xx_enet_dma")) |
1903 | return -EBUSY; | 1903 | return -EBUSY; |
1904 | 1904 | ||
@@ -1916,7 +1916,7 @@ static int __devexit bcm_enet_shared_remove(struct platform_device *pdev) | |||
1916 | 1916 | ||
1917 | iounmap(bcm_enet_shared_base); | 1917 | iounmap(bcm_enet_shared_base); |
1918 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | 1918 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
1919 | release_mem_region(res->start, res->end - res->start + 1); | 1919 | release_mem_region(res->start, resource_size(res)); |
1920 | return 0; | 1920 | return 0; |
1921 | } | 1921 | } |
1922 | 1922 | ||
diff --git a/drivers/net/bsd_comp.c b/drivers/net/bsd_comp.c index 6e99d80ec409..a9b759add187 100644 --- a/drivers/net/bsd_comp.c +++ b/drivers/net/bsd_comp.c | |||
@@ -201,7 +201,7 @@ extern void ppp_unregister_compressor (struct compressor *cp); | |||
201 | #define LAST 255 | 201 | #define LAST 255 |
202 | 202 | ||
203 | #define MAXCODE(b) ((1 << (b)) - 1) | 203 | #define MAXCODE(b) ((1 << (b)) - 1) |
204 | #define BADCODEM1 MAXCODE(MAX_BSD_BITS); | 204 | #define BADCODEM1 MAXCODE(MAX_BSD_BITS) |
205 | 205 | ||
206 | #define BSD_HASH(prefix,suffix,hshift) ((((unsigned long)(suffix))<<(hshift)) \ | 206 | #define BSD_HASH(prefix,suffix,hshift) ((((unsigned long)(suffix))<<(hshift)) \ |
207 | ^ (unsigned long)(prefix)) | 207 | ^ (unsigned long)(prefix)) |
diff --git a/drivers/net/can/softing/softing_main.c b/drivers/net/can/softing/softing_main.c index a79925e72d66..09a8b86cf1ac 100644 --- a/drivers/net/can/softing/softing_main.c +++ b/drivers/net/can/softing/softing_main.c | |||
@@ -799,7 +799,7 @@ static __devinit int softing_pdev_probe(struct platform_device *pdev) | |||
799 | if (!pres) | 799 | if (!pres) |
800 | goto platform_resource_failed; | 800 | goto platform_resource_failed; |
801 | card->dpram_phys = pres->start; | 801 | card->dpram_phys = pres->start; |
802 | card->dpram_size = pres->end - pres->start + 1; | 802 | card->dpram_size = resource_size(pres); |
803 | card->dpram = ioremap_nocache(card->dpram_phys, card->dpram_size); | 803 | card->dpram = ioremap_nocache(card->dpram_phys, card->dpram_size); |
804 | if (!card->dpram) { | 804 | if (!card->dpram) { |
805 | dev_alert(&card->pdev->dev, "dpram ioremap failed\n"); | 805 | dev_alert(&card->pdev->dev, "dpram ioremap failed\n"); |
diff --git a/drivers/net/davinci_emac.c b/drivers/net/davinci_emac.c index acef7e96c9fd..3f451e4d8361 100644 --- a/drivers/net/davinci_emac.c +++ b/drivers/net/davinci_emac.c | |||
@@ -1822,7 +1822,7 @@ static int __devinit davinci_emac_probe(struct platform_device *pdev) | |||
1822 | } | 1822 | } |
1823 | 1823 | ||
1824 | priv->emac_base_phys = res->start + pdata->ctrl_reg_offset; | 1824 | priv->emac_base_phys = res->start + pdata->ctrl_reg_offset; |
1825 | size = res->end - res->start + 1; | 1825 | size = resource_size(res); |
1826 | if (!request_mem_region(res->start, size, ndev->name)) { | 1826 | if (!request_mem_region(res->start, size, ndev->name)) { |
1827 | dev_err(&pdev->dev, "failed request_mem_region() for regs\n"); | 1827 | dev_err(&pdev->dev, "failed request_mem_region() for regs\n"); |
1828 | rc = -ENXIO; | 1828 | rc = -ENXIO; |
@@ -1927,7 +1927,7 @@ no_irq_res: | |||
1927 | cpdma_ctlr_destroy(priv->dma); | 1927 | cpdma_ctlr_destroy(priv->dma); |
1928 | no_dma: | 1928 | no_dma: |
1929 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | 1929 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
1930 | release_mem_region(res->start, res->end - res->start + 1); | 1930 | release_mem_region(res->start, resource_size(res)); |
1931 | iounmap(priv->remap_addr); | 1931 | iounmap(priv->remap_addr); |
1932 | 1932 | ||
1933 | probe_quit: | 1933 | probe_quit: |
@@ -1961,7 +1961,7 @@ static int __devexit davinci_emac_remove(struct platform_device *pdev) | |||
1961 | cpdma_chan_destroy(priv->rxchan); | 1961 | cpdma_chan_destroy(priv->rxchan); |
1962 | cpdma_ctlr_destroy(priv->dma); | 1962 | cpdma_ctlr_destroy(priv->dma); |
1963 | 1963 | ||
1964 | release_mem_region(res->start, res->end - res->start + 1); | 1964 | release_mem_region(res->start, resource_size(res)); |
1965 | 1965 | ||
1966 | unregister_netdev(ndev); | 1966 | unregister_netdev(ndev); |
1967 | iounmap(priv->remap_addr); | 1967 | iounmap(priv->remap_addr); |
diff --git a/drivers/net/eexpress.c b/drivers/net/eexpress.c index 48ee51bb9e50..a19228563efd 100644 --- a/drivers/net/eexpress.c +++ b/drivers/net/eexpress.c | |||
@@ -365,7 +365,7 @@ static int __init do_express_probe(struct net_device *dev) | |||
365 | dev->irq = mca_irqmap[(pos1>>4)&0x7]; | 365 | dev->irq = mca_irqmap[(pos1>>4)&0x7]; |
366 | 366 | ||
367 | /* | 367 | /* |
368 | * XXX: Transciever selection is done | 368 | * XXX: Transceiver selection is done |
369 | * differently on the MCA version. | 369 | * differently on the MCA version. |
370 | * How to get it to select something | 370 | * How to get it to select something |
371 | * other than external/AUI is currently | 371 | * other than external/AUI is currently |
diff --git a/drivers/net/ethoc.c b/drivers/net/ethoc.c index 0da6295d9da6..8abbe1d82826 100644 --- a/drivers/net/ethoc.c +++ b/drivers/net/ethoc.c | |||
@@ -968,7 +968,7 @@ static int __devinit ethoc_probe(struct platform_device *pdev) | |||
968 | priv = netdev_priv(netdev); | 968 | priv = netdev_priv(netdev); |
969 | priv->netdev = netdev; | 969 | priv->netdev = netdev; |
970 | priv->dma_alloc = 0; | 970 | priv->dma_alloc = 0; |
971 | priv->io_region_size = mmio->end - mmio->start + 1; | 971 | priv->io_region_size = resource_size(mmio); |
972 | 972 | ||
973 | priv->iobase = devm_ioremap_nocache(&pdev->dev, netdev->base_addr, | 973 | priv->iobase = devm_ioremap_nocache(&pdev->dev, netdev->base_addr, |
974 | resource_size(mmio)); | 974 | resource_size(mmio)); |
diff --git a/drivers/net/fec_mpc52xx.c b/drivers/net/fec_mpc52xx.c index 381bdea97d5f..cb4416e591f1 100644 --- a/drivers/net/fec_mpc52xx.c +++ b/drivers/net/fec_mpc52xx.c | |||
@@ -871,10 +871,11 @@ static int __devinit mpc52xx_fec_probe(struct platform_device *op) | |||
871 | "Error while parsing device node resource\n" ); | 871 | "Error while parsing device node resource\n" ); |
872 | goto err_netdev; | 872 | goto err_netdev; |
873 | } | 873 | } |
874 | if ((mem.end - mem.start + 1) < sizeof(struct mpc52xx_fec)) { | 874 | if (resource_size(&mem) < sizeof(struct mpc52xx_fec)) { |
875 | printk(KERN_ERR DRIVER_NAME | 875 | printk(KERN_ERR DRIVER_NAME |
876 | " - invalid resource size (%lx < %x), check mpc52xx_devices.c\n", | 876 | " - invalid resource size (%lx < %x), check mpc52xx_devices.c\n", |
877 | (unsigned long)(mem.end - mem.start + 1), sizeof(struct mpc52xx_fec)); | 877 | (unsigned long)resource_size(&mem), |
878 | sizeof(struct mpc52xx_fec)); | ||
878 | rv = -EINVAL; | 879 | rv = -EINVAL; |
879 | goto err_netdev; | 880 | goto err_netdev; |
880 | } | 881 | } |
diff --git a/drivers/net/fs_enet/mii-bitbang.c b/drivers/net/fs_enet/mii-bitbang.c index ad2975440719..b09270b5d0a5 100644 --- a/drivers/net/fs_enet/mii-bitbang.c +++ b/drivers/net/fs_enet/mii-bitbang.c | |||
@@ -120,7 +120,7 @@ static int __devinit fs_mii_bitbang_init(struct mii_bus *bus, | |||
120 | if (ret) | 120 | if (ret) |
121 | return ret; | 121 | return ret; |
122 | 122 | ||
123 | if (res.end - res.start < 13) | 123 | if (resource_size(&res) <= 13) |
124 | return -ENODEV; | 124 | return -ENODEV; |
125 | 125 | ||
126 | /* This should really encode the pin number as well, but all | 126 | /* This should really encode the pin number as well, but all |
@@ -139,7 +139,7 @@ static int __devinit fs_mii_bitbang_init(struct mii_bus *bus, | |||
139 | return -ENODEV; | 139 | return -ENODEV; |
140 | mdc_pin = *data; | 140 | mdc_pin = *data; |
141 | 141 | ||
142 | bitbang->dir = ioremap(res.start, res.end - res.start + 1); | 142 | bitbang->dir = ioremap(res.start, resource_size(&res)); |
143 | if (!bitbang->dir) | 143 | if (!bitbang->dir) |
144 | return -ENOMEM; | 144 | return -ENOMEM; |
145 | 145 | ||
diff --git a/drivers/net/fs_enet/mii-fec.c b/drivers/net/fs_enet/mii-fec.c index 6a2e150e75bb..e0e9d6c35d83 100644 --- a/drivers/net/fs_enet/mii-fec.c +++ b/drivers/net/fs_enet/mii-fec.c | |||
@@ -136,7 +136,7 @@ static int __devinit fs_enet_mdio_probe(struct platform_device *ofdev) | |||
136 | 136 | ||
137 | snprintf(new_bus->id, MII_BUS_ID_SIZE, "%x", res.start); | 137 | snprintf(new_bus->id, MII_BUS_ID_SIZE, "%x", res.start); |
138 | 138 | ||
139 | fec->fecp = ioremap(res.start, res.end - res.start + 1); | 139 | fec->fecp = ioremap(res.start, resource_size(&res)); |
140 | if (!fec->fecp) | 140 | if (!fec->fecp) |
141 | goto out_fec; | 141 | goto out_fec; |
142 | 142 | ||
diff --git a/drivers/net/gianfar_ptp.c b/drivers/net/gianfar_ptp.c index d8e175382d1d..1c97861596f0 100644 --- a/drivers/net/gianfar_ptp.c +++ b/drivers/net/gianfar_ptp.c | |||
@@ -491,7 +491,7 @@ static int gianfar_ptp_probe(struct platform_device *dev) | |||
491 | spin_lock_init(&etsects->lock); | 491 | spin_lock_init(&etsects->lock); |
492 | 492 | ||
493 | etsects->regs = ioremap(etsects->rsrc->start, | 493 | etsects->regs = ioremap(etsects->rsrc->start, |
494 | 1 + etsects->rsrc->end - etsects->rsrc->start); | 494 | resource_size(etsects->rsrc)); |
495 | if (!etsects->regs) { | 495 | if (!etsects->regs) { |
496 | pr_err("ioremap ptp registers failed\n"); | 496 | pr_err("ioremap ptp registers failed\n"); |
497 | goto no_ioremap; | 497 | goto no_ioremap; |
diff --git a/drivers/net/ibm_newemac/core.c b/drivers/net/ibm_newemac/core.c index 079450fe5e96..725399ea0690 100644 --- a/drivers/net/ibm_newemac/core.c +++ b/drivers/net/ibm_newemac/core.c | |||
@@ -2770,7 +2770,7 @@ static int __devinit emac_probe(struct platform_device *ofdev) | |||
2770 | } | 2770 | } |
2771 | // TODO : request_mem_region | 2771 | // TODO : request_mem_region |
2772 | dev->emacp = ioremap(dev->rsrc_regs.start, | 2772 | dev->emacp = ioremap(dev->rsrc_regs.start, |
2773 | dev->rsrc_regs.end - dev->rsrc_regs.start + 1); | 2773 | resource_size(&dev->rsrc_regs)); |
2774 | if (dev->emacp == NULL) { | 2774 | if (dev->emacp == NULL) { |
2775 | printk(KERN_ERR "%s: Can't map device registers!\n", | 2775 | printk(KERN_ERR "%s: Can't map device registers!\n", |
2776 | np->full_name); | 2776 | np->full_name); |
diff --git a/drivers/net/irda/toim3232-sir.c b/drivers/net/irda/toim3232-sir.c index 99e1ec02a011..19ad4606b799 100644 --- a/drivers/net/irda/toim3232-sir.c +++ b/drivers/net/irda/toim3232-sir.c | |||
@@ -78,7 +78,7 @@ | |||
78 | * Target hardware: IRWave IR320ST-2 | 78 | * Target hardware: IRWave IR320ST-2 |
79 | * | 79 | * |
80 | * The IRWave IR320ST-2 is a simple dongle based on the Vishay/Temic | 80 | * The IRWave IR320ST-2 is a simple dongle based on the Vishay/Temic |
81 | * TOIM3232 SIR Endec and the Vishay/Temic TFDS4500 SIR IRDA transciever. | 81 | * TOIM3232 SIR Endec and the Vishay/Temic TFDS4500 SIR IRDA transceiver. |
82 | * It uses a hex inverter and some discrete components to buffer and | 82 | * It uses a hex inverter and some discrete components to buffer and |
83 | * line convert the RS232 down to 5V. | 83 | * line convert the RS232 down to 5V. |
84 | * | 84 | * |
diff --git a/drivers/net/macb.c b/drivers/net/macb.c index dcf6011b136c..0fcdc25699d8 100644 --- a/drivers/net/macb.c +++ b/drivers/net/macb.c | |||
@@ -1172,7 +1172,7 @@ static int __init macb_probe(struct platform_device *pdev) | |||
1172 | clk_enable(bp->hclk); | 1172 | clk_enable(bp->hclk); |
1173 | #endif | 1173 | #endif |
1174 | 1174 | ||
1175 | bp->regs = ioremap(regs->start, regs->end - regs->start + 1); | 1175 | bp->regs = ioremap(regs->start, resource_size(regs)); |
1176 | if (!bp->regs) { | 1176 | if (!bp->regs) { |
1177 | dev_err(&pdev->dev, "failed to map registers, aborting.\n"); | 1177 | dev_err(&pdev->dev, "failed to map registers, aborting.\n"); |
1178 | err = -ENOMEM; | 1178 | err = -ENOMEM; |
diff --git a/drivers/net/mv643xx_eth.c b/drivers/net/mv643xx_eth.c index 77dc6abe1867..259699983ca5 100644 --- a/drivers/net/mv643xx_eth.c +++ b/drivers/net/mv643xx_eth.c | |||
@@ -2597,7 +2597,7 @@ static int mv643xx_eth_shared_probe(struct platform_device *pdev) | |||
2597 | if (msp == NULL) | 2597 | if (msp == NULL) |
2598 | goto out; | 2598 | goto out; |
2599 | 2599 | ||
2600 | msp->base = ioremap(res->start, res->end - res->start + 1); | 2600 | msp->base = ioremap(res->start, resource_size(res)); |
2601 | if (msp->base == NULL) | 2601 | if (msp->base == NULL) |
2602 | goto out_free; | 2602 | goto out_free; |
2603 | 2603 | ||
diff --git a/drivers/net/natsemi.c b/drivers/net/natsemi.c index 60f46bc2bf64..2962cc695ce3 100644 --- a/drivers/net/natsemi.c +++ b/drivers/net/natsemi.c | |||
@@ -1382,7 +1382,7 @@ static int find_mii(struct net_device *dev) | |||
1382 | /* WCSR bits [0:4] [9:10] */ | 1382 | /* WCSR bits [0:4] [9:10] */ |
1383 | #define WCSR_RESET_SAVE 0x61f | 1383 | #define WCSR_RESET_SAVE 0x61f |
1384 | /* RFCR bits [20] [22] [27:31] */ | 1384 | /* RFCR bits [20] [22] [27:31] */ |
1385 | #define RFCR_RESET_SAVE 0xf8500000; | 1385 | #define RFCR_RESET_SAVE 0xf8500000 |
1386 | 1386 | ||
1387 | static void natsemi_reset(struct net_device *dev) | 1387 | static void natsemi_reset(struct net_device *dev) |
1388 | { | 1388 | { |
@@ -2920,7 +2920,7 @@ static int netdev_set_ecmd(struct net_device *dev, struct ethtool_cmd *ecmd) | |||
2920 | 2920 | ||
2921 | /* | 2921 | /* |
2922 | * If we're ignoring the PHY then autoneg and the internal | 2922 | * If we're ignoring the PHY then autoneg and the internal |
2923 | * transciever are really not going to work so don't let the | 2923 | * transceiver are really not going to work so don't let the |
2924 | * user select them. | 2924 | * user select them. |
2925 | */ | 2925 | */ |
2926 | if (np->ignore_phy && (ecmd->autoneg == AUTONEG_ENABLE || | 2926 | if (np->ignore_phy && (ecmd->autoneg == AUTONEG_ENABLE || |
diff --git a/drivers/net/pxa168_eth.c b/drivers/net/pxa168_eth.c index c1bb05be7a7c..1a3033d8e7ed 100644 --- a/drivers/net/pxa168_eth.c +++ b/drivers/net/pxa168_eth.c | |||
@@ -1505,7 +1505,7 @@ static int pxa168_eth_probe(struct platform_device *pdev) | |||
1505 | err = -ENODEV; | 1505 | err = -ENODEV; |
1506 | goto err_netdev; | 1506 | goto err_netdev; |
1507 | } | 1507 | } |
1508 | pep->base = ioremap(res->start, res->end - res->start + 1); | 1508 | pep->base = ioremap(res->start, resource_size(res)); |
1509 | if (pep->base == NULL) { | 1509 | if (pep->base == NULL) { |
1510 | err = -ENOMEM; | 1510 | err = -ENOMEM; |
1511 | goto err_netdev; | 1511 | goto err_netdev; |
diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c index 4e2d1448093c..7d9c650f395e 100644 --- a/drivers/net/r8169.c +++ b/drivers/net/r8169.c | |||
@@ -694,7 +694,7 @@ struct rtl8169_private { | |||
694 | size_t size; | 694 | size_t size; |
695 | } phy_action; | 695 | } phy_action; |
696 | } *rtl_fw; | 696 | } *rtl_fw; |
697 | #define RTL_FIRMWARE_UNKNOWN ERR_PTR(-EAGAIN); | 697 | #define RTL_FIRMWARE_UNKNOWN ERR_PTR(-EAGAIN) |
698 | }; | 698 | }; |
699 | 699 | ||
700 | MODULE_AUTHOR("Realtek and the Linux r8169 crew <netdev@vger.kernel.org>"); | 700 | MODULE_AUTHOR("Realtek and the Linux r8169 crew <netdev@vger.kernel.org>"); |
diff --git a/drivers/net/s2io.h b/drivers/net/s2io.h index ae3c8e79b32f..d5596926a1ef 100644 --- a/drivers/net/s2io.h +++ b/drivers/net/s2io.h | |||
@@ -967,8 +967,8 @@ struct s2io_nic { | |||
967 | u8 serial_num[VPD_STRING_LEN]; | 967 | u8 serial_num[VPD_STRING_LEN]; |
968 | }; | 968 | }; |
969 | 969 | ||
970 | #define RESET_ERROR 1; | 970 | #define RESET_ERROR 1 |
971 | #define CMD_ERROR 2; | 971 | #define CMD_ERROR 2 |
972 | 972 | ||
973 | /* OS related system calls */ | 973 | /* OS related system calls */ |
974 | #ifndef readq | 974 | #ifndef readq |
diff --git a/drivers/net/sb1250-mac.c b/drivers/net/sb1250-mac.c index 68d50429ddf3..ea65f7ec360a 100644 --- a/drivers/net/sb1250-mac.c +++ b/drivers/net/sb1250-mac.c | |||
@@ -2597,7 +2597,7 @@ static int __devinit sbmac_probe(struct platform_device *pldev) | |||
2597 | 2597 | ||
2598 | res = platform_get_resource(pldev, IORESOURCE_MEM, 0); | 2598 | res = platform_get_resource(pldev, IORESOURCE_MEM, 0); |
2599 | BUG_ON(!res); | 2599 | BUG_ON(!res); |
2600 | sbm_base = ioremap_nocache(res->start, res->end - res->start + 1); | 2600 | sbm_base = ioremap_nocache(res->start, resource_size(res)); |
2601 | if (!sbm_base) { | 2601 | if (!sbm_base) { |
2602 | printk(KERN_ERR "%s: unable to map device registers\n", | 2602 | printk(KERN_ERR "%s: unable to map device registers\n", |
2603 | dev_name(&pldev->dev)); | 2603 | dev_name(&pldev->dev)); |
diff --git a/drivers/net/sungem.c b/drivers/net/sungem.c index ade35dde5b51..be745ae8f4e3 100644 --- a/drivers/net/sungem.c +++ b/drivers/net/sungem.c | |||
@@ -46,15 +46,14 @@ | |||
46 | #include <asm/byteorder.h> | 46 | #include <asm/byteorder.h> |
47 | #include <asm/uaccess.h> | 47 | #include <asm/uaccess.h> |
48 | #include <asm/irq.h> | 48 | #include <asm/irq.h> |
49 | #include <asm/prom.h> | ||
49 | 50 | ||
50 | #ifdef CONFIG_SPARC | 51 | #ifdef CONFIG_SPARC |
51 | #include <asm/idprom.h> | 52 | #include <asm/idprom.h> |
52 | #include <asm/prom.h> | ||
53 | #endif | 53 | #endif |
54 | 54 | ||
55 | #ifdef CONFIG_PPC_PMAC | 55 | #ifdef CONFIG_PPC_PMAC |
56 | #include <asm/pci-bridge.h> | 56 | #include <asm/pci-bridge.h> |
57 | #include <asm/prom.h> | ||
58 | #include <asm/machdep.h> | 57 | #include <asm/machdep.h> |
59 | #include <asm/pmac_feature.h> | 58 | #include <asm/pmac_feature.h> |
60 | #endif | 59 | #endif |
diff --git a/drivers/net/wan/lmc/lmc_var.h b/drivers/net/wan/lmc/lmc_var.h index 01ad45218d19..a1d202d8ad67 100644 --- a/drivers/net/wan/lmc/lmc_var.h +++ b/drivers/net/wan/lmc/lmc_var.h | |||
@@ -380,7 +380,7 @@ struct lmc___softc { | |||
380 | /* CSR6 settings */ | 380 | /* CSR6 settings */ |
381 | #define OPERATION_MODE 0x00000200 /* Full Duplex */ | 381 | #define OPERATION_MODE 0x00000200 /* Full Duplex */ |
382 | #define PROMISC_MODE 0x00000040 /* Promiscuous Mode */ | 382 | #define PROMISC_MODE 0x00000040 /* Promiscuous Mode */ |
383 | #define RECIEVE_ALL 0x40000000 /* Receive All */ | 383 | #define RECEIVE_ALL 0x40000000 /* Receive All */ |
384 | #define PASS_BAD_FRAMES 0x00000008 /* Pass Bad Frames */ | 384 | #define PASS_BAD_FRAMES 0x00000008 /* Pass Bad Frames */ |
385 | 385 | ||
386 | /* Dec control registers CSR6 as well */ | 386 | /* Dec control registers CSR6 as well */ |
diff --git a/drivers/net/wireless/ath/ath5k/ahb.c b/drivers/net/wireless/ath/ath5k/ahb.c index 9f69a4c9a3f3..a2a167363dbf 100644 --- a/drivers/net/wireless/ath/ath5k/ahb.c +++ b/drivers/net/wireless/ath/ath5k/ahb.c | |||
@@ -24,7 +24,6 @@ | |||
24 | #include "debug.h" | 24 | #include "debug.h" |
25 | #include "base.h" | 25 | #include "base.h" |
26 | #include "reg.h" | 26 | #include "reg.h" |
27 | #include "debug.h" | ||
28 | 27 | ||
29 | /* return bus cachesize in 4B word units */ | 28 | /* return bus cachesize in 4B word units */ |
30 | static void ath5k_ahb_read_cachesize(struct ath_common *common, int *csz) | 29 | static void ath5k_ahb_read_cachesize(struct ath_common *common, int *csz) |
diff --git a/drivers/net/wireless/b43/debugfs.c b/drivers/net/wireless/b43/debugfs.c index 59f59fa40334..e751fdee89b2 100644 --- a/drivers/net/wireless/b43/debugfs.c +++ b/drivers/net/wireless/b43/debugfs.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | debugfs driver debugging code | 5 | debugfs driver debugging code |
6 | 6 | ||
7 | Copyright (c) 2005-2007 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2005-2007 Michael Buesch <m@bues.ch> |
8 | 8 | ||
9 | This program is free software; you can redistribute it and/or modify | 9 | This program is free software; you can redistribute it and/or modify |
10 | it under the terms of the GNU General Public License as published by | 10 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43/dma.c b/drivers/net/wireless/b43/dma.c index 0953ce1ac1b0..83cba22ac6e8 100644 --- a/drivers/net/wireless/b43/dma.c +++ b/drivers/net/wireless/b43/dma.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | DMA ringbuffer and descriptor allocation/management | 5 | DMA ringbuffer and descriptor allocation/management |
6 | 6 | ||
7 | Copyright (c) 2005, 2006 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2005, 2006 Michael Buesch <m@bues.ch> |
8 | 8 | ||
9 | Some code in this file is derived from the b44.c driver | 9 | Some code in this file is derived from the b44.c driver |
10 | Copyright (C) 2002 David S. Miller | 10 | Copyright (C) 2002 David S. Miller |
diff --git a/drivers/net/wireless/b43/leds.c b/drivers/net/wireless/b43/leds.c index b56ed41fc1bd..a38c1c6446ad 100644 --- a/drivers/net/wireless/b43/leds.c +++ b/drivers/net/wireless/b43/leds.c | |||
@@ -5,7 +5,7 @@ | |||
5 | 5 | ||
6 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 6 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
7 | Copyright (c) 2005 Stefano Brivio <stefano.brivio@polimi.it> | 7 | Copyright (c) 2005 Stefano Brivio <stefano.brivio@polimi.it> |
8 | Copyright (c) 2005-2007 Michael Buesch <mb@bu3sch.de> | 8 | Copyright (c) 2005-2007 Michael Buesch <m@bues.ch> |
9 | Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> | 9 | Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> |
10 | Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 10 | Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
11 | 11 | ||
diff --git a/drivers/net/wireless/b43/lo.c b/drivers/net/wireless/b43/lo.c index a3dc8bb8ca95..4c82d582a524 100644 --- a/drivers/net/wireless/b43/lo.c +++ b/drivers/net/wireless/b43/lo.c | |||
@@ -6,7 +6,7 @@ | |||
6 | 6 | ||
7 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 7 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
8 | Copyright (c) 2005, 2006 Stefano Brivio <stefano.brivio@polimi.it> | 8 | Copyright (c) 2005, 2006 Stefano Brivio <stefano.brivio@polimi.it> |
9 | Copyright (c) 2005-2007 Michael Buesch <mb@bu3sch.de> | 9 | Copyright (c) 2005-2007 Michael Buesch <m@bues.ch> |
10 | Copyright (c) 2005, 2006 Danny van Dyk <kugelfang@gentoo.org> | 10 | Copyright (c) 2005, 2006 Danny van Dyk <kugelfang@gentoo.org> |
11 | Copyright (c) 2005, 2006 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 11 | Copyright (c) 2005, 2006 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
12 | 12 | ||
diff --git a/drivers/net/wireless/b43/main.c b/drivers/net/wireless/b43/main.c index 73fbf0358f96..032d46674f6b 100644 --- a/drivers/net/wireless/b43/main.c +++ b/drivers/net/wireless/b43/main.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de> | 5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de> |
6 | Copyright (c) 2005 Stefano Brivio <stefano.brivio@polimi.it> | 6 | Copyright (c) 2005 Stefano Brivio <stefano.brivio@polimi.it> |
7 | Copyright (c) 2005-2009 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2005-2009 Michael Buesch <m@bues.ch> |
8 | Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> | 8 | Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> |
9 | Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 9 | Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
10 | 10 | ||
diff --git a/drivers/net/wireless/b43/main.h b/drivers/net/wireless/b43/main.h index e4ebce9be592..8c684cd33529 100644 --- a/drivers/net/wireless/b43/main.h +++ b/drivers/net/wireless/b43/main.h | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
6 | Stefano Brivio <stefano.brivio@polimi.it> | 6 | Stefano Brivio <stefano.brivio@polimi.it> |
7 | Michael Buesch <mb@bu3sch.de> | 7 | Michael Buesch <m@bues.ch> |
8 | Danny van Dyk <kugelfang@gentoo.org> | 8 | Danny van Dyk <kugelfang@gentoo.org> |
9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> | 9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> |
10 | 10 | ||
diff --git a/drivers/net/wireless/b43/pcmcia.c b/drivers/net/wireless/b43/pcmcia.c index 2c8461dcf1b0..12b6b4067a39 100644 --- a/drivers/net/wireless/b43/pcmcia.c +++ b/drivers/net/wireless/b43/pcmcia.c | |||
@@ -2,7 +2,7 @@ | |||
2 | 2 | ||
3 | Broadcom B43 wireless driver | 3 | Broadcom B43 wireless driver |
4 | 4 | ||
5 | Copyright (c) 2007 Michael Buesch <mb@bu3sch.de> | 5 | Copyright (c) 2007 Michael Buesch <m@bues.ch> |
6 | 6 | ||
7 | This program is free software; you can redistribute it and/or modify | 7 | This program is free software; you can redistribute it and/or modify |
8 | it under the terms of the GNU General Public License as published by | 8 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43/phy_a.c b/drivers/net/wireless/b43/phy_a.c index 73ace5552bad..a6c38104693d 100644 --- a/drivers/net/wireless/b43/phy_a.c +++ b/drivers/net/wireless/b43/phy_a.c | |||
@@ -5,7 +5,7 @@ | |||
5 | 5 | ||
6 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 6 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
7 | Copyright (c) 2005-2007 Stefano Brivio <stefano.brivio@polimi.it> | 7 | Copyright (c) 2005-2007 Stefano Brivio <stefano.brivio@polimi.it> |
8 | Copyright (c) 2005-2008 Michael Buesch <mb@bu3sch.de> | 8 | Copyright (c) 2005-2008 Michael Buesch <m@bues.ch> |
9 | Copyright (c) 2005, 2006 Danny van Dyk <kugelfang@gentoo.org> | 9 | Copyright (c) 2005, 2006 Danny van Dyk <kugelfang@gentoo.org> |
10 | Copyright (c) 2005, 2006 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 10 | Copyright (c) 2005, 2006 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
11 | 11 | ||
diff --git a/drivers/net/wireless/b43/phy_common.c b/drivers/net/wireless/b43/phy_common.c index 101957512bcc..07f009ff5ee2 100644 --- a/drivers/net/wireless/b43/phy_common.c +++ b/drivers/net/wireless/b43/phy_common.c | |||
@@ -5,7 +5,7 @@ | |||
5 | 5 | ||
6 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 6 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
7 | Copyright (c) 2005-2007 Stefano Brivio <stefano.brivio@polimi.it> | 7 | Copyright (c) 2005-2007 Stefano Brivio <stefano.brivio@polimi.it> |
8 | Copyright (c) 2005-2008 Michael Buesch <mb@bu3sch.de> | 8 | Copyright (c) 2005-2008 Michael Buesch <m@bues.ch> |
9 | Copyright (c) 2005, 2006 Danny van Dyk <kugelfang@gentoo.org> | 9 | Copyright (c) 2005, 2006 Danny van Dyk <kugelfang@gentoo.org> |
10 | Copyright (c) 2005, 2006 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 10 | Copyright (c) 2005, 2006 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
11 | 11 | ||
diff --git a/drivers/net/wireless/b43/phy_g.c b/drivers/net/wireless/b43/phy_g.c index 83532d19347f..8e157bc213f3 100644 --- a/drivers/net/wireless/b43/phy_g.c +++ b/drivers/net/wireless/b43/phy_g.c | |||
@@ -5,7 +5,7 @@ | |||
5 | 5 | ||
6 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 6 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
7 | Copyright (c) 2005-2007 Stefano Brivio <stefano.brivio@polimi.it> | 7 | Copyright (c) 2005-2007 Stefano Brivio <stefano.brivio@polimi.it> |
8 | Copyright (c) 2005-2008 Michael Buesch <mb@bu3sch.de> | 8 | Copyright (c) 2005-2008 Michael Buesch <m@bues.ch> |
9 | Copyright (c) 2005, 2006 Danny van Dyk <kugelfang@gentoo.org> | 9 | Copyright (c) 2005, 2006 Danny van Dyk <kugelfang@gentoo.org> |
10 | Copyright (c) 2005, 2006 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 10 | Copyright (c) 2005, 2006 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
11 | 11 | ||
diff --git a/drivers/net/wireless/b43/phy_lp.c b/drivers/net/wireless/b43/phy_lp.c index daec1d9e4a18..f93d66b1817b 100644 --- a/drivers/net/wireless/b43/phy_lp.c +++ b/drivers/net/wireless/b43/phy_lp.c | |||
@@ -3,7 +3,7 @@ | |||
3 | Broadcom B43 wireless driver | 3 | Broadcom B43 wireless driver |
4 | IEEE 802.11a/g LP-PHY driver | 4 | IEEE 802.11a/g LP-PHY driver |
5 | 5 | ||
6 | Copyright (c) 2008-2009 Michael Buesch <mb@bu3sch.de> | 6 | Copyright (c) 2008-2009 Michael Buesch <m@bues.ch> |
7 | Copyright (c) 2009 Gábor Stefanik <netrolller.3d@gmail.com> | 7 | Copyright (c) 2009 Gábor Stefanik <netrolller.3d@gmail.com> |
8 | 8 | ||
9 | This program is free software; you can redistribute it and/or modify | 9 | This program is free software; you can redistribute it and/or modify |
diff --git a/drivers/net/wireless/b43/phy_n.c b/drivers/net/wireless/b43/phy_n.c index 1ae1e84cb4d1..3b46360da99b 100644 --- a/drivers/net/wireless/b43/phy_n.c +++ b/drivers/net/wireless/b43/phy_n.c | |||
@@ -3,7 +3,7 @@ | |||
3 | Broadcom B43 wireless driver | 3 | Broadcom B43 wireless driver |
4 | IEEE 802.11n PHY support | 4 | IEEE 802.11n PHY support |
5 | 5 | ||
6 | Copyright (c) 2008 Michael Buesch <mb@bu3sch.de> | 6 | Copyright (c) 2008 Michael Buesch <m@bues.ch> |
7 | 7 | ||
8 | This program is free software; you can redistribute it and/or modify | 8 | This program is free software; you can redistribute it and/or modify |
9 | it under the terms of the GNU General Public License as published by | 9 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43/pio.c b/drivers/net/wireless/b43/pio.c index 44da620d9cc2..6e4228c3ed1b 100644 --- a/drivers/net/wireless/b43/pio.c +++ b/drivers/net/wireless/b43/pio.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | PIO data transfer | 5 | PIO data transfer |
6 | 6 | ||
7 | Copyright (c) 2005-2008 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2005-2008 Michael Buesch <m@bues.ch> |
8 | 8 | ||
9 | This program is free software; you can redistribute it and/or modify | 9 | This program is free software; you can redistribute it and/or modify |
10 | it under the terms of the GNU General Public License as published by | 10 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43/radio_2055.c b/drivers/net/wireless/b43/radio_2055.c index 44c6dea66882..93643f18c2b3 100644 --- a/drivers/net/wireless/b43/radio_2055.c +++ b/drivers/net/wireless/b43/radio_2055.c | |||
@@ -3,7 +3,7 @@ | |||
3 | Broadcom B43 wireless driver | 3 | Broadcom B43 wireless driver |
4 | IEEE 802.11n PHY and radio device data tables | 4 | IEEE 802.11n PHY and radio device data tables |
5 | 5 | ||
6 | Copyright (c) 2008 Michael Buesch <mb@bu3sch.de> | 6 | Copyright (c) 2008 Michael Buesch <m@bues.ch> |
7 | 7 | ||
8 | This program is free software; you can redistribute it and/or modify | 8 | This program is free software; you can redistribute it and/or modify |
9 | it under the terms of the GNU General Public License as published by | 9 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43/rfkill.c b/drivers/net/wireless/b43/rfkill.c index 59c3afe047af..70c2fcedd1bb 100644 --- a/drivers/net/wireless/b43/rfkill.c +++ b/drivers/net/wireless/b43/rfkill.c | |||
@@ -3,7 +3,7 @@ | |||
3 | Broadcom B43 wireless driver | 3 | Broadcom B43 wireless driver |
4 | RFKILL support | 4 | RFKILL support |
5 | 5 | ||
6 | Copyright (c) 2007 Michael Buesch <mb@bu3sch.de> | 6 | Copyright (c) 2007 Michael Buesch <m@bues.ch> |
7 | 7 | ||
8 | This program is free software; you can redistribute it and/or modify | 8 | This program is free software; you can redistribute it and/or modify |
9 | it under the terms of the GNU General Public License as published by | 9 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43/sdio.c b/drivers/net/wireless/b43/sdio.c index 4fd6775b8c33..80b0755ed3af 100644 --- a/drivers/net/wireless/b43/sdio.c +++ b/drivers/net/wireless/b43/sdio.c | |||
@@ -4,7 +4,7 @@ | |||
4 | * SDIO over Sonics Silicon Backplane bus glue for b43. | 4 | * SDIO over Sonics Silicon Backplane bus glue for b43. |
5 | * | 5 | * |
6 | * Copyright (C) 2009 Albert Herranz | 6 | * Copyright (C) 2009 Albert Herranz |
7 | * Copyright (C) 2009 Michael Buesch <mb@bu3sch.de> | 7 | * Copyright (C) 2009 Michael Buesch <m@bues.ch> |
8 | * | 8 | * |
9 | * This program is free software; you can redistribute it and/or modify | 9 | * This program is free software; you can redistribute it and/or modify |
10 | * it under the terms of the GNU General Public License as published by | 10 | * it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43/sysfs.c b/drivers/net/wireless/b43/sysfs.c index f1ae4e05a32c..8e8431d4eb0c 100644 --- a/drivers/net/wireless/b43/sysfs.c +++ b/drivers/net/wireless/b43/sysfs.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | SYSFS support routines | 5 | SYSFS support routines |
6 | 6 | ||
7 | Copyright (c) 2006 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2006 Michael Buesch <m@bues.ch> |
8 | 8 | ||
9 | This program is free software; you can redistribute it and/or modify | 9 | This program is free software; you can redistribute it and/or modify |
10 | it under the terms of the GNU General Public License as published by | 10 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43/tables.c b/drivers/net/wireless/b43/tables.c index 1ef9a6463ec6..ea288df8aee9 100644 --- a/drivers/net/wireless/b43/tables.c +++ b/drivers/net/wireless/b43/tables.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
6 | Copyright (c) 2005-2007 Stefano Brivio <stefano.brivio@polimi.it> | 6 | Copyright (c) 2005-2007 Stefano Brivio <stefano.brivio@polimi.it> |
7 | Copyright (c) 2006, 2006 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2006, 2006 Michael Buesch <m@bues.ch> |
8 | Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> | 8 | Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> |
9 | Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 9 | Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
10 | 10 | ||
diff --git a/drivers/net/wireless/b43/tables_lpphy.c b/drivers/net/wireless/b43/tables_lpphy.c index 6748c5a196e9..cff187c5616d 100644 --- a/drivers/net/wireless/b43/tables_lpphy.c +++ b/drivers/net/wireless/b43/tables_lpphy.c | |||
@@ -3,7 +3,7 @@ | |||
3 | Broadcom B43 wireless driver | 3 | Broadcom B43 wireless driver |
4 | IEEE 802.11a/g LP-PHY and radio device data tables | 4 | IEEE 802.11a/g LP-PHY and radio device data tables |
5 | 5 | ||
6 | Copyright (c) 2009 Michael Buesch <mb@bu3sch.de> | 6 | Copyright (c) 2009 Michael Buesch <m@bues.ch> |
7 | Copyright (c) 2009 Gábor Stefanik <netrolller.3d@gmail.com> | 7 | Copyright (c) 2009 Gábor Stefanik <netrolller.3d@gmail.com> |
8 | 8 | ||
9 | This program is free software; you can redistribute it and/or modify | 9 | This program is free software; you can redistribute it and/or modify |
diff --git a/drivers/net/wireless/b43/tables_nphy.c b/drivers/net/wireless/b43/tables_nphy.c index 2de483b3d3ba..916f238a71df 100644 --- a/drivers/net/wireless/b43/tables_nphy.c +++ b/drivers/net/wireless/b43/tables_nphy.c | |||
@@ -3,7 +3,7 @@ | |||
3 | Broadcom B43 wireless driver | 3 | Broadcom B43 wireless driver |
4 | IEEE 802.11n PHY data tables | 4 | IEEE 802.11n PHY data tables |
5 | 5 | ||
6 | Copyright (c) 2008 Michael Buesch <mb@bu3sch.de> | 6 | Copyright (c) 2008 Michael Buesch <m@bues.ch> |
7 | 7 | ||
8 | This program is free software; you can redistribute it and/or modify | 8 | This program is free software; you can redistribute it and/or modify |
9 | it under the terms of the GNU General Public License as published by | 9 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43/wa.c b/drivers/net/wireless/b43/wa.c index 5d00d0eaf2e7..9b1a038be08b 100644 --- a/drivers/net/wireless/b43/wa.c +++ b/drivers/net/wireless/b43/wa.c | |||
@@ -5,7 +5,7 @@ | |||
5 | PHY workarounds. | 5 | PHY workarounds. |
6 | 6 | ||
7 | Copyright (c) 2005-2007 Stefano Brivio <stefano.brivio@polimi.it> | 7 | Copyright (c) 2005-2007 Stefano Brivio <stefano.brivio@polimi.it> |
8 | Copyright (c) 2005-2007 Michael Buesch <mbuesch@freenet.de> | 8 | Copyright (c) 2005-2007 Michael Buesch <m@bues.ch> |
9 | 9 | ||
10 | This program is free software; you can redistribute it and/or modify | 10 | This program is free software; you can redistribute it and/or modify |
11 | it under the terms of the GNU General Public License as published by | 11 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43/xmit.c b/drivers/net/wireless/b43/xmit.c index 82bcf7595139..b74f25ec1ab4 100644 --- a/drivers/net/wireless/b43/xmit.c +++ b/drivers/net/wireless/b43/xmit.c | |||
@@ -6,7 +6,7 @@ | |||
6 | 6 | ||
7 | Copyright (C) 2005 Martin Langer <martin-langer@gmx.de> | 7 | Copyright (C) 2005 Martin Langer <martin-langer@gmx.de> |
8 | Copyright (C) 2005 Stefano Brivio <stefano.brivio@polimi.it> | 8 | Copyright (C) 2005 Stefano Brivio <stefano.brivio@polimi.it> |
9 | Copyright (C) 2005, 2006 Michael Buesch <mb@bu3sch.de> | 9 | Copyright (C) 2005, 2006 Michael Buesch <m@bues.ch> |
10 | Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org> | 10 | Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org> |
11 | Copyright (C) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 11 | Copyright (C) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
12 | 12 | ||
diff --git a/drivers/net/wireless/b43legacy/debugfs.c b/drivers/net/wireless/b43legacy/debugfs.c index f232618f2cd1..5e28ad0d6d17 100644 --- a/drivers/net/wireless/b43legacy/debugfs.c +++ b/drivers/net/wireless/b43legacy/debugfs.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | debugfs driver debugging code | 5 | debugfs driver debugging code |
6 | 6 | ||
7 | Copyright (c) 2005-2007 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2005-2007 Michael Buesch <m@bues.ch> |
8 | 8 | ||
9 | This program is free software; you can redistribute it and/or modify | 9 | This program is free software; you can redistribute it and/or modify |
10 | it under the terms of the GNU General Public License as published by | 10 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43legacy/dma.c b/drivers/net/wireless/b43legacy/dma.c index 704ee62101bd..5010c477abdf 100644 --- a/drivers/net/wireless/b43legacy/dma.c +++ b/drivers/net/wireless/b43legacy/dma.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | DMA ringbuffer and descriptor allocation/management | 5 | DMA ringbuffer and descriptor allocation/management |
6 | 6 | ||
7 | Copyright (c) 2005, 2006 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2005, 2006 Michael Buesch <m@bues.ch> |
8 | 8 | ||
9 | Some code in this file is derived from the b44.c driver | 9 | Some code in this file is derived from the b44.c driver |
10 | Copyright (C) 2002 David S. Miller | 10 | Copyright (C) 2002 David S. Miller |
diff --git a/drivers/net/wireless/b43legacy/ilt.c b/drivers/net/wireless/b43legacy/ilt.c index a849078aea69..ee5682e54204 100644 --- a/drivers/net/wireless/b43legacy/ilt.c +++ b/drivers/net/wireless/b43legacy/ilt.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
6 | Stefano Brivio <stefano.brivio@polimi.it> | 6 | Stefano Brivio <stefano.brivio@polimi.it> |
7 | Michael Buesch <mbuesch@freenet.de> | 7 | Michael Buesch <m@bues.ch> |
8 | Danny van Dyk <kugelfang@gentoo.org> | 8 | Danny van Dyk <kugelfang@gentoo.org> |
9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> | 9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> |
10 | 10 | ||
diff --git a/drivers/net/wireless/b43legacy/leds.c b/drivers/net/wireless/b43legacy/leds.c index 37e9be893560..2f1bfdc44f94 100644 --- a/drivers/net/wireless/b43legacy/leds.c +++ b/drivers/net/wireless/b43legacy/leds.c | |||
@@ -5,7 +5,7 @@ | |||
5 | 5 | ||
6 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 6 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
7 | Copyright (c) 2005 Stefano Brivio <stefano.brivio@polimi.it> | 7 | Copyright (c) 2005 Stefano Brivio <stefano.brivio@polimi.it> |
8 | Copyright (c) 2005-2007 Michael Buesch <mb@bu3sch.de> | 8 | Copyright (c) 2005-2007 Michael Buesch <m@bues.ch> |
9 | Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> | 9 | Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> |
10 | Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 10 | Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
11 | 11 | ||
diff --git a/drivers/net/wireless/b43legacy/main.c b/drivers/net/wireless/b43legacy/main.c index d6db6c17da4f..04c03b212a5e 100644 --- a/drivers/net/wireless/b43legacy/main.c +++ b/drivers/net/wireless/b43legacy/main.c | |||
@@ -4,7 +4,7 @@ | |||
4 | * | 4 | * |
5 | * Copyright (c) 2005 Martin Langer <martin-langer@gmx.de> | 5 | * Copyright (c) 2005 Martin Langer <martin-langer@gmx.de> |
6 | * Copyright (c) 2005-2008 Stefano Brivio <stefano.brivio@polimi.it> | 6 | * Copyright (c) 2005-2008 Stefano Brivio <stefano.brivio@polimi.it> |
7 | * Copyright (c) 2005, 2006 Michael Buesch <mb@bu3sch.de> | 7 | * Copyright (c) 2005, 2006 Michael Buesch <m@bues.ch> |
8 | * Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> | 8 | * Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> |
9 | * Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 9 | * Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
10 | * Copyright (c) 2007 Larry Finger <Larry.Finger@lwfinger.net> | 10 | * Copyright (c) 2007 Larry Finger <Larry.Finger@lwfinger.net> |
diff --git a/drivers/net/wireless/b43legacy/main.h b/drivers/net/wireless/b43legacy/main.h index 1f0e2e379b02..b74a058d7bac 100644 --- a/drivers/net/wireless/b43legacy/main.h +++ b/drivers/net/wireless/b43legacy/main.h | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
6 | Copyright (c) 2005 Stefano Brivio <stefano.brivio@polimi.it> | 6 | Copyright (c) 2005 Stefano Brivio <stefano.brivio@polimi.it> |
7 | Copyright (c) 2005, 2006 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2005, 2006 Michael Buesch <m@bues.ch> |
8 | Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> | 8 | Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> |
9 | Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 9 | Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
10 | Copyright (c) 2007 Larry Finger <Larry.Finger@lwfinger.net> | 10 | Copyright (c) 2007 Larry Finger <Larry.Finger@lwfinger.net> |
diff --git a/drivers/net/wireless/b43legacy/phy.c b/drivers/net/wireless/b43legacy/phy.c index 28e477d01587..96faaef3661b 100644 --- a/drivers/net/wireless/b43legacy/phy.c +++ b/drivers/net/wireless/b43legacy/phy.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
6 | Stefano Brivio <stefano.brivio@polimi.it> | 6 | Stefano Brivio <stefano.brivio@polimi.it> |
7 | Michael Buesch <mbuesch@freenet.de> | 7 | Michael Buesch <m@bues.ch> |
8 | Danny van Dyk <kugelfang@gentoo.org> | 8 | Danny van Dyk <kugelfang@gentoo.org> |
9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> | 9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> |
10 | Copyright (c) 2007 Larry Finger <Larry.Finger@lwfinger.net> | 10 | Copyright (c) 2007 Larry Finger <Larry.Finger@lwfinger.net> |
diff --git a/drivers/net/wireless/b43legacy/phy.h b/drivers/net/wireless/b43legacy/phy.h index ecbe409f9a94..831a7a4760e5 100644 --- a/drivers/net/wireless/b43legacy/phy.h +++ b/drivers/net/wireless/b43legacy/phy.h | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
6 | Stefano Brivio <stefano.brivio@polimi.it> | 6 | Stefano Brivio <stefano.brivio@polimi.it> |
7 | Michael Buesch <mbuesch@freenet.de> | 7 | Michael Buesch <m@bues.ch> |
8 | Danny van Dyk <kugelfang@gentoo.org> | 8 | Danny van Dyk <kugelfang@gentoo.org> |
9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> | 9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> |
10 | Copyright (c) 2007 Larry Finger <Larry.Finger@lwfinger.net> | 10 | Copyright (c) 2007 Larry Finger <Larry.Finger@lwfinger.net> |
diff --git a/drivers/net/wireless/b43legacy/pio.c b/drivers/net/wireless/b43legacy/pio.c index b033b0ed4ca0..192251adf986 100644 --- a/drivers/net/wireless/b43legacy/pio.c +++ b/drivers/net/wireless/b43legacy/pio.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | PIO Transmission | 5 | PIO Transmission |
6 | 6 | ||
7 | Copyright (c) 2005 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2005 Michael Buesch <m@bues.ch> |
8 | 8 | ||
9 | This program is free software; you can redistribute it and/or modify | 9 | This program is free software; you can redistribute it and/or modify |
10 | it under the terms of the GNU General Public License as published by | 10 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43legacy/radio.c b/drivers/net/wireless/b43legacy/radio.c index 2df545cfad14..475eb14e665b 100644 --- a/drivers/net/wireless/b43legacy/radio.c +++ b/drivers/net/wireless/b43legacy/radio.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
6 | Stefano Brivio <stefano.brivio@polimi.it> | 6 | Stefano Brivio <stefano.brivio@polimi.it> |
7 | Michael Buesch <mbuesch@freenet.de> | 7 | Michael Buesch <m@bues.ch> |
8 | Danny van Dyk <kugelfang@gentoo.org> | 8 | Danny van Dyk <kugelfang@gentoo.org> |
9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> | 9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> |
10 | Copyright (c) 2007 Larry Finger <Larry.Finger@lwfinger.net> | 10 | Copyright (c) 2007 Larry Finger <Larry.Finger@lwfinger.net> |
diff --git a/drivers/net/wireless/b43legacy/radio.h b/drivers/net/wireless/b43legacy/radio.h index ec4de2811c52..bccb3d7da682 100644 --- a/drivers/net/wireless/b43legacy/radio.h +++ b/drivers/net/wireless/b43legacy/radio.h | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, | 5 | Copyright (c) 2005 Martin Langer <martin-langer@gmx.de>, |
6 | Stefano Brivio <stefano.brivio@polimi.it> | 6 | Stefano Brivio <stefano.brivio@polimi.it> |
7 | Michael Buesch <mbuesch@freenet.de> | 7 | Michael Buesch <m@bues.ch> |
8 | Danny van Dyk <kugelfang@gentoo.org> | 8 | Danny van Dyk <kugelfang@gentoo.org> |
9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> | 9 | Andreas Jaggi <andreas.jaggi@waterwave.ch> |
10 | 10 | ||
diff --git a/drivers/net/wireless/b43legacy/rfkill.c b/drivers/net/wireless/b43legacy/rfkill.c index b90f223fb31c..c4559bcbc707 100644 --- a/drivers/net/wireless/b43legacy/rfkill.c +++ b/drivers/net/wireless/b43legacy/rfkill.c | |||
@@ -3,7 +3,7 @@ | |||
3 | Broadcom B43 wireless driver | 3 | Broadcom B43 wireless driver |
4 | RFKILL support | 4 | RFKILL support |
5 | 5 | ||
6 | Copyright (c) 2007 Michael Buesch <mb@bu3sch.de> | 6 | Copyright (c) 2007 Michael Buesch <m@bues.ch> |
7 | 7 | ||
8 | This program is free software; you can redistribute it and/or modify | 8 | This program is free software; you can redistribute it and/or modify |
9 | it under the terms of the GNU General Public License as published by | 9 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43legacy/sysfs.c b/drivers/net/wireless/b43legacy/sysfs.c index 56c384fa9b1f..57f8b089767c 100644 --- a/drivers/net/wireless/b43legacy/sysfs.c +++ b/drivers/net/wireless/b43legacy/sysfs.c | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | SYSFS support routines | 5 | SYSFS support routines |
6 | 6 | ||
7 | Copyright (c) 2006 Michael Buesch <mb@bu3sch.de> | 7 | Copyright (c) 2006 Michael Buesch <m@bues.ch> |
8 | 8 | ||
9 | This program is free software; you can redistribute it and/or modify | 9 | This program is free software; you can redistribute it and/or modify |
10 | it under the terms of the GNU General Public License as published by | 10 | it under the terms of the GNU General Public License as published by |
diff --git a/drivers/net/wireless/b43legacy/xmit.c b/drivers/net/wireless/b43legacy/xmit.c index 6c174f38ca3c..5188fab0b377 100644 --- a/drivers/net/wireless/b43legacy/xmit.c +++ b/drivers/net/wireless/b43legacy/xmit.c | |||
@@ -6,7 +6,7 @@ | |||
6 | 6 | ||
7 | Copyright (C) 2005 Martin Langer <martin-langer@gmx.de> | 7 | Copyright (C) 2005 Martin Langer <martin-langer@gmx.de> |
8 | Copyright (C) 2005 Stefano Brivio <stefano.brivio@polimi.it> | 8 | Copyright (C) 2005 Stefano Brivio <stefano.brivio@polimi.it> |
9 | Copyright (C) 2005, 2006 Michael Buesch <mb@bu3sch.de> | 9 | Copyright (C) 2005, 2006 Michael Buesch <m@bues.ch> |
10 | Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org> | 10 | Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org> |
11 | Copyright (C) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 11 | Copyright (C) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
12 | Copyright (C) 2007 Larry Finger <Larry.Finger@lwfinger.net> | 12 | Copyright (C) 2007 Larry Finger <Larry.Finger@lwfinger.net> |
diff --git a/drivers/net/wireless/iwlegacy/iwl-commands.h b/drivers/net/wireless/iwlegacy/iwl-commands.h index ee21210bea9c..89904054473f 100644 --- a/drivers/net/wireless/iwlegacy/iwl-commands.h +++ b/drivers/net/wireless/iwlegacy/iwl-commands.h | |||
@@ -2617,8 +2617,8 @@ struct iwl_scanstart_notification { | |||
2617 | __le32 status; | 2617 | __le32 status; |
2618 | } __packed; | 2618 | } __packed; |
2619 | 2619 | ||
2620 | #define SCAN_OWNER_STATUS 0x1; | 2620 | #define SCAN_OWNER_STATUS 0x1 |
2621 | #define MEASURE_OWNER_STATUS 0x2; | 2621 | #define MEASURE_OWNER_STATUS 0x2 |
2622 | 2622 | ||
2623 | #define IWL_PROBE_STATUS_OK 0 | 2623 | #define IWL_PROBE_STATUS_OK 0 |
2624 | #define IWL_PROBE_STATUS_TX_FAILED BIT(0) | 2624 | #define IWL_PROBE_STATUS_TX_FAILED BIT(0) |
diff --git a/drivers/net/wireless/iwlwifi/iwl-commands.h b/drivers/net/wireless/iwlwifi/iwl-commands.h index 5769ca5cebca..e9e9d1d1778d 100644 --- a/drivers/net/wireless/iwlwifi/iwl-commands.h +++ b/drivers/net/wireless/iwlwifi/iwl-commands.h | |||
@@ -2468,8 +2468,8 @@ struct iwl_scanstart_notification { | |||
2468 | __le32 status; | 2468 | __le32 status; |
2469 | } __packed; | 2469 | } __packed; |
2470 | 2470 | ||
2471 | #define SCAN_OWNER_STATUS 0x1; | 2471 | #define SCAN_OWNER_STATUS 0x1 |
2472 | #define MEASURE_OWNER_STATUS 0x2; | 2472 | #define MEASURE_OWNER_STATUS 0x2 |
2473 | 2473 | ||
2474 | #define IWL_PROBE_STATUS_OK 0 | 2474 | #define IWL_PROBE_STATUS_OK 0 |
2475 | #define IWL_PROBE_STATUS_TX_FAILED BIT(0) | 2475 | #define IWL_PROBE_STATUS_TX_FAILED BIT(0) |
diff --git a/drivers/net/wireless/rtlwifi/rtl8192ce/reg.h b/drivers/net/wireless/rtlwifi/rtl8192ce/reg.h index 72a3d5497547..ba5ff0411f0a 100644 --- a/drivers/net/wireless/rtlwifi/rtl8192ce/reg.h +++ b/drivers/net/wireless/rtlwifi/rtl8192ce/reg.h | |||
@@ -1074,10 +1074,10 @@ | |||
1074 | #define _SRL(x) (((x) & 0x3F) << 8) | 1074 | #define _SRL(x) (((x) & 0x3F) << 8) |
1075 | 1075 | ||
1076 | #define _SIFS_CCK_CTX(x) ((x) & 0xFF) | 1076 | #define _SIFS_CCK_CTX(x) ((x) & 0xFF) |
1077 | #define _SIFS_CCK_TRX(x) (((x) & 0xFF) << 8); | 1077 | #define _SIFS_CCK_TRX(x) (((x) & 0xFF) << 8) |
1078 | 1078 | ||
1079 | #define _SIFS_OFDM_CTX(x) ((x) & 0xFF) | 1079 | #define _SIFS_OFDM_CTX(x) ((x) & 0xFF) |
1080 | #define _SIFS_OFDM_TRX(x) (((x) & 0xFF) << 8); | 1080 | #define _SIFS_OFDM_TRX(x) (((x) & 0xFF) << 8) |
1081 | 1081 | ||
1082 | #define _TBTT_PROHIBIT_HOLD(x) (((x) & 0xFF) << 8) | 1082 | #define _TBTT_PROHIBIT_HOLD(x) (((x) & 0xFF) << 8) |
1083 | 1083 | ||
diff --git a/drivers/parport/parport_ax88796.c b/drivers/parport/parport_ax88796.c index 2c5ac2bf5c56..844f6137970a 100644 --- a/drivers/parport/parport_ax88796.c +++ b/drivers/parport/parport_ax88796.c | |||
@@ -293,7 +293,7 @@ static int parport_ax88796_probe(struct platform_device *pdev) | |||
293 | goto exit_mem; | 293 | goto exit_mem; |
294 | } | 294 | } |
295 | 295 | ||
296 | size = (res->end - res->start) + 1; | 296 | size = resource_size(res); |
297 | spacing = size / 3; | 297 | spacing = size / 3; |
298 | 298 | ||
299 | dd->io = request_mem_region(res->start, size, pdev->name); | 299 | dd->io = request_mem_region(res->start, size, pdev->name); |
diff --git a/drivers/pci/hotplug/shpchp_sysfs.c b/drivers/pci/hotplug/shpchp_sysfs.c index 071b7dc0094b..efa30da1ae8f 100644 --- a/drivers/pci/hotplug/shpchp_sysfs.c +++ b/drivers/pci/hotplug/shpchp_sysfs.c | |||
@@ -50,29 +50,26 @@ static ssize_t show_ctrl (struct device *dev, struct device_attribute *attr, cha | |||
50 | pci_bus_for_each_resource(bus, res, index) { | 50 | pci_bus_for_each_resource(bus, res, index) { |
51 | if (res && (res->flags & IORESOURCE_MEM) && | 51 | if (res && (res->flags & IORESOURCE_MEM) && |
52 | !(res->flags & IORESOURCE_PREFETCH)) { | 52 | !(res->flags & IORESOURCE_PREFETCH)) { |
53 | out += sprintf(out, "start = %8.8llx, " | 53 | out += sprintf(out, "start = %8.8llx, length = %8.8llx\n", |
54 | "length = %8.8llx\n", | 54 | (unsigned long long)res->start, |
55 | (unsigned long long)res->start, | 55 | (unsigned long long)resource_size(res)); |
56 | (unsigned long long)(res->end - res->start)); | ||
57 | } | 56 | } |
58 | } | 57 | } |
59 | out += sprintf(out, "Free resources: prefetchable memory\n"); | 58 | out += sprintf(out, "Free resources: prefetchable memory\n"); |
60 | pci_bus_for_each_resource(bus, res, index) { | 59 | pci_bus_for_each_resource(bus, res, index) { |
61 | if (res && (res->flags & IORESOURCE_MEM) && | 60 | if (res && (res->flags & IORESOURCE_MEM) && |
62 | (res->flags & IORESOURCE_PREFETCH)) { | 61 | (res->flags & IORESOURCE_PREFETCH)) { |
63 | out += sprintf(out, "start = %8.8llx, " | 62 | out += sprintf(out, "start = %8.8llx, length = %8.8llx\n", |
64 | "length = %8.8llx\n", | 63 | (unsigned long long)res->start, |
65 | (unsigned long long)res->start, | 64 | (unsigned long long)resource_size(res)); |
66 | (unsigned long long)(res->end - res->start)); | ||
67 | } | 65 | } |
68 | } | 66 | } |
69 | out += sprintf(out, "Free resources: IO\n"); | 67 | out += sprintf(out, "Free resources: IO\n"); |
70 | pci_bus_for_each_resource(bus, res, index) { | 68 | pci_bus_for_each_resource(bus, res, index) { |
71 | if (res && (res->flags & IORESOURCE_IO)) { | 69 | if (res && (res->flags & IORESOURCE_IO)) { |
72 | out += sprintf(out, "start = %8.8llx, " | 70 | out += sprintf(out, "start = %8.8llx, length = %8.8llx\n", |
73 | "length = %8.8llx\n", | 71 | (unsigned long long)res->start, |
74 | (unsigned long long)res->start, | 72 | (unsigned long long)resource_size(res)); |
75 | (unsigned long long)(res->end - res->start)); | ||
76 | } | 73 | } |
77 | } | 74 | } |
78 | out += sprintf(out, "Free resources: bus numbers\n"); | 75 | out += sprintf(out, "Free resources: bus numbers\n"); |
diff --git a/drivers/pci/pcie/aspm.c b/drivers/pci/pcie/aspm.c index 6892601fc76f..cbfbab18be91 100644 --- a/drivers/pci/pcie/aspm.c +++ b/drivers/pci/pcie/aspm.c | |||
@@ -940,7 +940,7 @@ static int __init pcie_aspm_disable(char *str) | |||
940 | printk(KERN_INFO "PCIe ASPM is disabled\n"); | 940 | printk(KERN_INFO "PCIe ASPM is disabled\n"); |
941 | } else if (!strcmp(str, "force")) { | 941 | } else if (!strcmp(str, "force")) { |
942 | aspm_force = 1; | 942 | aspm_force = 1; |
943 | printk(KERN_INFO "PCIe ASPM is forcedly enabled\n"); | 943 | printk(KERN_INFO "PCIe ASPM is forcibly enabled\n"); |
944 | } | 944 | } |
945 | return 1; | 945 | return 1; |
946 | } | 946 | } |
diff --git a/drivers/pcmcia/at91_cf.c b/drivers/pcmcia/at91_cf.c index fb33fa42d249..4902206f53d9 100644 --- a/drivers/pcmcia/at91_cf.c +++ b/drivers/pcmcia/at91_cf.c | |||
@@ -283,8 +283,7 @@ static int __init at91_cf_probe(struct platform_device *pdev) | |||
283 | } | 283 | } |
284 | 284 | ||
285 | /* reserve chip-select regions */ | 285 | /* reserve chip-select regions */ |
286 | if (!request_mem_region(io->start, io->end + 1 - io->start, | 286 | if (!request_mem_region(io->start, resource_size(io), driver_name)) { |
287 | driver_name)) { | ||
288 | status = -ENXIO; | 287 | status = -ENXIO; |
289 | goto fail1; | 288 | goto fail1; |
290 | } | 289 | } |
@@ -308,7 +307,7 @@ static int __init at91_cf_probe(struct platform_device *pdev) | |||
308 | return 0; | 307 | return 0; |
309 | 308 | ||
310 | fail2: | 309 | fail2: |
311 | release_mem_region(io->start, io->end + 1 - io->start); | 310 | release_mem_region(io->start, resource_size(io)); |
312 | fail1: | 311 | fail1: |
313 | if (cf->socket.io_offset) | 312 | if (cf->socket.io_offset) |
314 | iounmap((void __iomem *) cf->socket.io_offset); | 313 | iounmap((void __iomem *) cf->socket.io_offset); |
@@ -339,7 +338,7 @@ static int __exit at91_cf_remove(struct platform_device *pdev) | |||
339 | struct resource *io = cf->socket.io[0].res; | 338 | struct resource *io = cf->socket.io[0].res; |
340 | 339 | ||
341 | pcmcia_unregister_socket(&cf->socket); | 340 | pcmcia_unregister_socket(&cf->socket); |
342 | release_mem_region(io->start, io->end + 1 - io->start); | 341 | release_mem_region(io->start, resource_size(io)); |
343 | iounmap((void __iomem *) cf->socket.io_offset); | 342 | iounmap((void __iomem *) cf->socket.io_offset); |
344 | if (board->irq_pin) { | 343 | if (board->irq_pin) { |
345 | free_irq(board->irq_pin, cf); | 344 | free_irq(board->irq_pin, cf); |
diff --git a/drivers/pcmcia/electra_cf.c b/drivers/pcmcia/electra_cf.c index 6defd4a8168e..06ad3e5e7d3d 100644 --- a/drivers/pcmcia/electra_cf.c +++ b/drivers/pcmcia/electra_cf.c | |||
@@ -209,9 +209,9 @@ static int __devinit electra_cf_probe(struct platform_device *ofdev) | |||
209 | 209 | ||
210 | cf->ofdev = ofdev; | 210 | cf->ofdev = ofdev; |
211 | cf->mem_phys = mem.start; | 211 | cf->mem_phys = mem.start; |
212 | cf->mem_size = PAGE_ALIGN(mem.end - mem.start); | 212 | cf->mem_size = PAGE_ALIGN(resource_size(&mem)); |
213 | cf->mem_base = ioremap(cf->mem_phys, cf->mem_size); | 213 | cf->mem_base = ioremap(cf->mem_phys, cf->mem_size); |
214 | cf->io_size = PAGE_ALIGN(io.end - io.start); | 214 | cf->io_size = PAGE_ALIGN(resource_size(&io)); |
215 | 215 | ||
216 | area = __get_vm_area(cf->io_size, 0, PHB_IO_BASE, PHB_IO_END); | 216 | area = __get_vm_area(cf->io_size, 0, PHB_IO_BASE, PHB_IO_END); |
217 | if (area == NULL) | 217 | if (area == NULL) |
diff --git a/drivers/pcmcia/rsrc_iodyn.c b/drivers/pcmcia/rsrc_iodyn.c index 523eb691c30b..f53c237bda2f 100644 --- a/drivers/pcmcia/rsrc_iodyn.c +++ b/drivers/pcmcia/rsrc_iodyn.c | |||
@@ -135,7 +135,7 @@ static int iodyn_find_io(struct pcmcia_socket *s, unsigned int attr, | |||
135 | try = res->end + 1; | 135 | try = res->end + 1; |
136 | if ((*base == 0) || (*base == try)) { | 136 | if ((*base == 0) || (*base == try)) { |
137 | if (adjust_resource(s->io[i].res, res->start, | 137 | if (adjust_resource(s->io[i].res, res->start, |
138 | res->end - res->start + num + 1)) | 138 | resource_size(res) + num)) |
139 | continue; | 139 | continue; |
140 | *base = try; | 140 | *base = try; |
141 | s->io[i].InUse += num; | 141 | s->io[i].InUse += num; |
@@ -147,8 +147,8 @@ static int iodyn_find_io(struct pcmcia_socket *s, unsigned int attr, | |||
147 | try = res->start - num; | 147 | try = res->start - num; |
148 | if ((*base == 0) || (*base == try)) { | 148 | if ((*base == 0) || (*base == try)) { |
149 | if (adjust_resource(s->io[i].res, | 149 | if (adjust_resource(s->io[i].res, |
150 | res->start - num, | 150 | res->start - num, |
151 | res->end - res->start + num + 1)) | 151 | resource_size(res) + num)) |
152 | continue; | 152 | continue; |
153 | *base = try; | 153 | *base = try; |
154 | s->io[i].InUse += num; | 154 | s->io[i].InUse += num; |
diff --git a/drivers/pcmcia/rsrc_nonstatic.c b/drivers/pcmcia/rsrc_nonstatic.c index b187555d4388..9da9656242af 100644 --- a/drivers/pcmcia/rsrc_nonstatic.c +++ b/drivers/pcmcia/rsrc_nonstatic.c | |||
@@ -770,7 +770,7 @@ static int nonstatic_find_io(struct pcmcia_socket *s, unsigned int attr, | |||
770 | res->end + num); | 770 | res->end + num); |
771 | if (!ret) { | 771 | if (!ret) { |
772 | ret = adjust_resource(s->io[i].res, res->start, | 772 | ret = adjust_resource(s->io[i].res, res->start, |
773 | res->end - res->start + num + 1); | 773 | resource_size(res) + num); |
774 | if (ret) | 774 | if (ret) |
775 | continue; | 775 | continue; |
776 | *base = try; | 776 | *base = try; |
@@ -788,8 +788,8 @@ static int nonstatic_find_io(struct pcmcia_socket *s, unsigned int attr, | |||
788 | res->end); | 788 | res->end); |
789 | if (!ret) { | 789 | if (!ret) { |
790 | ret = adjust_resource(s->io[i].res, | 790 | ret = adjust_resource(s->io[i].res, |
791 | res->start - num, | 791 | res->start - num, |
792 | res->end - res->start + num + 1); | 792 | resource_size(res) + num); |
793 | if (ret) | 793 | if (ret) |
794 | continue; | 794 | continue; |
795 | *base = try; | 795 | *base = try; |
diff --git a/drivers/pnp/pnpacpi/rsparser.c b/drivers/pnp/pnpacpi/rsparser.c index 100e4d9372f1..1a6937d9118f 100644 --- a/drivers/pnp/pnpacpi/rsparser.c +++ b/drivers/pnp/pnpacpi/rsparser.c | |||
@@ -1018,7 +1018,7 @@ static void pnpacpi_encode_io(struct pnp_dev *dev, | |||
1018 | io->minimum = p->start; | 1018 | io->minimum = p->start; |
1019 | io->maximum = p->end; | 1019 | io->maximum = p->end; |
1020 | io->alignment = 0; /* Correct? */ | 1020 | io->alignment = 0; /* Correct? */ |
1021 | io->address_length = p->end - p->start + 1; | 1021 | io->address_length = resource_size(p); |
1022 | } else { | 1022 | } else { |
1023 | io->minimum = 0; | 1023 | io->minimum = 0; |
1024 | io->address_length = 0; | 1024 | io->address_length = 0; |
@@ -1036,7 +1036,7 @@ static void pnpacpi_encode_fixed_io(struct pnp_dev *dev, | |||
1036 | 1036 | ||
1037 | if (pnp_resource_enabled(p)) { | 1037 | if (pnp_resource_enabled(p)) { |
1038 | fixed_io->address = p->start; | 1038 | fixed_io->address = p->start; |
1039 | fixed_io->address_length = p->end - p->start + 1; | 1039 | fixed_io->address_length = resource_size(p); |
1040 | } else { | 1040 | } else { |
1041 | fixed_io->address = 0; | 1041 | fixed_io->address = 0; |
1042 | fixed_io->address_length = 0; | 1042 | fixed_io->address_length = 0; |
@@ -1059,7 +1059,7 @@ static void pnpacpi_encode_mem24(struct pnp_dev *dev, | |||
1059 | memory24->minimum = p->start; | 1059 | memory24->minimum = p->start; |
1060 | memory24->maximum = p->end; | 1060 | memory24->maximum = p->end; |
1061 | memory24->alignment = 0; | 1061 | memory24->alignment = 0; |
1062 | memory24->address_length = p->end - p->start + 1; | 1062 | memory24->address_length = resource_size(p); |
1063 | } else { | 1063 | } else { |
1064 | memory24->minimum = 0; | 1064 | memory24->minimum = 0; |
1065 | memory24->address_length = 0; | 1065 | memory24->address_length = 0; |
@@ -1083,7 +1083,7 @@ static void pnpacpi_encode_mem32(struct pnp_dev *dev, | |||
1083 | memory32->minimum = p->start; | 1083 | memory32->minimum = p->start; |
1084 | memory32->maximum = p->end; | 1084 | memory32->maximum = p->end; |
1085 | memory32->alignment = 0; | 1085 | memory32->alignment = 0; |
1086 | memory32->address_length = p->end - p->start + 1; | 1086 | memory32->address_length = resource_size(p); |
1087 | } else { | 1087 | } else { |
1088 | memory32->minimum = 0; | 1088 | memory32->minimum = 0; |
1089 | memory32->alignment = 0; | 1089 | memory32->alignment = 0; |
@@ -1106,7 +1106,7 @@ static void pnpacpi_encode_fixed_mem32(struct pnp_dev *dev, | |||
1106 | p->flags & IORESOURCE_MEM_WRITEABLE ? | 1106 | p->flags & IORESOURCE_MEM_WRITEABLE ? |
1107 | ACPI_READ_WRITE_MEMORY : ACPI_READ_ONLY_MEMORY; | 1107 | ACPI_READ_WRITE_MEMORY : ACPI_READ_ONLY_MEMORY; |
1108 | fixed_memory32->address = p->start; | 1108 | fixed_memory32->address = p->start; |
1109 | fixed_memory32->address_length = p->end - p->start + 1; | 1109 | fixed_memory32->address_length = resource_size(p); |
1110 | } else { | 1110 | } else { |
1111 | fixed_memory32->address = 0; | 1111 | fixed_memory32->address = 0; |
1112 | fixed_memory32->address_length = 0; | 1112 | fixed_memory32->address_length = 0; |
diff --git a/drivers/pnp/pnpbios/rsparser.c b/drivers/pnp/pnpbios/rsparser.c index cb1f47bfee96..cca2f9f9f3e3 100644 --- a/drivers/pnp/pnpbios/rsparser.c +++ b/drivers/pnp/pnpbios/rsparser.c | |||
@@ -505,7 +505,7 @@ static void pnpbios_encode_mem(struct pnp_dev *dev, unsigned char *p, | |||
505 | 505 | ||
506 | if (pnp_resource_enabled(res)) { | 506 | if (pnp_resource_enabled(res)) { |
507 | base = res->start; | 507 | base = res->start; |
508 | len = res->end - res->start + 1; | 508 | len = resource_size(res); |
509 | } else { | 509 | } else { |
510 | base = 0; | 510 | base = 0; |
511 | len = 0; | 511 | len = 0; |
@@ -529,7 +529,7 @@ static void pnpbios_encode_mem32(struct pnp_dev *dev, unsigned char *p, | |||
529 | 529 | ||
530 | if (pnp_resource_enabled(res)) { | 530 | if (pnp_resource_enabled(res)) { |
531 | base = res->start; | 531 | base = res->start; |
532 | len = res->end - res->start + 1; | 532 | len = resource_size(res); |
533 | } else { | 533 | } else { |
534 | base = 0; | 534 | base = 0; |
535 | len = 0; | 535 | len = 0; |
@@ -559,7 +559,7 @@ static void pnpbios_encode_fixed_mem32(struct pnp_dev *dev, unsigned char *p, | |||
559 | 559 | ||
560 | if (pnp_resource_enabled(res)) { | 560 | if (pnp_resource_enabled(res)) { |
561 | base = res->start; | 561 | base = res->start; |
562 | len = res->end - res->start + 1; | 562 | len = resource_size(res); |
563 | } else { | 563 | } else { |
564 | base = 0; | 564 | base = 0; |
565 | len = 0; | 565 | len = 0; |
@@ -617,7 +617,7 @@ static void pnpbios_encode_port(struct pnp_dev *dev, unsigned char *p, | |||
617 | 617 | ||
618 | if (pnp_resource_enabled(res)) { | 618 | if (pnp_resource_enabled(res)) { |
619 | base = res->start; | 619 | base = res->start; |
620 | len = res->end - res->start + 1; | 620 | len = resource_size(res); |
621 | } else { | 621 | } else { |
622 | base = 0; | 622 | base = 0; |
623 | len = 0; | 623 | len = 0; |
@@ -636,11 +636,11 @@ static void pnpbios_encode_fixed_port(struct pnp_dev *dev, unsigned char *p, | |||
636 | struct resource *res) | 636 | struct resource *res) |
637 | { | 637 | { |
638 | unsigned long base = res->start; | 638 | unsigned long base = res->start; |
639 | unsigned long len = res->end - res->start + 1; | 639 | unsigned long len = resource_size(res); |
640 | 640 | ||
641 | if (pnp_resource_enabled(res)) { | 641 | if (pnp_resource_enabled(res)) { |
642 | base = res->start; | 642 | base = res->start; |
643 | len = res->end - res->start + 1; | 643 | len = resource_size(res); |
644 | } else { | 644 | } else { |
645 | base = 0; | 645 | base = 0; |
646 | len = 0; | 646 | len = 0; |
diff --git a/drivers/power/ds2782_battery.c b/drivers/power/ds2782_battery.c index 4d2dc4fa2888..bfbce5de49da 100644 --- a/drivers/power/ds2782_battery.c +++ b/drivers/power/ds2782_battery.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * | 3 | * |
4 | * Copyright (C) 2009 Bluewater Systems Ltd | 4 | * Copyright (C) 2009 Bluewater Systems Ltd |
5 | * | 5 | * |
6 | * Author: Ryan Mallon <ryan@bluewatersys.com> | 6 | * Author: Ryan Mallon |
7 | * | 7 | * |
8 | * DS2786 added by Yulia Vilensky <vilensky@compulab.co.il> | 8 | * DS2786 added by Yulia Vilensky <vilensky@compulab.co.il> |
9 | * | 9 | * |
@@ -416,6 +416,6 @@ static void __exit ds278x_exit(void) | |||
416 | } | 416 | } |
417 | module_exit(ds278x_exit); | 417 | module_exit(ds278x_exit); |
418 | 418 | ||
419 | MODULE_AUTHOR("Ryan Mallon <ryan@bluewatersys.com>"); | 419 | MODULE_AUTHOR("Ryan Mallon"); |
420 | MODULE_DESCRIPTION("Maxim/Dallas DS2782 Stand-Alone Fuel Gauage IC driver"); | 420 | MODULE_DESCRIPTION("Maxim/Dallas DS2782 Stand-Alone Fuel Gauage IC driver"); |
421 | MODULE_LICENSE("GPL"); | 421 | MODULE_LICENSE("GPL"); |
diff --git a/drivers/rtc/rtc-at32ap700x.c b/drivers/rtc/rtc-at32ap700x.c index e725d51e773d..8dd08305aae1 100644 --- a/drivers/rtc/rtc-at32ap700x.c +++ b/drivers/rtc/rtc-at32ap700x.c | |||
@@ -223,7 +223,7 @@ static int __init at32_rtc_probe(struct platform_device *pdev) | |||
223 | } | 223 | } |
224 | 224 | ||
225 | rtc->irq = irq; | 225 | rtc->irq = irq; |
226 | rtc->regs = ioremap(regs->start, regs->end - regs->start + 1); | 226 | rtc->regs = ioremap(regs->start, resource_size(regs)); |
227 | if (!rtc->regs) { | 227 | if (!rtc->regs) { |
228 | ret = -ENOMEM; | 228 | ret = -ENOMEM; |
229 | dev_dbg(&pdev->dev, "could not map I/O memory\n"); | 229 | dev_dbg(&pdev->dev, "could not map I/O memory\n"); |
diff --git a/drivers/rtc/rtc-cmos.c b/drivers/rtc/rtc-cmos.c index 911e75cdc125..05beb6c1ca79 100644 --- a/drivers/rtc/rtc-cmos.c +++ b/drivers/rtc/rtc-cmos.c | |||
@@ -606,7 +606,7 @@ cmos_do_probe(struct device *dev, struct resource *ports, int rtc_irq) | |||
606 | * (needing ioremap etc), not i/o space resources like this ... | 606 | * (needing ioremap etc), not i/o space resources like this ... |
607 | */ | 607 | */ |
608 | ports = request_region(ports->start, | 608 | ports = request_region(ports->start, |
609 | ports->end + 1 - ports->start, | 609 | resource_size(ports), |
610 | driver_name); | 610 | driver_name); |
611 | if (!ports) { | 611 | if (!ports) { |
612 | dev_dbg(dev, "i/o registers already in use\n"); | 612 | dev_dbg(dev, "i/o registers already in use\n"); |
@@ -750,7 +750,7 @@ cleanup1: | |||
750 | cmos_rtc.dev = NULL; | 750 | cmos_rtc.dev = NULL; |
751 | rtc_device_unregister(cmos_rtc.rtc); | 751 | rtc_device_unregister(cmos_rtc.rtc); |
752 | cleanup0: | 752 | cleanup0: |
753 | release_region(ports->start, ports->end + 1 - ports->start); | 753 | release_region(ports->start, resource_size(ports)); |
754 | return retval; | 754 | return retval; |
755 | } | 755 | } |
756 | 756 | ||
@@ -779,7 +779,7 @@ static void __exit cmos_do_remove(struct device *dev) | |||
779 | cmos->rtc = NULL; | 779 | cmos->rtc = NULL; |
780 | 780 | ||
781 | ports = cmos->iomem; | 781 | ports = cmos->iomem; |
782 | release_region(ports->start, ports->end + 1 - ports->start); | 782 | release_region(ports->start, resource_size(ports)); |
783 | cmos->iomem = NULL; | 783 | cmos->iomem = NULL; |
784 | 784 | ||
785 | cmos->dev = NULL; | 785 | cmos->dev = NULL; |
diff --git a/drivers/rtc/rtc-ds1286.c b/drivers/rtc/rtc-ds1286.c index 47e681df31e2..68e6caf25496 100644 --- a/drivers/rtc/rtc-ds1286.c +++ b/drivers/rtc/rtc-ds1286.c | |||
@@ -343,7 +343,7 @@ static int __devinit ds1286_probe(struct platform_device *pdev) | |||
343 | if (!priv) | 343 | if (!priv) |
344 | return -ENOMEM; | 344 | return -ENOMEM; |
345 | 345 | ||
346 | priv->size = res->end - res->start + 1; | 346 | priv->size = resource_size(res); |
347 | if (!request_mem_region(res->start, priv->size, pdev->name)) { | 347 | if (!request_mem_region(res->start, priv->size, pdev->name)) { |
348 | ret = -EBUSY; | 348 | ret = -EBUSY; |
349 | goto out; | 349 | goto out; |
diff --git a/drivers/rtc/rtc-ds1511.c b/drivers/rtc/rtc-ds1511.c index fbabc773dded..568ad30617e7 100644 --- a/drivers/rtc/rtc-ds1511.c +++ b/drivers/rtc/rtc-ds1511.c | |||
@@ -490,7 +490,7 @@ ds1511_rtc_probe(struct platform_device *pdev) | |||
490 | pdata = devm_kzalloc(&pdev->dev, sizeof(*pdata), GFP_KERNEL); | 490 | pdata = devm_kzalloc(&pdev->dev, sizeof(*pdata), GFP_KERNEL); |
491 | if (!pdata) | 491 | if (!pdata) |
492 | return -ENOMEM; | 492 | return -ENOMEM; |
493 | pdata->size = res->end - res->start + 1; | 493 | pdata->size = resource_size(res); |
494 | if (!devm_request_mem_region(&pdev->dev, res->start, pdata->size, | 494 | if (!devm_request_mem_region(&pdev->dev, res->start, pdata->size, |
495 | pdev->name)) | 495 | pdev->name)) |
496 | return -EBUSY; | 496 | return -EBUSY; |
diff --git a/drivers/rtc/rtc-ds1742.c b/drivers/rtc/rtc-ds1742.c index 042630c90dd3..d84a448dd754 100644 --- a/drivers/rtc/rtc-ds1742.c +++ b/drivers/rtc/rtc-ds1742.c | |||
@@ -173,7 +173,7 @@ static int __devinit ds1742_rtc_probe(struct platform_device *pdev) | |||
173 | pdata = devm_kzalloc(&pdev->dev, sizeof(*pdata), GFP_KERNEL); | 173 | pdata = devm_kzalloc(&pdev->dev, sizeof(*pdata), GFP_KERNEL); |
174 | if (!pdata) | 174 | if (!pdata) |
175 | return -ENOMEM; | 175 | return -ENOMEM; |
176 | pdata->size = res->end - res->start + 1; | 176 | pdata->size = resource_size(res); |
177 | if (!devm_request_mem_region(&pdev->dev, res->start, pdata->size, | 177 | if (!devm_request_mem_region(&pdev->dev, res->start, pdata->size, |
178 | pdev->name)) | 178 | pdev->name)) |
179 | return -EBUSY; | 179 | return -EBUSY; |
diff --git a/drivers/rtc/rtc-m48t35.c b/drivers/rtc/rtc-m48t35.c index 7410875e5838..8e2a24e33ed6 100644 --- a/drivers/rtc/rtc-m48t35.c +++ b/drivers/rtc/rtc-m48t35.c | |||
@@ -154,7 +154,7 @@ static int __devinit m48t35_probe(struct platform_device *pdev) | |||
154 | if (!priv) | 154 | if (!priv) |
155 | return -ENOMEM; | 155 | return -ENOMEM; |
156 | 156 | ||
157 | priv->size = res->end - res->start + 1; | 157 | priv->size = resource_size(res); |
158 | /* | 158 | /* |
159 | * kludge: remove the #ifndef after ioc3 resource | 159 | * kludge: remove the #ifndef after ioc3 resource |
160 | * conflicts are resolved | 160 | * conflicts are resolved |
diff --git a/drivers/rtc/rtc-m48t59.c b/drivers/rtc/rtc-m48t59.c index 3978f4caf724..28365388fb6c 100644 --- a/drivers/rtc/rtc-m48t59.c +++ b/drivers/rtc/rtc-m48t59.c | |||
@@ -433,7 +433,7 @@ static int __devinit m48t59_rtc_probe(struct platform_device *pdev) | |||
433 | 433 | ||
434 | if (!m48t59->ioaddr) { | 434 | if (!m48t59->ioaddr) { |
435 | /* ioaddr not mapped externally */ | 435 | /* ioaddr not mapped externally */ |
436 | m48t59->ioaddr = ioremap(res->start, res->end - res->start + 1); | 436 | m48t59->ioaddr = ioremap(res->start, resource_size(res)); |
437 | if (!m48t59->ioaddr) | 437 | if (!m48t59->ioaddr) |
438 | goto out; | 438 | goto out; |
439 | } | 439 | } |
diff --git a/drivers/rtc/rtc-mrst.c b/drivers/rtc/rtc-mrst.c index 0cec5650d56a..d33544802a2e 100644 --- a/drivers/rtc/rtc-mrst.c +++ b/drivers/rtc/rtc-mrst.c | |||
@@ -332,9 +332,8 @@ vrtc_mrst_do_probe(struct device *dev, struct resource *iomem, int rtc_irq) | |||
332 | if (!iomem) | 332 | if (!iomem) |
333 | return -ENODEV; | 333 | return -ENODEV; |
334 | 334 | ||
335 | iomem = request_mem_region(iomem->start, | 335 | iomem = request_mem_region(iomem->start, resource_size(iomem), |
336 | iomem->end + 1 - iomem->start, | 336 | driver_name); |
337 | driver_name); | ||
338 | if (!iomem) { | 337 | if (!iomem) { |
339 | dev_dbg(dev, "i/o mem already in use.\n"); | 338 | dev_dbg(dev, "i/o mem already in use.\n"); |
340 | return -EBUSY; | 339 | return -EBUSY; |
diff --git a/drivers/rtc/rtc-puv3.c b/drivers/rtc/rtc-puv3.c index 46f14b82f3ab..b3eba3cddd42 100644 --- a/drivers/rtc/rtc-puv3.c +++ b/drivers/rtc/rtc-puv3.c | |||
@@ -267,9 +267,8 @@ static int puv3_rtc_probe(struct platform_device *pdev) | |||
267 | return -ENOENT; | 267 | return -ENOENT; |
268 | } | 268 | } |
269 | 269 | ||
270 | puv3_rtc_mem = request_mem_region(res->start, | 270 | puv3_rtc_mem = request_mem_region(res->start, resource_size(res), |
271 | res->end-res->start+1, | 271 | pdev->name); |
272 | pdev->name); | ||
273 | 272 | ||
274 | if (puv3_rtc_mem == NULL) { | 273 | if (puv3_rtc_mem == NULL) { |
275 | dev_err(&pdev->dev, "failed to reserve memory region\n"); | 274 | dev_err(&pdev->dev, "failed to reserve memory region\n"); |
diff --git a/drivers/rtc/rtc-s3c.c b/drivers/rtc/rtc-s3c.c index 16512ecae31a..2a65e85e0f56 100644 --- a/drivers/rtc/rtc-s3c.c +++ b/drivers/rtc/rtc-s3c.c | |||
@@ -455,8 +455,7 @@ static int __devinit s3c_rtc_probe(struct platform_device *pdev) | |||
455 | return -ENOENT; | 455 | return -ENOENT; |
456 | } | 456 | } |
457 | 457 | ||
458 | s3c_rtc_mem = request_mem_region(res->start, | 458 | s3c_rtc_mem = request_mem_region(res->start, resource_size(res), |
459 | res->end-res->start+1, | ||
460 | pdev->name); | 459 | pdev->name); |
461 | 460 | ||
462 | if (s3c_rtc_mem == NULL) { | 461 | if (s3c_rtc_mem == NULL) { |
@@ -465,7 +464,7 @@ static int __devinit s3c_rtc_probe(struct platform_device *pdev) | |||
465 | goto err_nores; | 464 | goto err_nores; |
466 | } | 465 | } |
467 | 466 | ||
468 | s3c_rtc_base = ioremap(res->start, res->end - res->start + 1); | 467 | s3c_rtc_base = ioremap(res->start, resource_size(res)); |
469 | if (s3c_rtc_base == NULL) { | 468 | if (s3c_rtc_base == NULL) { |
470 | dev_err(&pdev->dev, "failed ioremap()\n"); | 469 | dev_err(&pdev->dev, "failed ioremap()\n"); |
471 | ret = -EINVAL; | 470 | ret = -EINVAL; |
diff --git a/drivers/scsi/device_handler/scsi_dh_rdac.c b/drivers/scsi/device_handler/scsi_dh_rdac.c index e7fc70d6b478..2e7c136bb805 100644 --- a/drivers/scsi/device_handler/scsi_dh_rdac.c +++ b/drivers/scsi/device_handler/scsi_dh_rdac.c | |||
@@ -35,7 +35,7 @@ | |||
35 | * mode page were taken from the LSI RDAC 2.4 GPL'd | 35 | * mode page were taken from the LSI RDAC 2.4 GPL'd |
36 | * driver, and then converted to Linux conventions. | 36 | * driver, and then converted to Linux conventions. |
37 | */ | 37 | */ |
38 | #define RDAC_QUIESCENCE_TIME 20; | 38 | #define RDAC_QUIESCENCE_TIME 20 |
39 | /* | 39 | /* |
40 | * Page Codes | 40 | * Page Codes |
41 | */ | 41 | */ |
diff --git a/drivers/scsi/lpfc/lpfc_hw.h b/drivers/scsi/lpfc/lpfc_hw.h index 9059524cf225..ab4c4d651d0c 100644 --- a/drivers/scsi/lpfc/lpfc_hw.h +++ b/drivers/scsi/lpfc/lpfc_hw.h | |||
@@ -2955,18 +2955,18 @@ typedef struct _SLI2_RDSC { | |||
2955 | typedef struct _PCB { | 2955 | typedef struct _PCB { |
2956 | #ifdef __BIG_ENDIAN_BITFIELD | 2956 | #ifdef __BIG_ENDIAN_BITFIELD |
2957 | uint32_t type:8; | 2957 | uint32_t type:8; |
2958 | #define TYPE_NATIVE_SLI2 0x01; | 2958 | #define TYPE_NATIVE_SLI2 0x01 |
2959 | uint32_t feature:8; | 2959 | uint32_t feature:8; |
2960 | #define FEATURE_INITIAL_SLI2 0x01; | 2960 | #define FEATURE_INITIAL_SLI2 0x01 |
2961 | uint32_t rsvd:12; | 2961 | uint32_t rsvd:12; |
2962 | uint32_t maxRing:4; | 2962 | uint32_t maxRing:4; |
2963 | #else /* __LITTLE_ENDIAN_BITFIELD */ | 2963 | #else /* __LITTLE_ENDIAN_BITFIELD */ |
2964 | uint32_t maxRing:4; | 2964 | uint32_t maxRing:4; |
2965 | uint32_t rsvd:12; | 2965 | uint32_t rsvd:12; |
2966 | uint32_t feature:8; | 2966 | uint32_t feature:8; |
2967 | #define FEATURE_INITIAL_SLI2 0x01; | 2967 | #define FEATURE_INITIAL_SLI2 0x01 |
2968 | uint32_t type:8; | 2968 | uint32_t type:8; |
2969 | #define TYPE_NATIVE_SLI2 0x01; | 2969 | #define TYPE_NATIVE_SLI2 0x01 |
2970 | #endif | 2970 | #endif |
2971 | 2971 | ||
2972 | uint32_t mailBoxSize; | 2972 | uint32_t mailBoxSize; |
diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c index 1b60a95adb50..ae8e298746ba 100644 --- a/drivers/scsi/qla2xxx/qla_isr.c +++ b/drivers/scsi/qla2xxx/qla_isr.c | |||
@@ -63,7 +63,7 @@ qla2100_intr_handler(int irq, void *dev_id) | |||
63 | 63 | ||
64 | /* | 64 | /* |
65 | * Issue a "HARD" reset in order for the RISC interrupt | 65 | * Issue a "HARD" reset in order for the RISC interrupt |
66 | * bit to be cleared. Schedule a big hammmer to get | 66 | * bit to be cleared. Schedule a big hammer to get |
67 | * out of the RISC PAUSED state. | 67 | * out of the RISC PAUSED state. |
68 | */ | 68 | */ |
69 | WRT_REG_WORD(®->hccr, HCCR_RESET_RISC); | 69 | WRT_REG_WORD(®->hccr, HCCR_RESET_RISC); |
@@ -169,7 +169,7 @@ qla2300_intr_handler(int irq, void *dev_id) | |||
169 | /* | 169 | /* |
170 | * Issue a "HARD" reset in order for the RISC | 170 | * Issue a "HARD" reset in order for the RISC |
171 | * interrupt bit to be cleared. Schedule a big | 171 | * interrupt bit to be cleared. Schedule a big |
172 | * hammmer to get out of the RISC PAUSED state. | 172 | * hammer to get out of the RISC PAUSED state. |
173 | */ | 173 | */ |
174 | WRT_REG_WORD(®->hccr, HCCR_RESET_RISC); | 174 | WRT_REG_WORD(®->hccr, HCCR_RESET_RISC); |
175 | RD_REG_WORD(®->hccr); | 175 | RD_REG_WORD(®->hccr); |
diff --git a/drivers/ssb/b43_pci_bridge.c b/drivers/ssb/b43_pci_bridge.c index 744d3f6e4709..bf53e44c82a1 100644 --- a/drivers/ssb/b43_pci_bridge.c +++ b/drivers/ssb/b43_pci_bridge.c | |||
@@ -5,7 +5,7 @@ | |||
5 | * because of its small size we include it in the SSB core | 5 | * because of its small size we include it in the SSB core |
6 | * instead of creating a standalone module. | 6 | * instead of creating a standalone module. |
7 | * | 7 | * |
8 | * Copyright 2007 Michael Buesch <mb@bu3sch.de> | 8 | * Copyright 2007 Michael Buesch <m@bues.ch> |
9 | * | 9 | * |
10 | * Licensed under the GNU/GPL. See COPYING for details. | 10 | * Licensed under the GNU/GPL. See COPYING for details. |
11 | */ | 11 | */ |
diff --git a/drivers/ssb/driver_chipcommon.c b/drivers/ssb/driver_chipcommon.c index 06d15b6f2215..5d9c97c24797 100644 --- a/drivers/ssb/driver_chipcommon.c +++ b/drivers/ssb/driver_chipcommon.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * Broadcom ChipCommon core driver | 3 | * Broadcom ChipCommon core driver |
4 | * | 4 | * |
5 | * Copyright 2005, Broadcom Corporation | 5 | * Copyright 2005, Broadcom Corporation |
6 | * Copyright 2006, 2007, Michael Buesch <mb@bu3sch.de> | 6 | * Copyright 2006, 2007, Michael Buesch <m@bues.ch> |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
9 | */ | 9 | */ |
diff --git a/drivers/ssb/driver_chipcommon_pmu.c b/drivers/ssb/driver_chipcommon_pmu.c index a7aef47bf739..52901c14c68b 100644 --- a/drivers/ssb/driver_chipcommon_pmu.c +++ b/drivers/ssb/driver_chipcommon_pmu.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * Sonics Silicon Backplane | 2 | * Sonics Silicon Backplane |
3 | * Broadcom ChipCommon Power Management Unit driver | 3 | * Broadcom ChipCommon Power Management Unit driver |
4 | * | 4 | * |
5 | * Copyright 2009, Michael Buesch <mb@bu3sch.de> | 5 | * Copyright 2009, Michael Buesch <m@bues.ch> |
6 | * Copyright 2007, Broadcom Corporation | 6 | * Copyright 2007, Broadcom Corporation |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
diff --git a/drivers/ssb/driver_extif.c b/drivers/ssb/driver_extif.c index c3e1d3e6d610..dc47f30e9cf7 100644 --- a/drivers/ssb/driver_extif.c +++ b/drivers/ssb/driver_extif.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * Broadcom EXTIF core driver | 3 | * Broadcom EXTIF core driver |
4 | * | 4 | * |
5 | * Copyright 2005, Broadcom Corporation | 5 | * Copyright 2005, Broadcom Corporation |
6 | * Copyright 2006, 2007, Michael Buesch <mb@bu3sch.de> | 6 | * Copyright 2006, 2007, Michael Buesch <m@bues.ch> |
7 | * Copyright 2006, 2007, Felix Fietkau <nbd@openwrt.org> | 7 | * Copyright 2006, 2007, Felix Fietkau <nbd@openwrt.org> |
8 | * Copyright 2007, Aurelien Jarno <aurelien@aurel32.net> | 8 | * Copyright 2007, Aurelien Jarno <aurelien@aurel32.net> |
9 | * | 9 | * |
diff --git a/drivers/ssb/driver_gige.c b/drivers/ssb/driver_gige.c index d75890909222..3adb98dad70c 100644 --- a/drivers/ssb/driver_gige.c +++ b/drivers/ssb/driver_gige.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * Broadcom Gigabit Ethernet core driver | 3 | * Broadcom Gigabit Ethernet core driver |
4 | * | 4 | * |
5 | * Copyright 2008, Broadcom Corporation | 5 | * Copyright 2008, Broadcom Corporation |
6 | * Copyright 2008, Michael Buesch <mb@bu3sch.de> | 6 | * Copyright 2008, Michael Buesch <m@bues.ch> |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
9 | */ | 9 | */ |
diff --git a/drivers/ssb/driver_mipscore.c b/drivers/ssb/driver_mipscore.c index 97efce184a8f..ced501568594 100644 --- a/drivers/ssb/driver_mipscore.c +++ b/drivers/ssb/driver_mipscore.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * Broadcom MIPS core driver | 3 | * Broadcom MIPS core driver |
4 | * | 4 | * |
5 | * Copyright 2005, Broadcom Corporation | 5 | * Copyright 2005, Broadcom Corporation |
6 | * Copyright 2006, 2007, Michael Buesch <mb@bu3sch.de> | 6 | * Copyright 2006, 2007, Michael Buesch <m@bues.ch> |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
9 | */ | 9 | */ |
diff --git a/drivers/ssb/driver_pcicore.c b/drivers/ssb/driver_pcicore.c index 11d85bfd774e..e6ac3177fbbe 100644 --- a/drivers/ssb/driver_pcicore.c +++ b/drivers/ssb/driver_pcicore.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * Broadcom PCI-core driver | 3 | * Broadcom PCI-core driver |
4 | * | 4 | * |
5 | * Copyright 2005, Broadcom Corporation | 5 | * Copyright 2005, Broadcom Corporation |
6 | * Copyright 2006, 2007, Michael Buesch <mb@bu3sch.de> | 6 | * Copyright 2006, 2007, Michael Buesch <m@bues.ch> |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
9 | */ | 9 | */ |
diff --git a/drivers/ssb/embedded.c b/drivers/ssb/embedded.c index a0e0d246b592..eec3e267be4d 100644 --- a/drivers/ssb/embedded.c +++ b/drivers/ssb/embedded.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * Embedded systems support code | 3 | * Embedded systems support code |
4 | * | 4 | * |
5 | * Copyright 2005-2008, Broadcom Corporation | 5 | * Copyright 2005-2008, Broadcom Corporation |
6 | * Copyright 2006-2008, Michael Buesch <mb@bu3sch.de> | 6 | * Copyright 2006-2008, Michael Buesch <m@bues.ch> |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
9 | */ | 9 | */ |
diff --git a/drivers/ssb/main.c b/drivers/ssb/main.c index 6ec6e099fe04..29c7d4f9d1ae 100644 --- a/drivers/ssb/main.c +++ b/drivers/ssb/main.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * Subsystem core | 3 | * Subsystem core |
4 | * | 4 | * |
5 | * Copyright 2005, Broadcom Corporation | 5 | * Copyright 2005, Broadcom Corporation |
6 | * Copyright 2006, 2007, Michael Buesch <mb@bu3sch.de> | 6 | * Copyright 2006, 2007, Michael Buesch <m@bues.ch> |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
9 | */ | 9 | */ |
diff --git a/drivers/ssb/pci.c b/drivers/ssb/pci.c index a00b35f03084..34c3bab90b9a 100644 --- a/drivers/ssb/pci.c +++ b/drivers/ssb/pci.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * Sonics Silicon Backplane PCI-Hostbus related functions. | 2 | * Sonics Silicon Backplane PCI-Hostbus related functions. |
3 | * | 3 | * |
4 | * Copyright (C) 2005-2006 Michael Buesch <mb@bu3sch.de> | 4 | * Copyright (C) 2005-2006 Michael Buesch <m@bues.ch> |
5 | * Copyright (C) 2005 Martin Langer <martin-langer@gmx.de> | 5 | * Copyright (C) 2005 Martin Langer <martin-langer@gmx.de> |
6 | * Copyright (C) 2005 Stefano Brivio <st3@riseup.net> | 6 | * Copyright (C) 2005 Stefano Brivio <st3@riseup.net> |
7 | * Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org> | 7 | * Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org> |
diff --git a/drivers/ssb/pcihost_wrapper.c b/drivers/ssb/pcihost_wrapper.c index d7a98131ebf3..116a8116984b 100644 --- a/drivers/ssb/pcihost_wrapper.c +++ b/drivers/ssb/pcihost_wrapper.c | |||
@@ -6,7 +6,7 @@ | |||
6 | * Copyright (c) 2005 Stefano Brivio <st3@riseup.net> | 6 | * Copyright (c) 2005 Stefano Brivio <st3@riseup.net> |
7 | * Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> | 7 | * Copyright (c) 2005 Danny van Dyk <kugelfang@gentoo.org> |
8 | * Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> | 8 | * Copyright (c) 2005 Andreas Jaggi <andreas.jaggi@waterwave.ch> |
9 | * Copyright (c) 2005-2007 Michael Buesch <mbuesch@freenet.de> | 9 | * Copyright (c) 2005-2007 Michael Buesch <m@bues.ch> |
10 | * | 10 | * |
11 | * Licensed under the GNU/GPL. See COPYING for details. | 11 | * Licensed under the GNU/GPL. See COPYING for details. |
12 | */ | 12 | */ |
diff --git a/drivers/ssb/pcmcia.c b/drivers/ssb/pcmcia.c index f8533795ee7f..c821c6b2a6a0 100644 --- a/drivers/ssb/pcmcia.c +++ b/drivers/ssb/pcmcia.c | |||
@@ -3,7 +3,7 @@ | |||
3 | * PCMCIA-Hostbus related functions | 3 | * PCMCIA-Hostbus related functions |
4 | * | 4 | * |
5 | * Copyright 2006 Johannes Berg <johannes@sipsolutions.net> | 5 | * Copyright 2006 Johannes Berg <johannes@sipsolutions.net> |
6 | * Copyright 2007-2008 Michael Buesch <mb@bu3sch.de> | 6 | * Copyright 2007-2008 Michael Buesch <m@bues.ch> |
7 | * | 7 | * |
8 | * Licensed under the GNU/GPL. See COPYING for details. | 8 | * Licensed under the GNU/GPL. See COPYING for details. |
9 | */ | 9 | */ |
diff --git a/drivers/ssb/scan.c b/drivers/ssb/scan.c index 8047f9aaa4b2..3e844874631f 100644 --- a/drivers/ssb/scan.c +++ b/drivers/ssb/scan.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * Sonics Silicon Backplane | 2 | * Sonics Silicon Backplane |
3 | * Bus scanning | 3 | * Bus scanning |
4 | * | 4 | * |
5 | * Copyright (C) 2005-2007 Michael Buesch <mb@bu3sch.de> | 5 | * Copyright (C) 2005-2007 Michael Buesch <m@bues.ch> |
6 | * Copyright (C) 2005 Martin Langer <martin-langer@gmx.de> | 6 | * Copyright (C) 2005 Martin Langer <martin-langer@gmx.de> |
7 | * Copyright (C) 2005 Stefano Brivio <st3@riseup.net> | 7 | * Copyright (C) 2005 Stefano Brivio <st3@riseup.net> |
8 | * Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org> | 8 | * Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org> |
diff --git a/drivers/ssb/sdio.c b/drivers/ssb/sdio.c index 65a6080cb02a..63fd709038ca 100644 --- a/drivers/ssb/sdio.c +++ b/drivers/ssb/sdio.c | |||
@@ -6,7 +6,7 @@ | |||
6 | * | 6 | * |
7 | * Based on drivers/ssb/pcmcia.c | 7 | * Based on drivers/ssb/pcmcia.c |
8 | * Copyright 2006 Johannes Berg <johannes@sipsolutions.net> | 8 | * Copyright 2006 Johannes Berg <johannes@sipsolutions.net> |
9 | * Copyright 2007-2008 Michael Buesch <mb@bu3sch.de> | 9 | * Copyright 2007-2008 Michael Buesch <m@bues.ch> |
10 | * | 10 | * |
11 | * Licensed under the GNU/GPL. See COPYING for details. | 11 | * Licensed under the GNU/GPL. See COPYING for details. |
12 | * | 12 | * |
diff --git a/drivers/ssb/sprom.c b/drivers/ssb/sprom.c index 45ff0e3a3828..80d366fcf8d3 100644 --- a/drivers/ssb/sprom.c +++ b/drivers/ssb/sprom.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * Sonics Silicon Backplane | 2 | * Sonics Silicon Backplane |
3 | * Common SPROM support routines | 3 | * Common SPROM support routines |
4 | * | 4 | * |
5 | * Copyright (C) 2005-2008 Michael Buesch <mb@bu3sch.de> | 5 | * Copyright (C) 2005-2008 Michael Buesch <m@bues.ch> |
6 | * Copyright (C) 2005 Martin Langer <martin-langer@gmx.de> | 6 | * Copyright (C) 2005 Martin Langer <martin-langer@gmx.de> |
7 | * Copyright (C) 2005 Stefano Brivio <st3@riseup.net> | 7 | * Copyright (C) 2005 Stefano Brivio <st3@riseup.net> |
8 | * Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org> | 8 | * Copyright (C) 2005 Danny van Dyk <kugelfang@gentoo.org> |
diff --git a/drivers/staging/ath6kl/os/linux/include/ar6000_drv.h b/drivers/staging/ath6kl/os/linux/include/ar6000_drv.h index 22453b0873e4..11dc39c6987a 100644 --- a/drivers/staging/ath6kl/os/linux/include/ar6000_drv.h +++ b/drivers/staging/ath6kl/os/linux/include/ar6000_drv.h | |||
@@ -52,7 +52,6 @@ | |||
52 | #include "aggr_recv_api.h" | 52 | #include "aggr_recv_api.h" |
53 | #include <host_version.h> | 53 | #include <host_version.h> |
54 | #include <linux/rtnetlink.h> | 54 | #include <linux/rtnetlink.h> |
55 | #include <linux/init.h> | ||
56 | #include <linux/moduleparam.h> | 55 | #include <linux/moduleparam.h> |
57 | #include "ar6000_api.h" | 56 | #include "ar6000_api.h" |
58 | #ifdef CONFIG_HOST_TCMD_SUPPORT | 57 | #ifdef CONFIG_HOST_TCMD_SUPPORT |
diff --git a/drivers/staging/bcm/headers.h b/drivers/staging/bcm/headers.h index 1148e5e22eb9..8fe8d2b1f627 100644 --- a/drivers/staging/bcm/headers.h +++ b/drivers/staging/bcm/headers.h | |||
@@ -20,25 +20,23 @@ | |||
20 | #include <linux/file.h> | 20 | #include <linux/file.h> |
21 | #include <linux/string.h> | 21 | #include <linux/string.h> |
22 | #include <linux/etherdevice.h> | 22 | #include <linux/etherdevice.h> |
23 | #include <net/ip.h> | ||
24 | #include <linux/wait.h> | 23 | #include <linux/wait.h> |
25 | #include <linux/proc_fs.h> | 24 | #include <linux/proc_fs.h> |
26 | #include <linux/interrupt.h> | 25 | #include <linux/interrupt.h> |
27 | |||
28 | #include <linux/version.h> | 26 | #include <linux/version.h> |
29 | #include <linux/stddef.h> | 27 | #include <linux/stddef.h> |
30 | #include <linux/kernel.h> | ||
31 | #include <linux/stat.h> | 28 | #include <linux/stat.h> |
32 | #include <linux/fcntl.h> | 29 | #include <linux/fcntl.h> |
33 | #include <linux/unistd.h> | 30 | #include <linux/unistd.h> |
34 | #include <linux/sched.h> | 31 | #include <linux/sched.h> |
35 | #include <linux/mm.h> | 32 | #include <linux/mm.h> |
36 | #include <linux/pagemap.h> | 33 | #include <linux/pagemap.h> |
37 | #include <asm/uaccess.h> | ||
38 | #include <linux/kthread.h> | 34 | #include <linux/kthread.h> |
39 | #include <linux/tcp.h> | 35 | #include <linux/tcp.h> |
40 | #include <linux/udp.h> | 36 | #include <linux/udp.h> |
41 | #include <linux/usb.h> | 37 | #include <linux/usb.h> |
38 | #include <asm/uaccess.h> | ||
39 | #include <net/ip.h> | ||
42 | 40 | ||
43 | #include "Typedefs.h" | 41 | #include "Typedefs.h" |
44 | #include "Version.h" | 42 | #include "Version.h" |
@@ -61,7 +59,6 @@ | |||
61 | #include "Queue.h" | 59 | #include "Queue.h" |
62 | #include "vendorspecificextn.h" | 60 | #include "vendorspecificextn.h" |
63 | 61 | ||
64 | |||
65 | #include "InterfaceMacros.h" | 62 | #include "InterfaceMacros.h" |
66 | #include "InterfaceAdapter.h" | 63 | #include "InterfaceAdapter.h" |
67 | #include "InterfaceIsr.h" | 64 | #include "InterfaceIsr.h" |
diff --git a/drivers/staging/brcm80211/brcmfmac/dhd_sdio.c b/drivers/staging/brcm80211/brcmfmac/dhd_sdio.c index a71c6f8ee8a3..8cbfeae464b1 100644 --- a/drivers/staging/brcm80211/brcmfmac/dhd_sdio.c +++ b/drivers/staging/brcm80211/brcmfmac/dhd_sdio.c | |||
@@ -26,7 +26,6 @@ | |||
26 | #include BCMEMBEDIMAGE | 26 | #include BCMEMBEDIMAGE |
27 | #endif /* BCMEMBEDIMAGE */ | 27 | #endif /* BCMEMBEDIMAGE */ |
28 | 28 | ||
29 | #include <bcmdefs.h> | ||
30 | #include <bcmutils.h> | 29 | #include <bcmutils.h> |
31 | #include <bcmdevs.h> | 30 | #include <bcmdevs.h> |
32 | 31 | ||
diff --git a/drivers/staging/brcm80211/brcmfmac/wl_cfg80211.h b/drivers/staging/brcm80211/brcmfmac/wl_cfg80211.h index 996033cf9b09..d4bcc1edddb2 100644 --- a/drivers/staging/brcm80211/brcmfmac/wl_cfg80211.h +++ b/drivers/staging/brcm80211/brcmfmac/wl_cfg80211.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #define _wl_cfg80211_h_ | 18 | #define _wl_cfg80211_h_ |
19 | 19 | ||
20 | #include <linux/wireless.h> | 20 | #include <linux/wireless.h> |
21 | #include <linux/wireless.h> | ||
22 | #include <net/cfg80211.h> | 21 | #include <net/cfg80211.h> |
23 | #include <wlioctl.h> | 22 | #include <wlioctl.h> |
24 | 23 | ||
diff --git a/drivers/staging/brcm80211/brcmfmac/wl_iw.c b/drivers/staging/brcm80211/brcmfmac/wl_iw.c index 35eec917f232..53e6a10655e1 100644 --- a/drivers/staging/brcm80211/brcmfmac/wl_iw.c +++ b/drivers/staging/brcm80211/brcmfmac/wl_iw.c | |||
@@ -20,21 +20,16 @@ | |||
20 | #include <linux/netdevice.h> | 20 | #include <linux/netdevice.h> |
21 | #include <linux/hardirq.h> | 21 | #include <linux/hardirq.h> |
22 | #include <wlioctl.h> | 22 | #include <wlioctl.h> |
23 | |||
24 | #include <bcmutils.h> | 23 | #include <bcmutils.h> |
25 | |||
26 | #include <linux/if_arp.h> | 24 | #include <linux/if_arp.h> |
27 | #include <asm/uaccess.h> | 25 | #include <asm/uaccess.h> |
26 | #include <linux/ieee80211.h> | ||
28 | 27 | ||
29 | #include <dngl_stats.h> | 28 | #include <dngl_stats.h> |
30 | #include <dhd.h> | 29 | #include <dhd.h> |
31 | #include <dhdioctl.h> | 30 | #include <dhdioctl.h> |
32 | #include <linux/ieee80211.h> | ||
33 | typedef const struct si_pub si_t; | ||
34 | #include <wlioctl.h> | ||
35 | 31 | ||
36 | #include <dngl_stats.h> | 32 | typedef const struct si_pub si_t; |
37 | #include <dhd.h> | ||
38 | 33 | ||
39 | #define WL_ERROR(fmt, args...) printk(fmt, ##args) | 34 | #define WL_ERROR(fmt, args...) printk(fmt, ##args) |
40 | #define WL_TRACE(fmt, args...) no_printk(fmt, ##args) | 35 | #define WL_TRACE(fmt, args...) no_printk(fmt, ##args) |
diff --git a/drivers/staging/hv/hv_mouse.c b/drivers/staging/hv/hv_mouse.c index 359e73741c48..b3324d609c8b 100644 --- a/drivers/staging/hv/hv_mouse.c +++ b/drivers/staging/hv/hv_mouse.c | |||
@@ -24,7 +24,6 @@ | |||
24 | #include <linux/hiddev.h> | 24 | #include <linux/hiddev.h> |
25 | #include <linux/pci.h> | 25 | #include <linux/pci.h> |
26 | #include <linux/dmi.h> | 26 | #include <linux/dmi.h> |
27 | #include <linux/delay.h> | ||
28 | 27 | ||
29 | #include "hyperv.h" | 28 | #include "hyperv.h" |
30 | 29 | ||
diff --git a/drivers/staging/hv/tools/hv_kvp_daemon.c b/drivers/staging/hv/tools/hv_kvp_daemon.c index 33f0f1c8ad73..a4a407f7052a 100644 --- a/drivers/staging/hv/tools/hv_kvp_daemon.c +++ b/drivers/staging/hv/tools/hv_kvp_daemon.c | |||
@@ -35,7 +35,6 @@ | |||
35 | #include <arpa/inet.h> | 35 | #include <arpa/inet.h> |
36 | #include <linux/connector.h> | 36 | #include <linux/connector.h> |
37 | #include <linux/netlink.h> | 37 | #include <linux/netlink.h> |
38 | #include <sys/socket.h> | ||
39 | #include <ifaddrs.h> | 38 | #include <ifaddrs.h> |
40 | #include <netdb.h> | 39 | #include <netdb.h> |
41 | #include <syslog.h> | 40 | #include <syslog.h> |
diff --git a/drivers/staging/nvec/nvec.c b/drivers/staging/nvec/nvec.c index 1a94364c48b5..72258e8c64ca 100644 --- a/drivers/staging/nvec/nvec.c +++ b/drivers/staging/nvec/nvec.c | |||
@@ -21,7 +21,6 @@ | |||
21 | #include <linux/semaphore.h> | 21 | #include <linux/semaphore.h> |
22 | #include <linux/list.h> | 22 | #include <linux/list.h> |
23 | #include <linux/notifier.h> | 23 | #include <linux/notifier.h> |
24 | #include <linux/workqueue.h> | ||
25 | #include <linux/platform_device.h> | 24 | #include <linux/platform_device.h> |
26 | #include "nvec.h" | 25 | #include "nvec.h" |
27 | 26 | ||
diff --git a/drivers/staging/rtl8712/drv_types.h b/drivers/staging/rtl8712/drv_types.h index 3bb66dc2eb2c..4f380a64aa85 100644 --- a/drivers/staging/rtl8712/drv_types.h +++ b/drivers/staging/rtl8712/drv_types.h | |||
@@ -29,7 +29,6 @@ struct qos_priv { | |||
29 | 29 | ||
30 | #include "rtl871x_ht.h" | 30 | #include "rtl871x_ht.h" |
31 | #include "rtl871x_cmd.h" | 31 | #include "rtl871x_cmd.h" |
32 | #include "wlan_bssdef.h" | ||
33 | #include "rtl871x_xmit.h" | 32 | #include "rtl871x_xmit.h" |
34 | #include "rtl871x_recv.h" | 33 | #include "rtl871x_recv.h" |
35 | #include "rtl871x_security.h" | 34 | #include "rtl871x_security.h" |
diff --git a/drivers/staging/rtl8712/osdep_service.h b/drivers/staging/rtl8712/osdep_service.h index 3d3f73c5cd5b..505395cff282 100644 --- a/drivers/staging/rtl8712/osdep_service.h +++ b/drivers/staging/rtl8712/osdep_service.h | |||
@@ -22,7 +22,6 @@ | |||
22 | #include <linux/module.h> | 22 | #include <linux/module.h> |
23 | #include <linux/sched.h> | 23 | #include <linux/sched.h> |
24 | #include <linux/kref.h> | 24 | #include <linux/kref.h> |
25 | #include <linux/netdevice.h> | ||
26 | #include <linux/skbuff.h> | 25 | #include <linux/skbuff.h> |
27 | #include <linux/usb.h> | 26 | #include <linux/usb.h> |
28 | #include <linux/usb/ch9.h> | 27 | #include <linux/usb/ch9.h> |
diff --git a/drivers/staging/sep/sep_driver.c b/drivers/staging/sep/sep_driver.c index 52342c17eadd..848b4c57531d 100644 --- a/drivers/staging/sep/sep_driver.c +++ b/drivers/staging/sep/sep_driver.c | |||
@@ -50,7 +50,6 @@ | |||
50 | #include <linux/interrupt.h> | 50 | #include <linux/interrupt.h> |
51 | #include <linux/pagemap.h> | 51 | #include <linux/pagemap.h> |
52 | #include <asm/cacheflush.h> | 52 | #include <asm/cacheflush.h> |
53 | #include <linux/sched.h> | ||
54 | #include <linux/delay.h> | 53 | #include <linux/delay.h> |
55 | #include <linux/jiffies.h> | 54 | #include <linux/jiffies.h> |
56 | #include <linux/rar_register.h> | 55 | #include <linux/rar_register.h> |
diff --git a/drivers/staging/usbip/userspace/src/utils.h b/drivers/staging/usbip/userspace/src/utils.h index 6c29ae945212..991f662720bb 100644 --- a/drivers/staging/usbip/userspace/src/utils.h +++ b/drivers/staging/usbip/userspace/src/utils.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #include <glib.h> | 13 | #include <glib.h> |
14 | #include <unistd.h> | 14 | #include <unistd.h> |
15 | #include <stdio.h> | 15 | #include <stdio.h> |
16 | #include <sys/types.h> | ||
17 | #include <sys/stat.h> | 16 | #include <sys/stat.h> |
18 | #include <fcntl.h> | 17 | #include <fcntl.h> |
19 | #include <stdlib.h> | 18 | #include <stdlib.h> |
diff --git a/drivers/target/tcm_fc/tfc_cmd.c b/drivers/target/tcm_fc/tfc_cmd.c index a6bfb6deba94..09df38b4610c 100644 --- a/drivers/target/tcm_fc/tfc_cmd.c +++ b/drivers/target/tcm_fc/tfc_cmd.c | |||
@@ -45,7 +45,6 @@ | |||
45 | #include <target/target_core_device.h> | 45 | #include <target/target_core_device.h> |
46 | #include <target/target_core_tpg.h> | 46 | #include <target/target_core_tpg.h> |
47 | #include <target/target_core_configfs.h> | 47 | #include <target/target_core_configfs.h> |
48 | #include <target/target_core_base.h> | ||
49 | #include <target/target_core_tmr.h> | 48 | #include <target/target_core_tmr.h> |
50 | #include <target/configfs_macros.h> | 49 | #include <target/configfs_macros.h> |
51 | 50 | ||
diff --git a/drivers/target/tcm_fc/tfc_conf.c b/drivers/target/tcm_fc/tfc_conf.c index d63e3dd3b180..8781d1e423df 100644 --- a/drivers/target/tcm_fc/tfc_conf.c +++ b/drivers/target/tcm_fc/tfc_conf.c | |||
@@ -48,7 +48,6 @@ | |||
48 | #include <target/target_core_device.h> | 48 | #include <target/target_core_device.h> |
49 | #include <target/target_core_tpg.h> | 49 | #include <target/target_core_tpg.h> |
50 | #include <target/target_core_configfs.h> | 50 | #include <target/target_core_configfs.h> |
51 | #include <target/target_core_base.h> | ||
52 | #include <target/configfs_macros.h> | 51 | #include <target/configfs_macros.h> |
53 | 52 | ||
54 | #include "tcm_fc.h" | 53 | #include "tcm_fc.h" |
diff --git a/drivers/target/tcm_fc/tfc_io.c b/drivers/target/tcm_fc/tfc_io.c index 11e6483fc127..8e2a46ddcccb 100644 --- a/drivers/target/tcm_fc/tfc_io.c +++ b/drivers/target/tcm_fc/tfc_io.c | |||
@@ -54,7 +54,6 @@ | |||
54 | #include <target/target_core_device.h> | 54 | #include <target/target_core_device.h> |
55 | #include <target/target_core_tpg.h> | 55 | #include <target/target_core_tpg.h> |
56 | #include <target/target_core_configfs.h> | 56 | #include <target/target_core_configfs.h> |
57 | #include <target/target_core_base.h> | ||
58 | #include <target/configfs_macros.h> | 57 | #include <target/configfs_macros.h> |
59 | 58 | ||
60 | #include "tcm_fc.h" | 59 | #include "tcm_fc.h" |
diff --git a/drivers/target/tcm_fc/tfc_sess.c b/drivers/target/tcm_fc/tfc_sess.c index fbcbb3d1d06b..dbb5eaeee399 100644 --- a/drivers/target/tcm_fc/tfc_sess.c +++ b/drivers/target/tcm_fc/tfc_sess.c | |||
@@ -46,10 +46,8 @@ | |||
46 | #include <target/target_core_device.h> | 46 | #include <target/target_core_device.h> |
47 | #include <target/target_core_tpg.h> | 47 | #include <target/target_core_tpg.h> |
48 | #include <target/target_core_configfs.h> | 48 | #include <target/target_core_configfs.h> |
49 | #include <target/target_core_base.h> | ||
50 | #include <target/configfs_macros.h> | 49 | #include <target/configfs_macros.h> |
51 | 50 | ||
52 | #include <scsi/libfc.h> | ||
53 | #include "tcm_fc.h" | 51 | #include "tcm_fc.h" |
54 | 52 | ||
55 | static void ft_sess_delete_all(struct ft_tport *); | 53 | static void ft_sess_delete_all(struct ft_tport *); |
diff --git a/drivers/tty/serial/8250_pci.c b/drivers/tty/serial/8250_pci.c index f41b4259ecdd..cf35e0dc5085 100644 --- a/drivers/tty/serial/8250_pci.c +++ b/drivers/tty/serial/8250_pci.c | |||
@@ -743,7 +743,7 @@ pci_ni8430_setup(struct serial_private *priv, | |||
743 | len = pci_resource_len(priv->dev, bar); | 743 | len = pci_resource_len(priv->dev, bar); |
744 | p = ioremap_nocache(base, len); | 744 | p = ioremap_nocache(base, len); |
745 | 745 | ||
746 | /* enable the transciever */ | 746 | /* enable the transceiver */ |
747 | writeb(readb(p + offset + NI8430_PORTCON) | NI8430_PORTCON_TXVR_ENABLE, | 747 | writeb(readb(p + offset + NI8430_PORTCON) | NI8430_PORTCON_TXVR_ENABLE, |
748 | p + offset + NI8430_PORTCON); | 748 | p + offset + NI8430_PORTCON); |
749 | 749 | ||
diff --git a/drivers/tty/serial/bfin_5xx.c b/drivers/tty/serial/bfin_5xx.c index 9b1ff2b6bb37..ff6979181ac5 100644 --- a/drivers/tty/serial/bfin_5xx.c +++ b/drivers/tty/serial/bfin_5xx.c | |||
@@ -1304,8 +1304,7 @@ static int bfin_serial_probe(struct platform_device *pdev) | |||
1304 | goto out_error_free_peripherals; | 1304 | goto out_error_free_peripherals; |
1305 | } | 1305 | } |
1306 | 1306 | ||
1307 | uart->port.membase = ioremap(res->start, | 1307 | uart->port.membase = ioremap(res->start, resource_size(res)); |
1308 | res->end - res->start); | ||
1309 | if (!uart->port.membase) { | 1308 | if (!uart->port.membase) { |
1310 | dev_err(&pdev->dev, "Cannot map uart IO\n"); | 1309 | dev_err(&pdev->dev, "Cannot map uart IO\n"); |
1311 | ret = -ENXIO; | 1310 | ret = -ENXIO; |
@@ -1483,7 +1482,7 @@ static int bfin_earlyprintk_probe(struct platform_device *pdev) | |||
1483 | } | 1482 | } |
1484 | 1483 | ||
1485 | bfin_earlyprintk_port.port.membase = ioremap(res->start, | 1484 | bfin_earlyprintk_port.port.membase = ioremap(res->start, |
1486 | res->end - res->start); | 1485 | resource_size(res)); |
1487 | if (!bfin_earlyprintk_port.port.membase) { | 1486 | if (!bfin_earlyprintk_port.port.membase) { |
1488 | dev_err(&pdev->dev, "Cannot map uart IO\n"); | 1487 | dev_err(&pdev->dev, "Cannot map uart IO\n"); |
1489 | ret = -ENXIO; | 1488 | ret = -ENXIO; |
diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c index a54473123e0a..22fe801cce31 100644 --- a/drivers/tty/serial/imx.c +++ b/drivers/tty/serial/imx.c | |||
@@ -954,7 +954,7 @@ static void imx_release_port(struct uart_port *port) | |||
954 | struct resource *mmres; | 954 | struct resource *mmres; |
955 | 955 | ||
956 | mmres = platform_get_resource(pdev, IORESOURCE_MEM, 0); | 956 | mmres = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
957 | release_mem_region(mmres->start, mmres->end - mmres->start + 1); | 957 | release_mem_region(mmres->start, resource_size(mmres)); |
958 | } | 958 | } |
959 | 959 | ||
960 | /* | 960 | /* |
@@ -970,8 +970,7 @@ static int imx_request_port(struct uart_port *port) | |||
970 | if (!mmres) | 970 | if (!mmres) |
971 | return -ENODEV; | 971 | return -ENODEV; |
972 | 972 | ||
973 | ret = request_mem_region(mmres->start, mmres->end - mmres->start + 1, | 973 | ret = request_mem_region(mmres->start, resource_size(mmres), "imx-uart"); |
974 | "imx-uart"); | ||
975 | 974 | ||
976 | return ret ? 0 : -EBUSY; | 975 | return ret ? 0 : -EBUSY; |
977 | } | 976 | } |
diff --git a/drivers/tty/serial/m32r_sio.c b/drivers/tty/serial/m32r_sio.c index 84db7321cce8..8e07517f8acd 100644 --- a/drivers/tty/serial/m32r_sio.c +++ b/drivers/tty/serial/m32r_sio.c | |||
@@ -892,7 +892,7 @@ static int m32r_sio_request_port(struct uart_port *port) | |||
892 | * If we have a mapbase, then request that as well. | 892 | * If we have a mapbase, then request that as well. |
893 | */ | 893 | */ |
894 | if (ret == 0 && up->port.flags & UPF_IOREMAP) { | 894 | if (ret == 0 && up->port.flags & UPF_IOREMAP) { |
895 | int size = res->end - res->start + 1; | 895 | int size = resource_size(res); |
896 | 896 | ||
897 | up->port.membase = ioremap(up->port.mapbase, size); | 897 | up->port.membase = ioremap(up->port.mapbase, size); |
898 | if (!up->port.membase) | 898 | if (!up->port.membase) |
diff --git a/drivers/tty/serial/omap-serial.c b/drivers/tty/serial/omap-serial.c index 47cadf474149..c37df8d0fa28 100644 --- a/drivers/tty/serial/omap-serial.c +++ b/drivers/tty/serial/omap-serial.c | |||
@@ -1241,8 +1241,8 @@ static int serial_omap_probe(struct platform_device *pdev) | |||
1241 | return -ENODEV; | 1241 | return -ENODEV; |
1242 | } | 1242 | } |
1243 | 1243 | ||
1244 | if (!request_mem_region(mem->start, (mem->end - mem->start) + 1, | 1244 | if (!request_mem_region(mem->start, resource_size(mem), |
1245 | pdev->dev.driver->name)) { | 1245 | pdev->dev.driver->name)) { |
1246 | dev_err(&pdev->dev, "memory region already claimed\n"); | 1246 | dev_err(&pdev->dev, "memory region already claimed\n"); |
1247 | return -EBUSY; | 1247 | return -EBUSY; |
1248 | } | 1248 | } |
@@ -1308,7 +1308,7 @@ err: | |||
1308 | dev_err(&pdev->dev, "[UART%d]: failure [%s]: %d\n", | 1308 | dev_err(&pdev->dev, "[UART%d]: failure [%s]: %d\n", |
1309 | pdev->id, __func__, ret); | 1309 | pdev->id, __func__, ret); |
1310 | do_release_region: | 1310 | do_release_region: |
1311 | release_mem_region(mem->start, (mem->end - mem->start) + 1); | 1311 | release_mem_region(mem->start, resource_size(mem)); |
1312 | return ret; | 1312 | return ret; |
1313 | } | 1313 | } |
1314 | 1314 | ||
diff --git a/drivers/tty/serial/pxa.c b/drivers/tty/serial/pxa.c index 4302e6e3768e..531931c1b250 100644 --- a/drivers/tty/serial/pxa.c +++ b/drivers/tty/serial/pxa.c | |||
@@ -803,7 +803,7 @@ static int serial_pxa_probe(struct platform_device *dev) | |||
803 | break; | 803 | break; |
804 | } | 804 | } |
805 | 805 | ||
806 | sport->port.membase = ioremap(mmres->start, mmres->end - mmres->start + 1); | 806 | sport->port.membase = ioremap(mmres->start, resource_size(mmres)); |
807 | if (!sport->port.membase) { | 807 | if (!sport->port.membase) { |
808 | ret = -ENOMEM; | 808 | ret = -ENOMEM; |
809 | goto err_clk; | 809 | goto err_clk; |
diff --git a/drivers/tty/serial/sunsu.c b/drivers/tty/serial/sunsu.c index 92aa54550e84..ad0f8f5f6ea1 100644 --- a/drivers/tty/serial/sunsu.c +++ b/drivers/tty/serial/sunsu.c | |||
@@ -1435,7 +1435,7 @@ static int __devinit su_probe(struct platform_device *op) | |||
1435 | 1435 | ||
1436 | rp = &op->resource[0]; | 1436 | rp = &op->resource[0]; |
1437 | up->port.mapbase = rp->start; | 1437 | up->port.mapbase = rp->start; |
1438 | up->reg_size = (rp->end - rp->start) + 1; | 1438 | up->reg_size = resource_size(rp); |
1439 | up->port.membase = of_ioremap(rp, 0, up->reg_size, "su"); | 1439 | up->port.membase = of_ioremap(rp, 0, up->reg_size, "su"); |
1440 | if (!up->port.membase) { | 1440 | if (!up->port.membase) { |
1441 | if (type != SU_PORT_PORT) | 1441 | if (type != SU_PORT_PORT) |
diff --git a/drivers/tty/serial/vt8500_serial.c b/drivers/tty/serial/vt8500_serial.c index 37fc4e3d487c..026cb9ea5cd1 100644 --- a/drivers/tty/serial/vt8500_serial.c +++ b/drivers/tty/serial/vt8500_serial.c | |||
@@ -573,8 +573,7 @@ static int __init vt8500_serial_probe(struct platform_device *pdev) | |||
573 | snprintf(vt8500_port->name, sizeof(vt8500_port->name), | 573 | snprintf(vt8500_port->name, sizeof(vt8500_port->name), |
574 | "VT8500 UART%d", pdev->id); | 574 | "VT8500 UART%d", pdev->id); |
575 | 575 | ||
576 | vt8500_port->uart.membase = ioremap(mmres->start, | 576 | vt8500_port->uart.membase = ioremap(mmres->start, resource_size(mmres)); |
577 | mmres->end - mmres->start + 1); | ||
578 | if (!vt8500_port->uart.membase) { | 577 | if (!vt8500_port->uart.membase) { |
579 | ret = -ENOMEM; | 578 | ret = -ENOMEM; |
580 | goto err; | 579 | goto err; |
diff --git a/drivers/uio/uio_pdrv.c b/drivers/uio/uio_pdrv.c index 7d3e469b9904..bdc3db946122 100644 --- a/drivers/uio/uio_pdrv.c +++ b/drivers/uio/uio_pdrv.c | |||
@@ -58,7 +58,7 @@ static int uio_pdrv_probe(struct platform_device *pdev) | |||
58 | 58 | ||
59 | uiomem->memtype = UIO_MEM_PHYS; | 59 | uiomem->memtype = UIO_MEM_PHYS; |
60 | uiomem->addr = r->start; | 60 | uiomem->addr = r->start; |
61 | uiomem->size = r->end - r->start + 1; | 61 | uiomem->size = resource_size(r); |
62 | ++uiomem; | 62 | ++uiomem; |
63 | } | 63 | } |
64 | 64 | ||
diff --git a/drivers/uio/uio_pdrv_genirq.c b/drivers/uio/uio_pdrv_genirq.c index 0f424af7f109..31e799d9efe5 100644 --- a/drivers/uio/uio_pdrv_genirq.c +++ b/drivers/uio/uio_pdrv_genirq.c | |||
@@ -137,7 +137,7 @@ static int uio_pdrv_genirq_probe(struct platform_device *pdev) | |||
137 | 137 | ||
138 | uiomem->memtype = UIO_MEM_PHYS; | 138 | uiomem->memtype = UIO_MEM_PHYS; |
139 | uiomem->addr = r->start; | 139 | uiomem->addr = r->start; |
140 | uiomem->size = r->end - r->start + 1; | 140 | uiomem->size = resource_size(r); |
141 | ++uiomem; | 141 | ++uiomem; |
142 | } | 142 | } |
143 | 143 | ||
diff --git a/drivers/usb/gadget/atmel_usba_udc.c b/drivers/usb/gadget/atmel_usba_udc.c index db1a659702ba..f045c8968a6e 100644 --- a/drivers/usb/gadget/atmel_usba_udc.c +++ b/drivers/usb/gadget/atmel_usba_udc.c | |||
@@ -272,7 +272,7 @@ static void usba_init_debugfs(struct usba_udc *udc) | |||
272 | 272 | ||
273 | regs_resource = platform_get_resource(udc->pdev, IORESOURCE_MEM, | 273 | regs_resource = platform_get_resource(udc->pdev, IORESOURCE_MEM, |
274 | CTRL_IOMEM_ID); | 274 | CTRL_IOMEM_ID); |
275 | regs->d_inode->i_size = regs_resource->end - regs_resource->start + 1; | 275 | regs->d_inode->i_size = resource_size(regs_resource); |
276 | udc->debugfs_regs = regs; | 276 | udc->debugfs_regs = regs; |
277 | 277 | ||
278 | usba_ep_init_debugfs(udc, to_usba_ep(udc->gadget.ep0)); | 278 | usba_ep_init_debugfs(udc, to_usba_ep(udc->gadget.ep0)); |
diff --git a/drivers/usb/gadget/fsl_udc_core.c b/drivers/usb/gadget/fsl_udc_core.c index 4e4833168087..3e59035e6de8 100644 --- a/drivers/usb/gadget/fsl_udc_core.c +++ b/drivers/usb/gadget/fsl_udc_core.c | |||
@@ -2463,7 +2463,7 @@ static int __init fsl_udc_probe(struct platform_device *pdev) | |||
2463 | } | 2463 | } |
2464 | 2464 | ||
2465 | if (pdata->operating_mode == FSL_USB2_DR_DEVICE) { | 2465 | if (pdata->operating_mode == FSL_USB2_DR_DEVICE) { |
2466 | if (!request_mem_region(res->start, res->end - res->start + 1, | 2466 | if (!request_mem_region(res->start, resource_size(res), |
2467 | driver_name)) { | 2467 | driver_name)) { |
2468 | ERR("request mem region for %s failed\n", pdev->name); | 2468 | ERR("request mem region for %s failed\n", pdev->name); |
2469 | ret = -EBUSY; | 2469 | ret = -EBUSY; |
@@ -2605,7 +2605,7 @@ err_iounmap_noclk: | |||
2605 | iounmap(dr_regs); | 2605 | iounmap(dr_regs); |
2606 | err_release_mem_region: | 2606 | err_release_mem_region: |
2607 | if (pdata->operating_mode == FSL_USB2_DR_DEVICE) | 2607 | if (pdata->operating_mode == FSL_USB2_DR_DEVICE) |
2608 | release_mem_region(res->start, res->end - res->start + 1); | 2608 | release_mem_region(res->start, resource_size(res)); |
2609 | err_kfree: | 2609 | err_kfree: |
2610 | kfree(udc_controller); | 2610 | kfree(udc_controller); |
2611 | udc_controller = NULL; | 2611 | udc_controller = NULL; |
@@ -2640,7 +2640,7 @@ static int __exit fsl_udc_remove(struct platform_device *pdev) | |||
2640 | free_irq(udc_controller->irq, udc_controller); | 2640 | free_irq(udc_controller->irq, udc_controller); |
2641 | iounmap(dr_regs); | 2641 | iounmap(dr_regs); |
2642 | if (pdata->operating_mode == FSL_USB2_DR_DEVICE) | 2642 | if (pdata->operating_mode == FSL_USB2_DR_DEVICE) |
2643 | release_mem_region(res->start, res->end - res->start + 1); | 2643 | release_mem_region(res->start, resource_size(res)); |
2644 | 2644 | ||
2645 | device_unregister(&udc_controller->gadget.dev); | 2645 | device_unregister(&udc_controller->gadget.dev); |
2646 | /* free udc --wait for the release() finished */ | 2646 | /* free udc --wait for the release() finished */ |
diff --git a/drivers/usb/gadget/pxa27x_udc.h b/drivers/usb/gadget/pxa27x_udc.h index cd16231d8c73..b01696eab068 100644 --- a/drivers/usb/gadget/pxa27x_udc.h +++ b/drivers/usb/gadget/pxa27x_udc.h | |||
@@ -88,9 +88,9 @@ | |||
88 | #define UDCISR_INT_MASK (UDCICR_FIFOERR | UDCICR_PKTCOMPL) | 88 | #define UDCISR_INT_MASK (UDCICR_FIFOERR | UDCICR_PKTCOMPL) |
89 | 89 | ||
90 | #define UDCOTGICR_IESF (1 << 24) /* OTG SET_FEATURE command recvd */ | 90 | #define UDCOTGICR_IESF (1 << 24) /* OTG SET_FEATURE command recvd */ |
91 | #define UDCOTGICR_IEXR (1 << 17) /* Extra Transciever Interrupt | 91 | #define UDCOTGICR_IEXR (1 << 17) /* Extra Transceiver Interrupt |
92 | Rising Edge Interrupt Enable */ | 92 | Rising Edge Interrupt Enable */ |
93 | #define UDCOTGICR_IEXF (1 << 16) /* Extra Transciever Interrupt | 93 | #define UDCOTGICR_IEXF (1 << 16) /* Extra Transceiver Interrupt |
94 | Falling Edge Interrupt Enable */ | 94 | Falling Edge Interrupt Enable */ |
95 | #define UDCOTGICR_IEVV40R (1 << 9) /* OTG Vbus Valid 4.0V Rising Edge | 95 | #define UDCOTGICR_IEVV40R (1 << 9) /* OTG Vbus Valid 4.0V Rising Edge |
96 | Interrupt Enable */ | 96 | Interrupt Enable */ |
diff --git a/drivers/usb/host/ehci-ath79.c b/drivers/usb/host/ehci-ath79.c index aa248c2f2c60..4d2e88d04dab 100644 --- a/drivers/usb/host/ehci-ath79.c +++ b/drivers/usb/host/ehci-ath79.c | |||
@@ -148,7 +148,7 @@ static int ehci_ath79_probe(struct platform_device *pdev) | |||
148 | return -ENOMEM; | 148 | return -ENOMEM; |
149 | 149 | ||
150 | hcd->rsrc_start = res->start; | 150 | hcd->rsrc_start = res->start; |
151 | hcd->rsrc_len = res->end - res->start + 1; | 151 | hcd->rsrc_len = resource_size(res); |
152 | 152 | ||
153 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 153 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
154 | dev_dbg(&pdev->dev, "controller already in use\n"); | 154 | dev_dbg(&pdev->dev, "controller already in use\n"); |
diff --git a/drivers/usb/host/ehci-cns3xxx.c b/drivers/usb/host/ehci-cns3xxx.c index d41745c6f0c4..6536abdea6e6 100644 --- a/drivers/usb/host/ehci-cns3xxx.c +++ b/drivers/usb/host/ehci-cns3xxx.c | |||
@@ -107,7 +107,7 @@ static int cns3xxx_ehci_probe(struct platform_device *pdev) | |||
107 | } | 107 | } |
108 | 108 | ||
109 | hcd->rsrc_start = res->start; | 109 | hcd->rsrc_start = res->start; |
110 | hcd->rsrc_len = res->end - res->start + 1; | 110 | hcd->rsrc_len = resource_size(res); |
111 | 111 | ||
112 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, | 112 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, |
113 | driver->description)) { | 113 | driver->description)) { |
diff --git a/drivers/usb/host/ehci-fsl.c b/drivers/usb/host/ehci-fsl.c index f380bf97e5af..34a3140d1e5f 100644 --- a/drivers/usb/host/ehci-fsl.c +++ b/drivers/usb/host/ehci-fsl.c | |||
@@ -100,7 +100,7 @@ static int usb_hcd_fsl_probe(const struct hc_driver *driver, | |||
100 | goto err2; | 100 | goto err2; |
101 | } | 101 | } |
102 | hcd->rsrc_start = res->start; | 102 | hcd->rsrc_start = res->start; |
103 | hcd->rsrc_len = res->end - res->start + 1; | 103 | hcd->rsrc_len = resource_size(res); |
104 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, | 104 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, |
105 | driver->description)) { | 105 | driver->description)) { |
106 | dev_dbg(&pdev->dev, "controller already in use\n"); | 106 | dev_dbg(&pdev->dev, "controller already in use\n"); |
diff --git a/drivers/usb/host/ehci-grlib.c b/drivers/usb/host/ehci-grlib.c index 93b230dc51a2..fdfd8c5b639b 100644 --- a/drivers/usb/host/ehci-grlib.c +++ b/drivers/usb/host/ehci-grlib.c | |||
@@ -130,7 +130,7 @@ static int __devinit ehci_hcd_grlib_probe(struct platform_device *op) | |||
130 | return -ENOMEM; | 130 | return -ENOMEM; |
131 | 131 | ||
132 | hcd->rsrc_start = res.start; | 132 | hcd->rsrc_start = res.start; |
133 | hcd->rsrc_len = res.end - res.start + 1; | 133 | hcd->rsrc_len = resource_size(&res); |
134 | 134 | ||
135 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 135 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
136 | printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); | 136 | printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); |
diff --git a/drivers/usb/host/ehci-ixp4xx.c b/drivers/usb/host/ehci-ixp4xx.c index 50e600d26e28..c4460f3d009f 100644 --- a/drivers/usb/host/ehci-ixp4xx.c +++ b/drivers/usb/host/ehci-ixp4xx.c | |||
@@ -100,7 +100,7 @@ static int ixp4xx_ehci_probe(struct platform_device *pdev) | |||
100 | goto fail_request_resource; | 100 | goto fail_request_resource; |
101 | } | 101 | } |
102 | hcd->rsrc_start = res->start; | 102 | hcd->rsrc_start = res->start; |
103 | hcd->rsrc_len = res->end - res->start + 1; | 103 | hcd->rsrc_len = resource_size(res); |
104 | 104 | ||
105 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, | 105 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, |
106 | driver->description)) { | 106 | driver->description)) { |
diff --git a/drivers/usb/host/ehci-octeon.c b/drivers/usb/host/ehci-octeon.c index ff55757ba7d8..c3ba3ed5f3a6 100644 --- a/drivers/usb/host/ehci-octeon.c +++ b/drivers/usb/host/ehci-octeon.c | |||
@@ -124,7 +124,7 @@ static int ehci_octeon_drv_probe(struct platform_device *pdev) | |||
124 | return -ENOMEM; | 124 | return -ENOMEM; |
125 | 125 | ||
126 | hcd->rsrc_start = res_mem->start; | 126 | hcd->rsrc_start = res_mem->start; |
127 | hcd->rsrc_len = res_mem->end - res_mem->start + 1; | 127 | hcd->rsrc_len = resource_size(res_mem); |
128 | 128 | ||
129 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, | 129 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, |
130 | OCTEON_EHCI_HCD_NAME)) { | 130 | OCTEON_EHCI_HCD_NAME)) { |
diff --git a/drivers/usb/host/ehci-pmcmsp.c b/drivers/usb/host/ehci-pmcmsp.c index cd69099cda19..e8d54de44acc 100644 --- a/drivers/usb/host/ehci-pmcmsp.c +++ b/drivers/usb/host/ehci-pmcmsp.c | |||
@@ -124,7 +124,7 @@ static int usb_hcd_msp_map_regs(struct mspusb_device *dev) | |||
124 | res = platform_get_resource(pdev, IORESOURCE_MEM, 1); | 124 | res = platform_get_resource(pdev, IORESOURCE_MEM, 1); |
125 | if (res == NULL) | 125 | if (res == NULL) |
126 | return -ENOMEM; | 126 | return -ENOMEM; |
127 | res_len = res->end - res->start + 1; | 127 | res_len = resource_size(res); |
128 | if (!request_mem_region(res->start, res_len, "mab regs")) | 128 | if (!request_mem_region(res->start, res_len, "mab regs")) |
129 | return -EBUSY; | 129 | return -EBUSY; |
130 | 130 | ||
@@ -140,7 +140,7 @@ static int usb_hcd_msp_map_regs(struct mspusb_device *dev) | |||
140 | retval = -ENOMEM; | 140 | retval = -ENOMEM; |
141 | goto err2; | 141 | goto err2; |
142 | } | 142 | } |
143 | res_len = res->end - res->start + 1; | 143 | res_len = resource_size(res); |
144 | if (!request_mem_region(res->start, res_len, "usbid regs")) { | 144 | if (!request_mem_region(res->start, res_len, "usbid regs")) { |
145 | retval = -EBUSY; | 145 | retval = -EBUSY; |
146 | goto err2; | 146 | goto err2; |
@@ -154,13 +154,13 @@ static int usb_hcd_msp_map_regs(struct mspusb_device *dev) | |||
154 | return 0; | 154 | return 0; |
155 | err3: | 155 | err3: |
156 | res = platform_get_resource(pdev, IORESOURCE_MEM, 2); | 156 | res = platform_get_resource(pdev, IORESOURCE_MEM, 2); |
157 | res_len = res->end - res->start + 1; | 157 | res_len = resource_size(res); |
158 | release_mem_region(res->start, res_len); | 158 | release_mem_region(res->start, res_len); |
159 | err2: | 159 | err2: |
160 | iounmap(dev->mab_regs); | 160 | iounmap(dev->mab_regs); |
161 | err1: | 161 | err1: |
162 | res = platform_get_resource(pdev, IORESOURCE_MEM, 1); | 162 | res = platform_get_resource(pdev, IORESOURCE_MEM, 1); |
163 | res_len = res->end - res->start + 1; | 163 | res_len = resource_size(res); |
164 | release_mem_region(res->start, res_len); | 164 | release_mem_region(res->start, res_len); |
165 | dev_err(&pdev->dev, "Failed to map non-EHCI regs.\n"); | 165 | dev_err(&pdev->dev, "Failed to map non-EHCI regs.\n"); |
166 | return retval; | 166 | return retval; |
@@ -194,7 +194,7 @@ int usb_hcd_msp_probe(const struct hc_driver *driver, | |||
194 | goto err1; | 194 | goto err1; |
195 | } | 195 | } |
196 | hcd->rsrc_start = res->start; | 196 | hcd->rsrc_start = res->start; |
197 | hcd->rsrc_len = res->end - res->start + 1; | 197 | hcd->rsrc_len = resource_size(res); |
198 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, dev->name)) { | 198 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, dev->name)) { |
199 | retval = -EBUSY; | 199 | retval = -EBUSY; |
200 | goto err1; | 200 | goto err1; |
diff --git a/drivers/usb/host/ehci-ppc-of.c b/drivers/usb/host/ehci-ppc-of.c index 8552db6c29c9..41d11fe14252 100644 --- a/drivers/usb/host/ehci-ppc-of.c +++ b/drivers/usb/host/ehci-ppc-of.c | |||
@@ -130,7 +130,7 @@ static int __devinit ehci_hcd_ppc_of_probe(struct platform_device *op) | |||
130 | return -ENOMEM; | 130 | return -ENOMEM; |
131 | 131 | ||
132 | hcd->rsrc_start = res.start; | 132 | hcd->rsrc_start = res.start; |
133 | hcd->rsrc_len = res.end - res.start + 1; | 133 | hcd->rsrc_len = resource_size(&res); |
134 | 134 | ||
135 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 135 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
136 | printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); | 136 | printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); |
diff --git a/drivers/usb/host/ehci-w90x900.c b/drivers/usb/host/ehci-w90x900.c index 52a027aaa370..d661cf7de140 100644 --- a/drivers/usb/host/ehci-w90x900.c +++ b/drivers/usb/host/ehci-w90x900.c | |||
@@ -41,7 +41,7 @@ static int __devinit usb_w90x900_probe(const struct hc_driver *driver, | |||
41 | } | 41 | } |
42 | 42 | ||
43 | hcd->rsrc_start = res->start; | 43 | hcd->rsrc_start = res->start; |
44 | hcd->rsrc_len = res->end - res->start + 1; | 44 | hcd->rsrc_len = resource_size(res); |
45 | 45 | ||
46 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 46 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
47 | retval = -EBUSY; | 47 | retval = -EBUSY; |
diff --git a/drivers/usb/host/ehci-xilinx-of.c b/drivers/usb/host/ehci-xilinx-of.c index a64d6d66d760..32793ce3d9e9 100644 --- a/drivers/usb/host/ehci-xilinx-of.c +++ b/drivers/usb/host/ehci-xilinx-of.c | |||
@@ -174,7 +174,7 @@ static int __devinit ehci_hcd_xilinx_of_probe(struct platform_device *op) | |||
174 | return -ENOMEM; | 174 | return -ENOMEM; |
175 | 175 | ||
176 | hcd->rsrc_start = res.start; | 176 | hcd->rsrc_start = res.start; |
177 | hcd->rsrc_len = res.end - res.start + 1; | 177 | hcd->rsrc_len = resource_size(&res); |
178 | 178 | ||
179 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 179 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
180 | printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); | 180 | printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); |
diff --git a/drivers/usb/host/fhci-hcd.c b/drivers/usb/host/fhci-hcd.c index 19223c7449e1..572ea53b0226 100644 --- a/drivers/usb/host/fhci-hcd.c +++ b/drivers/usb/host/fhci-hcd.c | |||
@@ -605,7 +605,7 @@ static int __devinit of_fhci_probe(struct platform_device *ofdev) | |||
605 | goto err_regs; | 605 | goto err_regs; |
606 | } | 606 | } |
607 | 607 | ||
608 | hcd->regs = ioremap(usb_regs.start, usb_regs.end - usb_regs.start + 1); | 608 | hcd->regs = ioremap(usb_regs.start, resource_size(&usb_regs)); |
609 | if (!hcd->regs) { | 609 | if (!hcd->regs) { |
610 | dev_err(dev, "could not ioremap regs\n"); | 610 | dev_err(dev, "could not ioremap regs\n"); |
611 | ret = -ENOMEM; | 611 | ret = -ENOMEM; |
diff --git a/drivers/usb/host/ohci-ath79.c b/drivers/usb/host/ohci-ath79.c index ffea3e7cb0a8..c620c50f6770 100644 --- a/drivers/usb/host/ohci-ath79.c +++ b/drivers/usb/host/ohci-ath79.c | |||
@@ -93,8 +93,8 @@ static int ohci_ath79_probe(struct platform_device *pdev) | |||
93 | ret = -ENODEV; | 93 | ret = -ENODEV; |
94 | goto err_put_hcd; | 94 | goto err_put_hcd; |
95 | } | 95 | } |
96 | hcd->rsrc_start = res->start; | 96 | hcd->rsrc_start = res->start; |
97 | hcd->rsrc_len = res->end - res->start + 1; | 97 | hcd->rsrc_len = resource_size(res); |
98 | 98 | ||
99 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 99 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
100 | dev_dbg(&pdev->dev, "controller already in use\n"); | 100 | dev_dbg(&pdev->dev, "controller already in use\n"); |
diff --git a/drivers/usb/host/ohci-cns3xxx.c b/drivers/usb/host/ohci-cns3xxx.c index f05ef87e934c..5a00a1e1c6ca 100644 --- a/drivers/usb/host/ohci-cns3xxx.c +++ b/drivers/usb/host/ohci-cns3xxx.c | |||
@@ -100,7 +100,7 @@ static int cns3xxx_ohci_probe(struct platform_device *pdev) | |||
100 | goto err1; | 100 | goto err1; |
101 | } | 101 | } |
102 | hcd->rsrc_start = res->start; | 102 | hcd->rsrc_start = res->start; |
103 | hcd->rsrc_len = res->end - res->start + 1; | 103 | hcd->rsrc_len = resource_size(res); |
104 | 104 | ||
105 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, | 105 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, |
106 | driver->description)) { | 106 | driver->description)) { |
diff --git a/drivers/usb/host/ohci-da8xx.c b/drivers/usb/host/ohci-da8xx.c index d22fb4d577b7..6aca2c4453f7 100644 --- a/drivers/usb/host/ohci-da8xx.c +++ b/drivers/usb/host/ohci-da8xx.c | |||
@@ -322,7 +322,7 @@ static int usb_hcd_da8xx_probe(const struct hc_driver *driver, | |||
322 | goto err2; | 322 | goto err2; |
323 | } | 323 | } |
324 | hcd->rsrc_start = mem->start; | 324 | hcd->rsrc_start = mem->start; |
325 | hcd->rsrc_len = mem->end - mem->start + 1; | 325 | hcd->rsrc_len = resource_size(mem); |
326 | 326 | ||
327 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 327 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
328 | dev_dbg(&pdev->dev, "request_mem_region failed\n"); | 328 | dev_dbg(&pdev->dev, "request_mem_region failed\n"); |
diff --git a/drivers/usb/host/ohci-octeon.c b/drivers/usb/host/ohci-octeon.c index e4ddfaf8870f..d8b45647d1dc 100644 --- a/drivers/usb/host/ohci-octeon.c +++ b/drivers/usb/host/ohci-octeon.c | |||
@@ -135,7 +135,7 @@ static int ohci_octeon_drv_probe(struct platform_device *pdev) | |||
135 | return -ENOMEM; | 135 | return -ENOMEM; |
136 | 136 | ||
137 | hcd->rsrc_start = res_mem->start; | 137 | hcd->rsrc_start = res_mem->start; |
138 | hcd->rsrc_len = res_mem->end - res_mem->start + 1; | 138 | hcd->rsrc_len = resource_size(res_mem); |
139 | 139 | ||
140 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, | 140 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, |
141 | OCTEON_OHCI_HCD_NAME)) { | 141 | OCTEON_OHCI_HCD_NAME)) { |
diff --git a/drivers/usb/host/ohci-ppc-of.c b/drivers/usb/host/ohci-ppc-of.c index 1ca1821320f4..0c12f4e14dcd 100644 --- a/drivers/usb/host/ohci-ppc-of.c +++ b/drivers/usb/host/ohci-ppc-of.c | |||
@@ -110,7 +110,7 @@ static int __devinit ohci_hcd_ppc_of_probe(struct platform_device *op) | |||
110 | return -ENOMEM; | 110 | return -ENOMEM; |
111 | 111 | ||
112 | hcd->rsrc_start = res.start; | 112 | hcd->rsrc_start = res.start; |
113 | hcd->rsrc_len = res.end - res.start + 1; | 113 | hcd->rsrc_len = resource_size(&res); |
114 | 114 | ||
115 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 115 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
116 | printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); | 116 | printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); |
diff --git a/drivers/usb/host/ohci-ppc-soc.c b/drivers/usb/host/ohci-ppc-soc.c index 89e670e38c10..c0f595c44487 100644 --- a/drivers/usb/host/ohci-ppc-soc.c +++ b/drivers/usb/host/ohci-ppc-soc.c | |||
@@ -56,7 +56,7 @@ static int usb_hcd_ppc_soc_probe(const struct hc_driver *driver, | |||
56 | if (!hcd) | 56 | if (!hcd) |
57 | return -ENOMEM; | 57 | return -ENOMEM; |
58 | hcd->rsrc_start = res->start; | 58 | hcd->rsrc_start = res->start; |
59 | hcd->rsrc_len = res->end - res->start + 1; | 59 | hcd->rsrc_len = resource_size(res); |
60 | 60 | ||
61 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 61 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
62 | pr_debug("%s: request_mem_region failed\n", __FILE__); | 62 | pr_debug("%s: request_mem_region failed\n", __FILE__); |
diff --git a/drivers/usb/host/ohci-sa1111.c b/drivers/usb/host/ohci-sa1111.c index d8eb3bdafabb..4204d9720d23 100644 --- a/drivers/usb/host/ohci-sa1111.c +++ b/drivers/usb/host/ohci-sa1111.c | |||
@@ -131,7 +131,7 @@ int usb_hcd_sa1111_probe (const struct hc_driver *driver, | |||
131 | if (!hcd) | 131 | if (!hcd) |
132 | return -ENOMEM; | 132 | return -ENOMEM; |
133 | hcd->rsrc_start = dev->res.start; | 133 | hcd->rsrc_start = dev->res.start; |
134 | hcd->rsrc_len = dev->res.end - dev->res.start + 1; | 134 | hcd->rsrc_len = resource_size(&dev->res); |
135 | 135 | ||
136 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 136 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
137 | dbg("request_mem_region failed"); | 137 | dbg("request_mem_region failed"); |
diff --git a/drivers/usb/host/ohci-sm501.c b/drivers/usb/host/ohci-sm501.c index 041d30f30c10..78918ca0da23 100644 --- a/drivers/usb/host/ohci-sm501.c +++ b/drivers/usb/host/ohci-sm501.c | |||
@@ -103,8 +103,7 @@ static int ohci_hcd_sm501_drv_probe(struct platform_device *pdev) | |||
103 | goto err0; | 103 | goto err0; |
104 | } | 104 | } |
105 | 105 | ||
106 | if (!request_mem_region(mem->start, mem->end - mem->start + 1, | 106 | if (!request_mem_region(mem->start, resource_size(mem), pdev->name)) { |
107 | pdev->name)) { | ||
108 | dev_err(dev, "request_mem_region failed\n"); | 107 | dev_err(dev, "request_mem_region failed\n"); |
109 | retval = -EBUSY; | 108 | retval = -EBUSY; |
110 | goto err0; | 109 | goto err0; |
@@ -126,7 +125,7 @@ static int ohci_hcd_sm501_drv_probe(struct platform_device *pdev) | |||
126 | 125 | ||
127 | if (!dma_declare_coherent_memory(dev, mem->start, | 126 | if (!dma_declare_coherent_memory(dev, mem->start, |
128 | mem->start - mem->parent->start, | 127 | mem->start - mem->parent->start, |
129 | (mem->end - mem->start) + 1, | 128 | resource_size(mem), |
130 | DMA_MEMORY_MAP | | 129 | DMA_MEMORY_MAP | |
131 | DMA_MEMORY_EXCLUSIVE)) { | 130 | DMA_MEMORY_EXCLUSIVE)) { |
132 | dev_err(dev, "cannot declare coherent memory\n"); | 131 | dev_err(dev, "cannot declare coherent memory\n"); |
@@ -149,7 +148,7 @@ static int ohci_hcd_sm501_drv_probe(struct platform_device *pdev) | |||
149 | } | 148 | } |
150 | 149 | ||
151 | hcd->rsrc_start = res->start; | 150 | hcd->rsrc_start = res->start; |
152 | hcd->rsrc_len = res->end - res->start + 1; | 151 | hcd->rsrc_len = resource_size(res); |
153 | 152 | ||
154 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, pdev->name)) { | 153 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, pdev->name)) { |
155 | dev_err(dev, "request_mem_region failed\n"); | 154 | dev_err(dev, "request_mem_region failed\n"); |
@@ -185,7 +184,7 @@ err3: | |||
185 | err2: | 184 | err2: |
186 | dma_release_declared_memory(dev); | 185 | dma_release_declared_memory(dev); |
187 | err1: | 186 | err1: |
188 | release_mem_region(mem->start, mem->end - mem->start + 1); | 187 | release_mem_region(mem->start, resource_size(mem)); |
189 | err0: | 188 | err0: |
190 | return retval; | 189 | return retval; |
191 | } | 190 | } |
@@ -201,7 +200,7 @@ static int ohci_hcd_sm501_drv_remove(struct platform_device *pdev) | |||
201 | dma_release_declared_memory(&pdev->dev); | 200 | dma_release_declared_memory(&pdev->dev); |
202 | mem = platform_get_resource(pdev, IORESOURCE_MEM, 1); | 201 | mem = platform_get_resource(pdev, IORESOURCE_MEM, 1); |
203 | if (mem) | 202 | if (mem) |
204 | release_mem_region(mem->start, mem->end - mem->start + 1); | 203 | release_mem_region(mem->start, resource_size(mem)); |
205 | 204 | ||
206 | /* mask interrupts and disable power */ | 205 | /* mask interrupts and disable power */ |
207 | 206 | ||
diff --git a/drivers/usb/host/ohci-ssb.c b/drivers/usb/host/ohci-ssb.c index 48ee6943bf35..c4aea3b8315e 100644 --- a/drivers/usb/host/ohci-ssb.c +++ b/drivers/usb/host/ohci-ssb.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * Sonics Silicon Backplane | 2 | * Sonics Silicon Backplane |
3 | * Broadcom USB-core OHCI driver | 3 | * Broadcom USB-core OHCI driver |
4 | * | 4 | * |
5 | * Copyright 2007 Michael Buesch <mb@bu3sch.de> | 5 | * Copyright 2007 Michael Buesch <m@bues.ch> |
6 | * | 6 | * |
7 | * Derived from the OHCI-PCI driver | 7 | * Derived from the OHCI-PCI driver |
8 | * Copyright 1999 Roman Weissgaerber | 8 | * Copyright 1999 Roman Weissgaerber |
diff --git a/drivers/usb/host/ohci-tmio.c b/drivers/usb/host/ohci-tmio.c index 3558491dd87d..57ad1271fc9b 100644 --- a/drivers/usb/host/ohci-tmio.c +++ b/drivers/usb/host/ohci-tmio.c | |||
@@ -208,13 +208,13 @@ static int __devinit ohci_hcd_tmio_drv_probe(struct platform_device *dev) | |||
208 | } | 208 | } |
209 | 209 | ||
210 | hcd->rsrc_start = regs->start; | 210 | hcd->rsrc_start = regs->start; |
211 | hcd->rsrc_len = regs->end - regs->start + 1; | 211 | hcd->rsrc_len = resource_size(regs); |
212 | 212 | ||
213 | tmio = hcd_to_tmio(hcd); | 213 | tmio = hcd_to_tmio(hcd); |
214 | 214 | ||
215 | spin_lock_init(&tmio->lock); | 215 | spin_lock_init(&tmio->lock); |
216 | 216 | ||
217 | tmio->ccr = ioremap(config->start, config->end - config->start + 1); | 217 | tmio->ccr = ioremap(config->start, resource_size(config)); |
218 | if (!tmio->ccr) { | 218 | if (!tmio->ccr) { |
219 | ret = -ENOMEM; | 219 | ret = -ENOMEM; |
220 | goto err_ioremap_ccr; | 220 | goto err_ioremap_ccr; |
@@ -228,7 +228,7 @@ static int __devinit ohci_hcd_tmio_drv_probe(struct platform_device *dev) | |||
228 | 228 | ||
229 | if (!dma_declare_coherent_memory(&dev->dev, sram->start, | 229 | if (!dma_declare_coherent_memory(&dev->dev, sram->start, |
230 | sram->start, | 230 | sram->start, |
231 | sram->end - sram->start + 1, | 231 | resource_size(sram), |
232 | DMA_MEMORY_MAP | DMA_MEMORY_EXCLUSIVE)) { | 232 | DMA_MEMORY_MAP | DMA_MEMORY_EXCLUSIVE)) { |
233 | ret = -EBUSY; | 233 | ret = -EBUSY; |
234 | goto err_dma_declare; | 234 | goto err_dma_declare; |
diff --git a/drivers/usb/host/oxu210hp-hcd.c b/drivers/usb/host/oxu210hp-hcd.c index 5fbe997dc6df..dcd889803f0f 100644 --- a/drivers/usb/host/oxu210hp-hcd.c +++ b/drivers/usb/host/oxu210hp-hcd.c | |||
@@ -3828,7 +3828,7 @@ static int oxu_drv_probe(struct platform_device *pdev) | |||
3828 | return -ENODEV; | 3828 | return -ENODEV; |
3829 | } | 3829 | } |
3830 | memstart = res->start; | 3830 | memstart = res->start; |
3831 | memlen = res->end - res->start + 1; | 3831 | memlen = resource_size(res); |
3832 | dev_dbg(&pdev->dev, "MEM resource %lx-%lx\n", memstart, memlen); | 3832 | dev_dbg(&pdev->dev, "MEM resource %lx-%lx\n", memstart, memlen); |
3833 | if (!request_mem_region(memstart, memlen, | 3833 | if (!request_mem_region(memstart, memlen, |
3834 | oxu_hc_driver.description)) { | 3834 | oxu_hc_driver.description)) { |
diff --git a/drivers/usb/host/uhci-grlib.c b/drivers/usb/host/uhci-grlib.c index d01c1e227681..f7a62138e3e0 100644 --- a/drivers/usb/host/uhci-grlib.c +++ b/drivers/usb/host/uhci-grlib.c | |||
@@ -111,7 +111,7 @@ static int __devinit uhci_hcd_grlib_probe(struct platform_device *op) | |||
111 | return -ENOMEM; | 111 | return -ENOMEM; |
112 | 112 | ||
113 | hcd->rsrc_start = res.start; | 113 | hcd->rsrc_start = res.start; |
114 | hcd->rsrc_len = res.end - res.start + 1; | 114 | hcd->rsrc_len = resource_size(&res); |
115 | 115 | ||
116 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { | 116 | if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, hcd_name)) { |
117 | printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); | 117 | printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); |
diff --git a/drivers/usb/host/whci/init.c b/drivers/usb/host/whci/init.c index f7582e8e2169..d3e13b640d4b 100644 --- a/drivers/usb/host/whci/init.c +++ b/drivers/usb/host/whci/init.c | |||
@@ -178,7 +178,7 @@ void whc_clean_up(struct whc *whc) | |||
178 | if (whc->qset_pool) | 178 | if (whc->qset_pool) |
179 | dma_pool_destroy(whc->qset_pool); | 179 | dma_pool_destroy(whc->qset_pool); |
180 | 180 | ||
181 | len = whc->umc->resource.end - whc->umc->resource.start + 1; | 181 | len = resource_size(&whc->umc->resource); |
182 | if (whc->base) | 182 | if (whc->base) |
183 | iounmap(whc->base); | 183 | iounmap(whc->base); |
184 | if (whc->base_phys) | 184 | if (whc->base_phys) |
diff --git a/drivers/usb/misc/ftdi-elan.c b/drivers/usb/misc/ftdi-elan.c index b16bd3ce3915..2f41089cd854 100644 --- a/drivers/usb/misc/ftdi-elan.c +++ b/drivers/usb/misc/ftdi-elan.c | |||
@@ -187,7 +187,7 @@ struct usb_ftdi { | |||
187 | u32 controlreg; | 187 | u32 controlreg; |
188 | u8 response[4 + 1024]; | 188 | u8 response[4 + 1024]; |
189 | int expected; | 189 | int expected; |
190 | int recieved; | 190 | int received; |
191 | int ed_found; | 191 | int ed_found; |
192 | }; | 192 | }; |
193 | #define kref_to_usb_ftdi(d) container_of(d, struct usb_ftdi, kref) | 193 | #define kref_to_usb_ftdi(d) container_of(d, struct usb_ftdi, kref) |
@@ -353,7 +353,7 @@ static void ftdi_elan_abandon_targets(struct usb_ftdi *ftdi) | |||
353 | mutex_lock(&ftdi->u132_lock); | 353 | mutex_lock(&ftdi->u132_lock); |
354 | } | 354 | } |
355 | } | 355 | } |
356 | ftdi->recieved = 0; | 356 | ftdi->received = 0; |
357 | ftdi->expected = 4; | 357 | ftdi->expected = 4; |
358 | ftdi->ed_found = 0; | 358 | ftdi->ed_found = 0; |
359 | mutex_unlock(&ftdi->u132_lock); | 359 | mutex_unlock(&ftdi->u132_lock); |
@@ -411,7 +411,7 @@ static void ftdi_elan_flush_targets(struct usb_ftdi *ftdi) | |||
411 | } | 411 | } |
412 | } | 412 | } |
413 | } | 413 | } |
414 | ftdi->recieved = 0; | 414 | ftdi->received = 0; |
415 | ftdi->expected = 4; | 415 | ftdi->expected = 4; |
416 | ftdi->ed_found = 0; | 416 | ftdi->ed_found = 0; |
417 | mutex_unlock(&ftdi->u132_lock); | 417 | mutex_unlock(&ftdi->u132_lock); |
@@ -447,7 +447,7 @@ static void ftdi_elan_cancel_targets(struct usb_ftdi *ftdi) | |||
447 | } | 447 | } |
448 | } | 448 | } |
449 | } | 449 | } |
450 | ftdi->recieved = 0; | 450 | ftdi->received = 0; |
451 | ftdi->expected = 4; | 451 | ftdi->expected = 4; |
452 | ftdi->ed_found = 0; | 452 | ftdi->ed_found = 0; |
453 | mutex_unlock(&ftdi->u132_lock); | 453 | mutex_unlock(&ftdi->u132_lock); |
@@ -874,7 +874,7 @@ static char *have_ed_set_response(struct usb_ftdi *ftdi, | |||
874 | mutex_unlock(&ftdi->u132_lock); | 874 | mutex_unlock(&ftdi->u132_lock); |
875 | ftdi_elan_do_callback(ftdi, target, 4 + ftdi->response, | 875 | ftdi_elan_do_callback(ftdi, target, 4 + ftdi->response, |
876 | payload); | 876 | payload); |
877 | ftdi->recieved = 0; | 877 | ftdi->received = 0; |
878 | ftdi->expected = 4; | 878 | ftdi->expected = 4; |
879 | ftdi->ed_found = 0; | 879 | ftdi->ed_found = 0; |
880 | return ftdi->response; | 880 | return ftdi->response; |
@@ -890,7 +890,7 @@ static char *have_ed_set_response(struct usb_ftdi *ftdi, | |||
890 | mutex_unlock(&ftdi->u132_lock); | 890 | mutex_unlock(&ftdi->u132_lock); |
891 | ftdi_elan_do_callback(ftdi, target, 4 + ftdi->response, | 891 | ftdi_elan_do_callback(ftdi, target, 4 + ftdi->response, |
892 | payload); | 892 | payload); |
893 | ftdi->recieved = 0; | 893 | ftdi->received = 0; |
894 | ftdi->expected = 4; | 894 | ftdi->expected = 4; |
895 | ftdi->ed_found = 0; | 895 | ftdi->ed_found = 0; |
896 | return ftdi->response; | 896 | return ftdi->response; |
@@ -905,7 +905,7 @@ static char *have_ed_set_response(struct usb_ftdi *ftdi, | |||
905 | mutex_unlock(&ftdi->u132_lock); | 905 | mutex_unlock(&ftdi->u132_lock); |
906 | ftdi_elan_do_callback(ftdi, target, 4 + ftdi->response, | 906 | ftdi_elan_do_callback(ftdi, target, 4 + ftdi->response, |
907 | payload); | 907 | payload); |
908 | ftdi->recieved = 0; | 908 | ftdi->received = 0; |
909 | ftdi->expected = 4; | 909 | ftdi->expected = 4; |
910 | ftdi->ed_found = 0; | 910 | ftdi->ed_found = 0; |
911 | return ftdi->response; | 911 | return ftdi->response; |
@@ -914,7 +914,7 @@ static char *have_ed_set_response(struct usb_ftdi *ftdi, | |||
914 | mutex_unlock(&ftdi->u132_lock); | 914 | mutex_unlock(&ftdi->u132_lock); |
915 | ftdi_elan_do_callback(ftdi, target, 4 + ftdi->response, | 915 | ftdi_elan_do_callback(ftdi, target, 4 + ftdi->response, |
916 | payload); | 916 | payload); |
917 | ftdi->recieved = 0; | 917 | ftdi->received = 0; |
918 | ftdi->expected = 4; | 918 | ftdi->expected = 4; |
919 | ftdi->ed_found = 0; | 919 | ftdi->ed_found = 0; |
920 | return ftdi->response; | 920 | return ftdi->response; |
@@ -934,7 +934,7 @@ static char *have_ed_get_response(struct usb_ftdi *ftdi, | |||
934 | if (target->active) | 934 | if (target->active) |
935 | ftdi_elan_do_callback(ftdi, target, NULL, 0); | 935 | ftdi_elan_do_callback(ftdi, target, NULL, 0); |
936 | target->abandoning = 0; | 936 | target->abandoning = 0; |
937 | ftdi->recieved = 0; | 937 | ftdi->received = 0; |
938 | ftdi->expected = 4; | 938 | ftdi->expected = 4; |
939 | ftdi->ed_found = 0; | 939 | ftdi->ed_found = 0; |
940 | return ftdi->response; | 940 | return ftdi->response; |
@@ -951,7 +951,7 @@ static char *have_ed_get_response(struct usb_ftdi *ftdi, | |||
951 | */ | 951 | */ |
952 | static int ftdi_elan_respond_engine(struct usb_ftdi *ftdi) | 952 | static int ftdi_elan_respond_engine(struct usb_ftdi *ftdi) |
953 | { | 953 | { |
954 | u8 *b = ftdi->response + ftdi->recieved; | 954 | u8 *b = ftdi->response + ftdi->received; |
955 | int bytes_read = 0; | 955 | int bytes_read = 0; |
956 | int retry_on_empty = 1; | 956 | int retry_on_empty = 1; |
957 | int retry_on_timeout = 3; | 957 | int retry_on_timeout = 3; |
@@ -1043,11 +1043,11 @@ static int ftdi_elan_respond_engine(struct usb_ftdi *ftdi) | |||
1043 | u8 c = ftdi->bulk_in_buffer[++ftdi->bulk_in_last]; | 1043 | u8 c = ftdi->bulk_in_buffer[++ftdi->bulk_in_last]; |
1044 | bytes_read += 1; | 1044 | bytes_read += 1; |
1045 | ftdi->bulk_in_left -= 1; | 1045 | ftdi->bulk_in_left -= 1; |
1046 | if (ftdi->recieved == 0 && c == 0xFF) { | 1046 | if (ftdi->received == 0 && c == 0xFF) { |
1047 | goto have; | 1047 | goto have; |
1048 | } else | 1048 | } else |
1049 | *b++ = c; | 1049 | *b++ = c; |
1050 | if (++ftdi->recieved < ftdi->expected) { | 1050 | if (++ftdi->received < ftdi->expected) { |
1051 | goto have; | 1051 | goto have; |
1052 | } else if (ftdi->ed_found) { | 1052 | } else if (ftdi->ed_found) { |
1053 | int ed_number = (ftdi->response[0] >> 5) & 0x03; | 1053 | int ed_number = (ftdi->response[0] >> 5) & 0x03; |
@@ -1069,7 +1069,7 @@ static int ftdi_elan_respond_engine(struct usb_ftdi *ftdi) | |||
1069 | } | 1069 | } |
1070 | ftdi_elan_do_callback(ftdi, target, 4 + ftdi->response, | 1070 | ftdi_elan_do_callback(ftdi, target, 4 + ftdi->response, |
1071 | payload); | 1071 | payload); |
1072 | ftdi->recieved = 0; | 1072 | ftdi->received = 0; |
1073 | ftdi->expected = 4; | 1073 | ftdi->expected = 4; |
1074 | ftdi->ed_found = 0; | 1074 | ftdi->ed_found = 0; |
1075 | b = ftdi->response; | 1075 | b = ftdi->response; |
@@ -1089,7 +1089,7 @@ static int ftdi_elan_respond_engine(struct usb_ftdi *ftdi) | |||
1089 | *respond->value = data; | 1089 | *respond->value = data; |
1090 | *respond->result = 0; | 1090 | *respond->result = 0; |
1091 | complete(&respond->wait_completion); | 1091 | complete(&respond->wait_completion); |
1092 | ftdi->recieved = 0; | 1092 | ftdi->received = 0; |
1093 | ftdi->expected = 4; | 1093 | ftdi->expected = 4; |
1094 | ftdi->ed_found = 0; | 1094 | ftdi->ed_found = 0; |
1095 | b = ftdi->response; | 1095 | b = ftdi->response; |
diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c index c71b0372786e..bcbd1aba961a 100644 --- a/drivers/usb/musb/musb_core.c +++ b/drivers/usb/musb/musb_core.c | |||
@@ -1955,7 +1955,7 @@ musb_init_controller(struct device *dev, int nIrq, void __iomem *ctrl) | |||
1955 | * - initializes musb->xceiv, usually by otg_get_transceiver() | 1955 | * - initializes musb->xceiv, usually by otg_get_transceiver() |
1956 | * - stops powering VBUS | 1956 | * - stops powering VBUS |
1957 | * | 1957 | * |
1958 | * There are various transciever configurations. Blackfin, | 1958 | * There are various transceiver configurations. Blackfin, |
1959 | * DaVinci, TUSB60x0, and others integrate them. OMAP3 uses | 1959 | * DaVinci, TUSB60x0, and others integrate them. OMAP3 uses |
1960 | * external/discrete ones in various flavors (twl4030 family, | 1960 | * external/discrete ones in various flavors (twl4030 family, |
1961 | * isp1504, non-OTG, etc) mostly hooking up through ULPI. | 1961 | * isp1504, non-OTG, etc) mostly hooking up through ULPI. |
diff --git a/drivers/usb/otg/isp1301_omap.c b/drivers/usb/otg/isp1301_omap.c index 8c282258e1bd..ca9b690a7e40 100644 --- a/drivers/usb/otg/isp1301_omap.c +++ b/drivers/usb/otg/isp1301_omap.c | |||
@@ -660,7 +660,7 @@ static irqreturn_t omap_otg_irq(int irq, void *_isp) | |||
660 | int ret = IRQ_NONE; | 660 | int ret = IRQ_NONE; |
661 | struct isp1301 *isp = _isp; | 661 | struct isp1301 *isp = _isp; |
662 | 662 | ||
663 | /* update ISP1301 transciever from OTG controller */ | 663 | /* update ISP1301 transceiver from OTG controller */ |
664 | if (otg_irq & OPRT_CHG) { | 664 | if (otg_irq & OPRT_CHG) { |
665 | omap_writew(OPRT_CHG, OTG_IRQ_SRC); | 665 | omap_writew(OPRT_CHG, OTG_IRQ_SRC); |
666 | isp1301_defer_work(isp, WORK_UPDATE_ISP); | 666 | isp1301_defer_work(isp, WORK_UPDATE_ISP); |
@@ -755,7 +755,7 @@ static irqreturn_t omap_otg_irq(int irq, void *_isp) | |||
755 | omap_writew(A_VBUS_ERR, OTG_IRQ_SRC); | 755 | omap_writew(A_VBUS_ERR, OTG_IRQ_SRC); |
756 | ret = IRQ_HANDLED; | 756 | ret = IRQ_HANDLED; |
757 | 757 | ||
758 | /* switch driver; the transciever code activates it, | 758 | /* switch driver; the transceiver code activates it, |
759 | * ungating the udc clock or resuming OHCI. | 759 | * ungating the udc clock or resuming OHCI. |
760 | */ | 760 | */ |
761 | } else if (otg_irq & DRIVER_SWITCH) { | 761 | } else if (otg_irq & DRIVER_SWITCH) { |
diff --git a/drivers/usb/otg/otg_fsm.c b/drivers/usb/otg/otg_fsm.c index b0cc422f2ff9..09117387d2a4 100644 --- a/drivers/usb/otg/otg_fsm.c +++ b/drivers/usb/otg/otg_fsm.c | |||
@@ -28,7 +28,6 @@ | |||
28 | #include <linux/usb.h> | 28 | #include <linux/usb.h> |
29 | #include <linux/usb/gadget.h> | 29 | #include <linux/usb/gadget.h> |
30 | #include <linux/usb/otg.h> | 30 | #include <linux/usb/otg.h> |
31 | #include <linux/types.h> | ||
32 | 31 | ||
33 | #include "otg_fsm.h" | 32 | #include "otg_fsm.h" |
34 | 33 | ||
diff --git a/drivers/usb/otg/twl4030-usb.c b/drivers/usb/otg/twl4030-usb.c index efeb4d1517ff..14f66c358629 100644 --- a/drivers/usb/otg/twl4030-usb.c +++ b/drivers/usb/otg/twl4030-usb.c | |||
@@ -166,7 +166,7 @@ struct twl4030_usb { | |||
166 | }; | 166 | }; |
167 | 167 | ||
168 | /* internal define on top of container_of */ | 168 | /* internal define on top of container_of */ |
169 | #define xceiv_to_twl(x) container_of((x), struct twl4030_usb, otg); | 169 | #define xceiv_to_twl(x) container_of((x), struct twl4030_usb, otg) |
170 | 170 | ||
171 | /*-------------------------------------------------------------------------*/ | 171 | /*-------------------------------------------------------------------------*/ |
172 | 172 | ||
diff --git a/drivers/uwb/uwbd.c b/drivers/uwb/uwbd.c index 001c8b4020a8..bdcb13cc1d54 100644 --- a/drivers/uwb/uwbd.c +++ b/drivers/uwb/uwbd.c | |||
@@ -256,7 +256,7 @@ static void uwbd_event_handle(struct uwb_event *evt) | |||
256 | * UWB Daemon | 256 | * UWB Daemon |
257 | * | 257 | * |
258 | * Listens to all UWB notifications and takes care to track the state | 258 | * Listens to all UWB notifications and takes care to track the state |
259 | * of the UWB neighboorhood for the kernel. When we do a run, we | 259 | * of the UWB neighbourhood for the kernel. When we do a run, we |
260 | * spinlock, move the list to a private copy and release the | 260 | * spinlock, move the list to a private copy and release the |
261 | * lock. Hold it as little as possible. Not a conflict: it is | 261 | * lock. Hold it as little as possible. Not a conflict: it is |
262 | * guaranteed we own the events in the private list. | 262 | * guaranteed we own the events in the private list. |
diff --git a/drivers/uwb/whc-rc.c b/drivers/uwb/whc-rc.c index 70a004aa19db..3ae3c702500d 100644 --- a/drivers/uwb/whc-rc.c +++ b/drivers/uwb/whc-rc.c | |||
@@ -222,7 +222,7 @@ int whcrc_setup_rc_umc(struct whcrc *whcrc) | |||
222 | struct umc_dev *umc_dev = whcrc->umc_dev; | 222 | struct umc_dev *umc_dev = whcrc->umc_dev; |
223 | 223 | ||
224 | whcrc->area = umc_dev->resource.start; | 224 | whcrc->area = umc_dev->resource.start; |
225 | whcrc->rc_len = umc_dev->resource.end - umc_dev->resource.start + 1; | 225 | whcrc->rc_len = resource_size(&umc_dev->resource); |
226 | result = -EBUSY; | 226 | result = -EBUSY; |
227 | if (request_mem_region(whcrc->area, whcrc->rc_len, KBUILD_MODNAME) == NULL) { | 227 | if (request_mem_region(whcrc->area, whcrc->rc_len, KBUILD_MODNAME) == NULL) { |
228 | dev_err(dev, "can't request URC region (%zu bytes @ 0x%lx): %d\n", | 228 | dev_err(dev, "can't request URC region (%zu bytes @ 0x%lx): %d\n", |
diff --git a/drivers/video/atmel_lcdfb.c b/drivers/video/atmel_lcdfb.c index 4484c721f0f9..817ab60f7537 100644 --- a/drivers/video/atmel_lcdfb.c +++ b/drivers/video/atmel_lcdfb.c | |||
@@ -906,7 +906,7 @@ static int __init atmel_lcdfb_probe(struct platform_device *pdev) | |||
906 | if (map) { | 906 | if (map) { |
907 | /* use a pre-allocated memory buffer */ | 907 | /* use a pre-allocated memory buffer */ |
908 | info->fix.smem_start = map->start; | 908 | info->fix.smem_start = map->start; |
909 | info->fix.smem_len = map->end - map->start + 1; | 909 | info->fix.smem_len = resource_size(map); |
910 | if (!request_mem_region(info->fix.smem_start, | 910 | if (!request_mem_region(info->fix.smem_start, |
911 | info->fix.smem_len, pdev->name)) { | 911 | info->fix.smem_len, pdev->name)) { |
912 | ret = -EBUSY; | 912 | ret = -EBUSY; |
@@ -932,7 +932,7 @@ static int __init atmel_lcdfb_probe(struct platform_device *pdev) | |||
932 | 932 | ||
933 | /* LCDC registers */ | 933 | /* LCDC registers */ |
934 | info->fix.mmio_start = regs->start; | 934 | info->fix.mmio_start = regs->start; |
935 | info->fix.mmio_len = regs->end - regs->start + 1; | 935 | info->fix.mmio_len = resource_size(regs); |
936 | 936 | ||
937 | if (!request_mem_region(info->fix.mmio_start, | 937 | if (!request_mem_region(info->fix.mmio_start, |
938 | info->fix.mmio_len, pdev->name)) { | 938 | info->fix.mmio_len, pdev->name)) { |
diff --git a/drivers/video/aty/atyfb_base.c b/drivers/video/aty/atyfb_base.c index d7aaec5667bf..44bdce4242ad 100644 --- a/drivers/video/aty/atyfb_base.c +++ b/drivers/video/aty/atyfb_base.c | |||
@@ -3458,9 +3458,10 @@ static int __devinit atyfb_setup_generic(struct pci_dev *pdev, | |||
3458 | 3458 | ||
3459 | raddr = addr + 0x7ff000UL; | 3459 | raddr = addr + 0x7ff000UL; |
3460 | rrp = &pdev->resource[2]; | 3460 | rrp = &pdev->resource[2]; |
3461 | if ((rrp->flags & IORESOURCE_MEM) && request_mem_region(rrp->start, rrp->end - rrp->start + 1, "atyfb")) { | 3461 | if ((rrp->flags & IORESOURCE_MEM) && |
3462 | request_mem_region(rrp->start, resource_size(rrp), "atyfb")) { | ||
3462 | par->aux_start = rrp->start; | 3463 | par->aux_start = rrp->start; |
3463 | par->aux_size = rrp->end - rrp->start + 1; | 3464 | par->aux_size = resource_size(rrp); |
3464 | raddr = rrp->start; | 3465 | raddr = rrp->start; |
3465 | PRINTKI("using auxiliary register aperture\n"); | 3466 | PRINTKI("using auxiliary register aperture\n"); |
3466 | } | 3467 | } |
@@ -3550,7 +3551,7 @@ static int __devinit atyfb_pci_probe(struct pci_dev *pdev, | |||
3550 | 3551 | ||
3551 | /* Reserve space */ | 3552 | /* Reserve space */ |
3552 | res_start = rp->start; | 3553 | res_start = rp->start; |
3553 | res_size = rp->end - rp->start + 1; | 3554 | res_size = resource_size(rp); |
3554 | if (!request_mem_region(res_start, res_size, "atyfb")) | 3555 | if (!request_mem_region(res_start, res_size, "atyfb")) |
3555 | return -EBUSY; | 3556 | return -EBUSY; |
3556 | 3557 | ||
diff --git a/drivers/video/au1100fb.c b/drivers/video/au1100fb.c index 34b2fc472fe8..01a8fde67f20 100644 --- a/drivers/video/au1100fb.c +++ b/drivers/video/au1100fb.c | |||
@@ -486,7 +486,7 @@ static int __devinit au1100fb_drv_probe(struct platform_device *dev) | |||
486 | } | 486 | } |
487 | 487 | ||
488 | au1100fb_fix.mmio_start = regs_res->start; | 488 | au1100fb_fix.mmio_start = regs_res->start; |
489 | au1100fb_fix.mmio_len = regs_res->end - regs_res->start + 1; | 489 | au1100fb_fix.mmio_len = resource_size(regs_res); |
490 | 490 | ||
491 | if (!request_mem_region(au1100fb_fix.mmio_start, au1100fb_fix.mmio_len, | 491 | if (!request_mem_region(au1100fb_fix.mmio_start, au1100fb_fix.mmio_len, |
492 | DRIVER_NAME)) { | 492 | DRIVER_NAME)) { |
diff --git a/drivers/video/cobalt_lcdfb.c b/drivers/video/cobalt_lcdfb.c index 42fe155aba0e..e02764319ff7 100644 --- a/drivers/video/cobalt_lcdfb.c +++ b/drivers/video/cobalt_lcdfb.c | |||
@@ -303,7 +303,7 @@ static int __devinit cobalt_lcdfb_probe(struct platform_device *dev) | |||
303 | return -EBUSY; | 303 | return -EBUSY; |
304 | } | 304 | } |
305 | 305 | ||
306 | info->screen_size = res->end - res->start + 1; | 306 | info->screen_size = resource_size(res); |
307 | info->screen_base = ioremap(res->start, info->screen_size); | 307 | info->screen_base = ioremap(res->start, info->screen_size); |
308 | info->fbops = &cobalt_lcd_fbops; | 308 | info->fbops = &cobalt_lcd_fbops; |
309 | info->fix = cobalt_lcdfb_fix; | 309 | info->fix = cobalt_lcdfb_fix; |
diff --git a/drivers/video/controlfb.c b/drivers/video/controlfb.c index c225dcce89e7..9075bea55879 100644 --- a/drivers/video/controlfb.c +++ b/drivers/video/controlfb.c | |||
@@ -709,11 +709,11 @@ static int __init control_of_init(struct device_node *dp) | |||
709 | 709 | ||
710 | /* Map in frame buffer and registers */ | 710 | /* Map in frame buffer and registers */ |
711 | p->fb_orig_base = fb_res.start; | 711 | p->fb_orig_base = fb_res.start; |
712 | p->fb_orig_size = fb_res.end - fb_res.start + 1; | 712 | p->fb_orig_size = resource_size(&fb_res); |
713 | /* use the big-endian aperture (??) */ | 713 | /* use the big-endian aperture (??) */ |
714 | p->frame_buffer_phys = fb_res.start + 0x800000; | 714 | p->frame_buffer_phys = fb_res.start + 0x800000; |
715 | p->control_regs_phys = reg_res.start; | 715 | p->control_regs_phys = reg_res.start; |
716 | p->control_regs_size = reg_res.end - reg_res.start + 1; | 716 | p->control_regs_size = resource_size(®_res); |
717 | 717 | ||
718 | if (!p->fb_orig_base || | 718 | if (!p->fb_orig_base || |
719 | !request_mem_region(p->fb_orig_base,p->fb_orig_size,"controlfb")) { | 719 | !request_mem_region(p->fb_orig_base,p->fb_orig_size,"controlfb")) { |
diff --git a/drivers/video/ep93xx-fb.c b/drivers/video/ep93xx-fb.c index cbdb1bd77c21..40e5f17d1e4b 100644 --- a/drivers/video/ep93xx-fb.c +++ b/drivers/video/ep93xx-fb.c | |||
@@ -4,7 +4,7 @@ | |||
4 | * Framebuffer support for the EP93xx series. | 4 | * Framebuffer support for the EP93xx series. |
5 | * | 5 | * |
6 | * Copyright (C) 2007 Bluewater Systems Ltd | 6 | * Copyright (C) 2007 Bluewater Systems Ltd |
7 | * Author: Ryan Mallon <ryan@bluewatersys.com> | 7 | * Author: Ryan Mallon |
8 | * | 8 | * |
9 | * Copyright (c) 2009 H Hartley Sweeten <hsweeten@visionengravers.com> | 9 | * Copyright (c) 2009 H Hartley Sweeten <hsweeten@visionengravers.com> |
10 | * | 10 | * |
@@ -644,6 +644,6 @@ module_exit(ep93xxfb_exit); | |||
644 | 644 | ||
645 | MODULE_DESCRIPTION("EP93XX Framebuffer Driver"); | 645 | MODULE_DESCRIPTION("EP93XX Framebuffer Driver"); |
646 | MODULE_ALIAS("platform:ep93xx-fb"); | 646 | MODULE_ALIAS("platform:ep93xx-fb"); |
647 | MODULE_AUTHOR("Ryan Mallon <ryan&bluewatersys.com>, " | 647 | MODULE_AUTHOR("Ryan Mallon, " |
648 | "H Hartley Sweeten <hsweeten@visionengravers.com"); | 648 | "H Hartley Sweeten <hsweeten@visionengravers.com"); |
649 | MODULE_LICENSE("GPL"); | 649 | MODULE_LICENSE("GPL"); |
diff --git a/drivers/video/i810/i810.h b/drivers/video/i810/i810.h index f37de60ecc59..1414b73ac55b 100644 --- a/drivers/video/i810/i810.h +++ b/drivers/video/i810/i810.h | |||
@@ -137,7 +137,7 @@ | |||
137 | #define DRAM_ON 0x08 | 137 | #define DRAM_ON 0x08 |
138 | #define DRAM_OFF 0xE7 | 138 | #define DRAM_OFF 0xE7 |
139 | #define PG_ENABLE_MASK 0x01 | 139 | #define PG_ENABLE_MASK 0x01 |
140 | #define RING_SIZE_MASK (RINGBUFFER_SIZE - 1); | 140 | #define RING_SIZE_MASK (RINGBUFFER_SIZE - 1) |
141 | 141 | ||
142 | /* defines for restoring registers partially */ | 142 | /* defines for restoring registers partially */ |
143 | #define ADDR_MAP_MASK (0x07 << 5) | 143 | #define ADDR_MAP_MASK (0x07 << 5) |
diff --git a/drivers/video/mb862xx/mb862xxfbdrv.c b/drivers/video/mb862xx/mb862xxfbdrv.c index f70bd63b0187..ee1de3e26dec 100644 --- a/drivers/video/mb862xx/mb862xxfbdrv.c +++ b/drivers/video/mb862xx/mb862xxfbdrv.c | |||
@@ -697,7 +697,7 @@ static int __devinit of_platform_mb862xx_probe(struct platform_device *ofdev) | |||
697 | goto fbrel; | 697 | goto fbrel; |
698 | } | 698 | } |
699 | 699 | ||
700 | res_size = 1 + res.end - res.start; | 700 | res_size = resource_size(&res); |
701 | par->res = request_mem_region(res.start, res_size, DRV_NAME); | 701 | par->res = request_mem_region(res.start, res_size, DRV_NAME); |
702 | if (par->res == NULL) { | 702 | if (par->res == NULL) { |
703 | dev_err(dev, "Cannot claim framebuffer/mmio\n"); | 703 | dev_err(dev, "Cannot claim framebuffer/mmio\n"); |
@@ -787,7 +787,7 @@ static int __devexit of_platform_mb862xx_remove(struct platform_device *ofdev) | |||
787 | { | 787 | { |
788 | struct fb_info *fbi = dev_get_drvdata(&ofdev->dev); | 788 | struct fb_info *fbi = dev_get_drvdata(&ofdev->dev); |
789 | struct mb862xxfb_par *par = fbi->par; | 789 | struct mb862xxfb_par *par = fbi->par; |
790 | resource_size_t res_size = 1 + par->res->end - par->res->start; | 790 | resource_size_t res_size = resource_size(par->res); |
791 | unsigned long reg; | 791 | unsigned long reg; |
792 | 792 | ||
793 | dev_dbg(fbi->dev, "%s release\n", fbi->fix.id); | 793 | dev_dbg(fbi->dev, "%s release\n", fbi->fix.id); |
diff --git a/drivers/video/msm/mdp.c b/drivers/video/msm/mdp.c index c3636d55a3c5..243d16f09b8a 100644 --- a/drivers/video/msm/mdp.c +++ b/drivers/video/msm/mdp.c | |||
@@ -406,8 +406,7 @@ int mdp_probe(struct platform_device *pdev) | |||
406 | goto error_get_irq; | 406 | goto error_get_irq; |
407 | } | 407 | } |
408 | 408 | ||
409 | mdp->base = ioremap(resource->start, | 409 | mdp->base = ioremap(resource->start, resource_size(resource)); |
410 | resource->end - resource->start); | ||
411 | if (mdp->base == 0) { | 410 | if (mdp->base == 0) { |
412 | printk(KERN_ERR "msmfb: cannot allocate mdp regs!\n"); | 411 | printk(KERN_ERR "msmfb: cannot allocate mdp regs!\n"); |
413 | ret = -ENOMEM; | 412 | ret = -ENOMEM; |
diff --git a/drivers/video/msm/msm_fb.c b/drivers/video/msm/msm_fb.c index ec351309e607..c6e3b4fcdd68 100644 --- a/drivers/video/msm/msm_fb.c +++ b/drivers/video/msm/msm_fb.c | |||
@@ -525,10 +525,9 @@ static int setup_fbmem(struct msmfb_info *msmfb, struct platform_device *pdev) | |||
525 | return -ENOMEM; | 525 | return -ENOMEM; |
526 | } | 526 | } |
527 | fb->fix.smem_start = resource->start; | 527 | fb->fix.smem_start = resource->start; |
528 | fb->fix.smem_len = resource->end - resource->start; | 528 | fb->fix.smem_len = resource_size(resource); |
529 | fbram = ioremap(resource->start, | 529 | fbram = ioremap(resource->start, resource_size(resource)); |
530 | resource->end - resource->start); | 530 | if (fbram == NULL) { |
531 | if (fbram == 0) { | ||
532 | printk(KERN_ERR "msmfb: cannot allocate fbram!\n"); | 531 | printk(KERN_ERR "msmfb: cannot allocate fbram!\n"); |
533 | return -ENOMEM; | 532 | return -ENOMEM; |
534 | } | 533 | } |
diff --git a/drivers/video/nuc900fb.c b/drivers/video/nuc900fb.c index f838d9e277f0..0fff59782e45 100644 --- a/drivers/video/nuc900fb.c +++ b/drivers/video/nuc900fb.c | |||
@@ -551,7 +551,7 @@ static int __devinit nuc900fb_probe(struct platform_device *pdev) | |||
551 | 551 | ||
552 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | 552 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
553 | 553 | ||
554 | size = (res->end - res->start) + 1; | 554 | size = resource_size(res); |
555 | fbi->mem = request_mem_region(res->start, size, pdev->name); | 555 | fbi->mem = request_mem_region(res->start, size, pdev->name); |
556 | if (fbi->mem == NULL) { | 556 | if (fbi->mem == NULL) { |
557 | dev_err(&pdev->dev, "failed to alloc memory region\n"); | 557 | dev_err(&pdev->dev, "failed to alloc memory region\n"); |
diff --git a/drivers/video/platinumfb.c b/drivers/video/platinumfb.c index ef532d9d3c99..f27ae16ead2e 100644 --- a/drivers/video/platinumfb.c +++ b/drivers/video/platinumfb.c | |||
@@ -567,7 +567,7 @@ static int __devinit platinumfb_probe(struct platform_device* odev) | |||
567 | * northbridge and that can fail. Only request framebuffer | 567 | * northbridge and that can fail. Only request framebuffer |
568 | */ | 568 | */ |
569 | if (!request_mem_region(pinfo->rsrc_fb.start, | 569 | if (!request_mem_region(pinfo->rsrc_fb.start, |
570 | pinfo->rsrc_fb.end - pinfo->rsrc_fb.start + 1, | 570 | resource_size(&pinfo->rsrc_fb), |
571 | "platinumfb framebuffer")) { | 571 | "platinumfb framebuffer")) { |
572 | printk(KERN_ERR "platinumfb: Can't request framebuffer !\n"); | 572 | printk(KERN_ERR "platinumfb: Can't request framebuffer !\n"); |
573 | framebuffer_release(info); | 573 | framebuffer_release(info); |
@@ -658,8 +658,7 @@ static int __devexit platinumfb_remove(struct platform_device* odev) | |||
658 | iounmap(pinfo->cmap_regs); | 658 | iounmap(pinfo->cmap_regs); |
659 | 659 | ||
660 | release_mem_region(pinfo->rsrc_fb.start, | 660 | release_mem_region(pinfo->rsrc_fb.start, |
661 | pinfo->rsrc_fb.end - | 661 | resource_size(&pinfo->rsrc_fb)); |
662 | pinfo->rsrc_fb.start + 1); | ||
663 | 662 | ||
664 | release_mem_region(pinfo->cmap_regs_phys, 0x1000); | 663 | release_mem_region(pinfo->cmap_regs_phys, 0x1000); |
665 | 664 | ||
diff --git a/drivers/video/pxa168fb.c b/drivers/video/pxa168fb.c index bb95ec56d25d..18ead6f0184d 100644 --- a/drivers/video/pxa168fb.c +++ b/drivers/video/pxa168fb.c | |||
@@ -662,7 +662,7 @@ static int __devinit pxa168fb_probe(struct platform_device *pdev) | |||
662 | info->fix.ypanstep = 0; | 662 | info->fix.ypanstep = 0; |
663 | info->fix.ywrapstep = 0; | 663 | info->fix.ywrapstep = 0; |
664 | info->fix.mmio_start = res->start; | 664 | info->fix.mmio_start = res->start; |
665 | info->fix.mmio_len = res->end - res->start + 1; | 665 | info->fix.mmio_len = resource_size(res); |
666 | info->fix.accel = FB_ACCEL_NONE; | 666 | info->fix.accel = FB_ACCEL_NONE; |
667 | info->fbops = &pxa168fb_ops; | 667 | info->fbops = &pxa168fb_ops; |
668 | info->pseudo_palette = fbi->pseudo_palette; | 668 | info->pseudo_palette = fbi->pseudo_palette; |
diff --git a/drivers/video/udlfb.c b/drivers/video/udlfb.c index 816a4fda04f5..087fc9960bb9 100644 --- a/drivers/video/udlfb.c +++ b/drivers/video/udlfb.c | |||
@@ -29,7 +29,6 @@ | |||
29 | #include <linux/slab.h> | 29 | #include <linux/slab.h> |
30 | #include <linux/prefetch.h> | 30 | #include <linux/prefetch.h> |
31 | #include <linux/delay.h> | 31 | #include <linux/delay.h> |
32 | #include <linux/prefetch.h> | ||
33 | #include <video/udlfb.h> | 32 | #include <video/udlfb.h> |
34 | #include "edid.h" | 33 | #include "edid.h" |
35 | 34 | ||
diff --git a/drivers/video/via/viafbdev.c b/drivers/video/via/viafbdev.c index cf43c80d27f6..53aa4430d86e 100644 --- a/drivers/video/via/viafbdev.c +++ b/drivers/video/via/viafbdev.c | |||
@@ -2016,7 +2016,7 @@ static int __init viafb_setup(void) | |||
2016 | int __init viafb_init(void) | 2016 | int __init viafb_init(void) |
2017 | { | 2017 | { |
2018 | u32 dummy_x, dummy_y; | 2018 | u32 dummy_x, dummy_y; |
2019 | int r; | 2019 | int r = 0; |
2020 | 2020 | ||
2021 | if (machine_is_olpc()) | 2021 | if (machine_is_olpc()) |
2022 | /* Apply XO-1.5-specific configuration. */ | 2022 | /* Apply XO-1.5-specific configuration. */ |
@@ -2039,7 +2039,7 @@ int __init viafb_init(void) | |||
2039 | printk(KERN_INFO | 2039 | printk(KERN_INFO |
2040 | "VIA Graphics Integration Chipset framebuffer %d.%d initializing\n", | 2040 | "VIA Graphics Integration Chipset framebuffer %d.%d initializing\n", |
2041 | VERSION_MAJOR, VERSION_MINOR); | 2041 | VERSION_MAJOR, VERSION_MINOR); |
2042 | return 0; | 2042 | return r; |
2043 | } | 2043 | } |
2044 | 2044 | ||
2045 | void __exit viafb_exit(void) | 2045 | void __exit viafb_exit(void) |
diff --git a/fs/ecryptfs/keystore.c b/fs/ecryptfs/keystore.c index 27a7fefb83eb..fa8049ecdc64 100644 --- a/fs/ecryptfs/keystore.c +++ b/fs/ecryptfs/keystore.c | |||
@@ -2248,7 +2248,7 @@ write_tag_3_packet(char *dest, size_t *remaining_bytes, | |||
2248 | auth_tok->token.password.session_key_encryption_key, | 2248 | auth_tok->token.password.session_key_encryption_key, |
2249 | crypt_stat->key_size); | 2249 | crypt_stat->key_size); |
2250 | ecryptfs_printk(KERN_DEBUG, | 2250 | ecryptfs_printk(KERN_DEBUG, |
2251 | "Cached session key " "encryption key: \n"); | 2251 | "Cached session key encryption key:\n"); |
2252 | if (ecryptfs_verbosity > 0) | 2252 | if (ecryptfs_verbosity > 0) |
2253 | ecryptfs_dump_hex(session_key_encryption_key, 16); | 2253 | ecryptfs_dump_hex(session_key_encryption_key, 16); |
2254 | } | 2254 | } |
diff --git a/fs/jffs2/readinode.c b/fs/jffs2/readinode.c index 2ab1a0d91210..ee57bac1ba6d 100644 --- a/fs/jffs2/readinode.c +++ b/fs/jffs2/readinode.c | |||
@@ -1041,7 +1041,7 @@ static int jffs2_get_inode_nodes(struct jffs2_sb_info *c, struct jffs2_inode_inf | |||
1041 | /* FIXME: point() */ | 1041 | /* FIXME: point() */ |
1042 | err = jffs2_flash_read(c, ref_offset(ref), len, &retlen, buf); | 1042 | err = jffs2_flash_read(c, ref_offset(ref), len, &retlen, buf); |
1043 | if (err) { | 1043 | if (err) { |
1044 | JFFS2_ERROR("can not read %d bytes from 0x%08x, " "error code: %d.\n", len, ref_offset(ref), err); | 1044 | JFFS2_ERROR("can not read %d bytes from 0x%08x, error code: %d.\n", len, ref_offset(ref), err); |
1045 | goto free_out; | 1045 | goto free_out; |
1046 | } | 1046 | } |
1047 | 1047 | ||
diff --git a/fs/nfs/idmap.c b/fs/nfs/idmap.c index 79664a1025af..f20801ae0a16 100644 --- a/fs/nfs/idmap.c +++ b/fs/nfs/idmap.c | |||
@@ -36,6 +36,8 @@ | |||
36 | #include <linux/types.h> | 36 | #include <linux/types.h> |
37 | #include <linux/string.h> | 37 | #include <linux/string.h> |
38 | #include <linux/kernel.h> | 38 | #include <linux/kernel.h> |
39 | #include <linux/slab.h> | ||
40 | #include <linux/nfs_idmap.h> | ||
39 | 41 | ||
40 | static int nfs_map_string_to_numeric(const char *name, size_t namelen, __u32 *res) | 42 | static int nfs_map_string_to_numeric(const char *name, size_t namelen, __u32 *res) |
41 | { | 43 | { |
@@ -59,12 +61,10 @@ static int nfs_map_numeric_to_string(__u32 id, char *buf, size_t buflen) | |||
59 | 61 | ||
60 | #ifdef CONFIG_NFS_USE_NEW_IDMAPPER | 62 | #ifdef CONFIG_NFS_USE_NEW_IDMAPPER |
61 | 63 | ||
62 | #include <linux/slab.h> | ||
63 | #include <linux/cred.h> | 64 | #include <linux/cred.h> |
64 | #include <linux/sunrpc/sched.h> | 65 | #include <linux/sunrpc/sched.h> |
65 | #include <linux/nfs4.h> | 66 | #include <linux/nfs4.h> |
66 | #include <linux/nfs_fs_sb.h> | 67 | #include <linux/nfs_fs_sb.h> |
67 | #include <linux/nfs_idmap.h> | ||
68 | #include <linux/keyctl.h> | 68 | #include <linux/keyctl.h> |
69 | #include <linux/key-type.h> | 69 | #include <linux/key-type.h> |
70 | #include <linux/rcupdate.h> | 70 | #include <linux/rcupdate.h> |
@@ -284,18 +284,15 @@ int nfs_map_gid_to_group(const struct nfs_server *server, __u32 gid, char *buf, | |||
284 | #include <linux/module.h> | 284 | #include <linux/module.h> |
285 | #include <linux/mutex.h> | 285 | #include <linux/mutex.h> |
286 | #include <linux/init.h> | 286 | #include <linux/init.h> |
287 | #include <linux/slab.h> | ||
288 | #include <linux/socket.h> | 287 | #include <linux/socket.h> |
289 | #include <linux/in.h> | 288 | #include <linux/in.h> |
290 | #include <linux/sched.h> | 289 | #include <linux/sched.h> |
291 | |||
292 | #include <linux/sunrpc/clnt.h> | 290 | #include <linux/sunrpc/clnt.h> |
293 | #include <linux/workqueue.h> | 291 | #include <linux/workqueue.h> |
294 | #include <linux/sunrpc/rpc_pipe_fs.h> | 292 | #include <linux/sunrpc/rpc_pipe_fs.h> |
295 | 293 | ||
296 | #include <linux/nfs_fs.h> | 294 | #include <linux/nfs_fs.h> |
297 | 295 | ||
298 | #include <linux/nfs_idmap.h> | ||
299 | #include "nfs4_fs.h" | 296 | #include "nfs4_fs.h" |
300 | 297 | ||
301 | #define IDMAP_HASH_SZ 128 | 298 | #define IDMAP_HASH_SZ 128 |
diff --git a/fs/ocfs2/move_extents.c b/fs/ocfs2/move_extents.c index cd9427023d2e..d53cb706f14c 100644 --- a/fs/ocfs2/move_extents.c +++ b/fs/ocfs2/move_extents.c | |||
@@ -36,7 +36,6 @@ | |||
36 | #include "dir.h" | 36 | #include "dir.h" |
37 | #include "buffer_head_io.h" | 37 | #include "buffer_head_io.h" |
38 | #include "sysfile.h" | 38 | #include "sysfile.h" |
39 | #include "suballoc.h" | ||
40 | #include "refcounttree.h" | 39 | #include "refcounttree.h" |
41 | #include "move_extents.h" | 40 | #include "move_extents.h" |
42 | 41 | ||
diff --git a/fs/xfs/xfs_dir2_node.c b/fs/xfs/xfs_dir2_node.c index 084b3247d636..0179a41d9e5a 100644 --- a/fs/xfs/xfs_dir2_node.c +++ b/fs/xfs/xfs_dir2_node.c | |||
@@ -1564,7 +1564,7 @@ xfs_dir2_node_addname_int( | |||
1564 | 1564 | ||
1565 | if (unlikely(xfs_dir2_db_to_fdb(mp, dbno) != fbno)) { | 1565 | if (unlikely(xfs_dir2_db_to_fdb(mp, dbno) != fbno)) { |
1566 | xfs_alert(mp, | 1566 | xfs_alert(mp, |
1567 | "%s: dir ino " "%llu needed freesp block %lld for\n" | 1567 | "%s: dir ino %llu needed freesp block %lld for\n" |
1568 | " data block %lld, got %lld ifbno %llu lastfbno %d", | 1568 | " data block %lld, got %lld ifbno %llu lastfbno %d", |
1569 | __func__, (unsigned long long)dp->i_ino, | 1569 | __func__, (unsigned long long)dp->i_ino, |
1570 | (long long)xfs_dir2_db_to_fdb(mp, dbno), | 1570 | (long long)xfs_dir2_db_to_fdb(mp, dbno), |
diff --git a/include/linux/ceph/libceph.h b/include/linux/ceph/libceph.h index 6365f041745b..563755181c1e 100644 --- a/include/linux/ceph/libceph.h +++ b/include/linux/ceph/libceph.h | |||
@@ -35,7 +35,7 @@ | |||
35 | #define CEPH_OPT_MYIP (1<<2) /* specified my ip */ | 35 | #define CEPH_OPT_MYIP (1<<2) /* specified my ip */ |
36 | #define CEPH_OPT_NOCRC (1<<3) /* no data crc on writes */ | 36 | #define CEPH_OPT_NOCRC (1<<3) /* no data crc on writes */ |
37 | 37 | ||
38 | #define CEPH_OPT_DEFAULT (0); | 38 | #define CEPH_OPT_DEFAULT (0) |
39 | 39 | ||
40 | #define ceph_set_opt(client, opt) \ | 40 | #define ceph_set_opt(client, opt) \ |
41 | (client)->options->flags |= CEPH_OPT_##opt; | 41 | (client)->options->flags |= CEPH_OPT_##opt; |
diff --git a/include/linux/cgroup.h b/include/linux/cgroup.h index ab4ac0ccb857..da7e4bc34e8c 100644 --- a/include/linux/cgroup.h +++ b/include/linux/cgroup.h | |||
@@ -539,7 +539,6 @@ static inline struct cgroup_subsys_state *cgroup_subsys_state( | |||
539 | */ | 539 | */ |
540 | #define task_subsys_state_check(task, subsys_id, __c) \ | 540 | #define task_subsys_state_check(task, subsys_id, __c) \ |
541 | rcu_dereference_check(task->cgroups->subsys[subsys_id], \ | 541 | rcu_dereference_check(task->cgroups->subsys[subsys_id], \ |
542 | rcu_read_lock_held() || \ | ||
543 | lockdep_is_held(&task->alloc_lock) || \ | 542 | lockdep_is_held(&task->alloc_lock) || \ |
544 | cgroup_lock_is_held() || (__c)) | 543 | cgroup_lock_is_held() || (__c)) |
545 | 544 | ||
diff --git a/include/linux/cred.h b/include/linux/cred.h index 82607992f308..f240f2fa0197 100644 --- a/include/linux/cred.h +++ b/include/linux/cred.h | |||
@@ -284,7 +284,6 @@ static inline void put_cred(const struct cred *_cred) | |||
284 | ({ \ | 284 | ({ \ |
285 | const struct task_struct *__t = (task); \ | 285 | const struct task_struct *__t = (task); \ |
286 | rcu_dereference_check(__t->real_cred, \ | 286 | rcu_dereference_check(__t->real_cred, \ |
287 | rcu_read_lock_held() || \ | ||
288 | task_is_dead(__t)); \ | 287 | task_is_dead(__t)); \ |
289 | }) | 288 | }) |
290 | 289 | ||
diff --git a/include/linux/dio.h b/include/linux/dio.h index b2dd31ca1710..2cc0fd00463f 100644 --- a/include/linux/dio.h +++ b/include/linux/dio.h | |||
@@ -254,7 +254,7 @@ static inline struct dio_driver *dio_dev_driver(const struct dio_dev *d) | |||
254 | 254 | ||
255 | #define dio_resource_start(d) ((d)->resource.start) | 255 | #define dio_resource_start(d) ((d)->resource.start) |
256 | #define dio_resource_end(d) ((d)->resource.end) | 256 | #define dio_resource_end(d) ((d)->resource.end) |
257 | #define dio_resource_len(d) ((d)->resource.end-(d)->resource.start+1) | 257 | #define dio_resource_len(d) (resource_size(&(d)->resource)) |
258 | #define dio_resource_flags(d) ((d)->resource.flags) | 258 | #define dio_resource_flags(d) ((d)->resource.flags) |
259 | 259 | ||
260 | #define dio_request_device(d, name) \ | 260 | #define dio_request_device(d, name) \ |
diff --git a/include/linux/fdtable.h b/include/linux/fdtable.h index 133c0ba25e30..df7e3cf82e97 100644 --- a/include/linux/fdtable.h +++ b/include/linux/fdtable.h | |||
@@ -60,7 +60,6 @@ struct files_struct { | |||
60 | 60 | ||
61 | #define rcu_dereference_check_fdtable(files, fdtfd) \ | 61 | #define rcu_dereference_check_fdtable(files, fdtfd) \ |
62 | (rcu_dereference_check((fdtfd), \ | 62 | (rcu_dereference_check((fdtfd), \ |
63 | rcu_read_lock_held() || \ | ||
64 | lockdep_is_held(&(files)->file_lock) || \ | 63 | lockdep_is_held(&(files)->file_lock) || \ |
65 | atomic_read(&(files)->count) == 1 || \ | 64 | atomic_read(&(files)->count) == 1 || \ |
66 | rcu_my_thread_group_empty())) | 65 | rcu_my_thread_group_empty())) |
diff --git a/include/linux/fs.h b/include/linux/fs.h index 292f8a7d4089..a6658043258a 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -379,7 +379,6 @@ struct inodes_stat_t { | |||
379 | 379 | ||
380 | #include <linux/linkage.h> | 380 | #include <linux/linkage.h> |
381 | #include <linux/wait.h> | 381 | #include <linux/wait.h> |
382 | #include <linux/types.h> | ||
383 | #include <linux/kdev_t.h> | 382 | #include <linux/kdev_t.h> |
384 | #include <linux/dcache.h> | 383 | #include <linux/dcache.h> |
385 | #include <linux/path.h> | 384 | #include <linux/path.h> |
diff --git a/include/linux/hw_random.h b/include/linux/hw_random.h index 9bede7633f74..b4b0eef5fddf 100644 --- a/include/linux/hw_random.h +++ b/include/linux/hw_random.h | |||
@@ -25,7 +25,7 @@ | |||
25 | * there is always data available. *OBSOLETE* | 25 | * there is always data available. *OBSOLETE* |
26 | * @data_read: Read data from the RNG device. | 26 | * @data_read: Read data from the RNG device. |
27 | * Returns the number of lower random bytes in "data". | 27 | * Returns the number of lower random bytes in "data". |
28 | * Must not be NULL. *OSOLETE* | 28 | * Must not be NULL. *OBSOLETE* |
29 | * @read: New API. drivers can fill up to max bytes of data | 29 | * @read: New API. drivers can fill up to max bytes of data |
30 | * into the buffer. The buffer is aligned for any type. | 30 | * into the buffer. The buffer is aligned for any type. |
31 | * @priv: Private data, for use by the RNG driver. | 31 | * @priv: Private data, for use by the RNG driver. |
diff --git a/include/linux/mfd/tps65910.h b/include/linux/mfd/tps65910.h index 8bb85b930c07..73572c65d04f 100644 --- a/include/linux/mfd/tps65910.h +++ b/include/linux/mfd/tps65910.h | |||
@@ -269,7 +269,7 @@ | |||
269 | #define LDO1_SEL_MASK 0xFC | 269 | #define LDO1_SEL_MASK 0xFC |
270 | #define LDO3_SEL_MASK 0x7C | 270 | #define LDO3_SEL_MASK 0x7C |
271 | #define LDO_MIN_VOLT 1000 | 271 | #define LDO_MIN_VOLT 1000 |
272 | #define LDO_MAX_VOLT 3300; | 272 | #define LDO_MAX_VOLT 3300 |
273 | 273 | ||
274 | 274 | ||
275 | /*Register VDIG1 (0x80) register.RegisterDescription */ | 275 | /*Register VDIG1 (0x80) register.RegisterDescription */ |
diff --git a/include/linux/nl80211.h b/include/linux/nl80211.h index e4da76c9e4d9..8ad70dcac3f9 100644 --- a/include/linux/nl80211.h +++ b/include/linux/nl80211.h | |||
@@ -6,7 +6,7 @@ | |||
6 | * Copyright 2006-2010 Johannes Berg <johannes@sipsolutions.net> | 6 | * Copyright 2006-2010 Johannes Berg <johannes@sipsolutions.net> |
7 | * Copyright 2008 Michael Wu <flamingice@sourmilk.net> | 7 | * Copyright 2008 Michael Wu <flamingice@sourmilk.net> |
8 | * Copyright 2008 Luis Carlos Cobo <luisca@cozybit.com> | 8 | * Copyright 2008 Luis Carlos Cobo <luisca@cozybit.com> |
9 | * Copyright 2008 Michael Buesch <mb@bu3sch.de> | 9 | * Copyright 2008 Michael Buesch <m@bues.ch> |
10 | * Copyright 2008, 2009 Luis R. Rodriguez <lrodriguez@atheros.com> | 10 | * Copyright 2008, 2009 Luis R. Rodriguez <lrodriguez@atheros.com> |
11 | * Copyright 2008 Jouni Malinen <jouni.malinen@atheros.com> | 11 | * Copyright 2008 Jouni Malinen <jouni.malinen@atheros.com> |
12 | * Copyright 2008 Colin McCabe <colin@cozybit.com> | 12 | * Copyright 2008 Colin McCabe <colin@cozybit.com> |
diff --git a/include/linux/pnp.h b/include/linux/pnp.h index 1bc1338b817b..195aafc6cd07 100644 --- a/include/linux/pnp.h +++ b/include/linux/pnp.h | |||
@@ -50,7 +50,7 @@ static inline resource_size_t pnp_resource_len(struct resource *res) | |||
50 | { | 50 | { |
51 | if (res->start == 0 && res->end == 0) | 51 | if (res->start == 0 && res->end == 0) |
52 | return 0; | 52 | return 0; |
53 | return res->end - res->start + 1; | 53 | return resource_size(res); |
54 | } | 54 | } |
55 | 55 | ||
56 | 56 | ||
diff --git a/include/linux/rtnetlink.h b/include/linux/rtnetlink.h index c81226a9a35c..8e872ead88b5 100644 --- a/include/linux/rtnetlink.h +++ b/include/linux/rtnetlink.h | |||
@@ -760,8 +760,7 @@ extern int lockdep_rtnl_is_held(void); | |||
760 | * or RTNL. Note : Please prefer rtnl_dereference() or rcu_dereference() | 760 | * or RTNL. Note : Please prefer rtnl_dereference() or rcu_dereference() |
761 | */ | 761 | */ |
762 | #define rcu_dereference_rtnl(p) \ | 762 | #define rcu_dereference_rtnl(p) \ |
763 | rcu_dereference_check(p, rcu_read_lock_held() || \ | 763 | rcu_dereference_check(p, lockdep_rtnl_is_held()) |
764 | lockdep_rtnl_is_held()) | ||
765 | 764 | ||
766 | /** | 765 | /** |
767 | * rtnl_dereference - fetch RCU pointer when updates are prevented by RTNL | 766 | * rtnl_dereference - fetch RCU pointer when updates are prevented by RTNL |
diff --git a/include/linux/ssb/ssb_driver_chipcommon.h b/include/linux/ssb/ssb_driver_chipcommon.h index a08d693d8324..1a6b0045b06b 100644 --- a/include/linux/ssb/ssb_driver_chipcommon.h +++ b/include/linux/ssb/ssb_driver_chipcommon.h | |||
@@ -8,7 +8,7 @@ | |||
8 | * gpio interface, extbus, and support for serial and parallel flashes. | 8 | * gpio interface, extbus, and support for serial and parallel flashes. |
9 | * | 9 | * |
10 | * Copyright 2005, Broadcom Corporation | 10 | * Copyright 2005, Broadcom Corporation |
11 | * Copyright 2006, Michael Buesch <mb@bu3sch.de> | 11 | * Copyright 2006, Michael Buesch <m@bues.ch> |
12 | * | 12 | * |
13 | * Licensed under the GPL version 2. See COPYING for details. | 13 | * Licensed under the GPL version 2. See COPYING for details. |
14 | */ | 14 | */ |
diff --git a/include/linux/stop_machine.h b/include/linux/stop_machine.h index 4a9d0c7edc65..2d04ea916760 100644 --- a/include/linux/stop_machine.h +++ b/include/linux/stop_machine.h | |||
@@ -94,7 +94,7 @@ static inline int try_stop_cpus(const struct cpumask *cpumask, | |||
94 | * stop_machine "Bogolock": stop the entire machine, disable | 94 | * stop_machine "Bogolock": stop the entire machine, disable |
95 | * interrupts. This is a very heavy lock, which is equivalent to | 95 | * interrupts. This is a very heavy lock, which is equivalent to |
96 | * grabbing every spinlock (and more). So the "read" side to such a | 96 | * grabbing every spinlock (and more). So the "read" side to such a |
97 | * lock is anything which disables preeempt. | 97 | * lock is anything which disables preemption. |
98 | */ | 98 | */ |
99 | #if defined(CONFIG_STOP_MACHINE) && defined(CONFIG_SMP) | 99 | #if defined(CONFIG_STOP_MACHINE) && defined(CONFIG_SMP) |
100 | 100 | ||
diff --git a/include/linux/zorro.h b/include/linux/zorro.h index 7bf9db525e9e..dff42025649b 100644 --- a/include/linux/zorro.h +++ b/include/linux/zorro.h | |||
@@ -187,7 +187,7 @@ extern struct zorro_dev *zorro_find_device(zorro_id id, | |||
187 | 187 | ||
188 | #define zorro_resource_start(z) ((z)->resource.start) | 188 | #define zorro_resource_start(z) ((z)->resource.start) |
189 | #define zorro_resource_end(z) ((z)->resource.end) | 189 | #define zorro_resource_end(z) ((z)->resource.end) |
190 | #define zorro_resource_len(z) ((z)->resource.end-(z)->resource.start+1) | 190 | #define zorro_resource_len(z) (resource_size(&(z)->resource)) |
191 | #define zorro_resource_flags(z) ((z)->resource.flags) | 191 | #define zorro_resource_flags(z) ((z)->resource.flags) |
192 | 192 | ||
193 | #define zorro_request_device(z, name) \ | 193 | #define zorro_request_device(z, name) \ |
diff --git a/include/net/sock.h b/include/net/sock.h index 396f735e0cd5..8e4062f165b8 100644 --- a/include/net/sock.h +++ b/include/net/sock.h | |||
@@ -1303,8 +1303,7 @@ extern unsigned long sock_i_ino(struct sock *sk); | |||
1303 | static inline struct dst_entry * | 1303 | static inline struct dst_entry * |
1304 | __sk_dst_get(struct sock *sk) | 1304 | __sk_dst_get(struct sock *sk) |
1305 | { | 1305 | { |
1306 | return rcu_dereference_check(sk->sk_dst_cache, rcu_read_lock_held() || | 1306 | return rcu_dereference_check(sk->sk_dst_cache, sock_owned_by_user(sk) || |
1307 | sock_owned_by_user(sk) || | ||
1308 | lockdep_is_held(&sk->sk_lock.slock)); | 1307 | lockdep_is_held(&sk->sk_lock.slock)); |
1309 | } | 1308 | } |
1310 | 1309 | ||
diff --git a/include/scsi/osd_initiator.h b/include/scsi/osd_initiator.h index 0a5079974fe9..572fb5493661 100644 --- a/include/scsi/osd_initiator.h +++ b/include/scsi/osd_initiator.h | |||
@@ -262,7 +262,7 @@ int osd_execute_request_async(struct osd_request *or, | |||
262 | * osd_req_decode_sense_full - Decode sense information after execution. | 262 | * osd_req_decode_sense_full - Decode sense information after execution. |
263 | * | 263 | * |
264 | * @or: - osd_request to examine | 264 | * @or: - osd_request to examine |
265 | * @osi - Recievs a more detailed error report information (optional). | 265 | * @osi - Receives a more detailed error report information (optional). |
266 | * @silent - Do not print to dmsg (Even if enabled) | 266 | * @silent - Do not print to dmsg (Even if enabled) |
267 | * @bad_obj_list - Some commands act on multiple objects. Failed objects will | 267 | * @bad_obj_list - Some commands act on multiple objects. Failed objects will |
268 | * be received here (optional) | 268 | * be received here (optional) |
diff --git a/include/scsi/scsi.h b/include/scsi/scsi.h index 3668903e397b..8001ae4cd7ba 100644 --- a/include/scsi/scsi.h +++ b/include/scsi/scsi.h | |||
@@ -495,7 +495,7 @@ static inline int scsi_is_wlun(unsigned int lun) | |||
495 | 495 | ||
496 | #define sense_class(sense) (((sense) >> 4) & 0x7) | 496 | #define sense_class(sense) (((sense) >> 4) & 0x7) |
497 | #define sense_error(sense) ((sense) & 0xf) | 497 | #define sense_error(sense) ((sense) & 0xf) |
498 | #define sense_valid(sense) ((sense) & 0x80); | 498 | #define sense_valid(sense) ((sense) & 0x80) |
499 | 499 | ||
500 | /* | 500 | /* |
501 | * default timeouts | 501 | * default timeouts |
diff --git a/include/sound/soundfont.h b/include/sound/soundfont.h index f95d99ba7f74..679df0574066 100644 --- a/include/sound/soundfont.h +++ b/include/sound/soundfont.h | |||
@@ -121,7 +121,7 @@ int snd_soundfont_search_zone(struct snd_sf_list *sflist, int *notep, int vel, | |||
121 | int snd_sf_calc_parm_hold(int msec); | 121 | int snd_sf_calc_parm_hold(int msec); |
122 | int snd_sf_calc_parm_attack(int msec); | 122 | int snd_sf_calc_parm_attack(int msec); |
123 | int snd_sf_calc_parm_decay(int msec); | 123 | int snd_sf_calc_parm_decay(int msec); |
124 | #define snd_sf_calc_parm_delay(msec) (0x8000 - (msec) * 1000 / 725); | 124 | #define snd_sf_calc_parm_delay(msec) (0x8000 - (msec) * 1000 / 725) |
125 | extern int snd_sf_vol_table[128]; | 125 | extern int snd_sf_vol_table[128]; |
126 | int snd_sf_linear_to_log(unsigned int amount, int offset, int ratio); | 126 | int snd_sf_linear_to_log(unsigned int amount, int offset, int ratio); |
127 | 127 | ||
diff --git a/kernel/cgroup.c b/kernel/cgroup.c index e1c72c0f512b..a63507b92ca4 100644 --- a/kernel/cgroup.c +++ b/kernel/cgroup.c | |||
@@ -1697,7 +1697,6 @@ int cgroup_path(const struct cgroup *cgrp, char *buf, int buflen) | |||
1697 | { | 1697 | { |
1698 | char *start; | 1698 | char *start; |
1699 | struct dentry *dentry = rcu_dereference_check(cgrp->dentry, | 1699 | struct dentry *dentry = rcu_dereference_check(cgrp->dentry, |
1700 | rcu_read_lock_held() || | ||
1701 | cgroup_lock_is_held()); | 1700 | cgroup_lock_is_held()); |
1702 | 1701 | ||
1703 | if (!dentry || cgrp == dummytop) { | 1702 | if (!dentry || cgrp == dummytop) { |
@@ -1723,7 +1722,6 @@ int cgroup_path(const struct cgroup *cgrp, char *buf, int buflen) | |||
1723 | break; | 1722 | break; |
1724 | 1723 | ||
1725 | dentry = rcu_dereference_check(cgrp->dentry, | 1724 | dentry = rcu_dereference_check(cgrp->dentry, |
1726 | rcu_read_lock_held() || | ||
1727 | cgroup_lock_is_held()); | 1725 | cgroup_lock_is_held()); |
1728 | if (!cgrp->parent) | 1726 | if (!cgrp->parent) |
1729 | continue; | 1727 | continue; |
@@ -4814,8 +4812,7 @@ unsigned short css_id(struct cgroup_subsys_state *css) | |||
4814 | * on this or this is under rcu_read_lock(). Once css->id is allocated, | 4812 | * on this or this is under rcu_read_lock(). Once css->id is allocated, |
4815 | * it's unchanged until freed. | 4813 | * it's unchanged until freed. |
4816 | */ | 4814 | */ |
4817 | cssid = rcu_dereference_check(css->id, | 4815 | cssid = rcu_dereference_check(css->id, atomic_read(&css->refcnt)); |
4818 | rcu_read_lock_held() || atomic_read(&css->refcnt)); | ||
4819 | 4816 | ||
4820 | if (cssid) | 4817 | if (cssid) |
4821 | return cssid->id; | 4818 | return cssid->id; |
@@ -4827,8 +4824,7 @@ unsigned short css_depth(struct cgroup_subsys_state *css) | |||
4827 | { | 4824 | { |
4828 | struct css_id *cssid; | 4825 | struct css_id *cssid; |
4829 | 4826 | ||
4830 | cssid = rcu_dereference_check(css->id, | 4827 | cssid = rcu_dereference_check(css->id, atomic_read(&css->refcnt)); |
4831 | rcu_read_lock_held() || atomic_read(&css->refcnt)); | ||
4832 | 4828 | ||
4833 | if (cssid) | 4829 | if (cssid) |
4834 | return cssid->depth; | 4830 | return cssid->depth; |
diff --git a/kernel/exit.c b/kernel/exit.c index 12ea415c6435..9ee58bb9e60f 100644 --- a/kernel/exit.c +++ b/kernel/exit.c | |||
@@ -85,7 +85,6 @@ static void __exit_signal(struct task_struct *tsk) | |||
85 | struct tty_struct *uninitialized_var(tty); | 85 | struct tty_struct *uninitialized_var(tty); |
86 | 86 | ||
87 | sighand = rcu_dereference_check(tsk->sighand, | 87 | sighand = rcu_dereference_check(tsk->sighand, |
88 | rcu_read_lock_held() || | ||
89 | lockdep_tasklist_lock_is_held()); | 88 | lockdep_tasklist_lock_is_held()); |
90 | spin_lock(&sighand->siglock); | 89 | spin_lock(&sighand->siglock); |
91 | 90 | ||
diff --git a/kernel/kexec.c b/kernel/kexec.c index 8d814cbc8109..296fbc84d659 100644 --- a/kernel/kexec.c +++ b/kernel/kexec.c | |||
@@ -1095,7 +1095,7 @@ size_t crash_get_memory_size(void) | |||
1095 | size_t size = 0; | 1095 | size_t size = 0; |
1096 | mutex_lock(&kexec_mutex); | 1096 | mutex_lock(&kexec_mutex); |
1097 | if (crashk_res.end != crashk_res.start) | 1097 | if (crashk_res.end != crashk_res.start) |
1098 | size = crashk_res.end - crashk_res.start + 1; | 1098 | size = resource_size(&crashk_res); |
1099 | mutex_unlock(&kexec_mutex); | 1099 | mutex_unlock(&kexec_mutex); |
1100 | return size; | 1100 | return size; |
1101 | } | 1101 | } |
diff --git a/kernel/pid.c b/kernel/pid.c index 57a8346a270e..e432057f3b21 100644 --- a/kernel/pid.c +++ b/kernel/pid.c | |||
@@ -405,7 +405,6 @@ struct task_struct *pid_task(struct pid *pid, enum pid_type type) | |||
405 | if (pid) { | 405 | if (pid) { |
406 | struct hlist_node *first; | 406 | struct hlist_node *first; |
407 | first = rcu_dereference_check(hlist_first_rcu(&pid->tasks[type]), | 407 | first = rcu_dereference_check(hlist_first_rcu(&pid->tasks[type]), |
408 | rcu_read_lock_held() || | ||
409 | lockdep_tasklist_lock_is_held()); | 408 | lockdep_tasklist_lock_is_held()); |
410 | if (first) | 409 | if (first) |
411 | result = hlist_entry(first, struct task_struct, pids[(type)].node); | 410 | result = hlist_entry(first, struct task_struct, pids[(type)].node); |
diff --git a/kernel/power/Kconfig b/kernel/power/Kconfig index 7b856b3458d2..b1914cb9095c 100644 --- a/kernel/power/Kconfig +++ b/kernel/power/Kconfig | |||
@@ -193,8 +193,8 @@ config APM_EMULATION | |||
193 | notification of APM "events" (e.g. battery status change). | 193 | notification of APM "events" (e.g. battery status change). |
194 | 194 | ||
195 | In order to use APM, you will need supporting software. For location | 195 | In order to use APM, you will need supporting software. For location |
196 | and more information, read <file:Documentation/power/pm.txt> and the | 196 | and more information, read <file:Documentation/power/apm-acpi.txt> |
197 | Battery Powered Linux mini-HOWTO, available from | 197 | and the Battery Powered Linux mini-HOWTO, available from |
198 | <http://www.tldp.org/docs.html#howto>. | 198 | <http://www.tldp.org/docs.html#howto>. |
199 | 199 | ||
200 | This driver does not spin down disk drives (see the hdparm(8) | 200 | This driver does not spin down disk drives (see the hdparm(8) |
diff --git a/kernel/rcutorture.c b/kernel/rcutorture.c index 2e138db03382..ced72102adc2 100644 --- a/kernel/rcutorture.c +++ b/kernel/rcutorture.c | |||
@@ -941,7 +941,6 @@ static void rcu_torture_timer(unsigned long unused) | |||
941 | idx = cur_ops->readlock(); | 941 | idx = cur_ops->readlock(); |
942 | completed = cur_ops->completed(); | 942 | completed = cur_ops->completed(); |
943 | p = rcu_dereference_check(rcu_torture_current, | 943 | p = rcu_dereference_check(rcu_torture_current, |
944 | rcu_read_lock_held() || | ||
945 | rcu_read_lock_bh_held() || | 944 | rcu_read_lock_bh_held() || |
946 | rcu_read_lock_sched_held() || | 945 | rcu_read_lock_sched_held() || |
947 | srcu_read_lock_held(&srcu_ctl)); | 946 | srcu_read_lock_held(&srcu_ctl)); |
@@ -1002,7 +1001,6 @@ rcu_torture_reader(void *arg) | |||
1002 | idx = cur_ops->readlock(); | 1001 | idx = cur_ops->readlock(); |
1003 | completed = cur_ops->completed(); | 1002 | completed = cur_ops->completed(); |
1004 | p = rcu_dereference_check(rcu_torture_current, | 1003 | p = rcu_dereference_check(rcu_torture_current, |
1005 | rcu_read_lock_held() || | ||
1006 | rcu_read_lock_bh_held() || | 1004 | rcu_read_lock_bh_held() || |
1007 | rcu_read_lock_sched_held() || | 1005 | rcu_read_lock_sched_held() || |
1008 | srcu_read_lock_held(&srcu_ctl)); | 1006 | srcu_read_lock_held(&srcu_ctl)); |
diff --git a/kernel/sched.c b/kernel/sched.c index 751a7cc6a5cd..ccacdbdecf45 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -590,7 +590,6 @@ static inline int cpu_of(struct rq *rq) | |||
590 | 590 | ||
591 | #define rcu_dereference_check_sched_domain(p) \ | 591 | #define rcu_dereference_check_sched_domain(p) \ |
592 | rcu_dereference_check((p), \ | 592 | rcu_dereference_check((p), \ |
593 | rcu_read_lock_held() || \ | ||
594 | lockdep_is_held(&sched_domains_mutex)) | 593 | lockdep_is_held(&sched_domains_mutex)) |
595 | 594 | ||
596 | /* | 595 | /* |
diff --git a/lib/vsprintf.c b/lib/vsprintf.c index 4365df31a1d5..75bace7acefb 100644 --- a/lib/vsprintf.c +++ b/lib/vsprintf.c | |||
@@ -1149,8 +1149,7 @@ qualifier: | |||
1149 | * %pi4 print an IPv4 address with leading zeros | 1149 | * %pi4 print an IPv4 address with leading zeros |
1150 | * %pI6 print an IPv6 address with colons | 1150 | * %pI6 print an IPv6 address with colons |
1151 | * %pi6 print an IPv6 address without colons | 1151 | * %pi6 print an IPv6 address without colons |
1152 | * %pI6c print an IPv6 address as specified by | 1152 | * %pI6c print an IPv6 address as specified by RFC 5952 |
1153 | * http://tools.ietf.org/html/draft-ietf-6man-text-addr-representation-00 | ||
1154 | * %pU[bBlL] print a UUID/GUID in big or little endian using lower or upper | 1153 | * %pU[bBlL] print a UUID/GUID in big or little endian using lower or upper |
1155 | * case. | 1154 | * case. |
1156 | * %n is ignored | 1155 | * %n is ignored |
diff --git a/mm/Kconfig b/mm/Kconfig index 8ca47a5ee9c8..f2f1ca19ed53 100644 --- a/mm/Kconfig +++ b/mm/Kconfig | |||
@@ -356,7 +356,7 @@ config CLEANCACHE | |||
356 | for clean pages that the kernel's pageframe replacement algorithm | 356 | for clean pages that the kernel's pageframe replacement algorithm |
357 | (PFRA) would like to keep around, but can't since there isn't enough | 357 | (PFRA) would like to keep around, but can't since there isn't enough |
358 | memory. So when the PFRA "evicts" a page, it first attempts to use | 358 | memory. So when the PFRA "evicts" a page, it first attempts to use |
359 | cleancacne code to put the data contained in that page into | 359 | cleancache code to put the data contained in that page into |
360 | "transcendent memory", memory that is not directly accessible or | 360 | "transcendent memory", memory that is not directly accessible or |
361 | addressable by the kernel and is of unknown and possibly | 361 | addressable by the kernel and is of unknown and possibly |
362 | time-varying size. And when a cleancache-enabled | 362 | time-varying size. And when a cleancache-enabled |
@@ -4159,7 +4159,7 @@ static int any_slab_objects(struct kmem_cache *s) | |||
4159 | #endif | 4159 | #endif |
4160 | 4160 | ||
4161 | #define to_slab_attr(n) container_of(n, struct slab_attribute, attr) | 4161 | #define to_slab_attr(n) container_of(n, struct slab_attribute, attr) |
4162 | #define to_slab(n) container_of(n, struct kmem_cache, kobj); | 4162 | #define to_slab(n) container_of(n, struct kmem_cache, kobj) |
4163 | 4163 | ||
4164 | struct slab_attribute { | 4164 | struct slab_attribute { |
4165 | struct attribute attr; | 4165 | struct attribute attr; |
diff --git a/net/bridge/netfilter/ebt_ulog.c b/net/bridge/netfilter/ebt_ulog.c index 26377e96fa1c..bf2a333ca7c7 100644 --- a/net/bridge/netfilter/ebt_ulog.c +++ b/net/bridge/netfilter/ebt_ulog.c | |||
@@ -216,7 +216,6 @@ unlock: | |||
216 | nlmsg_failure: | 216 | nlmsg_failure: |
217 | pr_debug("error during NLMSG_PUT. This should " | 217 | pr_debug("error during NLMSG_PUT. This should " |
218 | "not happen, please report to author.\n"); | 218 | "not happen, please report to author.\n"); |
219 | goto unlock; | ||
220 | alloc_failure: | 219 | alloc_failure: |
221 | goto unlock; | 220 | goto unlock; |
222 | } | 221 | } |
diff --git a/net/mac80211/mesh_hwmp.c b/net/mac80211/mesh_hwmp.c index 2b18053070c1..3460108810d5 100644 --- a/net/mac80211/mesh_hwmp.c +++ b/net/mac80211/mesh_hwmp.c | |||
@@ -57,29 +57,29 @@ static inline u32 u16_field_get(u8 *preq_elem, int offset, bool ae) | |||
57 | #define PREQ_IE_TTL(x) (*(x + 2)) | 57 | #define PREQ_IE_TTL(x) (*(x + 2)) |
58 | #define PREQ_IE_PREQ_ID(x) u32_field_get(x, 3, 0) | 58 | #define PREQ_IE_PREQ_ID(x) u32_field_get(x, 3, 0) |
59 | #define PREQ_IE_ORIG_ADDR(x) (x + 7) | 59 | #define PREQ_IE_ORIG_ADDR(x) (x + 7) |
60 | #define PREQ_IE_ORIG_SN(x) u32_field_get(x, 13, 0); | 60 | #define PREQ_IE_ORIG_SN(x) u32_field_get(x, 13, 0) |
61 | #define PREQ_IE_LIFETIME(x) u32_field_get(x, 17, AE_F_SET(x)); | 61 | #define PREQ_IE_LIFETIME(x) u32_field_get(x, 17, AE_F_SET(x)) |
62 | #define PREQ_IE_METRIC(x) u32_field_get(x, 21, AE_F_SET(x)); | 62 | #define PREQ_IE_METRIC(x) u32_field_get(x, 21, AE_F_SET(x)) |
63 | #define PREQ_IE_TARGET_F(x) (*(AE_F_SET(x) ? x + 32 : x + 26)) | 63 | #define PREQ_IE_TARGET_F(x) (*(AE_F_SET(x) ? x + 32 : x + 26)) |
64 | #define PREQ_IE_TARGET_ADDR(x) (AE_F_SET(x) ? x + 33 : x + 27) | 64 | #define PREQ_IE_TARGET_ADDR(x) (AE_F_SET(x) ? x + 33 : x + 27) |
65 | #define PREQ_IE_TARGET_SN(x) u32_field_get(x, 33, AE_F_SET(x)); | 65 | #define PREQ_IE_TARGET_SN(x) u32_field_get(x, 33, AE_F_SET(x)) |
66 | 66 | ||
67 | 67 | ||
68 | #define PREP_IE_FLAGS(x) PREQ_IE_FLAGS(x) | 68 | #define PREP_IE_FLAGS(x) PREQ_IE_FLAGS(x) |
69 | #define PREP_IE_HOPCOUNT(x) PREQ_IE_HOPCOUNT(x) | 69 | #define PREP_IE_HOPCOUNT(x) PREQ_IE_HOPCOUNT(x) |
70 | #define PREP_IE_TTL(x) PREQ_IE_TTL(x) | 70 | #define PREP_IE_TTL(x) PREQ_IE_TTL(x) |
71 | #define PREP_IE_ORIG_ADDR(x) (x + 3) | 71 | #define PREP_IE_ORIG_ADDR(x) (x + 3) |
72 | #define PREP_IE_ORIG_SN(x) u32_field_get(x, 9, 0); | 72 | #define PREP_IE_ORIG_SN(x) u32_field_get(x, 9, 0) |
73 | #define PREP_IE_LIFETIME(x) u32_field_get(x, 13, AE_F_SET(x)); | 73 | #define PREP_IE_LIFETIME(x) u32_field_get(x, 13, AE_F_SET(x)) |
74 | #define PREP_IE_METRIC(x) u32_field_get(x, 17, AE_F_SET(x)); | 74 | #define PREP_IE_METRIC(x) u32_field_get(x, 17, AE_F_SET(x)) |
75 | #define PREP_IE_TARGET_ADDR(x) (AE_F_SET(x) ? x + 27 : x + 21) | 75 | #define PREP_IE_TARGET_ADDR(x) (AE_F_SET(x) ? x + 27 : x + 21) |
76 | #define PREP_IE_TARGET_SN(x) u32_field_get(x, 27, AE_F_SET(x)); | 76 | #define PREP_IE_TARGET_SN(x) u32_field_get(x, 27, AE_F_SET(x)) |
77 | 77 | ||
78 | #define PERR_IE_TTL(x) (*(x)) | 78 | #define PERR_IE_TTL(x) (*(x)) |
79 | #define PERR_IE_TARGET_FLAGS(x) (*(x + 2)) | 79 | #define PERR_IE_TARGET_FLAGS(x) (*(x + 2)) |
80 | #define PERR_IE_TARGET_ADDR(x) (x + 3) | 80 | #define PERR_IE_TARGET_ADDR(x) (x + 3) |
81 | #define PERR_IE_TARGET_SN(x) u32_field_get(x, 9, 0); | 81 | #define PERR_IE_TARGET_SN(x) u32_field_get(x, 9, 0) |
82 | #define PERR_IE_TARGET_RCODE(x) u16_field_get(x, 13, 0); | 82 | #define PERR_IE_TARGET_RCODE(x) u16_field_get(x, 13, 0) |
83 | 83 | ||
84 | #define MSEC_TO_TU(x) (x*1000/1024) | 84 | #define MSEC_TO_TU(x) (x*1000/1024) |
85 | #define SN_GT(x, y) ((long) (y) - (long) (x) < 0) | 85 | #define SN_GT(x, y) ((long) (y) - (long) (x) < 0) |
diff --git a/net/mac80211/sta_info.c b/net/mac80211/sta_info.c index b83870bf60fa..3db78b696c5c 100644 --- a/net/mac80211/sta_info.c +++ b/net/mac80211/sta_info.c | |||
@@ -97,7 +97,6 @@ struct sta_info *sta_info_get(struct ieee80211_sub_if_data *sdata, | |||
97 | struct sta_info *sta; | 97 | struct sta_info *sta; |
98 | 98 | ||
99 | sta = rcu_dereference_check(local->sta_hash[STA_HASH(addr)], | 99 | sta = rcu_dereference_check(local->sta_hash[STA_HASH(addr)], |
100 | rcu_read_lock_held() || | ||
101 | lockdep_is_held(&local->sta_lock) || | 100 | lockdep_is_held(&local->sta_lock) || |
102 | lockdep_is_held(&local->sta_mtx)); | 101 | lockdep_is_held(&local->sta_mtx)); |
103 | while (sta) { | 102 | while (sta) { |
@@ -105,7 +104,6 @@ struct sta_info *sta_info_get(struct ieee80211_sub_if_data *sdata, | |||
105 | memcmp(sta->sta.addr, addr, ETH_ALEN) == 0) | 104 | memcmp(sta->sta.addr, addr, ETH_ALEN) == 0) |
106 | break; | 105 | break; |
107 | sta = rcu_dereference_check(sta->hnext, | 106 | sta = rcu_dereference_check(sta->hnext, |
108 | rcu_read_lock_held() || | ||
109 | lockdep_is_held(&local->sta_lock) || | 107 | lockdep_is_held(&local->sta_lock) || |
110 | lockdep_is_held(&local->sta_mtx)); | 108 | lockdep_is_held(&local->sta_mtx)); |
111 | } | 109 | } |
@@ -123,7 +121,6 @@ struct sta_info *sta_info_get_bss(struct ieee80211_sub_if_data *sdata, | |||
123 | struct sta_info *sta; | 121 | struct sta_info *sta; |
124 | 122 | ||
125 | sta = rcu_dereference_check(local->sta_hash[STA_HASH(addr)], | 123 | sta = rcu_dereference_check(local->sta_hash[STA_HASH(addr)], |
126 | rcu_read_lock_held() || | ||
127 | lockdep_is_held(&local->sta_lock) || | 124 | lockdep_is_held(&local->sta_lock) || |
128 | lockdep_is_held(&local->sta_mtx)); | 125 | lockdep_is_held(&local->sta_mtx)); |
129 | while (sta) { | 126 | while (sta) { |
@@ -132,7 +129,6 @@ struct sta_info *sta_info_get_bss(struct ieee80211_sub_if_data *sdata, | |||
132 | memcmp(sta->sta.addr, addr, ETH_ALEN) == 0) | 129 | memcmp(sta->sta.addr, addr, ETH_ALEN) == 0) |
133 | break; | 130 | break; |
134 | sta = rcu_dereference_check(sta->hnext, | 131 | sta = rcu_dereference_check(sta->hnext, |
135 | rcu_read_lock_held() || | ||
136 | lockdep_is_held(&local->sta_lock) || | 132 | lockdep_is_held(&local->sta_lock) || |
137 | lockdep_is_held(&local->sta_mtx)); | 133 | lockdep_is_held(&local->sta_mtx)); |
138 | } | 134 | } |
diff --git a/net/netlabel/netlabel_domainhash.c b/net/netlabel/netlabel_domainhash.c index de0d8e4cbfb6..2aa975e5452d 100644 --- a/net/netlabel/netlabel_domainhash.c +++ b/net/netlabel/netlabel_domainhash.c | |||
@@ -55,8 +55,7 @@ struct netlbl_domhsh_tbl { | |||
55 | * should be okay */ | 55 | * should be okay */ |
56 | static DEFINE_SPINLOCK(netlbl_domhsh_lock); | 56 | static DEFINE_SPINLOCK(netlbl_domhsh_lock); |
57 | #define netlbl_domhsh_rcu_deref(p) \ | 57 | #define netlbl_domhsh_rcu_deref(p) \ |
58 | rcu_dereference_check(p, rcu_read_lock_held() || \ | 58 | rcu_dereference_check(p, lockdep_is_held(&netlbl_domhsh_lock)) |
59 | lockdep_is_held(&netlbl_domhsh_lock)) | ||
60 | static struct netlbl_domhsh_tbl *netlbl_domhsh = NULL; | 59 | static struct netlbl_domhsh_tbl *netlbl_domhsh = NULL; |
61 | static struct netlbl_dom_map *netlbl_domhsh_def = NULL; | 60 | static struct netlbl_dom_map *netlbl_domhsh_def = NULL; |
62 | 61 | ||
diff --git a/net/netlabel/netlabel_unlabeled.c b/net/netlabel/netlabel_unlabeled.c index 8efd061a0ae9..9a290ef5c175 100644 --- a/net/netlabel/netlabel_unlabeled.c +++ b/net/netlabel/netlabel_unlabeled.c | |||
@@ -116,8 +116,7 @@ struct netlbl_unlhsh_walk_arg { | |||
116 | * hash table should be okay */ | 116 | * hash table should be okay */ |
117 | static DEFINE_SPINLOCK(netlbl_unlhsh_lock); | 117 | static DEFINE_SPINLOCK(netlbl_unlhsh_lock); |
118 | #define netlbl_unlhsh_rcu_deref(p) \ | 118 | #define netlbl_unlhsh_rcu_deref(p) \ |
119 | rcu_dereference_check(p, rcu_read_lock_held() || \ | 119 | rcu_dereference_check(p, lockdep_is_held(&netlbl_unlhsh_lock)) |
120 | lockdep_is_held(&netlbl_unlhsh_lock)) | ||
121 | static struct netlbl_unlhsh_tbl *netlbl_unlhsh = NULL; | 120 | static struct netlbl_unlhsh_tbl *netlbl_unlhsh = NULL; |
122 | static struct netlbl_unlhsh_iface *netlbl_unlhsh_def = NULL; | 121 | static struct netlbl_unlhsh_iface *netlbl_unlhsh_def = NULL; |
123 | 122 | ||
diff --git a/scripts/bootgraph.pl b/scripts/bootgraph.pl index 12caa822a232..b78fca994a15 100644 --- a/scripts/bootgraph.pl +++ b/scripts/bootgraph.pl | |||
@@ -44,7 +44,7 @@ my %end; | |||
44 | my %type; | 44 | my %type; |
45 | my $done = 0; | 45 | my $done = 0; |
46 | my $maxtime = 0; | 46 | my $maxtime = 0; |
47 | my $firsttime = 100; | 47 | my $firsttime = 99999; |
48 | my $count = 0; | 48 | my $count = 0; |
49 | my %pids; | 49 | my %pids; |
50 | my %pidctr; | 50 | my %pidctr; |
diff --git a/scripts/docproc.c b/scripts/docproc.c index 98dec87974d0..4cfdc1797eb8 100644 --- a/scripts/docproc.c +++ b/scripts/docproc.c | |||
@@ -205,8 +205,7 @@ static void find_export_symbols(char * filename) | |||
205 | PATH_MAX - strlen(real_filename)); | 205 | PATH_MAX - strlen(real_filename)); |
206 | sym = add_new_file(filename); | 206 | sym = add_new_file(filename); |
207 | fp = fopen(real_filename, "r"); | 207 | fp = fopen(real_filename, "r"); |
208 | if (fp == NULL) | 208 | if (fp == NULL) { |
209 | { | ||
210 | fprintf(stderr, "docproc: "); | 209 | fprintf(stderr, "docproc: "); |
211 | perror(real_filename); | 210 | perror(real_filename); |
212 | exit(1); | 211 | exit(1); |
@@ -487,8 +486,7 @@ static void parse_file(FILE *infile) | |||
487 | default: | 486 | default: |
488 | defaultline(line); | 487 | defaultline(line); |
489 | } | 488 | } |
490 | } | 489 | } else { |
491 | else { | ||
492 | defaultline(line); | 490 | defaultline(line); |
493 | } | 491 | } |
494 | } | 492 | } |
@@ -519,8 +517,7 @@ int main(int argc, char *argv[]) | |||
519 | exit(2); | 517 | exit(2); |
520 | } | 518 | } |
521 | 519 | ||
522 | if (strcmp("doc", argv[1]) == 0) | 520 | if (strcmp("doc", argv[1]) == 0) { |
523 | { | ||
524 | /* Need to do this in two passes. | 521 | /* Need to do this in two passes. |
525 | * First pass is used to collect all symbols exported | 522 | * First pass is used to collect all symbols exported |
526 | * in the various files; | 523 | * in the various files; |
@@ -556,9 +553,7 @@ int main(int argc, char *argv[]) | |||
556 | fprintf(stderr, "Warning: didn't use docs for %s\n", | 553 | fprintf(stderr, "Warning: didn't use docs for %s\n", |
557 | all_list[i]); | 554 | all_list[i]); |
558 | } | 555 | } |
559 | } | 556 | } else if (strcmp("depend", argv[1]) == 0) { |
560 | else if (strcmp("depend", argv[1]) == 0) | ||
561 | { | ||
562 | /* Create first part of dependency chain | 557 | /* Create first part of dependency chain |
563 | * file.tmpl */ | 558 | * file.tmpl */ |
564 | printf("%s\t", argv[2]); | 559 | printf("%s\t", argv[2]); |
@@ -571,9 +566,7 @@ int main(int argc, char *argv[]) | |||
571 | findall = adddep; | 566 | findall = adddep; |
572 | parse_file(infile); | 567 | parse_file(infile); |
573 | printf("\n"); | 568 | printf("\n"); |
574 | } | 569 | } else { |
575 | else | ||
576 | { | ||
577 | fprintf(stderr, "Unknown option: %s\n", argv[1]); | 570 | fprintf(stderr, "Unknown option: %s\n", argv[1]); |
578 | exit(1); | 571 | exit(1); |
579 | } | 572 | } |
diff --git a/scripts/gcc-goto.sh b/scripts/gcc-goto.sh index 520d16b1ffaf..98cffcb941ea 100644 --- a/scripts/gcc-goto.sh +++ b/scripts/gcc-goto.sh | |||
@@ -1,5 +1,5 @@ | |||
1 | #!/bin/sh | 1 | #!/bin/sh |
2 | # Test for gcc 'asm goto' suport | 2 | # Test for gcc 'asm goto' support |
3 | # Copyright (C) 2010, Jason Baron <jbaron@redhat.com> | 3 | # Copyright (C) 2010, Jason Baron <jbaron@redhat.com> |
4 | 4 | ||
5 | echo "int main(void) { entry: asm goto (\"\"::::entry); return 0; }" | $@ -x c - -c -o /dev/null >/dev/null 2>&1 && echo "y" | 5 | echo "int main(void) { entry: asm goto (\"\"::::entry); return 0; }" | $@ -x c - -c -o /dev/null >/dev/null 2>&1 && echo "y" |
diff --git a/security/keys/keyring.c b/security/keys/keyring.c index a06ffab38568..30e242f7bd0e 100644 --- a/security/keys/keyring.c +++ b/security/keys/keyring.c | |||
@@ -155,7 +155,6 @@ static void keyring_destroy(struct key *keyring) | |||
155 | } | 155 | } |
156 | 156 | ||
157 | klist = rcu_dereference_check(keyring->payload.subscriptions, | 157 | klist = rcu_dereference_check(keyring->payload.subscriptions, |
158 | rcu_read_lock_held() || | ||
159 | atomic_read(&keyring->usage) == 0); | 158 | atomic_read(&keyring->usage) == 0); |
160 | if (klist) { | 159 | if (klist) { |
161 | for (loop = klist->nkeys - 1; loop >= 0; loop--) | 160 | for (loop = klist->nkeys - 1; loop >= 0; loop--) |
diff --git a/sound/aoa/soundbus/i2sbus/core.c b/sound/aoa/soundbus/i2sbus/core.c index 3ff8cc5f487a..010658335881 100644 --- a/sound/aoa/soundbus/i2sbus/core.c +++ b/sound/aoa/soundbus/i2sbus/core.c | |||
@@ -262,8 +262,7 @@ static int i2sbus_add_dev(struct macio_dev *macio, | |||
262 | */ | 262 | */ |
263 | dev->allocated_resource[i] = | 263 | dev->allocated_resource[i] = |
264 | request_mem_region(dev->resources[i].start, | 264 | request_mem_region(dev->resources[i].start, |
265 | dev->resources[i].end - | 265 | resource_size(&dev->resources[i]), |
266 | dev->resources[i].start + 1, | ||
267 | dev->rnames[i]); | 266 | dev->rnames[i]); |
268 | if (!dev->allocated_resource[i]) { | 267 | if (!dev->allocated_resource[i]) { |
269 | printk(KERN_ERR "i2sbus: failed to claim resource %d!\n", i); | 268 | printk(KERN_ERR "i2sbus: failed to claim resource %d!\n", i); |
@@ -272,19 +271,19 @@ static int i2sbus_add_dev(struct macio_dev *macio, | |||
272 | } | 271 | } |
273 | 272 | ||
274 | r = &dev->resources[aoa_resource_i2smmio]; | 273 | r = &dev->resources[aoa_resource_i2smmio]; |
275 | rlen = r->end - r->start + 1; | 274 | rlen = resource_size(r); |
276 | if (rlen < sizeof(struct i2s_interface_regs)) | 275 | if (rlen < sizeof(struct i2s_interface_regs)) |
277 | goto err; | 276 | goto err; |
278 | dev->intfregs = ioremap(r->start, rlen); | 277 | dev->intfregs = ioremap(r->start, rlen); |
279 | 278 | ||
280 | r = &dev->resources[aoa_resource_txdbdma]; | 279 | r = &dev->resources[aoa_resource_txdbdma]; |
281 | rlen = r->end - r->start + 1; | 280 | rlen = resource_size(r); |
282 | if (rlen < sizeof(struct dbdma_regs)) | 281 | if (rlen < sizeof(struct dbdma_regs)) |
283 | goto err; | 282 | goto err; |
284 | dev->out.dbdma = ioremap(r->start, rlen); | 283 | dev->out.dbdma = ioremap(r->start, rlen); |
285 | 284 | ||
286 | r = &dev->resources[aoa_resource_rxdbdma]; | 285 | r = &dev->resources[aoa_resource_rxdbdma]; |
287 | rlen = r->end - r->start + 1; | 286 | rlen = resource_size(r); |
288 | if (rlen < sizeof(struct dbdma_regs)) | 287 | if (rlen < sizeof(struct dbdma_regs)) |
289 | goto err; | 288 | goto err; |
290 | dev->in.dbdma = ioremap(r->start, rlen); | 289 | dev->in.dbdma = ioremap(r->start, rlen); |
diff --git a/sound/atmel/abdac.c b/sound/atmel/abdac.c index bfee60c4d4c0..6fd9391b3a6c 100644 --- a/sound/atmel/abdac.c +++ b/sound/atmel/abdac.c | |||
@@ -448,7 +448,7 @@ static int __devinit atmel_abdac_probe(struct platform_device *pdev) | |||
448 | goto out_free_card; | 448 | goto out_free_card; |
449 | } | 449 | } |
450 | 450 | ||
451 | dac->regs = ioremap(regs->start, regs->end - regs->start + 1); | 451 | dac->regs = ioremap(regs->start, resource_size(regs)); |
452 | if (!dac->regs) { | 452 | if (!dac->regs) { |
453 | dev_dbg(&pdev->dev, "could not remap register memory\n"); | 453 | dev_dbg(&pdev->dev, "could not remap register memory\n"); |
454 | goto out_free_card; | 454 | goto out_free_card; |
diff --git a/sound/atmel/ac97c.c b/sound/atmel/ac97c.c index ac35222ad0dd..6e5addeb236b 100644 --- a/sound/atmel/ac97c.c +++ b/sound/atmel/ac97c.c | |||
@@ -971,7 +971,7 @@ static int __devinit atmel_ac97c_probe(struct platform_device *pdev) | |||
971 | chip->card = card; | 971 | chip->card = card; |
972 | chip->pclk = pclk; | 972 | chip->pclk = pclk; |
973 | chip->pdev = pdev; | 973 | chip->pdev = pdev; |
974 | chip->regs = ioremap(regs->start, regs->end - regs->start + 1); | 974 | chip->regs = ioremap(regs->start, resource_size(regs)); |
975 | 975 | ||
976 | if (!chip->regs) { | 976 | if (!chip->regs) { |
977 | dev_dbg(&pdev->dev, "could not remap register memory\n"); | 977 | dev_dbg(&pdev->dev, "could not remap register memory\n"); |
diff --git a/sound/pci/ice1712/ice1712.c b/sound/pci/ice1712/ice1712.c index be06fb3e45a1..0ccc0eb75775 100644 --- a/sound/pci/ice1712/ice1712.c +++ b/sound/pci/ice1712/ice1712.c | |||
@@ -87,7 +87,7 @@ static char *id[SNDRV_CARDS] = SNDRV_DEFAULT_STR; /* ID for this card */ | |||
87 | static int enable[SNDRV_CARDS] = SNDRV_DEFAULT_ENABLE_PNP;/* Enable this card */ | 87 | static int enable[SNDRV_CARDS] = SNDRV_DEFAULT_ENABLE_PNP;/* Enable this card */ |
88 | static char *model[SNDRV_CARDS]; | 88 | static char *model[SNDRV_CARDS]; |
89 | static int omni[SNDRV_CARDS]; /* Delta44 & 66 Omni I/O support */ | 89 | static int omni[SNDRV_CARDS]; /* Delta44 & 66 Omni I/O support */ |
90 | static int cs8427_timeout[SNDRV_CARDS] = {[0 ... (SNDRV_CARDS-1)] = 500}; /* CS8427 S/PDIF transciever reset timeout value in msec */ | 90 | static int cs8427_timeout[SNDRV_CARDS] = {[0 ... (SNDRV_CARDS-1)] = 500}; /* CS8427 S/PDIF transceiver reset timeout value in msec */ |
91 | static int dxr_enable[SNDRV_CARDS]; /* DXR enable for DMX6FIRE */ | 91 | static int dxr_enable[SNDRV_CARDS]; /* DXR enable for DMX6FIRE */ |
92 | 92 | ||
93 | module_param_array(index, int, NULL, 0444); | 93 | module_param_array(index, int, NULL, 0444); |
diff --git a/sound/ppc/pmac.c b/sound/ppc/pmac.c index 3ecbd67f88c9..ab96cde7417b 100644 --- a/sound/ppc/pmac.c +++ b/sound/ppc/pmac.c | |||
@@ -881,8 +881,7 @@ static int snd_pmac_free(struct snd_pmac *chip) | |||
881 | for (i = 0; i < 3; i++) { | 881 | for (i = 0; i < 3; i++) { |
882 | if (chip->requested & (1 << i)) | 882 | if (chip->requested & (1 << i)) |
883 | release_mem_region(chip->rsrc[i].start, | 883 | release_mem_region(chip->rsrc[i].start, |
884 | chip->rsrc[i].end - | 884 | resource_size(&chip->rsrc[i])); |
885 | chip->rsrc[i].start + 1); | ||
886 | } | 885 | } |
887 | } | 886 | } |
888 | 887 | ||
@@ -1228,8 +1227,7 @@ int __devinit snd_pmac_new(struct snd_card *card, struct snd_pmac **chip_return) | |||
1228 | goto __error; | 1227 | goto __error; |
1229 | } | 1228 | } |
1230 | if (request_mem_region(chip->rsrc[i].start, | 1229 | if (request_mem_region(chip->rsrc[i].start, |
1231 | chip->rsrc[i].end - | 1230 | resource_size(&chip->rsrc[i]), |
1232 | chip->rsrc[i].start + 1, | ||
1233 | rnames[i]) == NULL) { | 1231 | rnames[i]) == NULL) { |
1234 | printk(KERN_ERR "snd: can't request rsrc " | 1232 | printk(KERN_ERR "snd: can't request rsrc " |
1235 | " %d (%s: %pR)\n", | 1233 | " %d (%s: %pR)\n", |
@@ -1254,8 +1252,7 @@ int __devinit snd_pmac_new(struct snd_card *card, struct snd_pmac **chip_return) | |||
1254 | goto __error; | 1252 | goto __error; |
1255 | } | 1253 | } |
1256 | if (request_mem_region(chip->rsrc[i].start, | 1254 | if (request_mem_region(chip->rsrc[i].start, |
1257 | chip->rsrc[i].end - | 1255 | resource_size(&chip->rsrc[i]), |
1258 | chip->rsrc[i].start + 1, | ||
1259 | rnames[i]) == NULL) { | 1256 | rnames[i]) == NULL) { |
1260 | printk(KERN_ERR "snd: can't request rsrc " | 1257 | printk(KERN_ERR "snd: can't request rsrc " |
1261 | " %d (%s: %pR)\n", | 1258 | " %d (%s: %pR)\n", |
diff --git a/sound/soc/ep93xx/ep93xx-i2s.c b/sound/soc/ep93xx/ep93xx-i2s.c index 30df42568dbb..56efa0c1c9a9 100644 --- a/sound/soc/ep93xx/ep93xx-i2s.c +++ b/sound/soc/ep93xx/ep93xx-i2s.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * linux/sound/soc/ep93xx-i2s.c | 2 | * linux/sound/soc/ep93xx-i2s.c |
3 | * EP93xx I2S driver | 3 | * EP93xx I2S driver |
4 | * | 4 | * |
5 | * Copyright (C) 2010 Ryan Mallon <ryan@bluewatersys.com> | 5 | * Copyright (C) 2010 Ryan Mallon |
6 | * | 6 | * |
7 | * Based on the original driver by: | 7 | * Based on the original driver by: |
8 | * Copyright (C) 2007 Chase Douglas <chasedouglas@gmail> | 8 | * Copyright (C) 2007 Chase Douglas <chasedouglas@gmail> |
@@ -477,6 +477,6 @@ module_init(ep93xx_i2s_init); | |||
477 | module_exit(ep93xx_i2s_exit); | 477 | module_exit(ep93xx_i2s_exit); |
478 | 478 | ||
479 | MODULE_ALIAS("platform:ep93xx-i2s"); | 479 | MODULE_ALIAS("platform:ep93xx-i2s"); |
480 | MODULE_AUTHOR("Ryan Mallon <ryan@bluewatersys.com>"); | 480 | MODULE_AUTHOR("Ryan Mallon"); |
481 | MODULE_DESCRIPTION("EP93XX I2S driver"); | 481 | MODULE_DESCRIPTION("EP93XX I2S driver"); |
482 | MODULE_LICENSE("GPL"); | 482 | MODULE_LICENSE("GPL"); |
diff --git a/sound/soc/ep93xx/ep93xx-pcm.c b/sound/soc/ep93xx/ep93xx-pcm.c index dd7ac5374cef..8dfd3ad84b19 100644 --- a/sound/soc/ep93xx/ep93xx-pcm.c +++ b/sound/soc/ep93xx/ep93xx-pcm.c | |||
@@ -5,7 +5,7 @@ | |||
5 | * Copyright (C) 2006 Applied Data Systems | 5 | * Copyright (C) 2006 Applied Data Systems |
6 | * | 6 | * |
7 | * Rewritten for the SoC audio subsystem (Based on PXA2xx code): | 7 | * Rewritten for the SoC audio subsystem (Based on PXA2xx code): |
8 | * Copyright (c) 2008 Ryan Mallon <ryan@bluewatersys.com> | 8 | * Copyright (c) 2008 Ryan Mallon |
9 | * | 9 | * |
10 | * This program is free software; you can redistribute it and/or modify | 10 | * This program is free software; you can redistribute it and/or modify |
11 | * it under the terms of the GNU General Public License version 2 as | 11 | * it under the terms of the GNU General Public License version 2 as |
@@ -352,6 +352,6 @@ static void __exit ep93xx_soc_platform_exit(void) | |||
352 | module_init(ep93xx_soc_platform_init); | 352 | module_init(ep93xx_soc_platform_init); |
353 | module_exit(ep93xx_soc_platform_exit); | 353 | module_exit(ep93xx_soc_platform_exit); |
354 | 354 | ||
355 | MODULE_AUTHOR("Ryan Mallon <ryan@bluewatersys.com>"); | 355 | MODULE_AUTHOR("Ryan Mallon"); |
356 | MODULE_DESCRIPTION("EP93xx ALSA PCM interface"); | 356 | MODULE_DESCRIPTION("EP93xx ALSA PCM interface"); |
357 | MODULE_LICENSE("GPL"); | 357 | MODULE_LICENSE("GPL"); |
diff --git a/sound/soc/ep93xx/snappercl15.c b/sound/soc/ep93xx/snappercl15.c index dfe1d7f74ea6..c8aa8a5003ca 100644 --- a/sound/soc/ep93xx/snappercl15.c +++ b/sound/soc/ep93xx/snappercl15.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * snappercl15.c -- SoC audio for Bluewater Systems Snapper CL15 module | 2 | * snappercl15.c -- SoC audio for Bluewater Systems Snapper CL15 module |
3 | * | 3 | * |
4 | * Copyright (C) 2008 Bluewater Systems Ltd | 4 | * Copyright (C) 2008 Bluewater Systems Ltd |
5 | * Author: Ryan Mallon <ryan@bluewatersys.com> | 5 | * Author: Ryan Mallon |
6 | * | 6 | * |
7 | * This program is free software; you can redistribute it and/or modify it | 7 | * This program is free software; you can redistribute it and/or modify it |
8 | * under the terms of the GNU General Public License as published by the | 8 | * under the terms of the GNU General Public License as published by the |
@@ -140,7 +140,7 @@ static void __exit snappercl15_exit(void) | |||
140 | module_init(snappercl15_init); | 140 | module_init(snappercl15_init); |
141 | module_exit(snappercl15_exit); | 141 | module_exit(snappercl15_exit); |
142 | 142 | ||
143 | MODULE_AUTHOR("Ryan Mallon <ryan@bluewatersys.com>"); | 143 | MODULE_AUTHOR("Ryan Mallon"); |
144 | MODULE_DESCRIPTION("ALSA SoC Snapper CL15"); | 144 | MODULE_DESCRIPTION("ALSA SoC Snapper CL15"); |
145 | MODULE_LICENSE("GPL"); | 145 | MODULE_LICENSE("GPL"); |
146 | 146 | ||
diff --git a/sound/soc/fsl/mpc5200_dma.c b/sound/soc/fsl/mpc5200_dma.c index 19ad0c1be67e..fd0dc46afc34 100644 --- a/sound/soc/fsl/mpc5200_dma.c +++ b/sound/soc/fsl/mpc5200_dma.c | |||
@@ -385,7 +385,7 @@ static int mpc5200_hpcd_probe(struct of_device *op) | |||
385 | dev_err(&op->dev, "Missing reg property\n"); | 385 | dev_err(&op->dev, "Missing reg property\n"); |
386 | return -ENODEV; | 386 | return -ENODEV; |
387 | } | 387 | } |
388 | regs = ioremap(res.start, 1 + res.end - res.start); | 388 | regs = ioremap(res.start, resource_size(&res)); |
389 | if (!regs) { | 389 | if (!regs) { |
390 | dev_err(&op->dev, "Could not map registers\n"); | 390 | dev_err(&op->dev, "Could not map registers\n"); |
391 | return -ENODEV; | 391 | return -ENODEV; |
diff --git a/sound/soc/omap/ams-delta.c b/sound/soc/omap/ams-delta.c index b40095a19883..30fe0d0efe1c 100644 --- a/sound/soc/omap/ams-delta.c +++ b/sound/soc/omap/ams-delta.c | |||
@@ -330,7 +330,7 @@ static int cx81801_hangup(struct tty_struct *tty) | |||
330 | return 0; | 330 | return 0; |
331 | } | 331 | } |
332 | 332 | ||
333 | /* Line discipline .recieve_buf() */ | 333 | /* Line discipline .receive_buf() */ |
334 | static void cx81801_receive(struct tty_struct *tty, | 334 | static void cx81801_receive(struct tty_struct *tty, |
335 | const unsigned char *cp, char *fp, int count) | 335 | const unsigned char *cp, char *fp, int count) |
336 | { | 336 | { |