msm-vidc.txt 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. * Qualcomm MSM VIDC
  2. Required properties:
  3. - compatible : one of:
  4. - "qcom,msm-vidc"
  5. - qcom,hfi : supported Host-Firmware Interface, one of:
  6. - "venus"
  7. - "q6"
  8. - qcom,max-hw-load: The maximum load the hardware can support expressed in units
  9. of macroblocks per second.
  10. Optional properties:
  11. - reg : offset and length of the register set for the device.
  12. - interrupts : should contain the vidc interrupt.
  13. - vdd-supply : regulator to supply venus.
  14. - qcom,vidc-cp-map : start and size of device virtual address range for
  15. secure buffers. Video hardware uses this address range to identify if
  16. the buffers are secure or non-secure.
  17. - qcom,vidc-ns-map : start and size of device virtual address range for
  18. non-secure buffers. Video hardware uses this address range to identify
  19. if the buffers are secure or non-secure.
  20. - qcom,load-freq-tbl : load (in macroblocks/sec) and corresponding vcodec
  21. clock required for optimal performance in descending order.
  22. - qcom,reg-presets : list of offset-value pairs for registers to be written.
  23. The offsets are from the base offset specified in 'reg'. This is mainly
  24. used for QoS, vbif, etc. presets for video.
  25. - qcom,bus-ports : number of bus ports supported by venus to access
  26. ddr/ocmem.
  27. - qcom,enc-ocmem-ab-ib : list of bus vectors (ab, ib pair) for ocmem
  28. bandwidth request by different video encoder usecases.
  29. - qcom,dec-ocmem-ab-ib : list of bus vectors(ab, ib pair) for ocmem
  30. bandwidth request by different video decoder usecases.
  31. - qcom,enc-ddr-ab-ib : list of bus vectors(ab,ib pair) for ddr bandwidth
  32. request by different video encoder usecases.
  33. - qcom,dec-ddr-ab-ib : list of bus vectors(ab, ib pair) for ddr bandwidth
  34. request by different video decoder usecases.
  35. - qcom,buffer-type-tz-usage-table : a key-value pair, mapping a buffer type
  36. (enum hal_buffer) to its corresponding TZ usage. The TZ usages are defined
  37. as "enum cp_mem_usage" in include/linux/msm_ion.h
  38. - qcom,has-ocmem: indicate the target has ocmem if this property exists
  39. - qcom,vidc-iommu-domains: node containing individual domain nodes, each with:
  40. - a unique domain name for the domain node (e.g vidc,domain-ns)
  41. - qcom,vidc-domain-phandle: phandle for the domain as defined in
  42. <target>-iommu-domains.dtsi (e.g msm8974-v1-iommu-domains.dtsi)
  43. - qcom,vidc-partition-buffer-types: bitmap of buffer types that can
  44. be mapped into each IOMMU domain partition. There must be exactly
  45. one buffer bitmap per partition in the domain, with order of the
  46. bitmaps to be the same as the order of the respective partitions.
  47. - Buffer types are defined as the following:
  48. input = 0x1
  49. output = 0x2
  50. output2 = 0x4
  51. extradata input = 0x8
  52. extradata output = 0x10
  53. extradata output2 = 0x20
  54. internal scratch = 0x40
  55. internal scratch1 = 0x80
  56. internal scratch2 = 0x100
  57. internal persist = 0x200
  58. internal persist1 = 0x400
  59. internal cmd queue = 0x800
  60. Example:
  61. qcom,vidc@fdc00000 {
  62. compatible = "qcom,msm-vidc";
  63. reg = <0xfdc00000 0xff000>;
  64. interrupts = <0 44 0>;
  65. vdd-supply = <&gdsc_venus>;
  66. qcom,vidc-cp-map = <0x1000000 0x40000000>;
  67. qcom,vidc-ns-map = <0x40000000 0x40000000>;
  68. qcom,load-freq-tbl = <979200 410000000>,
  69. <560145 266670000>,
  70. <421161 200000000>,
  71. <243000 133330000>,
  72. <108000 100000000>,
  73. <36000 50000000>;
  74. qcom,has-ocmem;
  75. qcom,hfi = "venus";
  76. qcom,reg-presets = <0x80004 0x1>,
  77. <0x80178 0x00001FFF>;
  78. qcom,bus-ports = <1>;
  79. qcom,enc-ocmem-ab-ib = <0 0>,
  80. <138200 1222000>;
  81. qcom,dec-ocmem-ab-ib = <0 0>,
  82. <176900 1556640>;
  83. qcom,enc-ddr-ab-ib = <0 0>,
  84. <60000 664950>;
  85. qcom,dec-ddr-ab-ib = <0 0>,
  86. <110000 909000>;
  87. qcom,buffer-type-tz-usage-table = <0x1 0x1>,
  88. <0x1fe 0x2>;
  89. qcom,max-hw-load = <1224450>; /* 4k @ 30 + 1080p @ 30*/
  90. qcom,vidc-iommu-domains {
  91. qcom,domain-ns {
  92. qcom,vidc-domain-phandle = <&venus_domain_ns>;
  93. qcom,vidc-partition-buffer-types = <0x7ff>,
  94. <0x800>;
  95. };
  96. qcom,domain-cp {
  97. qcom,vidc-domain-phandle = <&venus_domain_cp>;
  98. qcom,vidc-partition-buffer-types = <0x6>,
  99. <0x7c1>;
  100. };
  101. };
  102. };