1 /*
2 * Copyright (C) 2022 HiHope Open Source Organization .
3 *
4 * HDF is dual licensed: you can use it either under the terms of
5 * the GPL, or the BSD license, at your option.
6 * See the LICENSE file in the root of this repository for complete details.
7 */
8
9 #include "rk3568_dsp_ops.h"
10 #include "spi_if.h"
11 #include "audio_dsp_if.h"
12 #include "audio_driver_log.h"
13
14 #define HDF_LOG_TAG rk3568_dsp_ops
15
DspDaiStartup(const struct AudioCard * card,const struct DaiDevice * device)16 int32_t DspDaiStartup(const struct AudioCard *card, const struct DaiDevice *device)
17 {
18 (void)card;
19 (void)device;
20 return HDF_SUCCESS;
21 }
22
DspDaiHwParams(const struct AudioCard * card,const struct AudioPcmHwParams * param)23 int32_t DspDaiHwParams(const struct AudioCard *card, const struct AudioPcmHwParams *param)
24 {
25 (void)card;
26 (void)param;
27 AUDIO_DRIVER_LOG_DEBUG("success.");
28 return HDF_SUCCESS;
29 }
30
31
DspDeviceInit(const struct DspDevice * device)32 int32_t DspDeviceInit(const struct DspDevice *device)
33 {
34 (void)device;
35 return HDF_SUCCESS;
36 }
37
DspDeviceReadReg(const struct DspDevice * device,const void * msgs,const uint32_t len)38 int32_t DspDeviceReadReg(const struct DspDevice *device, const void *msgs, const uint32_t len)
39 {
40 (void)device;
41 (void)msgs;
42 return HDF_SUCCESS;
43 }
44
DspDeviceWriteReg(const struct DspDevice * device,const void * msgs,const uint32_t len)45 int32_t DspDeviceWriteReg(const struct DspDevice *device, const void *msgs, const uint32_t len)
46 {
47 (void)device;
48 (void)msgs;
49 return HDF_SUCCESS;
50 }
51
DspDaiDeviceInit(struct AudioCard * card,const struct DaiDevice * device)52 int32_t DspDaiDeviceInit(struct AudioCard *card, const struct DaiDevice *device)
53 {
54 (void)card;
55 (void)device;
56 return HDF_SUCCESS;
57 }
58
DspDecodeAudioStream(const struct AudioCard * card,const uint8_t * buf,const struct DspDevice * device)59 int32_t DspDecodeAudioStream(const struct AudioCard *card, const uint8_t *buf, const struct DspDevice *device)
60 {
61 (void)card;
62 (void)buf;
63 (void)device;
64 AUDIO_DRIVER_LOG_DEBUG("decode run!!!");
65 return HDF_SUCCESS;
66 }
67
DspEncodeAudioStream(const struct AudioCard * card,const uint8_t * buf,const struct DspDevice * device)68 int32_t DspEncodeAudioStream(const struct AudioCard *card, const uint8_t *buf, const struct DspDevice *device)
69 {
70 (void)card;
71 (void)buf;
72 (void)device;
73 AUDIO_DRIVER_LOG_DEBUG("encode run!!!");
74 return HDF_SUCCESS;
75 }
76
77
DspEqualizerActive(const struct AudioCard * card,const uint8_t * buf,const struct DspDevice * device)78 int32_t DspEqualizerActive(const struct AudioCard *card, const uint8_t *buf, const struct DspDevice *device)
79 {
80 (void)card;
81 (void)buf;
82 (void)device;
83 AUDIO_DRIVER_LOG_DEBUG("equalizer run!!!");
84 return HDF_SUCCESS;
85 }
86