summaryrefslogtreecommitdiff
path: root/drivers/soundwire/bus.h
diff options
context:
space:
mode:
authorSrinivas Kandagatla <srinivas.kandagatla@linaro.org>2020-09-24 14:44:29 -0500
committerVinod Koul <vkoul@kernel.org>2020-09-28 11:17:40 +0530
commitfcb9d730be1d3010e0c8fdc5aaff62836d7a942c (patch)
treea137dd77e43bb7bbbb92a07b0030074263c662c7 /drivers/soundwire/bus.h
parent5ec3215e56af8f7ce30c3d9d39029a85616713c0 (diff)
soundwire: bus: add enumerated Slave device to device list
Currently Slave devices are only added on startup, either from Device Tree or ACPI entries. However Slave devices that are physically present on the bus, but not described in platform firmware, will never be added to the device list. The user/integrator can only know the list of devices by looking a dynamic debug logs. This patch suggests adding a Slave device even if there is no matching DT or ACPI entry, so that we can see this in sysfs entry. Initial code from Srinivas. Comments, fixes for ACPI probe and edits of commit message by Pierre. Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Co-developed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20200924194430.121058-2-pierre-louis.bossart@linux.intel.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/soundwire/bus.h')
-rw-r--r--drivers/soundwire/bus.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/soundwire/bus.h b/drivers/soundwire/bus.h
index e0703991aad9..2e049d39c6e5 100644
--- a/drivers/soundwire/bus.h
+++ b/drivers/soundwire/bus.h
@@ -19,6 +19,8 @@ static inline int sdw_acpi_find_slaves(struct sdw_bus *bus)
int sdw_of_find_slaves(struct sdw_bus *bus);
void sdw_extract_slave_id(struct sdw_bus *bus,
u64 addr, struct sdw_slave_id *id);
+int sdw_slave_add(struct sdw_bus *bus, struct sdw_slave_id *id,
+ struct fwnode_handle *fwnode);
int sdw_master_device_add(struct sdw_bus *bus, struct device *parent,
struct fwnode_handle *fwnode);
int sdw_master_device_del(struct sdw_bus *bus);