Commit Graph

839785 Commits

Author SHA1 Message Date
Finley Xiao
e46a06270b arm64: dts: rockchip: rk3399: Add specification serial number for cpu
Change-Id: Ie48b09944ae3b294e3c7666bd9aa68706bdd4ba5
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 20:22:04 +08:00
Hu Kejun
e08c5bc9e0 arm64: dts: rockchip: rk3399: add interrupt name for rkisp
Change-Id: If942773bb18b55463cdd2137493f6573ce747893
Signed-off-by: Hu Kejun <william.hu@rock-chips.com>
2019-02-28 20:22:04 +08:00
Weixin Zhou
990796fbed arm64: dts: rockchip: rk3399: add gpio drive strength 10ma
Change-Id: Iff6303af2e87425b0509fd962b9e6b2fca8eb896
Signed-off-by: Weixin Zhou <zwx@rock-chips.com>
2019-02-28 20:22:04 +08:00
Huibin Hong
e759baa233 arm64: dts: rockchip: rk3399 fix uart3 cts and rts pinctl config
Change-Id: I2549e2a2e1913e9d9430087b9fc0009ec28a4c8f
Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
2019-02-28 20:22:04 +08:00
Finley Xiao
b4b084f506 arm64: dts: rockchip: rk3399: Add wide-temperature configure
Change-Id: I5e8cca3de8b671f04d9fdf07f6c566ebb8b7988a
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 20:22:04 +08:00
YouMin Chen
3509ed3d18 arm64: dts: rockchip: rk3399: fix VDD_CENTER to 0.9V
Change-Id: I1226b92fd96be7a86208a9363cc38060115043be
Signed-off-by: YouMin Chen <cym@rock-chips.com>
2019-02-28 20:22:04 +08:00
Finley Xiao
a95306e198 arm64: dts: rockchip: rk3399: add pvtm resets
Change-Id: I1250a5193bd44b164d62d918401e60c7c4d31c59
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 20:22:04 +08:00
Finley Xiao
e181776b90 arm64: dts: rockchip: rk3399: add nvmem-cells property for gpu
Change-Id: If538d1f8085dc686a25563a9eb891b79565a1c8d
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 20:22:04 +08:00
Finley Xiao
5f19e6737b arm64: dts: rockchip: rk3399: add gpu pvtm voltage table
stress test:
1. Antutu, use governor simpleondemand
2. Need for Speed, use governor simpleondemand
3. Glmark2, use userspace, scanning frequency

Change-Id: Ibe27380e582b193d900b0d55da3567ce553c32df
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 20:22:04 +08:00
Finley Xiao
59d87c96d7 arm64: dts: rockchip: rk3399: add cpu pvtm voltage table
stress test:
1. reboot
2. antutu, use governor performance
3. antutu, use governor interactive
4. Thomas-sRoomIII, use governor interactive
5. Thomas-sRoomIII, use governor userspace and sweep frequency

Change-Id: If12d2bd72ce3bba01021314265eba4f83a0072e1
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 20:22:04 +08:00
Finley Xiao
eb2a71ddf7 arm64: dts: rk3399: add leakage nvmem-cells properties for cpu
Change-Id: Id156f2a9a3871747d9379b49d09034238d204670
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 20:22:04 +08:00
Finley Xiao
425399a399 arm64: dts: rockchip: Rename OPP nodes as opp-<opp-hz>
Compiling the DT file with W=1, DTC warns like follows:

Warning (unit_address_vs_reg): Node /opp_table0/opp@1000000000 has a
unit name, but no reg property

Fix this by replacing '@' with '-' as the OPP nodes will never have a
"reg" property.

Change-Id: I5748be7888db149633c3980c3f5e9715cd256a52
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 20:22:04 +08:00
Finley Xiao
654ad2c999 arm64: dts: rk3399: remove 297MHz and add 300MHz for dmc
Only 200MHz, 300MHz, 400MHz, 528MHz, 600MHz, 666MHz, 732MHz and
800MHz are available at present.

Change-Id: I48ed7e6e6f636389fbc239b1cca201f5c5f19d7a
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 20:22:04 +08:00
Finley Xiao
17004d9ad6 arm64: dts: rockchip: rk3399: Rename OPP nodes as opp@<opp-hz>
It would be better to name OPP nodes as opp@<opp-hz> as that will ensure
that multiple DT nodes don't contain the same frequency. Of course we
expect the writer to name the node with its opp-hz frequency and not any
other frequency.

