X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=drivers%2Famba%2Fbus.c;h=6b94fb7be5f280bbe2a8e5c0ddace6355cae0185;hb=4d4423caaa1b9ca709ef6a911a030a3b6e68c46b;hp=fd5475071accea2d48ff5ec7f15270d61409a27b;hpb=6705cda24fad1cb0ac82ac4f312df8ec735b39b0;p=mv-sheeva.git diff --git a/drivers/amba/bus.c b/drivers/amba/bus.c index fd5475071ac..6b94fb7be5f 100644 --- a/drivers/amba/bus.c +++ b/drivers/amba/bus.c @@ -44,17 +44,13 @@ static int amba_match(struct device *dev, struct device_driver *drv) } #ifdef CONFIG_HOTPLUG -static int amba_uevent(struct device *dev, char **envp, int nr_env, char *buf, int bufsz) +static int amba_uevent(struct device *dev, struct kobj_uevent_env *env) { struct amba_device *pcdev = to_amba_device(dev); + int retval = 0; - if (nr_env < 2) - return -ENOMEM; - - snprintf(buf, bufsz, "AMBA_ID=%08x", pcdev->periphid); - *envp++ = buf; - *envp++ = NULL; - return 0; + retval = add_uevent_var(env, "AMBA_ID=%08x", pcdev->periphid); + return retval; } #else #define amba_uevent NULL