Nokia X2 sound

Материал из Toshiba AC100 wiki
Перейти к навигации Перейти к поиску

Patches

  1. Nokia specific changes to sound/soc/msm folder https://github.com/cm-nokia-x2/android_kernel_nokia_msm8610/commit/843a557336ed0942aeecef7d73778861929c6601
  2. Nokia specific changes to default msm8610 files in arch/arm/boot/dts folder https://github.com/cm-nokia-x2/android_kernel_nokia_msm8610/commit/b2fdfce5c5e1adf9f2ff8d107f36b952651aff64
  3. Nokia clock/gpio patch https://github.com/cm-nokia-x2/android_kernel_nokia_msm8610/commit/3070d917e6a0bfb67ccb33d09784710731acce02

Diff

  1. Diff stat of sound/soc/msm between kernel kk vs stock
git diff --stat cm-11.0-wip-bisect origin/jellybean-wip sound/soc/msm/ 
 sound/soc/msm/apq8074.c                         |    7 +-
 sound/soc/msm/msm-dai-fe.c                      |   40 +-
 sound/soc/msm/msm8226.c                         |  153 +-------
 sound/soc/msm/msm8974.c                         |   86 +---
 sound/soc/msm/msm8x10.c                         |  274 ++++++++++---
 sound/soc/msm/qdsp6v2/Makefile                  |    8 +-
 sound/soc/msm/qdsp6v2/audio_acdb.c              |   53 ++-
 sound/soc/msm/qdsp6v2/audio_acdb.h              |    1 +
 sound/soc/msm/qdsp6v2/audio_ocmem.c             |    6 +-
 sound/soc/msm/qdsp6v2/msm-audio-effects-q6-v2.c |  721 ----------------------------------
 sound/soc/msm/qdsp6v2/msm-audio-effects-q6-v2.h |   33 --
 sound/soc/msm/qdsp6v2/msm-compr-q6-v2.c         |  163 +++++---
 sound/soc/msm/qdsp6v2/msm-compress-q6-v2.c      | 2097 -------------------------------------------------------------------------------------------------
 sound/soc/msm/qdsp6v2/msm-dai-q6-hdmi-v2.c      |   13 -
 sound/soc/msm/qdsp6v2/msm-dai-q6-v2.c           |   42 +-
 sound/soc/msm/qdsp6v2/msm-dolby-dap-config.c    |   11 +-
 sound/soc/msm/qdsp6v2/msm-dolby-dap-config.h    |    2 +-
 sound/soc/msm/qdsp6v2/msm-pcm-afe-v2.c          |    4 +-
 sound/soc/msm/qdsp6v2/msm-pcm-loopback-v2.c     |  445 ---------------------
 sound/soc/msm/qdsp6v2/msm-pcm-q6-v2.c           |  177 ++-------
 sound/soc/msm/qdsp6v2/msm-pcm-routing-v2.c      |  218 +++-------
 sound/soc/msm/qdsp6v2/msm-pcm-routing-v2.h      |   17 +-
 sound/soc/msm/qdsp6v2/msm-pcm-voip-v2.c         |   83 ++--
 sound/soc/msm/qdsp6v2/q6adm.c                   |   26 +-
 sound/soc/msm/qdsp6v2/q6afe.c                   |  109 ++++-
 sound/soc/msm/qdsp6v2/q6asm.c                   |  891 ++++++++---------------------------------
 sound/soc/msm/qdsp6v2/q6audio-v2.c              |    6 +
 sound/soc/msm/qdsp6v2/q6voice.c                 |   29 +-
 sound/soc/msm/qdsp6v2/rtac.c                    |  180 +--------
 29 files changed, 813 insertions(+), 5082 deletions(-)

Dts

  1. Nokia dts tree
msm8610-ara.dts
 /include/ "msm8610-v2.dtsi"
           /include/ "msm8610.dtsi"
                      /include/ "msm8610-camera.dtsi"
                      /include/ "msm-iommu-v0.dtsi"
                      /include/ "msm8610-ion.dtsi"
                      /include/ "msm8610-gpu.dtsi"
                      /include/ "msm-gdsc.dtsi"
                      /include/ "msm8610-coresight.dtsi"
                      /include/ "msm8610-smp2p.dtsi"
                      /include/ "msm8610-bus.dtsi"
                      /include/ "msm8610-mdss.dtsi"
                      /include/ "msm-rdbg.dtsi"
           /include/ "msm8610-v2-pm.dtsi"
 /include/ "msm8610-ara.dtsi"
 /include/ "msm8610-camera-sensor-ara.dtsi"
 /include/ "c4_touch.dtsi"
 /include/ "sms_dtv.dtsi"
  1. Sound stuff in dts
    1. msm8610-ara.dtsi
sound {
        qcom,audio-routing =
            "RX_BIAS", "MCLK",
            "INT_LDO_H", "MCLK",
            "MIC BIAS External", "Handset Mic",
            "MIC BIAS External", "Headset Mic",
            "MIC BIAS External", "Secondary Mic",
            "AMIC1", "MIC BIAS External",
            "AMIC2", "MIC BIAS External",
            "AMIC3", "MIC BIAS External";
    };