And that will let the compile error out if multiple nodes are using the
same opp-hz frequency.

Change-Id: I8c77646329e39390fb135d4d75d34893a8168876
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 20:22:04 +08:00
Jianqun Xu
696d1ad811 ARM64: dts: rk3399: move opp tables to rk3399-opp.dtsi
Add a new dtsi file - rk3399-opp.dtsi, to configure opp-tables
for cpu, gpu and dmc.

Add rk3399-early-opp.dtsi for board with ES1, which need limit
frequency for cpu, gpu and dmc.

Change-Id: Ib57761fd5f405b0e79039d7a01e6e023d6f5dc2c
Reviewed-by: Finley Xiao <finley.xiao@rock-chips.com>
Reviewed-by: Huang, Tao <huangtao@rock-chips.com>
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2019-02-28 20:22:04 +08:00
Elaine Zhang
80f56a2fa8 clk: rockchip: rk3399: remove the flag ROCKCHIP_PLL_SYNC_RATE for VPLL and CPLL
to slove the display shaking, when uboot logo display to kernel show.

Change-Id: I804aa09f24bc4fa7b6314a7a5487f0ee1a321724
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:49:02 +08:00
Elaine Zhang
168ead39aa clk: rockchip: rk3399: fix up the pr_err for debug
Change-Id: I16eeacaf0307146ebf8db745621ef57e5ab16fec
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:49:02 +08:00
Elaine Zhang
9a0256dba4 clk: rockchip: rk3399: Mark some grf clock as critical
pclk_perihp_grf and pclk_vio_grf is for some grf regs read and write,
mark it as critical and it never turns off.

Change-Id: If9465334b9168b4376a7ac95d5f08e389048409f
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:49:02 +08:00
Elaine Zhang
2d399082b2 clk: rockchip: rk3399: make the cpll as parent just for vop
others clk change it's parent from cpll to dummy_cpll.
the vop's parent just vpll and cpll,
make sure each vop have it's own pll as parent.

Change-Id: Ia61e10918e14a69c053455018ddf0183ff15ea19
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:49:02 +08:00
Finley Xiao
39d35a584c clk: rockchip: rk3399: delete the CLK_IGNORE_UNUSED for pvtm clks
These clks will be enabed and disabled in pvtm driver.

Change-Id: I742a8c4ef5877486fb21c014f1e4ab27f72e468d
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:49:02 +08:00
Elaine Zhang
a976a5c95e clk: rockchip: rk3399: fix up the spi softrst ID
fix up the spi3 and spi5 softrst ID.

Change-Id: Ib8870ef765284e04674ce80acf0b4702ed77cebc
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:49:02 +08:00
Elaine Zhang
e122942c9e clk: rockchip: rk3399: fix up the dclk_vop1_div parents
if the dclk_vop0_div allow CLK_SET_RATE_PARENT for VPLL,
the dclk_vop1_div parent is not allowed in vpll.

Change-Id: I9973014e8ed2fcf1c351e3f62c00040677391ff7
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:49:02 +08:00
Xing Zheng
e04b0bc907 clk: rockchip: rk3399: export 480M_SRC clock id for usbphy0/usbphy1
Change-Id: Icd566864d3651e7b64ee8209b66e8a326011422f
Signed-off-by: Xing Zheng <zhengxing@rock-chips.com>
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:26:59 +08:00
Elaine Zhang
d856a9e4a5 clk: rockchip: rk3399: add pll up and down when change pll freq
set pll sequence:
	->set pll to slow mode or other plls
	->set pll down
	->set pll params
	->set pll up
	->wait pll lock status
	->set pll to normal mode

To slove the system error:
rockchip_rk3399_wait_pll_lock: timeout waiting for pll to lock
rockchip_rk3399_pll_set_params: pll update unsucessful,
				trying to restore old params

Change-Id: I62aecd9f292de5a3c7bcd8a87231785bf115159d
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:26:59 +08:00
Elaine Zhang
11ce3bc6e4 clk: rockchip: rk3399: support pll setting by auto
If setting freq is not support in rockchip_pll_rate_table rk3399_pll_rates[],
It can set pll params by auto.

