diff options
author | Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> | 2020-05-19 04:35:51 +0800 |
---|---|---|
committer | Vinod Koul <vkoul@kernel.org> | 2020-05-20 17:22:41 +0530 |
commit | bcac59029955ae57d3c660a0a1d6d4c7ae78fb49 (patch) | |
tree | d1ed29a40b4a6a59760fce57ce394e0154d7dc57 /drivers/soundwire/Makefile | |
parent | c5778ca49a19420c67dbeff0744a3b3b75ef4e1a (diff) | |
download | linux-bcac59029955ae57d3c660a0a1d6d4c7ae78fb49.tar.bz2 |
soundwire: add Slave sysfs support
Expose MIPI DisCo Slave properties in sysfs.
For Slave properties and Data Port 0, the attributes are managed with
simple devm_ support.
A Slave Device may have more than one Data Port (DPN), and each Data
Port can be sink or source. The attributes are created dynamically
using pre-canned macros, but still use devm_ with a name attribute
group to avoid creating kobjects - as requested by GregKH. In the
_show function, we use container_of() to retrieve port number and
direction required to extract the information.
Audio modes are not supported for now. Depending on the discussions
the SoundWire Device Class, we may add it later as is or follow the
new specification.
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Link: https://lore.kernel.org/r/20200518203551.2053-4-yung-chuan.liao@linux.intel.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/soundwire/Makefile')
-rw-r--r-- | drivers/soundwire/Makefile | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/soundwire/Makefile b/drivers/soundwire/Makefile index 7319918e0aec..9b0aeee94876 100644 --- a/drivers/soundwire/Makefile +++ b/drivers/soundwire/Makefile @@ -4,7 +4,8 @@ # #Bus Objs -soundwire-bus-objs := bus_type.o bus.o master.o slave.o mipi_disco.o stream.o +soundwire-bus-objs := bus_type.o bus.o master.o slave.o mipi_disco.o stream.o \ + sysfs_slave.o sysfs_slave_dpn.o obj-$(CONFIG_SOUNDWIRE) += soundwire-bus.o ifdef CONFIG_DEBUG_FS |