Commit Graph

600294 Commits

Author SHA1 Message Date
Jianqun Xu
94ea732c72 arm64: dts: rockchip: rk3368 enable pmu node
Change-Id: I031fb437a84b19bb7cc389acb2404777f732cf6c
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2017-03-17 10:49:26 +08:00
Elaine Zhang
81ea6550cc arm64: dts: rockchip: rk3368: add qos node
when pd power on/off, the qos regs need to save and restore.

Change-Id: I34146660e75609517463d679271386b536401b20
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2017-03-17 10:48:49 +08:00
chenjh
30a9b9fd67 firmware: rockchip: fix AARCH32 compile warning
Change-Id: I31924c9a1180d7fe034233c7ebd90413a7fa0fc3
Signed-off-by: chenjh <chenjh@rock-chips.com>
2017-03-16 16:43:52 +08:00
Jianqun Xu
4fa5180387 arm64: dts: rk3368: set higher voltage for gpu dvfs
As GPU share voltage domain with DDR and the minimum voltage of DDR
696MHz is 1100mV, GPU's voltage must be equal or greater than 1100mV.

After add ddr frequency scaling support, we can change them again.

Change-Id: I761931675265aac75425bf1cc9c7280a33f91e16
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2017-03-16 14:30:34 +08:00
Bin Yang
c374936464 drm/bridge: dw_hdmi: clear ih_mute register when system resume
HDMI PD is power off when system suspend, so ih_mute register
bit0 mute_all_interrupt will be reset to 1 when system resume.
HPD interrupt will be mask, that would cause hdmi plugin could
not be detected.

Change-Id: I3bf2e6116e902cd516a7ac69fbe8569ca943e853
Signed-off-by: Bin Yang <yangbin@rock-chips.com>
2017-03-16 14:26:48 +08:00
Finley Xiao
f030ff821d arm64: dts: rockchip: modify cpu's opp table for rk3368
Change-Id: I2f7f15f9b3a9e6190e5e8895e9e4fe939d284b43
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2017-03-16 11:33:00 +08:00
Jianqun Xu
4f9bae4246 FROMLIST: arm64: dts: rockchip: rk3368 swap clust0 and clust1
Before this patch, clust1 has little core0~3, clust0 has big core0~3
cpu_l | cpu0 |
cpu_l | cpu1 | clust1
cpu_l | cpu2 |
cpu_l | cpu3 |
----------------------
cpu_b | cpu4 |
cpu_b | cpu5 | clust0
cpu_b | cpu6 |
cpu_b | cpu7 |

With this patch, clust0 will have little core0~3, clust1 will have big core0~3
cpu_l | cpu0 |
cpu_l | cpu1 | clust0
cpu_l | cpu2 |
cpu_l | cpu3 |
----------------------
cpu_b | cpu4 |
cpu_b | cpu5 | clust1
cpu_b | cpu6 |
cpu_b | cpu7 |