Change-Id: I5016cece64dca4c2efec18d552ee6be426f6b95a
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:26:59 +08:00
Heiko Stuebner
df80a68487 FROMLIST: clk: rockchip: make rk3399 vop dclks keep their rate on parent rate changes
The rk3399 hdmi phy is supplied by the vpll directly and needs to adapt
that frequency depending on the selected resolution on the hdmi output.
For the hdmi-phy the vpll frequency is supplied unchanged without
any dividers being present there.

The vpll also is one of the sources the general display clock of the
visual output processor (vop) and as it is somewhat special for
display operations possibly also the preferred pll source. Here a divider
is available between the pll-mux and the vop clock, so that this part
can adapt the resulting frequency if needed.

So to keep the vop clock in line with the target rate, set the newly
introduced CLK_KEEP_REQ_RATE flag for the dclk_vop clocks on rk3399.

(am from https://patchwork.kernel.org/patch/8993771/)

Change-Id: Iba9a179b764472f22d7531eb0c662dcd982433d4
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Xing Zheng <zhengxing@rock-chips.com>
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:25:13 +08:00
Heiko Stuebner
12da448610 FROMLIST: clk: adjust clocks to their requested rate after parent changes
Given a hirarchy of clk1 -> [div] -> clk2, when the rate of clk1 gets
changed, clk2 changes as well as the divider stays the same. There may
be cases where a user of clk2 needs it at a specific rate, so clk2
needs to be readjusted for the changed rate of clk1.

So if a rate was requested for the clock, and its rate changed during
the underlying rate-change, with this change the clock framework now
tries to readjust the rate back to/near the requested one.

The whole process is protected by a new clock-flag to not force this
behaviour change onto every clock defined in the ccf.

(am from https://patchwork.kernel.org/patch/8993761/)

Change-Id: Ie2636710cb4e66815ee45b28ec86eeaaa47c55c7
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Xing Zheng <zhengxing@rock-chips.com>
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 17:25:12 +08:00
William Wu
679371c2f0 arm64: dts: rockchip: add usic node for rk3399
Add usic node for rk3399 USB 2.0 EHCI controller
with usic phy.

Change-Id: Ibb4179ff1479816daa3b8455b0229f8a7a05bbdf
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-02-28 15:15:37 +08:00
Hu Kejun
b9a7b77a8e arm64: dts: rockchip: add mipi_dphy_tx1rx1 and modify rkisp1_1 for rk3399
Change-Id: I94d01c6963dc5f2f9b61159df1b13fc0bb32a0f1
Signed-off-by: Hu Kejun <william.hu@rock-chips.com>
2019-02-28 15:03:44 +08:00
CanYang He
4b354f3e22 arm64: dts: rockchip: increase mcu frequency to 97mhz for rk3399
mcu run at 97MHz to reduce lpddr4 scale frequency elapsed time

Change-Id: Ie2805eaf0d902c9531819217d05a86775d85f809
Signed-off-by: CanYang He <hcy@rock-chips.com>
2019-02-28 14:59:57 +08:00
Huicong Xu
ba7abca242 arm64: dts: rockchip: add hdmi hdcp2 node for rk3399
Change-Id: Ie78fbdc226d856a20c2da40e4166e7b23ed27aba
Signed-off-by: Huicong Xu <xhc@rock-chips.com>
2019-02-28 14:58:55 +08:00
Hu Kejun
e3b38bf4a2 arm64: dts: rockchip: Add rkisp1 for rk3399
Change-Id: Ie0eb7088d08f9c0cbd0443b6f9c635ade9b4cc8f
Signed-off-by: Hu Kejun <william.hu@rock-chips.com>
2019-02-28 14:56:28 +08:00
Tao Huang
28632a5e2b arm64: dts: rockchip: fix dtc warnings of rk3399
Change-Id: I31fbab7d90e35ae47bbc6d54aad5e82b8902af7f
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2019-02-28 14:52:46 +08:00
Rocky Hao
0e1ecbe0be ARM64: dts: rk3399: add dmc config for VOP
Change-Id: I1b07ca19c5f6529361630ac49ba8922ba0e32db2
Signed-off-by: Rocky Hao <rocky.hao@rock-chips.com>
2019-02-28 14:49:05 +08:00
Mark Yao
d8a4f839b9 arm64: dts: rockchip: rk3399: add dclk pll sources
Change-Id: I0e29d67d5e3738b18a7407a049d216f8dcebb8e8
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2019-02-28 14:47:15 +08:00
Finley Xiao
92ac4e68b2 arm64: dts: rockchip: rk3399: Add nocp device node
Change-Id: I9ef68b69a263720aea3d51e854375b51027c94a2
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 14:35:46 +08:00
Mark Yao
a4228aa5f4 arm64: dts: rockchip: rk3399: add cabc lut register
Change-Id: Ia4b47301b58141b24e75e35544beb903325e0a19
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
2019-02-28 14:34:17 +08:00
Mark Yao
14112699fb arm: dts: rockchip: add names for vop register
Change-Id: I463cc2dc92f233b5b4b6f91b71cf78af92d4a2c1
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
2019-02-28 14:33:17 +08:00
Mark Yao
83fd1bde66 arm64: dts: rockchip: add gamma table support for rk3399
Rk3399 vopb's gamma table size is 1024, vopl's gamma
table size is 256

Change-Id: Iea9cd70f82dfa9c9c8ae53a24c8153eebb981e7a
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
2019-02-28 14:29:36 +08:00
Shengfei xu
edc38a7122 arm64: dts: rockchip: add rockchip-suspend node for rk3399
Change-Id: I6af1f487f40c0775102d3b9951617c5d03b884ef
Signed-off-by: Shengfei xu <xsf@rock-chips.com>
2019-02-28 14:28:20 +08:00
Huang, Tao
f632877d6f arm64: dts: rockchip: move vpu/rkvdec to rk3399.dtsi
Right now only one driver support vpu and rkvdec,
so move the nodes from rk3399-android[-next].dtsi to rk3399.dtsi.

Change-Id: Id908843774ed8eede3aeddb24059ae92a35e5b98
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2019-02-28 14:26:35 +08:00
Finley Xiao
38ae16b5cb arm64: dts: rk3399: add a opp-suspend property for cpu opp table
The opp who contains a opp-suspend property will be configured
during suspend or reboot.

Change-Id: I6b2eede43216435f568db6959127a6e84c8cd4c8
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 14:20:26 +08:00
Finley Xiao
4cd5da2e76 arm64: dts: rockchip: add pvtm node for rk3399
Change-Id: Ic7becefeb7e7a1000b259c21fedda76794b7115c
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 14:18:21 +08:00
Elaine Zhang
d98b328e44 arm64: dts: rockchip: rk3399: add aclk_gpu init freq
Make sure the aclk_gpu freq is safety.
After soft reset the vdd_gpu is maintain
the voltage value before reset.

Change-Id: I3509b211d74cf649067090d13ce20d5c62782fd7
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-02-28 14:07:26 +08:00
tony.xie
8ea4689838 ARM64: dts: rk3399: support cluster idle feature
Add cluster sleep in cpu idle_states for RK3399 SoCs.

Change-Id: I85ea62f9af0d0c61e866a1937f79921d854fd1dc
Signed-off-by: tony.xie <tony.xie@rock-chips.com>
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2019-02-28 11:27:51 +08:00
Finley Xiao
28e5496a4b arm64: dts: rockchip: add cpu-avs node for rk3399
Change-Id: Ibfcda65b6b97af453942888cf07e8f08b06768c2
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2019-02-28 11:26:22 +08:00
Elaine Zhang
8df130821e arm64: dts: rockchip: rk3399: fix pd_sd as sub domain of pd_perihp
Change-Id: I62e53b85444f0f4bbb1d2e786a23ff1f91c89000
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2019-02-28 11:25:59 +08:00
Elaine Zhang
6919158470 arm64: dts: rockchip: add some pd nodes for rk3399 power domain
add emmc\gmac\usb3\sd\sdioaudio\perihp pd nodes

Change-Id: Ie5f65c19ebd87ef9ca25846674e17cb2018cfbf7
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2019-02-28 11:23:09 +08:00
Lin Huang
2a2741c761 ARM64: dts: rk3399: add dmc and dfi node
To support ddr frequency scaling function, we need
enable dmc and dfi node.

Change-Id: I84ea6bff679365d86937ff10bcdf466ea31901fb
Signed-off-by: Lin Huang <hl@rock-chips.com>
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2019-02-28 11:12:08 +08:00
Wenping Zhang
74f449378d arm64: dts: rockchip: add dp 4 lanes + usb2.0 function for rk3399
Change-Id: Ia45dd31ebfe2c0c038a6102920eefb50fd512f36
Signed-off-by: Wenping Zhang <wenping.zhang@rock-chips.com>
2019-02-28 11:10:59 +08:00