summaryrefslogtreecommitdiffstats
path: root/drivers/amba/bus.c
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2013-04-06 09:01:57 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2013-04-11 11:48:35 +0200
commit7c6c61fe8e66701263ee0b25056e65abcf3843d6 (patch)
tree2585770de051a43b0a016c9de5f165d87296d29a /drivers/amba/bus.c
parenta28085859402eecb4b2d9a051b1956e17f29e0aa (diff)
downloadbarebox-7c6c61fe8e66701263ee0b25056e65abcf3843d6.tar.gz
treewide: Use dev_add_param_int_ro where possible
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/amba/bus.c')
-rw-r--r--drivers/amba/bus.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/drivers/amba/bus.c b/drivers/amba/bus.c
index 7d7a654..6106252 100644
--- a/drivers/amba/bus.c
+++ b/drivers/amba/bus.c
@@ -153,14 +153,9 @@ int amba_device_add(struct amba_device *dev)
if (ret)
goto err_release;
- if (IS_ENABLED(CONFIG_PARAMETER)) {
- char str[16];
+ dev_add_param_int_ro(&dev->dev, "periphid", dev->periphid, "0x%08x");
- sprintf(str, "0x%08x", dev->periphid);
- dev_add_param_fixed(&dev->dev, "periphid", str);
- }
-
- return ret;
+ return ret;
err_release:
release_region(res);
return ret;