ASoC/soundwire: remove is_sdca boolean property
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Fri, 18 Nov 2022 02:58:06 +0000 (10:58 +0800)
committerVinod Koul <vkoul@kernel.org>
Mon, 9 Jan 2023 16:07:40 +0000 (21:37 +0530)
The Device_ID registers already tell us if a device supports the SDCA
specification or not, in hindsight we never needed a property when the
information is reported by both hardware and ACPI.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Rander Wang <rander.wang@intel.com>
Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com>
Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Acked-by: Mark Brown <broonie@kernel.org>
Link: https://lore.kernel.org/r/20221118025807.534863-2-yung-chuan.liao@linux.intel.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/soundwire/bus.c
include/linux/soundwire/sdw.h
sound/soc/codecs/rt1316-sdw.c
sound/soc/codecs/rt1318-sdw.c
sound/soc/codecs/rt711-sdca-sdw.c

index 76515c33e639ed646209b40b612fab517d3bea43..c23275b443acec68ce22fa56606944400c5419df 100644 (file)
@@ -1587,7 +1587,7 @@ static int sdw_handle_slave_alerts(struct sdw_slave *slave)
                goto io_err;
        }
 
-       if (slave->prop.is_sdca) {
+       if (slave->id.class_id) {
                ret = sdw_read_no_pm(slave, SDW_DP0_INT);
                if (ret < 0) {
                        dev_err(&slave->dev,
@@ -1724,7 +1724,7 @@ static int sdw_handle_slave_alerts(struct sdw_slave *slave)
                        goto io_err;
                }
 
-               if (slave->prop.is_sdca) {
+               if (slave->id.class_id) {
                        ret = sdw_read_no_pm(slave, SDW_DP0_INT);
                        if (ret < 0) {
                                dev_err(&slave->dev,
index 9e4537f409c295714354e16676223c541834974a..8fb458931772c057bd191410129d9ca8006b779e 100644 (file)
@@ -365,7 +365,6 @@ struct sdw_dpn_prop {
  * @sink_dpn_prop: Sink Data Port N properties
  * @scp_int1_mask: SCP_INT1_MASK desired settings
  * @quirks: bitmask identifying deltas from the MIPI specification
- * @is_sdca: the Slave supports the SDCA specification
  */
 struct sdw_slave_prop {
        u32 mipi_revision;
@@ -389,7 +388,6 @@ struct sdw_slave_prop {
        struct sdw_dpn_prop *sink_dpn_prop;
        u8 scp_int1_mask;
        u32 quirks;
-       bool is_sdca;
 };
 
 #define SDW_SLAVE_QUIRKS_INVALID_INITIAL_PARITY        BIT(0)
index e6294cc7a9954781598711c0d2fadf2a39b25c5b..c270fd9f85489deed0186e1306d6f534e7fa3a8f 100644 (file)
@@ -204,7 +204,6 @@ static int rt1316_read_prop(struct sdw_slave *slave)
 
        prop->scp_int1_mask = SDW_SCP_INT1_BUS_CLASH | SDW_SCP_INT1_PARITY;
        prop->quirks = SDW_SLAVE_QUIRKS_INVALID_INITIAL_PARITY;
-       prop->is_sdca = true;
 
        prop->paging_support = true;
 
index f85f5ab2c6d048285faa6b78e691927793f0e4f4..8bc379215c34ecd5ee774a91d8060cf95d8cc2f4 100644 (file)
@@ -353,7 +353,6 @@ static int rt1318_read_prop(struct sdw_slave *slave)
 
        prop->scp_int1_mask = SDW_SCP_INT1_BUS_CLASH | SDW_SCP_INT1_PARITY;
        prop->quirks = SDW_SLAVE_QUIRKS_INVALID_INITIAL_PARITY;
-       prop->is_sdca = true;
 
        prop->paging_support = true;
 
index 88a8392a58edb5b33cf08f8bf72315ba17f3f81e..693e11ed8d0832819f9e75e608628cf4daec6948 100644 (file)
@@ -186,7 +186,6 @@ static int rt711_sdca_read_prop(struct sdw_slave *slave)
 
        prop->scp_int1_mask = SDW_SCP_INT1_BUS_CLASH | SDW_SCP_INT1_PARITY;
        prop->quirks = SDW_SLAVE_QUIRKS_INVALID_INITIAL_PARITY;
-       prop->is_sdca = true;
 
        prop->paging_support = true;