blob: 06a991ca99a208dbf97be3edc5f791067a3a1804 [file] [log] [blame]
Meng Wang43bbb872018-12-10 12:32:05 +08001// SPDX-License-Identifier: GPL-2.0-only
Asish Bhattacharya8e2277f2017-07-20 18:31:55 +05302/*
3 * Copyright (c) 2017, The Linux Foundation. All rights reserved.
Asish Bhattacharya8e2277f2017-07-20 18:31:55 +05304 */
5
6#include <linux/module.h>
7#include <sound/wcd-dsp-mgr.h>
8#include "audio-ext-clk-up.h"
9
10static int __init wcd9xxx_soc_init(void)
11{
12 int ret = 0;
13
14 ret = wcd_dsp_mgr_init();
15 if (!ret) {
16 ret = audio_ref_clk_platform_init();
17 if (ret) {
18 pr_err("%s: init extclk fail: %d\n", __func__, ret);
19 wcd_dsp_mgr_exit();
20 }
21 } else {
22 pr_err("%s: init dsp mgr fail: %d\n", __func__, ret);
23 }
24
25 return ret;
26}
27module_init(wcd9xxx_soc_init);
28
29static void __exit wcd9xxx_soc_exit(void)
30{
31 audio_ref_clk_platform_exit();
32 wcd_dsp_mgr_exit();
33}
34module_exit(wcd9xxx_soc_exit);
35
36MODULE_DESCRIPTION("WCD9XXX CODEC soc init driver");
37MODULE_LICENSE("GPL v2");