It makes no other change, just keep same with other SoCs definations.

Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
(am from https://patchwork.kernel.org/patch/9625109/)

Change-Id: I1beea4d3e75409d3a1f1614b0b86f1a929db4eee
2017-03-16 11:32:49 +08:00
Shawn Lin
03150c2ba8 arm64: dts: rockchip: add linux,pci-domain for PCIe
We need this to ask PCIe bus allocater to always
assign 0 to our root bus isntead of increasing it
, otherwise the hierarchy would be wrong if we unbind
and bind the root port.

Change-Id: I4ada61c89e617c7bccd92c5f9fa3334cae40603e
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
2017-03-16 11:30:35 +08:00
Sinan Kaya
3694d7d0d0 UPSTREAM: PCI: Add pci_unmap_iospace() to unmap I/O resources
Add pci_unmap_iospace() to undo what pci_remap_iospace() did.

This is needed to support hotplug removal of host bridges that use
pci_remap_iospace().

Change-Id: Iee5d778cb8ddfedab59c55c227a8c60825786854
[bhelgaas: changelog]
Signed-off-by: Sinan Kaya <okaya@codeaurora.org>
Signed-off-by: Tomasz Nowicki <tn@semihalf.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Acked-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
(cherry picked from 4d3f138459)
Conflicts:
	drivers/pci/pci.c
2017-03-16 11:25:48 +08:00
Shawn Lin
946c054110 UPSTREAM: PCI: rockchip: Fix rockchip_pcie_probe() error path to free resource list
rockchip_pcie_probe() calls of_pci_get_host_bridge_resources() to parse
resources from DT and build a resource list.  The caller is responsible for
disposing of the resource list.  This is normally done by
pci_release_host_bridge_dev() when the host bridge is removed.

If the host bridge probe fails, dispose of the resource list in the probe
error path.

Change-Id: Iefc17963a6ce99c64f2940d8dc2ba93bd00fe120
[bhelgaas: changelog]
Suggested-by: Bjorn Helgaas <bhelgaas@google.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
(cherry picked from f1d722b607)
2017-03-16 11:25:30 +08:00
Shawn Lin
ced6f050d4 PCI: rockchip: remove the warning log of 32bit-access only
That prevents me from doing git-am or git-cp patches from
linux-pci, but it was removed by a patch involving some other
platforms as well as a pci-core change, so I won't touch anything
else but pcie-rockchip.

Change-Id: I4268204b4c1d173a385bed8d1b6f7305bef0b5eb
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
2017-03-16 11:25:14 +08:00
Shawn Lin
21f50b58fb PCI: rockchip: remove redundant platform data assignment
We add it twice, so remove one.

Change-Id: I103ee8ffcc15569d65e9455a5465ac4b7dc5112d
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
2017-03-16 11:25:00 +08:00
Shawn Lin
cda08393f8 PCI: rockchip: add new dev variable to indent the log
Change-Id: Idc3bf972c7ab47187b115fb1d2efe7847ee82796
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
2017-03-16 11:24:53 +08:00
Elaine Zhang
a4d5799749 clk: rockchip: rk3368: export SCLK_TIMERXX id for timers
Change-Id: I77fa21f29e7ff46e1bd4150845dfafe0a83b84c1
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2017-03-16 08:50:17 +08:00
ZhuangXiaoLiang
ee26241747 ARM64: dts: rk3368: Update gpu opp table.
Change-Id: Id155a49d96e7533cb8c7f930c63528f452836b0e
Signed-off-by: ZhuangXiaoLiang <zhuangxl@rock-chips.com>
2017-03-16 08:43:48 +08:00
Frank Wang
8718e585e3 arm64: dts: rockchip: enable ehci/ohci and u2phy for rk3368-sheep
This adds enable ehci/ohci and u2phy configuration for rk3368-sheep.

Change-Id: Icafd7d0606ea199bdd8eac902b40459694b7f5a4
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2017-03-16 08:35:21 +08:00
Frank Wang
064752be44 arm64: dts: rockchip: add vcc-host regulator for rk3368-sheep
This adds abstract vbus-host as a vcc-host regulator on rk3368-sheep.

Change-Id: I64deb38a3333346c47a5e2f499cec8d538d18baa
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2017-03-16 08:35:05 +08:00
Frank Wang
2005ce5dc1 arm64: dts: rockchip: add ehci/ochi and u2phy nodes for rk3368
This adds configure ehci/ohci and u2phy nodes for rk3368 SoC.

Change-Id: I80cc311d7c14abc56084118baccf87501d44263e
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2017-03-16 08:34:03 +08:00
Frank Wang
53d9df84d4 phy: rockchip-inno-usb2: add support for rk3368 SoC
This adds support host-port on rk3368 SoC and amend phy Documentation.

Change-Id: I49a2efe37aad8b34505e4dac08336dc4231f4669
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2017-03-16 08:33:35 +08:00
Frank Wang
6f32ea684e phy: rockchip-inno-usb2: amend sm work to support legacy SoC
This adds amend logic of sm work to compatibly support some legacy SoCs,
because _host_utmi_linestate_ and _host_utmi_hostdisconnect_ GRF status
bits which are required for host sm work were not introduced in these
SoCs.

Change-Id: Ib4f499f592618930ac5016a63b7a530674aa6005
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2017-03-16 08:33:27 +08:00
Finley Xiao
af6f2d70c0 clk: rockchip: rk3368: add 216M and 126M for armclkb and armclkl
support 216M/126M for armclkb and armclkl

Change-Id: I047ac24ad5a176923a55bd6934f06afcf272660d
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2017-03-15 18:49:09 +08:00
Mark Yao
20201aebf8 ARM64: dts: rk3368: add vop display node
Change-Id: Ie747e90413fbfabe95e9d3c2ae55e02eff2e4708
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
2017-03-15 18:34:58 +08:00
William Wu
7cc91d50e9 phy: rockchip-inno-usb2: don't power on otg phy in ls irq handler
The commit c590056b6a ("phy: rockchip-inno-usb2: usb remote
wakeup support") power on otg phy in linestate irq handler,
this will cause usb peripheral fail to connect to PC in the
following case:
1. enable otg linestate irq
2. set system enter deep sleep
3. wakeup system by power key
4. connect usb peripheral to PC, pull up D+ to ~3V, trigger
   linestate irq and power on otg phy.
5. usb peripheral do BC1.2 detect, but PC try to enumerate
   the usb peripheral at the same time and fail at last.

Actually the usb controller drivers (e.g. dwc3 driver)
and otg_sm_work can manage the otg phy power consumption, so
it doesn't need to power on otg phy in linestate irq handler.

Change-Id: Ifd78e4d44ab96f07f75f063ed20af153b4027028
Signed-off-by: William Wu <wulf@rock-chips.com>
2017-03-15 17:38:47 +08:00
Elaine Zhang
edd7917229 arm64: dts: rockchip: rk3368-p9: add ramp-delay for syr82x dcdc
Change-Id: I0a1cca68d6e40a881e153f824ccbeb611d006ff0
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2017-03-15 16:51:10 +08:00
William Wu
d3e500796d usb: dwc_otg_310: pcd: fix isoc in ep transfer issue
When test usb gadget uvc function, we find a isoc in
ep transfer bug that will cause uvc data transfer fail.
The error case is:

1. The current EP request is done, call complete_ep()
to completes the request, and then call start_next_request()
to check the EP request queue, in this error case, the
queue is empty, so it doesn't start next request, just
set ep frame_num to 0xFFFFFFFF.

2. NAK Interrutp is triggered, check isoc ep frame_num
is 0xFFFFFFFF, then reset the frame_num to 0, and then
call start_next_request() to check the EP request queue,
in this error case, the queue is still empty, so set ep
frame_num to 0xFFFFFFFF again.

But afer the above operation, the current code will
modify the ep frame_num in NAK Interrutp handler by
add ep bInterval to frame_num, this cause frame_num
change again, but not keep in 0xFFFFFFFF, so the next
NAK Interrutp handler doesn't start next request any
more.

This patch reset the frame_num to the current frame
number got from DSTS SOFFN register if detect the
frame_num is 0xFFFFFFFF in NAK Interrutp handler.
And modify the frame_num in NAK Interrutp handler
only when the frame_num is not 0xFFFFFFFF.

TEST=Set usb gadget as webcam, use Ubuntu Guvcview
to preview the webcam, observe the preview screen
and the error log "There are no more ISOC requests".

Change-Id: I4403a67b1d5d257d092a2a71d5666c5d6fd5af3c
Signed-off-by: William Wu <wulf@rock-chips.com>
2017-03-15 11:07:52 +08:00
Jianqun Xu
51a9f0660f clk: rockchip: rk3368 add 1296000 support to freq table
Change-Id: I6cff0d8820401c36c98f54a9777629dc1d37fba8
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2017-03-15 10:56:07 +08:00
chenzhen
30e2eaaf4b Revert "Revert "MALI: midgard: support sharing regulator with other devices""
This reverts commit eb6c2ed720.

Change-Id: I09424d08bfac3457da24b10fe2b97d2856399e63
Signed-off-by: chenzhen <chenzhen@rock-chips.com>
2017-03-15 09:45:49 +08:00
chenzhen
6b022755ac Revert "Revert "MALI: midgard: avoid GPU voltage domain keeping the initial voltage""
This reverts commit e7db50b512.

Change-Id: I47f9c1d114b06264d6dd4098bc0e00228fd8f187
Signed-off-by: chenzhen <chenzhen@rock-chips.com>
2017-03-15 09:45:49 +08:00
chenzhen
422afe6b4a MALI: midgard: RK: add wake_lock for delayed_work_to_power_off_gpu
To ensure that the work is executed before system being suspended.

Change-Id: Iec1bd114dfff53e2464540f09ced66cf6be81d1a
Signed-off-by: chenzhen <chenzhen@rock-chips.com>
2017-03-15 09:45:49 +08:00
xiaoyao
2e9cf4d2e5 net: wireless: rockchip: fix compile error for rtl8822be
Fixes: 4d99f97 ("net: wireless: rockchip: add rtl8822be ...")
Change-Id: I40234ce807ef9289f422e762e2c94e163fe1824d
Signed-off-by: xiaoyao <xiaoyao@rock-chips.com>
2017-03-15 08:53:13 +08:00
Zorro Liu
4797250413 ARM64: dts: rk3368: add rk3368-p9.dts for p9 board
Change-Id: Id7e718b4f670aa91768db695e5c38da88f048987
Signed-off-by: Zorro Liu <lyx@rock-chips.com>
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2017-03-15 08:18:37 +08:00
Jianqun Xu
3d1d70f6ba ARM64: dts: rk3368-android enable usb otg
Change-Id: Idd9e683c1c48dad940779dbb701dd4271ca8292f
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2017-03-15 08:12:13 +08:00
Huang, Tao
8894bbbfb2 net: wireless: rockchip: disable build rtl8822be pcie wifi by default
Until fix this compile error:
ERROR: "Array_MP_8822B_FW_NIC" [drivers/net/wireless/rockchip_wlan/rtl8822be/8822be.ko] undefined!

Change-Id: I78afda57761bb0bd7737864e5d04deeaa1b7df8a
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2017-03-14 16:48:02 +08:00
Jianqun Xu
b59dbc2886 ARM64: dts: rk3368: add rk3368-sheep.dts for sheep board
rework for rk3368-tb.dtsi and rk3368-tb-sheep.dts, intergrate them
to rk3368-sheep.dts

Change-Id: Ieb9198be7c80a5c8c31b0a1990bac22079548eea
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2017-03-14 16:06:12 +08:00
Simon
53f846a05f ARM64: dts: rk3368: Add iommu node for ISP/HEVC/VOP/VPU
Change-Id: I8193fa6f4cf186c2122b56d652f076024f517fb7
Signed-off-by: Simon <xxm@rock-chips.com>
2017-03-14 14:38:07 +08:00
Finley Xiao
3ff7f2b035 arm64: dts: rockchip: add cpu-avs device node for rk3368
Add cpu-avs node in the device tree for the ARM64 rk3368 SoC.

Change-Id: Ie7eee09c20b06bd755b9277e0acd8eaf810c5331
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2017-03-14 10:28:27 +08:00
Finley Xiao
8c0fbe8d07 arm64: dts: rockchip: add efuse device node for rk3368
Add a efuse node in the device tree for the ARM64 rk3368 SoC.

Change-Id: I7d13febf73e336d5b9d1046ffe6ed69d99ea9dd6
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2017-03-14 10:28:27 +08:00
Finley Xiao
1846e7d725 nvmem: rockchip-efuse: add rk3368-efuse support
This adds the necessary data for handling efuse on the rk3368.
As efuse of rk3368 is secure, use secure interface to access efuse.

Change-Id: I72c29348b7744b232d75ab51c56dc7de0988c24e
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2017-03-14 10:28:27 +08:00
Finley Xiao
ed4dc984d2 clk: rockchip: use rk3368-efuse clock ids
Reference the newly added efuse clock-ids in the clock-tree.

Change-Id: Ibbef52bcc44d006ab48e6f1f874e3bc88c681bd6
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2017-03-14 10:28:27 +08:00
Finley Xiao
3125e80cd5 clk: rockchip: add ids for efuse pclk on rk3368
Adds new ids for the pclk supplying the efuse on rk3368 socs.

Change-Id: I69f0daf402d62079e47d8df8f6e9bef0b274239f
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2017-03-14 10:28:27 +08:00
chenjh
e5edf0a295 firmware: rockchip: sip: add secure register read/write
Change-Id: If1369fb63a2618d20bfe7edffdc49bd4a959f954
Signed-off-by: chenjh <chenjh@rock-chips.com>
2017-03-14 10:28:27 +08:00
Elaine Zhang
88dd889620 clk: rockchip: fix up the rockchip_rk3066_pll_clk_set_by_auto func
Change-Id: Id7c561a50a16918c2943f79701ab72c6eaccdc41
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2017-03-14 10:26:50 +08:00
Jacob Chen
181f6bdcff drm/rockchip: rga: fix potential buffer overflow
Change-Id: Id923e38264855320fbe994bed156bf16eac60245
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
2017-03-14 09:09:32 +08:00
Jacob Chen
89211fb8a7 drm/rockchip: rga: don't flush buffer context
to save time

Change-Id: Ie4a1618eabdbb9ebf5ad0b73b8acc9df884a81bb
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
2017-03-14 09:09:19 +08:00
Jacob Chen
0800d51b9d ARM: dts: rk3288: add dma-coherent to rga
RGA are used for scale copy buffer form vpu,isp,
no need to flush CPU cache

Change-Id: Id3cfa0560a14cea122321dc1ea814aa8ec5dd4b6
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
2017-03-14 09:09:08 +08:00
Zorro Liu
39d4073fe9 driver, touch, gt9xx: enable regulator default
Change-Id: I6e3e7fe6102c83058078486104f88a31cdf1d65b
Signed-off-by: Zorro Liu <lyx@rock-chips.com>
2017-03-13 17:45:17 +08:00
Frank Wang
acee7563ea arm64: configs: rockchip_defconfig: enable mailbox and scpi
This adds select mailbox and scpi support.

Change-Id: I98fa6ee1ca210779b44c1351b68e8725071de07a
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2017-03-13 15:55:00 +08:00
Frank Wang
c71a0bf1fd arm64: dts: rockchip: enable mbox related for rk3368-tb
This adds enable mbox and scpi function for rk3368-tb board.

Change-Id: I0b4866b72ad59892bc1c051c60bafd1a15ddce14
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2017-03-13 15:53:02 +08:00
Frank Wang
c77cc0a3ef arm64: dts: rockchip: add mbox related nodes for rk3368
This adds support rk3368-mbox and scpi nodes for rk3368 SoC.

Change-Id: Ifdb90f8101c67ec579b5bba28f163527ed096c4c
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2017-03-13 15:50:10 +08:00
Frank Wang
f18ee0f4d9 mailbox: rk3368: add mailbox and scpi function
Add mailbox and scpi protocol function support for rk3368 SoC.

Change-Id: I201c916865eb2729ed135c3f5a77a9dd97007952
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2017-03-13 15:49:22 +08:00