Commit 4f452e8aa492c0b8028ca9b4bdb4d018ba28c6c7
Committed by
Greg Kroah-Hartman
1 parent
a4ca661742
Exists in
master
and in
39 other branches
devres: support addresses greater than an unsigned long via dev_ioremap
Use a resource_size_t instead of unsigned long since some arch's are capable of having ioremap deal with addresses greater than the size of a unsigned long. Signed-off-by: Kumar Gala <galak@kernel.crashing.org> Cc: Tejun Heo <htejun@gmail.com> Cc: Jeff Garzik <jgarzik@pobox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Showing 2 changed files with 4 additions and 4 deletions Side-by-side Diff
include/linux/io.h
... | ... | @@ -58,9 +58,9 @@ |
58 | 58 | } |
59 | 59 | #endif |
60 | 60 | |
61 | -void __iomem * devm_ioremap(struct device *dev, unsigned long offset, | |
61 | +void __iomem *devm_ioremap(struct device *dev, resource_size_t offset, | |
62 | 62 | unsigned long size); |
63 | -void __iomem * devm_ioremap_nocache(struct device *dev, unsigned long offset, | |
63 | +void __iomem *devm_ioremap_nocache(struct device *dev, resource_size_t offset, | |
64 | 64 | unsigned long size); |
65 | 65 | void devm_iounmap(struct device *dev, void __iomem *addr); |
66 | 66 | int check_signature(const volatile void __iomem *io_addr, |
lib/devres.c
... | ... | @@ -20,7 +20,7 @@ |
20 | 20 | * |
21 | 21 | * Managed ioremap(). Map is automatically unmapped on driver detach. |
22 | 22 | */ |
23 | -void __iomem *devm_ioremap(struct device *dev, unsigned long offset, | |
23 | +void __iomem *devm_ioremap(struct device *dev, resource_size_t offset, | |
24 | 24 | unsigned long size) |
25 | 25 | { |
26 | 26 | void __iomem **ptr, *addr; |
... | ... | @@ -49,7 +49,7 @@ |
49 | 49 | * Managed ioremap_nocache(). Map is automatically unmapped on driver |
50 | 50 | * detach. |
51 | 51 | */ |
52 | -void __iomem *devm_ioremap_nocache(struct device *dev, unsigned long offset, | |
52 | +void __iomem *devm_ioremap_nocache(struct device *dev, resource_size_t offset, | |
53 | 53 | unsigned long size) |
54 | 54 | { |
55 | 55 | void __iomem **ptr, *addr; |