diff options
author | Tom Rini <trini@konsulko.com> | 2018-12-10 07:16:33 -0500 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2018-12-10 07:16:33 -0500 |
commit | 7ff485c68b7e5573e5a4a877066e98398283a24f (patch) | |
tree | 8070ad8de0b18240ee67e1c8b847afc37bdb2d5d /drivers/core/device.c | |
parent | 7504e9e75f76a5101b47cd32851ad7bd4ea8ff70 (diff) | |
parent | 19f8c4dfb6e744a31da59bdd23b24d144152f1dc (diff) |
Merge branch 'master' of git://git.denx.de/u-boot-i2c
- DM_I2C_COMPAT removal for all ti platforms from Jean-Jacques Hiblot
- Fix in i2c command help output from Chirstoph Muellner.
Diffstat (limited to 'drivers/core/device.c')
-rw-r--r-- | drivers/core/device.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/core/device.c b/drivers/core/device.c index 836bcadced..0d15e5062b 100644 --- a/drivers/core/device.c +++ b/drivers/core/device.c @@ -70,7 +70,8 @@ static int device_bind_common(struct udevice *parent, const struct driver *drv, dev->seq = -1; dev->req_seq = -1; - if (CONFIG_IS_ENABLED(OF_CONTROL) && CONFIG_IS_ENABLED(DM_SEQ_ALIAS)) { + if (CONFIG_IS_ENABLED(DM_SEQ_ALIAS) && + (uc->uc_drv->flags & DM_UC_FLAG_SEQ_ALIAS)) { /* * Some devices, such as a SPI bus, I2C bus and serial ports * are numbered using aliases. @@ -78,10 +79,11 @@ static int device_bind_common(struct udevice *parent, const struct driver *drv, * This is just a 'requested' sequence, and will be * resolved (and ->seq updated) when the device is probed. */ - if (uc->uc_drv->flags & DM_UC_FLAG_SEQ_ALIAS) { - if (uc->uc_drv->name && ofnode_valid(node)) { + if (CONFIG_IS_ENABLED(OF_CONTROL) && !CONFIG_IS_ENABLED(OF_PLATDATA)) { + if (uc->uc_drv->name && ofnode_valid(node)) dev_read_alias_seq(dev, &dev->req_seq); - } + } else { + dev->req_seq = uclass_find_next_free_req_seq(drv->id); } } |