diff --git a/drivers/amba/bus.c b/drivers/amba/bus.c index 4a3ac31c07d0..842314a439fd 100644 --- a/drivers/amba/bus.c +++ b/drivers/amba/bus.c @@ -101,8 +101,8 @@ static ssize_t driver_override_store(struct device *_dev, if (strlen(driver_override)) { dev->driver_override = driver_override; } else { - kfree(driver_override); - dev->driver_override = NULL; + kfree(driver_override); + dev->driver_override = NULL; } device_unlock(_dev);