+struct wcd937x_priv {
- struct sdw_slave *tx_sdw_dev;
- struct sdw_slave *rx_sdw_dev;
Does this mean that the codec has 2 SoundWire interfaces?
If yes, aren't there merits in splitting the implementation in two separate drivers, one for each interface and probing on the relevant partID?
This is how the RT713 was handled. The mic function was exposed as the RT1713.
By representing the device as a single entity, things could be fun because the two interfaces are really independent. things like clock stop are handled at the interface level.
The code in this driver is difficult to review, for example in the probe you wait for the TX part to complete the enumeration/initialization, but there's nothing mentioned or stated on the RX part, and there's really nothing related to the detection of this device. I don't actually see a sdw_driver at all, it's a platform driver.
Would you mind adding a paragraph on how the SoundWire interfaces are handled and how the SoundWire bus is involved if there's no sdw_driver?
Thanks!