* [PATCH] Try to support analog audio codec at firefly reload @ 2016-08-15 20:42 ` Randy Li 0 siblings, 0 replies; 10+ messages in thread From: Randy Li @ 2016-08-15 20:42 UTC (permalink / raw) To: devicetree Cc: linux-kernel, linux-rockchip, linux-arm-kernel, linux, mark.rutland, heiko, alsa-devel, Randy Li Hello: This patch could enabled the es8328 codec at firefly reload board, but it doesn't not really work. I disable the mute of channel Left mix and Right mix in alsamixer, I could hear the noise from my headphone, but it never be a music. I just send this patch here to see whether somebody could figure out what is wrong, I am really not familiar with sound. Randy Li (1): ARM: dts: rockchip: add analog audio support for firefly reload arch/arm/boot/dts/rk3288-firefly-reload.dts | 36 +++++++++++++++++++++++++---- 1 file changed, 31 insertions(+), 5 deletions(-) -- 2.7.4 ^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH] Try to support analog audio codec at firefly reload @ 2016-08-15 20:42 ` Randy Li 0 siblings, 0 replies; 10+ messages in thread From: Randy Li @ 2016-08-15 20:42 UTC (permalink / raw) To: linux-arm-kernel Hello: This patch could enabled the es8328 codec at firefly reload board, but it doesn't not really work. I disable the mute of channel Left mix and Right mix in alsamixer, I could hear the noise from my headphone, but it never be a music. I just send this patch here to see whether somebody could figure out what is wrong, I am really not familiar with sound. Randy Li (1): ARM: dts: rockchip: add analog audio support for firefly reload arch/arm/boot/dts/rk3288-firefly-reload.dts | 36 +++++++++++++++++++++++++---- 1 file changed, 31 insertions(+), 5 deletions(-) -- 2.7.4 ^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH] ARM: dts: rockchip: add analog audio support for firefly reload 2016-08-15 20:42 ` Randy Li @ 2016-08-15 20:42 ` Randy Li -1 siblings, 0 replies; 10+ messages in thread From: Randy Li @ 2016-08-15 20:42 UTC (permalink / raw) To: devicetree Cc: linux-kernel, linux-rockchip, linux-arm-kernel, linux, mark.rutland, heiko, alsa-devel, Randy Li The ES8323 found on firefly reload board is used to output analog audio to headphone and capture the sound from micphone on board and the one may attach to headphone. It would be also used to capture the sound from HDMI IN. Signed-off-by: Randy Li <ayaka@soulik.info> --- arch/arm/boot/dts/rk3288-firefly-reload.dts | 36 +++++++++++++++++++++++++---- 1 file changed, 31 insertions(+), 5 deletions(-) diff --git a/arch/arm/boot/dts/rk3288-firefly-reload.dts b/arch/arm/boot/dts/rk3288-firefly-reload.dts index 0f5a7c1..ae46231 100644 --- a/arch/arm/boot/dts/rk3288-firefly-reload.dts +++ b/arch/arm/boot/dts/rk3288-firefly-reload.dts @@ -200,8 +200,34 @@ sound { compatible = "simple-audio-card"; - simple-audio-card,name = "SPDIF"; - simple-audio-card,dai-link@1 { /* S/PDIF - S/PDIF */ + simple-audio-card,name = "rockchip-audio"; + /*simple-audio-card,hp-det-gpio = <&gpio7 15 GPIO_ACTIVE_HIGH>;*/ + simple-audio-card,widgets = + "Microphone", "Mic Jack", + "Headphone", "Headphone Jack"; + simple-audio-card,routing = + "Headphone Jack", "LOUT2", + "Headphone Jack", "ROUT2", + "LINPUT2", "Mic Jack", + "LINPUT1", "Mic Jack", + "RINPUT1", "Mic Jack"; + + simple-audio-card,dai-link@0 { + format = "i2s"; + bitclock-master = <&link0_codec>; + frame-master = <&link0_codec>; + + cpu { + sound-dai = <&i2s>; + }; + + link0_codec: codec { + sound-dai = <&codec>; + system-clock-frequency = <11289600>; + }; + }; + + simple-audio-card,dai-link@1 { cpu { sound-dai = <&spdif>; }; codec { sound-dai = <&spdif_out>; }; }; @@ -236,14 +262,15 @@ AVDD-supply = <&vcca_33>; PVDD-supply = <&vcca_33>; HPVDD-supply = <&vcca_33>; - clocks = <&cru HCLK_I2S0>, <&cru SCLK_I2S0>; - clock-names = "i2s_hclk", "i2s_clk"; + clocks = <&cru SCLK_I2S0_OUT>; reg = <0x10>; + #sound-dai-cells = <0>; }; }; &i2s { status = "okay"; + #sound-dai-cells = <0>; }; &sdmmc { @@ -256,7 +283,6 @@ pinctrl-names = "default"; pinctrl-0 = <&sdmmc_clk>, <&sdmmc_cmd>, <&sdmmc_cd>, <&sdmmc_bus4>; vmmc-supply = <&vcc_sd>; - vqmmc-supply = <&vcc_sd>; status = "okay"; }; -- 2.7.4 ^ permalink raw reply related [flat|nested] 10+ messages in thread
* [PATCH] ARM: dts: rockchip: add analog audio support for firefly reload @ 2016-08-15 20:42 ` Randy Li 0 siblings, 0 replies; 10+ messages in thread From: Randy Li @ 2016-08-15 20:42 UTC (permalink / raw) To: linux-arm-kernel The ES8323 found on firefly reload board is used to output analog audio to headphone and capture the sound from micphone on board and the one may attach to headphone. It would be also used to capture the sound from HDMI IN. Signed-off-by: Randy Li <ayaka@soulik.info> --- arch/arm/boot/dts/rk3288-firefly-reload.dts | 36 +++++++++++++++++++++++++---- 1 file changed, 31 insertions(+), 5 deletions(-) diff --git a/arch/arm/boot/dts/rk3288-firefly-reload.dts b/arch/arm/boot/dts/rk3288-firefly-reload.dts index 0f5a7c1..ae46231 100644 --- a/arch/arm/boot/dts/rk3288-firefly-reload.dts +++ b/arch/arm/boot/dts/rk3288-firefly-reload.dts @@ -200,8 +200,34 @@ sound { compatible = "simple-audio-card"; - simple-audio-card,name = "SPDIF"; - simple-audio-card,dai-link at 1 { /* S/PDIF - S/PDIF */ + simple-audio-card,name = "rockchip-audio"; + /*simple-audio-card,hp-det-gpio = <&gpio7 15 GPIO_ACTIVE_HIGH>;*/ + simple-audio-card,widgets = + "Microphone", "Mic Jack", + "Headphone", "Headphone Jack"; + simple-audio-card,routing = + "Headphone Jack", "LOUT2", + "Headphone Jack", "ROUT2", + "LINPUT2", "Mic Jack", + "LINPUT1", "Mic Jack", + "RINPUT1", "Mic Jack"; + + simple-audio-card,dai-link at 0 { + format = "i2s"; + bitclock-master = <&link0_codec>; + frame-master = <&link0_codec>; + + cpu { + sound-dai = <&i2s>; + }; + + link0_codec: codec { + sound-dai = <&codec>; + system-clock-frequency = <11289600>; + }; + }; + + simple-audio-card,dai-link at 1 { cpu { sound-dai = <&spdif>; }; codec { sound-dai = <&spdif_out>; }; }; @@ -236,14 +262,15 @@ AVDD-supply = <&vcca_33>; PVDD-supply = <&vcca_33>; HPVDD-supply = <&vcca_33>; - clocks = <&cru HCLK_I2S0>, <&cru SCLK_I2S0>; - clock-names = "i2s_hclk", "i2s_clk"; + clocks = <&cru SCLK_I2S0_OUT>; reg = <0x10>; + #sound-dai-cells = <0>; }; }; &i2s { status = "okay"; + #sound-dai-cells = <0>; }; &sdmmc { @@ -256,7 +283,6 @@ pinctrl-names = "default"; pinctrl-0 = <&sdmmc_clk>, <&sdmmc_cmd>, <&sdmmc_cd>, <&sdmmc_bus4>; vmmc-supply = <&vcc_sd>; - vqmmc-supply = <&vcc_sd>; status = "okay"; }; -- 2.7.4 ^ permalink raw reply related [flat|nested] 10+ messages in thread
[parent not found: <1471293727-26258-1-git-send-email-ayaka-xPW3/0Ywev/iB9QmIjCX8w@public.gmane.org>]
* Re: [PATCH] Try to support analog audio codec at firefly reload 2016-08-15 20:42 ` Randy Li (?) @ 2016-08-19 14:16 ` Heiko Stuebner -1 siblings, 0 replies; 10+ messages in thread From: Heiko Stuebner @ 2016-08-19 14:16 UTC (permalink / raw) To: Randy Li Cc: devicetree-u79uwXL29TY76Z2rM5mHXA, linux-kernel-u79uwXL29TY76Z2rM5mHXA, linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-I+IVW8TIWO2tmTQ+vhA3Yw, mark.rutland-5wv7dgnIgG8, alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw Am Dienstag, 16. August 2016, 04:42:06 CEST schrieb Randy Li: > Hello: > This patch could enabled the es8328 codec at firefly reload board, > but it doesn't not really work. I disable the mute of channel > Left mix and Right mix in alsamixer, I could hear the noise from > my headphone, but it never be a music. > I just send this patch here to see whether somebody could figure > out what is wrong, I am really not familiar with sound. I can't really help here as I have neither the board nor that much sound experience, but it's definitly customary to label patches as rfc when they're expected to need more work, so make that [PATCH RFC] ... for stuff that requires more work before it can actually be merged. Heiko -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Try to support analog audio codec at firefly reload @ 2016-08-19 14:16 ` Heiko Stuebner 0 siblings, 0 replies; 10+ messages in thread From: Heiko Stuebner @ 2016-08-19 14:16 UTC (permalink / raw) To: Randy Li Cc: devicetree, linux-kernel, linux-rockchip, linux-arm-kernel, linux, mark.rutland, alsa-devel Am Dienstag, 16. August 2016, 04:42:06 CEST schrieb Randy Li: > Hello: > This patch could enabled the es8328 codec at firefly reload board, > but it doesn't not really work. I disable the mute of channel > Left mix and Right mix in alsamixer, I could hear the noise from > my headphone, but it never be a music. > I just send this patch here to see whether somebody could figure > out what is wrong, I am really not familiar with sound. I can't really help here as I have neither the board nor that much sound experience, but it's definitly customary to label patches as rfc when they're expected to need more work, so make that [PATCH RFC] ... for stuff that requires more work before it can actually be merged. Heiko ^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH] Try to support analog audio codec at firefly reload @ 2016-08-19 14:16 ` Heiko Stuebner 0 siblings, 0 replies; 10+ messages in thread From: Heiko Stuebner @ 2016-08-19 14:16 UTC (permalink / raw) To: linux-arm-kernel Am Dienstag, 16. August 2016, 04:42:06 CEST schrieb Randy Li: > Hello: > This patch could enabled the es8328 codec at firefly reload board, > but it doesn't not really work. I disable the mute of channel > Left mix and Right mix in alsamixer, I could hear the noise from > my headphone, but it never be a music. > I just send this patch here to see whether somebody could figure > out what is wrong, I am really not familiar with sound. I can't really help here as I have neither the board nor that much sound experience, but it's definitly customary to label patches as rfc when they're expected to need more work, so make that [PATCH RFC] ... for stuff that requires more work before it can actually be merged. Heiko ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Try to support analog audio codec at firefly reload 2016-08-15 20:42 ` Randy Li (?) @ 2016-08-20 18:33 ` John Keeping -1 siblings, 0 replies; 10+ messages in thread From: John Keeping @ 2016-08-20 18:33 UTC (permalink / raw) To: Randy Li Cc: devicetree-u79uwXL29TY76Z2rM5mHXA, mark.rutland-5wv7dgnIgG8, alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw, heiko-4mtYJXux2i+zQB+pC5nmwQ, linux-kernel-u79uwXL29TY76Z2rM5mHXA, linux-I+IVW8TIWO2tmTQ+vhA3Yw, linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r On Tue, Aug 16, 2016 at 04:42:06AM +0800, Randy Li wrote: > This patch could enabled the es8328 codec at firefly reload board, > but it doesn't not really work. I disable the mute of channel > Left mix and Right mix in alsamixer, I could hear the noise from > my headphone, but it never be a music. > I just send this patch here to see whether somebody could figure > out what is wrong, I am really not familiar with sound. Have you tried adding an mclk-fs setting to the simple-audio-card? You probably want to set it to 256, which will allow 44.1kHz, 48kHz, 88.2kHz and 96kHz at the codec. This will give more functionality than pinning the clock to a specific rate. For the Rock2 Square, I write a machine driver for the sound because the headphone GPIO setup cannot be made to work with simple-audio-card; I found the Firefly Reload schematic and it looks like the configuration hardware is very similar. It's a bit of a mess but you can find it on Github [1] if you want to take a look. [1] https://github.com/johnkeeping/linux/tree/topic/audio -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH] Try to support analog audio codec at firefly reload @ 2016-08-20 18:33 ` John Keeping 0 siblings, 0 replies; 10+ messages in thread From: John Keeping @ 2016-08-20 18:33 UTC (permalink / raw) To: Randy Li Cc: devicetree, mark.rutland, alsa-devel, heiko, linux-kernel, linux, linux-rockchip, linux-arm-kernel On Tue, Aug 16, 2016 at 04:42:06AM +0800, Randy Li wrote: > This patch could enabled the es8328 codec at firefly reload board, > but it doesn't not really work. I disable the mute of channel > Left mix and Right mix in alsamixer, I could hear the noise from > my headphone, but it never be a music. > I just send this patch here to see whether somebody could figure > out what is wrong, I am really not familiar with sound. Have you tried adding an mclk-fs setting to the simple-audio-card? You probably want to set it to 256, which will allow 44.1kHz, 48kHz, 88.2kHz and 96kHz at the codec. This will give more functionality than pinning the clock to a specific rate. For the Rock2 Square, I write a machine driver for the sound because the headphone GPIO setup cannot be made to work with simple-audio-card; I found the Firefly Reload schematic and it looks like the configuration hardware is very similar. It's a bit of a mess but you can find it on Github [1] if you want to take a look. [1] https://github.com/johnkeeping/linux/tree/topic/audio ^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH] Try to support analog audio codec at firefly reload @ 2016-08-20 18:33 ` John Keeping 0 siblings, 0 replies; 10+ messages in thread From: John Keeping @ 2016-08-20 18:33 UTC (permalink / raw) To: linux-arm-kernel On Tue, Aug 16, 2016 at 04:42:06AM +0800, Randy Li wrote: > This patch could enabled the es8328 codec at firefly reload board, > but it doesn't not really work. I disable the mute of channel > Left mix and Right mix in alsamixer, I could hear the noise from > my headphone, but it never be a music. > I just send this patch here to see whether somebody could figure > out what is wrong, I am really not familiar with sound. Have you tried adding an mclk-fs setting to the simple-audio-card? You probably want to set it to 256, which will allow 44.1kHz, 48kHz, 88.2kHz and 96kHz at the codec. This will give more functionality than pinning the clock to a specific rate. For the Rock2 Square, I write a machine driver for the sound because the headphone GPIO setup cannot be made to work with simple-audio-card; I found the Firefly Reload schematic and it looks like the configuration hardware is very similar. It's a bit of a mess but you can find it on Github [1] if you want to take a look. [1] https://github.com/johnkeeping/linux/tree/topic/audio ^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2016-08-20 18:33 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-08-15 20:42 [PATCH] Try to support analog audio codec at firefly reload Randy Li
2016-08-15 20:42 ` Randy Li
2016-08-15 20:42 ` [PATCH] ARM: dts: rockchip: add analog audio support for " Randy Li
2016-08-15 20:42 ` Randy Li
[not found] ` <1471293727-26258-1-git-send-email-ayaka-xPW3/0Ywev/iB9QmIjCX8w@public.gmane.org>
2016-08-19 14:16 ` [PATCH] Try to support analog audio codec at " Heiko Stuebner
2016-08-19 14:16 ` Heiko Stuebner
2016-08-19 14:16 ` Heiko Stuebner
2016-08-20 18:33 ` John Keeping
2016-08-20 18:33 ` John Keeping
2016-08-20 18:33 ` John Keeping
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.