mirror of
https://github.com/torvalds/linux.git
synced 2026-06-01 19:13:47 +02:00
ASoC: SDCA: Parse Function Reset max delay
Parse the DisCo property to get the timeout for a Function Reset. Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.dev> Link: https://patch.msgid.link/20251020155512.353774-12-ckeepax@opensource.cirrus.com Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
0a5e9769d0
commit
7b6be935e7
|
|
@ -1323,6 +1323,8 @@ enum sdca_cluster_range {
|
||||||
* @num_clusters: Number of Channel Clusters reported in this Function.
|
* @num_clusters: Number of Channel Clusters reported in this Function.
|
||||||
* @busy_max_delay: Maximum Function busy delay in microseconds, before an
|
* @busy_max_delay: Maximum Function busy delay in microseconds, before an
|
||||||
* error should be reported.
|
* error should be reported.
|
||||||
|
* @reset_max_delay: Maximum Function reset delay in microseconds, before an
|
||||||
|
* error should be reported.
|
||||||
*/
|
*/
|
||||||
struct sdca_function_data {
|
struct sdca_function_data {
|
||||||
struct sdca_function_desc *desc;
|
struct sdca_function_desc *desc;
|
||||||
|
|
@ -1335,6 +1337,7 @@ struct sdca_function_data {
|
||||||
int num_clusters;
|
int num_clusters;
|
||||||
|
|
||||||
unsigned int busy_max_delay;
|
unsigned int busy_max_delay;
|
||||||
|
unsigned int reset_max_delay;
|
||||||
};
|
};
|
||||||
|
|
||||||
static inline u32 sdca_range(struct sdca_control_range *range,
|
static inline u32 sdca_range(struct sdca_control_range *range,
|
||||||
|
|
|
||||||
|
|
@ -2033,8 +2033,14 @@ int sdca_parse_function(struct device *dev, struct sdw_slave *sdw,
|
||||||
if (!ret)
|
if (!ret)
|
||||||
function->busy_max_delay = tmp;
|
function->busy_max_delay = tmp;
|
||||||
|
|
||||||
dev_info(dev, "%pfwP: name %s delay %dus\n", function->desc->node,
|
ret = fwnode_property_read_u32(function_desc->node,
|
||||||
function->desc->name, function->busy_max_delay);
|
"mipi-sdca-function-reset-max-delay", &tmp);
|
||||||
|
if (!ret)
|
||||||
|
function->reset_max_delay = tmp;
|
||||||
|
|
||||||
|
dev_info(dev, "%pfwP: name %s busy delay %dus reset delay %dus\n",
|
||||||
|
function->desc->node, function->desc->name,
|
||||||
|
function->busy_max_delay, function->reset_max_delay);
|
||||||
|
|
||||||
ret = find_sdca_init_table(dev, function_desc->node, function);
|
ret = find_sdca_init_table(dev, function_desc->node, function);
|
||||||
if (ret)
|
if (ret)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user