diff options
author | Tom Rini <trini@ti.com> | 2014-11-24 12:01:48 -0500 |
---|---|---|
committer | Tom Rini <trini@ti.com> | 2014-11-24 12:01:48 -0500 |
commit | 1739564e753bc3a8097f8937a3cbe738bdaaed5d (patch) | |
tree | 56fe759e62f129dc055b6f6a22f299f6c8b5cdde /include/dm/device-internal.h | |
parent | 746667f1e56bf08d03e66a178df3c4f4f6c806e1 (diff) | |
parent | 17b28edb37a33d0c89089faf36e4edd7084f65fa (diff) | |
download | u-boot-imx-1739564e753bc3a8097f8937a3cbe738bdaaed5d.zip u-boot-imx-1739564e753bc3a8097f8937a3cbe738bdaaed5d.tar.gz u-boot-imx-1739564e753bc3a8097f8937a3cbe738bdaaed5d.tar.bz2 |
Merge git://git.denx.de/u-boot-dm
Conflicts:
drivers/serial/serial-uclass.c
Signed-off-by: Tom Rini <trini@ti.com>
Diffstat (limited to 'include/dm/device-internal.h')
-rw-r--r-- | include/dm/device-internal.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/dm/device-internal.h b/include/dm/device-internal.h index 44cb7ef..f0cc794 100644 --- a/include/dm/device-internal.h +++ b/include/dm/device-internal.h @@ -87,7 +87,11 @@ int device_probe_child(struct udevice *dev, void *parent_priv); * @dev: Pointer to device to remove * @return 0 if OK, -ve on error (an error here is normally a very bad thing) */ +#ifdef CONFIG_DM_DEVICE_REMOVE int device_remove(struct udevice *dev); +#else +static inline int device_remove(struct udevice *dev) { return 0; } +#endif /** * device_unbind() - Unbind a device, destroying it @@ -99,6 +103,12 @@ int device_remove(struct udevice *dev); */ int device_unbind(struct udevice *dev); +#ifdef CONFIG_DM_DEVICE_REMOVE +void device_free(struct udevice *dev); +#else +static inline void device_free(struct udevice *dev) {} +#endif + /* Cast away any volatile pointer */ #define DM_ROOT_NON_CONST (((gd_t *)gd)->dm_root) #define DM_UCLASS_ROOT_NON_CONST (((gd_t *)gd)->uclass_root) |