summaryrefslogtreecommitdiffstats
path: root/commands/devinfo.c
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2016-01-15 15:31:13 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2016-01-15 15:33:59 +0100
commite2306ada3ee62a9dcf82c072477d9eeeb8bbede3 (patch)
tree638bfbfbda2bf6fa1711c26d6d1566bc8f9888ed /commands/devinfo.c
parent7f2e215fcfce225a3e6e09a0364693e2ada0cdd2 (diff)
downloadbarebox-e2306ada3ee62a9dcf82c072477d9eeeb8bbede3.tar.gz
Convert users of PRINTF_CONVERSION_RESOURCE to %pa
printf now supports printing resource_size_t directly, convert all users of the previously used PRINTF_CONVERSION_RESOURCE over to %pa. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'commands/devinfo.c')
-rw-r--r--commands/devinfo.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/commands/devinfo.c b/commands/devinfo.c
index c78efcb..9d5e8b8 100644
--- a/commands/devinfo.c
+++ b/commands/devinfo.c
@@ -77,13 +77,15 @@ static int do_devinfo(int argc, char *argv[])
if (dev->num_resources)
printf("Resources:\n");
for (i = 0; i < dev->num_resources; i++) {
+ resource_size_t size;
res = &dev->resource[i];
+ size = resource_size(res);
printf(" num: %d\n", i);
if (res->name)
printf(" name: %s\n", res->name);
- printf(" start: " PRINTF_CONVERSION_RESOURCE "\n"
- " size: " PRINTF_CONVERSION_RESOURCE "\n",
- res->start, resource_size(res));
+ printf(" start: %pa\n"
+ " size: %pa\n",
+ &res->start, &size);
}
if (dev->driver)