Unverified Commit 870b10f6 authored by Johan Hovold's avatar Johan Hovold Committed by Mark Brown
Browse files

ASoC: soc_sdw_utils: drop bogus container_of() error handling



The dev_to_sdw_dev() helper uses container_of() to return the containing
soundwire device structure of its pointer argument and will never return
NULL.

Fixes: 4f8ef33d ("ASoC: soc_sdw_utils: skip the endpoint that doesn't present")
Cc: Bard Liao <yung-chuan.liao@linux.intel.com>
Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
Reviewed-by: default avatarKonrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Reviewed-by: default avatarDmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Link: https://patch.msgid.link/20251219142715.19254-4-johan@kernel.org


Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 61a50d6f
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -1414,10 +1414,6 @@ static int is_sdca_endpoint_present(struct device *dev,
	}

	slave = dev_to_sdw_dev(sdw_dev);
	if (!slave) {
		ret = -EINVAL;
		goto put_device;
	}

	/* Make sure BIOS provides SDCA properties */
	if (!slave->sdca_data.interface_revision) {