On Wed, May 21, 2008 at 10:50:02AM -0600, Grant Likely wrote: [..] > > + > > + master->num_chipselect = of_num_children(np); > > This assumes that there are no gaps in the assigned CS numbers of > child nodes, or that the child nodes are an exhaustive list of > attached devices, neither of which may be true. num_chipselect should > be calculated from the number of GPIOs specified instead.
[I'm not arguing just a thought.] - every SPI device must have its own chip-select, otherwise SPI device node should not be a part of a SPI controller node; - or there is just once device on the SPI bus with chip-select always asserted, no gpios = <> is specified (this case is implemented); - or the SPI is bridged, gpios = <> should list behind-the-bridge devices' chip-selects, and driver should understand that there is a "special" (bridge) device somewhere on the bus (not implemented). -- Anton Vorontsov email: [EMAIL PROTECTED] irc://irc.freenode.net/bd2 _______________________________________________ Linuxppc-dev mailing list Linuxppc-dev@ozlabs.org https://ozlabs.org/mailman/listinfo/linuxppc-dev