mediatek: fix sysupgrade on eMMC boards
[openwrt/openwrt.git] / target / linux / mediatek / patches-4.9 / 00013-soc-mediatek-Add-MT2701-power-dt-bindings.patch
1 From 3e96c653372d8852c45dcd3bd856975157a0fd6a Mon Sep 17 00:00:00 2001
2 From: Shunli Wang <shunli.wang@mediatek.com>
3 Date: Thu, 20 Oct 2016 16:56:37 +0800
4 Subject: [PATCH] soc: mediatek: Add MT2701 power dt-bindings
5
6 Add power dt-bindings for MT2701.
7
8 Signed-off-by: Shunli Wang <shunli.wang@mediatek.com>
9 Signed-off-by: James Liao <jamesjj.liao@mediatek.com>
10 Acked-by: Rob Herring <robh@kernel.org>
11 Reviewed-by: Kevin Hilman <khilman@baylibre.com>
12 Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
13 ---
14 .../devicetree/bindings/soc/mediatek/scpsys.txt | 13 +++++++----
15 include/dt-bindings/power/mt2701-power.h | 27 ++++++++++++++++++++++
16 2 files changed, 35 insertions(+), 5 deletions(-)
17 create mode 100644 include/dt-bindings/power/mt2701-power.h
18
19 Index: linux-4.9.14/Documentation/devicetree/bindings/soc/mediatek/scpsys.txt
20 ===================================================================
21 --- linux-4.9.14.orig/Documentation/devicetree/bindings/soc/mediatek/scpsys.txt
22 +++ linux-4.9.14/Documentation/devicetree/bindings/soc/mediatek/scpsys.txt
23 @@ -9,17 +9,20 @@ domain control.
24
25 The driver implements the Generic PM domain bindings described in
26 power/power_domain.txt. It provides the power domains defined in
27 -include/dt-bindings/power/mt8173-power.h.
28 +include/dt-bindings/power/mt8173-power.h and mt2701-power.h.
29
30 Required properties:
31 -- compatible: Must be "mediatek,mt8173-scpsys"
32 +- compatible: Should be one of:
33 + - "mediatek,mt2701-scpsys"
34 + - "mediatek,mt8173-scpsys"
35 - #power-domain-cells: Must be 1
36 - reg: Address range of the SCPSYS unit
37 - infracfg: must contain a phandle to the infracfg controller
38 - clock, clock-names: clocks according to the common clock binding.
39 - The clocks needed "mm", "mfg", "venc" and "venc_lt".
40 - These are the clocks which hardware needs to be enabled
41 - before enabling certain power domains.
42 + These are clocks which hardware needs to be
43 + enabled before enabling certain power domains.
44 + Required clocks for MT2701: "mm", "mfg", "ethif"
45 + Required clocks for MT8173: "mm", "mfg", "venc", "venc_lt"
46
47 Optional properties:
48 - vdec-supply: Power supply for the vdec power domain
49 Index: linux-4.9.14/include/dt-bindings/power/mt2701-power.h
50 ===================================================================
51 --- /dev/null
52 +++ linux-4.9.14/include/dt-bindings/power/mt2701-power.h
53 @@ -0,0 +1,26 @@
54 +/*
55 + * Copyright (C) 2015 MediaTek Inc.
56 + *
57 + * This program is free software: you can redistribute it and/or modify
58 + * it under the terms of the GNU General Public License version 2 as
59 + * published by the Free Software Foundation.
60 + *
61 + * This program is distributed in the hope that it will be useful,
62 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
63 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
64 + * GNU General Public License for more details.
65 + */
66 +
67 +#ifndef _DT_BINDINGS_POWER_MT2701_POWER_H
68 +#define _DT_BINDINGS_POWER_MT2701_POWER_H
69 +
70 +#define MT2701_POWER_DOMAIN_CONN 0
71 +#define MT2701_POWER_DOMAIN_DISP 1
72 +#define MT2701_POWER_DOMAIN_IFR_MSC 2
73 +#define MT2701_POWER_DOMAIN_VDEC 3
74 +#define MT2701_POWER_DOMAIN_ISP 4
75 +#define MT2701_POWER_DOMAIN_BDP 5
76 +#define MT2701_POWER_DOMAIN_ETH 6
77 +#define MT2701_POWER_DOMAIN_HIF 7
78 +
79 +#endif /* _DT_BINDINGS_POWER_MT2701_POWER_H */