On 25 April 2012 09:52, Fabio Estevam <[email protected]> wrote: > int spi_register_master(struct spi_master *master) > { > - static atomic_t dyn_bus_id = ATOMIC_INIT((1<<15) - 1); > struct device *dev = master->dev.parent; > struct boardinfo *bi; > int status = -ENODEV; > @@ -986,7 +985,7 @@ int spi_register_master(struct spi_master *master) > /* FIXME switch to an IDR based scheme, something like > * I2C now uses, so we can't run out of "dynamic" IDs > */ > - master->bus_num = atomic_dec_return(&dyn_bus_id); > + master->bus_num = dev->id; > dynamic = 1; > } > > Then the spi bus number becomes the same in dt and non-dt cases. > > So maybe the current behavior is expected because the usage of dyn_bus_id ?
I would think so. Not sure if you are interested in solving the FIXME in the comment right above that. Regards, Shawn ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ spi-devel-general mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/spi-devel-general
