From 908c4b0900a1069f7b346e0f178db01a35ed261c Mon Sep 17 00:00:00 2001 From: Jean-Christophe PLAGNIOL-VILLARD Date: Sun, 14 Oct 2012 16:27:08 +0200 Subject: amba: add periph id RO params to the device this will allow to knonw the pid probed Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD Signed-off-by: Sascha Hauer --- drivers/amba/bus.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'drivers/amba/bus.c') diff --git a/drivers/amba/bus.c b/drivers/amba/bus.c index f0a40b69c5..d1ab53ca72 100644 --- a/drivers/amba/bus.c +++ b/drivers/amba/bus.c @@ -157,6 +157,13 @@ int amba_device_add(struct amba_device *dev) if (ret) goto err_release; + if (IS_ENABLED(CONFIG_PARAMETER)) { + char str[16]; + + sprintf(str, "0x%08x", dev->periphid); + dev_add_param_fixed(&dev->dev, "periphid", str); + } + return ret; err_release: release_region(res); -- cgit v1.2.3