diff options
author | Arnd Bergmann <arnd@arndb.de> | 2012-09-14 16:08:08 -0400 |
---|---|---|
committer | Arnd Bergmann <arnd@arndb.de> | 2012-09-18 04:15:11 -0400 |
commit | 0a4b04dc299dfb691827a4001b3d8d7e443b71c9 (patch) | |
tree | 8f8aaabd715306eac4a814cdfd73ef9059f16fea /arch/arm/mach-shmobile/intc-sh7372.c | |
parent | 4cbe5a555fa58a79b6ecbb6c531b8bab0650778d (diff) |
ARM: shmobile: use __iomem pointers for MMIO
ARM is moving to stricter checks on readl/write functions,
so we need to use the correct types everywhere.
This patch is a bit ugly for shmobile, which is the only platform
that just uses integer literals all over the place, but I can't
see a better way to do this.
Acked-by: Simon Horman <horms@verge.net.au>
Cc: Magnus Damm <magnus.damm@gmail.com>
Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: linux-sh@vger.kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/arm/mach-shmobile/intc-sh7372.c')
-rw-r--r-- | arch/arm/mach-shmobile/intc-sh7372.c | 27 |
1 files changed, 15 insertions, 12 deletions
diff --git a/arch/arm/mach-shmobile/intc-sh7372.c b/arch/arm/mach-shmobile/intc-sh7372.c index 2587a22842f2..a91caad7db7c 100644 --- a/arch/arm/mach-shmobile/intc-sh7372.c +++ b/arch/arm/mach-shmobile/intc-sh7372.c | |||
@@ -624,6 +624,9 @@ void sh7372_intcs_resume(void) | |||
624 | __raw_writeb(ffd5[k], intcs_ffd5 + k); | 624 | __raw_writeb(ffd5[k], intcs_ffd5 + k); |
625 | } | 625 | } |
626 | 626 | ||
627 | #define E694_BASE IOMEM(0xe6940000) | ||
628 | #define E695_BASE IOMEM(0xe6950000) | ||
629 | |||
627 | static unsigned short e694[0x200]; | 630 | static unsigned short e694[0x200]; |
628 | static unsigned short e695[0x200]; | 631 | static unsigned short e695[0x200]; |
629 | 632 | ||
@@ -632,22 +635,22 @@ void sh7372_intca_suspend(void) | |||
632 | int k; | 635 | int k; |
633 | 636 | ||
634 | for (k = 0x00; k <= 0x38; k += 4) | 637 | for (k = 0x00; k <= 0x38; k += 4) |
635 | e694[k] = __raw_readw(0xe6940000 + k); | 638 | e694[k] = __raw_readw(E694_BASE + k); |
636 | 639 | ||
637 | for (k = 0x80; k <= 0xb4; k += 4) | 640 | for (k = 0x80; k <= 0xb4; k += 4) |
638 | e694[k] = __raw_readb(0xe6940000 + k); | 641 | e694[k] = __raw_readb(E694_BASE + k); |
639 | 642 | ||
640 | for (k = 0x180; k <= 0x1b4; k += 4) | 643 | for (k = 0x180; k <= 0x1b4; k += 4) |
641 | e694[k] = __raw_readb(0xe6940000 + k); | 644 | e694[k] = __raw_readb(E694_BASE + k); |
642 | 645 | ||
643 | for (k = 0x00; k <= 0x50; k += 4) | 646 | for (k = 0x00; k <= 0x50; k += 4) |
644 | e695[k] = __raw_readw(0xe6950000 + k); | 647 | e695[k] = __raw_readw(E695_BASE + k); |
645 | 648 | ||
646 | for (k = 0x80; k <= 0xa8; k += 4) | 649 | for (k = 0x80; k <= 0xa8; k += 4) |
647 | e695[k] = __raw_readb(0xe6950000 + k); | 650 | e695[k] = __raw_readb(E695_BASE + k); |
648 | 651 | ||
649 | for (k = 0x180; k <= 0x1a8; k += 4) | 652 | for (k = 0x180; k <= 0x1a8; k += 4) |
650 | e695[k] = __raw_readb(0xe6950000 + k); | 653 | e695[k] = __raw_readb(E695_BASE + k); |
651 | } | 654 | } |
652 | 655 | ||
653 | void sh7372_intca_resume(void) | 656 | void sh7372_intca_resume(void) |
@@ -655,20 +658,20 @@ void sh7372_intca_resume(void) | |||
655 | int k; | 658 | int k; |
656 | 659 | ||
657 | for (k = 0x00; k <= 0x38; k += 4) | 660 | for (k = 0x00; k <= 0x38; k += 4) |
658 | __raw_writew(e694[k], 0xe6940000 + k); | 661 | __raw_writew(e694[k], E694_BASE + k); |
659 | 662 | ||
660 | for (k = 0x80; k <= 0xb4; k += 4) | 663 | for (k = 0x80; k <= 0xb4; k += 4) |
661 | __raw_writeb(e694[k], 0xe6940000 + k); | 664 | __raw_writeb(e694[k], E694_BASE + k); |
662 | 665 | ||
663 | for (k = 0x180; k <= 0x1b4; k += 4) | 666 | for (k = 0x180; k <= 0x1b4; k += 4) |
664 | __raw_writeb(e694[k], 0xe6940000 + k); | 667 | __raw_writeb(e694[k], E694_BASE + k); |
665 | 668 | ||
666 | for (k = 0x00; k <= 0x50; k += 4) | 669 | for (k = 0x00; k <= 0x50; k += 4) |
667 | __raw_writew(e695[k], 0xe6950000 + k); | 670 | __raw_writew(e695[k], E695_BASE + k); |
668 | 671 | ||
669 | for (k = 0x80; k <= 0xa8; k += 4) | 672 | for (k = 0x80; k <= 0xa8; k += 4) |
670 | __raw_writeb(e695[k], 0xe6950000 + k); | 673 | __raw_writeb(e695[k], E695_BASE + k); |
671 | 674 | ||
672 | for (k = 0x180; k <= 0x1a8; k += 4) | 675 | for (k = 0x180; k <= 0x1a8; k += 4) |
673 | __raw_writeb(e695[k], 0xe6950000 + k); | 676 | __raw_writeb(e695[k], E695_BASE + k); |
674 | } | 677 | } |