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 #include "audio_accessory_base.h"
14
15 #define HDF_LOG_TAG rk3568_dsp_ops
16
DspDaiStartup(const struct AudioCard * card,const struct DaiDevice * device)17 int32_t DspDaiStartup(const struct AudioCard *card, const struct DaiDevice *device)
18 {
19 (void)card;
20 (void)device;
21 return HDF_SUCCESS;
22 }
23
DspDaiHwParams(const struct AudioCard * card,const struct AudioPcmHwParams * param)24 int32_t DspDaiHwParams(const struct AudioCard *card, const struct AudioPcmHwParams *param)
25 {
26 (void)card;
27 (void)param;
28 AUDIO_DRIVER_LOG_DEBUG("success.");
29 return HDF_SUCCESS;
30 }
31
32
DspDeviceInit(const struct DspDevice * device)33 int32_t DspDeviceInit(const struct DspDevice *device)
34 {
35 (void)device;
36 return HDF_SUCCESS;
37 }
38
DspDeviceReadReg(const struct DspDevice * device,const void * msgs,const uint32_t len)39 int32_t DspDeviceReadReg(const struct DspDevice *device, const void *msgs, const uint32_t len)
40 {
41 (void)device;
42 (void)msgs;
43 return HDF_SUCCESS;
44 }
45
DspDeviceWriteReg(const struct DspDevice * device,const void * msgs,const uint32_t len)46 int32_t DspDeviceWriteReg(const struct DspDevice *device, const void *msgs, const uint32_t len)
47 {
48 (void)device;
49 (void)msgs;
50 return HDF_SUCCESS;
51 }
52
DspDaiDeviceInit(struct AudioCard * card,const struct DaiDevice * device)53 int32_t DspDaiDeviceInit(struct AudioCard *card, const struct DaiDevice *device)
54 {
55 (void)card;
56 (void)device;
57 return HDF_SUCCESS;
58 }
59
DspDecodeAudioStream(const struct AudioCard * card,const uint8_t * buf,const struct DspDevice * device)60 int32_t DspDecodeAudioStream(const struct AudioCard *card, const uint8_t *buf, const struct DspDevice *device)
61 {
62 (void)card;
63 (void)buf;
64 (void)device;
65 AUDIO_DRIVER_LOG_DEBUG("decode run!!!");
66 return HDF_SUCCESS;
67 }
68
DspEncodeAudioStream(const struct AudioCard * card,const uint8_t * buf,const struct DspDevice * device)69 int32_t DspEncodeAudioStream(const struct AudioCard *card, const uint8_t *buf, const struct DspDevice *device)
70 {
71 (void)card;
72 (void)buf;
73 (void)device;
74 AUDIO_DRIVER_LOG_DEBUG("encode run!!!");
75 return HDF_SUCCESS;
76 }
77
78
DspEqualizerActive(const struct AudioCard * card,const uint8_t * buf,const struct DspDevice * device)79 int32_t DspEqualizerActive(const struct AudioCard *card, const uint8_t *buf, const struct DspDevice *device)
80 {
81 (void)card;
82 (void)buf;
83 (void)device;
84 AUDIO_DRIVER_LOG_DEBUG("equalizer run!!!");
85 return HDF_SUCCESS;
86 }
87