diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2013-03-06 20:03:50 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2013-03-14 08:42:24 +0100 |
commit | 1a66a775674e3ae940e68c95e42dbad75af77523 (patch) | |
tree | a173a07320e49344cb72fc8989e95069891ccd39 /drivers/base/driver.c | |
parent | 7a76f0607bef50e4439d162e577007aa74f51a5f (diff) | |
download | barebox-1a66a775674e3ae940e68c95e42dbad75af77523.tar.gz barebox-1a66a775674e3ae940e68c95e42dbad75af77523.tar.xz |
bus: Make struct device a pointer
struct bus_type contains an embedded struct device_d which is quite
a big structure. Dynamically allocate this instead to save the space
in the binary.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/base/driver.c')
-rw-r--r-- | drivers/base/driver.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/base/driver.c b/drivers/base/driver.c index fa30c68059..487f478d69 100644 --- a/drivers/base/driver.c +++ b/drivers/base/driver.c @@ -135,7 +135,7 @@ int register_device(struct device_d *new_device) if (new_device->bus) { if (!new_device->parent) - new_device->parent = &new_device->bus->dev; + new_device->parent = new_device->bus->dev; list_add_tail(&new_device->bus_list, &new_device->bus->device_list); |