lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1311364042-8325-1-git-send-email-balbi@ti.com>
Date:	Fri, 22 Jul 2011 22:47:21 +0300
From:	Felipe Balbi <balbi@...com>
To:	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Cc:	Linux ARM Kernel Mailing List 
	<linux-arm-kernel@...ts.infradead.org>,
	Linux OMAP Mailing List <linux-omap@...r.kernel.org>,
	Tony Lindgren <tony@...mide.com>,
	Russell King <linux@....linux.org.uk>,
	devicetree-discuss@...ts.ozlabs.org, Felipe Balbi <balbi@...com>,
	Grant Likely <grant.likely@...retlab.ca>
Subject: [PATCH 1/2] of: address: use resource_size helper

that should be the approved way of calculating
the size of resources. No functional changes.

Cc: Grant Likely <grant.likely@...retlab.ca>
Signed-off-by: Felipe Balbi <balbi@...com>
---
 drivers/of/address.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/of/address.c b/drivers/of/address.c
index deefc0c..6e7b2cf 100644
--- a/drivers/of/address.c
+++ b/drivers/of/address.c
@@ -624,6 +624,6 @@ void __iomem *of_iomap(struct device_node *np, int index)
 	if (of_address_to_resource(np, index, &res))
 		return NULL;
 
-	return ioremap(res.start, 1 + res.end - res.start);
+	return ioremap(res.start, resource_size(&res));
 }
 EXPORT_SYMBOL(of_iomap);
-- 
1.7.6

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