&i2c_cdc  {
        msm8x10_wcd_codec@0d{
                compatible = "qcom,msm8x10-wcd-i2c";
                reg = <0x0d>;

                interrupt-parent = <&wcd9xxx_intc>;
                interrupts = <0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
                              17 18 19 20 21 22 23>;

                cdc-vdda-cp-supply = <&pm8110_s4>;
                qcom,cdc-vdda-cp-voltage = <1800000 2150000>;
                qcom,cdc-vdda-cp-current = <650000>;

                cdc-vdda-h-supply = <&pm8110_l6>;
                qcom,cdc-vdda-h-voltage = <1800000 1800000>;
                qcom,cdc-vdda-h-current = <25000>;

                cdc-vdd-px-supply = <&pm8110_l6>;
                qcom,cdc-vdd-px-voltage = <1800000 1800000>;
                qcom,cdc-vdd-px-current = <10000>;

                cdc-vdd-1p2v-supply = <&pm8110_l4>;
                qcom,cdc-vdd-1p2v-voltage = <1200000 1200000>;
                qcom,cdc-vdd-1p2v-current = <5000>;

                cdc-vdd-mic-bias-supply = <&pm8110_l20>;
                qcom,cdc-vdd-mic-bias-voltage = <3075000 3075000>;
                qcom,cdc-vdd-mic-bias-current = <25000>;

                qcom,cdc-micbias-ldoh-v = <0x3>;
                qcom,cdc-micbias-cfilt-sel = <0x0>;
                qcom,cdc-micbias-cfilt-mv = <2700>;
                qcom,cdc-mclk-clk-rate = <12288000>;

                qcom,cdc-static-supplies = "cdc-vdda-h",
                                           "cdc-vdd-px",
                                           "cdc-vdd-1p2v";

                qcom,cdc-on-demand-supplies = "cdc-vdda-cp",
                                              "cdc-vdd-mic-bias";
        };
        msm8x10_wcd_codec@77{
                compatible = "qcom,msm8x10-wcd-i2c";
                reg = <0x77>;
        };

        msm8x10_wcd_codec@66{
                compatible = "qcom,msm8x10-wcd-i2c";
                reg = <0x66>;
        };

        msm8x10_wcd_codec@55{
                compatible = "qcom,msm8x10-wcd-i2c";
                reg = <0x55>;
        };
};
    1. msm8610.dtsi
sound {
                compatible = "qcom,msm8x10-audio-codec";
                qcom,model = "msm8x10-snd-card";
                qcom,vibrator-amp-gpio = <&msmgpio 101 0x0>;
        };

        qti,msm-pcm {
                compatible = "qti,msm-pcm-dsp";
                qti,msm-pcm-dsp-id = <0>;
        };

        qti,msm-pcm-low-latency {
                compatible = "qti,msm-pcm-dsp";
                qti,msm-pcm-dsp-id = <1>;
                qti,msm-pcm-low-latency;
                qti,latency-level = "ultra";
        };

        qcom,msm-pcm-routing {
                compatible = "qcom,msm-pcm-routing";
        };

        qcom,msm-pcm-lpa {
                compatible = "qcom,msm-pcm-lpa";
        };

        qcom,msm-compr-dsp {
                compatible = "qcom,msm-compr-dsp";
        };

        qcom,msm-compress-dsp {
                compatible = "qcom,msm-compress-dsp";
        };

        qcom,msm-voip-dsp {
                compatible = "qcom,msm-voip-dsp";
        };

        qcom,msm-pcm-voice {
                compatible = "qcom,msm-pcm-voice";
        };

        qcom,msm-stub-codec {
                compatible = "qcom,msm-stub-codec";
        };

        qcom,msm-dai-fe {
                compatible = "qcom,msm-dai-fe";
        };

        qcom,msm-pcm-afe {
                compatible = "qcom,msm-pcm-afe";
        };

        qcom,msm-dai-mi2s {
                compatible = "qcom,msm-dai-mi2s";
                qcom,msm-dai-q6-mi2s-prim {
                        compatible = "qcom,msm-dai-q6-mi2s";
                        qcom,msm-dai-q6-mi2s-dev-id = <0>;
                        qcom,msm-mi2s-rx-lines = <0>;
                        qcom,msm-mi2s-tx-lines = <3>;
                };

                qcom,msm-dai-q6-mi2s-sec {
                        compatible = "qcom,msm-dai-q6-mi2s";
                        qcom,msm-dai-q6-mi2s-dev-id = <1>;
                        qcom,msm-mi2s-rx-lines = <3>;
                        qcom,msm-mi2s-tx-lines = <0>;
                };
        };
        qcom,msm-dai-q6 {
                compatible = "qcom,msm-dai-q6";
                qcom,msm-dai-q6-bt-sco-rx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <12288>;
                };

                qcom,msm-dai-q6-bt-sco-tx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <12289>;
                };

                qcom,msm-dai-q6-int-fm-rx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <12292>;
                };

                qcom,msm-dai-q6-int-fm-tx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <12293>;
                };

                qcom,msm-dai-q6-be-afe-pcm-rx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <224>;
                };

                qcom,msm-dai-q6-be-afe-pcm-tx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <225>;
                };

                qcom,msm-dai-q6-afe-proxy-rx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <241>;
                };

                qcom,msm-dai-q6-afe-proxy-tx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <240>;
                };

                qcom,msm-dai-q6-incall-record-rx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <32771>;
                };
                
                qcom,msm-dai-q6-incall-record-tx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <32772>;
                };

                qcom,msm-dai-q6-incall-music-rx {
                        compatible = "qcom,msm-dai-q6-dev";
                        qcom,msm-dai-q6-dev-id = <32773>;
                };
        };

        qcom,msm-pcm-hostless {
                compatible = "qcom,msm-pcm-hostless";
        };

Sound initcall