mirror of https://github.com/thesofproject/sof.git
Audio: ASRC: Fix the IPC3 incompatible pointer type
Fix the IPC3 incompatible pointer type passing 'struct timestamp_data *' to parameter of type 'struct dai_ts_data *', which is found by ./scripts/fuzz.sh test. Signed-off-by: Andrula Song <andrula.song@intel.com>
This commit is contained in:
parent
7e5d40aaf7
commit
3f572b8cb6
|
@ -39,12 +39,6 @@ static inline bool asrc_get_asynchronous_mode(const struct ipc4_asrc_module_cfg
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if CONFIG_ZEPHYR_NATIVE_DRIVERS
|
|
||||||
int asrc_dai_get_timestamp(struct comp_data *cd, struct dai_ts_data *tsd);
|
|
||||||
#else
|
|
||||||
int asrc_dai_get_timestamp(struct comp_data *cd, struct timestamp_data *tsd);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#else /*IPC3 version*/
|
#else /*IPC3 version*/
|
||||||
typedef struct ipc_config_asrc ipc_asrc_cfg;
|
typedef struct ipc_config_asrc ipc_asrc_cfg;
|
||||||
|
|
||||||
|
@ -68,10 +62,13 @@ static inline bool asrc_get_asynchronous_mode(const struct ipc_config_asrc *ipc_
|
||||||
return ipc_asrc->asynchronous_mode;
|
return ipc_asrc->asynchronous_mode;
|
||||||
}
|
}
|
||||||
|
|
||||||
int asrc_dai_get_timestamp(struct comp_data *cd, struct timestamp_data *tsd);
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if CONFIG_ZEPHYR_NATIVE_DRIVERS
|
||||||
|
int asrc_dai_get_timestamp(struct comp_data *cd, struct dai_ts_data *tsd);
|
||||||
|
#else
|
||||||
|
int asrc_dai_get_timestamp(struct comp_data *cd, struct timestamp_data *tsd);
|
||||||
|
#endif
|
||||||
/* Simple count value to prevent first delta timestamp
|
/* Simple count value to prevent first delta timestamp
|
||||||
* from being input to low-pass filter.
|
* from being input to low-pass filter.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -46,7 +46,11 @@ int asrc_dai_stop_timestamp(struct comp_data *cd)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if CONFIG_ZEPHYR_NATIVE_DRIVERS
|
||||||
|
int asrc_dai_get_timestamp(struct comp_data *cd, struct dai_ts_data *tsd)
|
||||||
|
#else
|
||||||
int asrc_dai_get_timestamp(struct comp_data *cd, struct timestamp_data *tsd)
|
int asrc_dai_get_timestamp(struct comp_data *cd, struct timestamp_data *tsd)
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
if (!cd->dai_dev)
|
if (!cd->dai_dev)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
Loading…
Reference in New Issue