xref: /freebsd/sys/contrib/device-tree/Bindings/sound/rockchip,pdm.txt (revision c66ec88fed842fbaad62c30d510644ceb7bd2d71)
1*c66ec88fSEmmanuel Vadot* Rockchip PDM controller
2*c66ec88fSEmmanuel Vadot
3*c66ec88fSEmmanuel VadotRequired properties:
4*c66ec88fSEmmanuel Vadot
5*c66ec88fSEmmanuel Vadot- compatible: "rockchip,pdm"
6*c66ec88fSEmmanuel Vadot  - "rockchip,px30-pdm"
7*c66ec88fSEmmanuel Vadot  - "rockchip,rk1808-pdm"
8*c66ec88fSEmmanuel Vadot  - "rockchip,rk3308-pdm"
9*c66ec88fSEmmanuel Vadot- reg: physical base address of the controller and length of memory mapped
10*c66ec88fSEmmanuel Vadot  region.
11*c66ec88fSEmmanuel Vadot- dmas: DMA specifiers for rx dma. See the DMA client binding,
12*c66ec88fSEmmanuel Vadot	Documentation/devicetree/bindings/dma/dma.txt
13*c66ec88fSEmmanuel Vadot- dma-names: should include "rx".
14*c66ec88fSEmmanuel Vadot- clocks: a list of phandle + clock-specifer pairs, one for each entry in clock-names.
15*c66ec88fSEmmanuel Vadot- clock-names: should contain following:
16*c66ec88fSEmmanuel Vadot   - "pdm_hclk": clock for PDM BUS
17*c66ec88fSEmmanuel Vadot   - "pdm_clk" : clock for PDM controller
18*c66ec88fSEmmanuel Vadot- resets: a list of phandle + reset-specifer paris, one for each entry in reset-names.
19*c66ec88fSEmmanuel Vadot- reset-names: reset names, should include "pdm-m".
20*c66ec88fSEmmanuel Vadot- pinctrl-names: Must contain a "default" entry.
21*c66ec88fSEmmanuel Vadot- pinctrl-N: One property must exist for each entry in
22*c66ec88fSEmmanuel Vadot	     pinctrl-names. See ../pinctrl/pinctrl-bindings.txt
23*c66ec88fSEmmanuel Vadot	     for details of the property values.
24*c66ec88fSEmmanuel Vadot
25*c66ec88fSEmmanuel VadotExample for rk3328 PDM controller:
26*c66ec88fSEmmanuel Vadot
27*c66ec88fSEmmanuel Vadotpdm: pdm@ff040000 {
28*c66ec88fSEmmanuel Vadot	compatible = "rockchip,pdm";
29*c66ec88fSEmmanuel Vadot	reg = <0x0 0xff040000 0x0 0x1000>;
30*c66ec88fSEmmanuel Vadot	clocks = <&clk_pdm>, <&clk_gates28 0>;
31*c66ec88fSEmmanuel Vadot	clock-names = "pdm_clk", "pdm_hclk";
32*c66ec88fSEmmanuel Vadot	dmas = <&pdma 16>;
33*c66ec88fSEmmanuel Vadot	#dma-cells = <1>;
34*c66ec88fSEmmanuel Vadot	dma-names = "rx";
35*c66ec88fSEmmanuel Vadot	pinctrl-names = "default", "sleep";
36*c66ec88fSEmmanuel Vadot	pinctrl-0 = <&pdmm0_clk
37*c66ec88fSEmmanuel Vadot		     &pdmm0_sdi0
38*c66ec88fSEmmanuel Vadot		     &pdmm0_sdi1
39*c66ec88fSEmmanuel Vadot		     &pdmm0_sdi2
40*c66ec88fSEmmanuel Vadot		     &pdmm0_sdi3>;
41*c66ec88fSEmmanuel Vadot	pinctrl-1 = <&pdmm0_clk_sleep
42*c66ec88fSEmmanuel Vadot		     &pdmm0_sdi0_sleep
43*c66ec88fSEmmanuel Vadot		     &pdmm0_sdi1_sleep
44*c66ec88fSEmmanuel Vadot		     &pdmm0_sdi2_sleep
45*c66ec88fSEmmanuel Vadot		     &pdmm0_sdi3_sleep>;
46*c66ec88fSEmmanuel Vadot};
47