summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/dt-bindings/sound/rt5651.h15
-rw-r--r--include/sound/rt5651.h36
-rw-r--r--sound/soc/codecs/rt5651.h4
3 files changed, 17 insertions, 38 deletions
diff --git a/include/dt-bindings/sound/rt5651.h b/include/dt-bindings/sound/rt5651.h
new file mode 100644
index 000000000000..2f2dac915168
--- /dev/null
+++ b/include/dt-bindings/sound/rt5651.h
@@ -0,0 +1,15 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+#ifndef __DT_RT5651_H
+#define __DT_RT5651_H
+
+#define RT5651_JD_NULL 0
+#define RT5651_JD1_1 1
+#define RT5651_JD1_2 2
+#define RT5651_JD2 3
+
+#define RT5651_OVCD_SF_0P5 0
+#define RT5651_OVCD_SF_0P75 1
+#define RT5651_OVCD_SF_1P0 2
+#define RT5651_OVCD_SF_1P5 3
+
+#endif /* __DT_RT5651_H */
diff --git a/include/sound/rt5651.h b/include/sound/rt5651.h
deleted file mode 100644
index 6403b862fb9a..000000000000
--- a/include/sound/rt5651.h
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * linux/sound/rt286.h -- Platform data for RT286
- *
- * Copyright 2013 Realtek Microelectronics
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 2 as
- * published by the Free Software Foundation.
- */
-
-#ifndef __LINUX_SND_RT5651_H
-#define __LINUX_SND_RT5651_H
-
-/*
- * Note these MUST match the values from the DT binding:
- * Documentation/devicetree/bindings/sound/rt5651.txt
- */
-enum rt5651_jd_src {
- RT5651_JD_NULL,
- RT5651_JD1_1,
- RT5651_JD1_2,
- RT5651_JD2,
-};
-
-/*
- * Note these MUST match the values from the DT binding:
- * Documentation/devicetree/bindings/sound/rt5651.txt
- */
-enum rt5651_ovcd_sf {
- RT5651_OVCD_SF_0P5,
- RT5651_OVCD_SF_0P75,
- RT5651_OVCD_SF_1P0,
- RT5651_OVCD_SF_1P5,
-};
-
-#endif
diff --git a/sound/soc/codecs/rt5651.h b/sound/soc/codecs/rt5651.h
index f20c9be94fb2..3a0968c53fde 100644
--- a/sound/soc/codecs/rt5651.h
+++ b/sound/soc/codecs/rt5651.h
@@ -12,7 +12,7 @@
#ifndef __RT5651_H__
#define __RT5651_H__
-#include <sound/rt5651.h>
+#include <dt-bindings/sound/rt5651.h>
/* Info */
#define RT5651_RESET 0x00
@@ -2073,7 +2073,7 @@ struct rt5651_priv {
struct regmap *regmap;
struct snd_soc_jack *hp_jack;
struct work_struct jack_detect_work;
- enum rt5651_jd_src jd_src;
+ unsigned int jd_src;
unsigned int ovcd_th;
unsigned int ovcd_sf;