firefly-linux-kernel-4.4.55.git
7 years agoUPSTREAM: net: phy: dp83867: add support for MAC impedance configuration
Mugunthan V N [Tue, 18 Oct 2016 11:20:18 +0000 (16:50 +0530)]
UPSTREAM: net: phy: dp83867: add support for MAC impedance configuration

Add support for programmable MAC impedance configuration

Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit ed838fe937dbcdcf7c0444a5b62edfec6ecd753c)
Change-Id: I189307e95ccb4f71a245ec69df6f4ab0b32130ec
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
7 years agoUPSTREAM: net: phy: dp83867: Fix initialization of PHYCR register
Stefan Hauser [Fri, 1 Jul 2016 20:35:03 +0000 (22:35 +0200)]
UPSTREAM: net: phy: dp83867: Fix initialization of PHYCR register

When initializing the PHY control register, the FIFO depth bits are
written without reading the previous register value, i.e. all other
bits are overwritten with zero. This disables automatic MDI-X
configuration, which is enabled by default. Fix initialization by doing
a read/modify/write operation.

Signed-off-by: Stefan Hauser <stefan@shauser.net>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit b291c418172f2cfbe009d81cd9a92f7a2de7c579)
Change-Id: If14021286ff6e8b770f6cfe0f4026e29414e75d8
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
7 years agoUPSTREAM: phy: phy_{read|write}_mmd_indirect: get addr from phydev
Andrew Lunn [Wed, 6 Jan 2016 19:11:12 +0000 (20:11 +0100)]
UPSTREAM: phy: phy_{read|write}_mmd_indirect: get addr from phydev

The address of the device can be determined from the phydev structure,
rather than passing it as a parameter.

Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit 053e7e169229adebbc27fc176c5369398e9f5eba)
Change-Id: Ib0f855bb2f6ad38e37c030343d6ccb1cc8848178
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
7 years agoUPSTREAM: PHY: DP83867: Remove looking in parent device for OF properties
Andrew Lunn [Mon, 7 Dec 2015 03:38:58 +0000 (04:38 +0100)]
UPSTREAM: PHY: DP83867: Remove looking in parent device for OF properties

Device tree properties for a phy device are expected to be in the phy
node. The current code for the DP83867 also tries to look in the
parent node. The devices binding documentation does not mention this,
no current device tree file makes use of this, and it is not behaviour
we want. So remove looking in the parent device.

Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit 7bf9ae016efc0cf08263fbee5ac708c23b90792e)
Change-Id: Ia0b9f5fbe15b3c042880b8c8712c1b72f994029e
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
7 years agoUPSTREAM: leds: pca9532: Add device tree support
Phil Reid [Tue, 14 Jun 2016 07:36:17 +0000 (15:36 +0800)]
UPSTREAM: leds: pca9532: Add device tree support

This patch adds basic device tree support for the pca9532 LEDs.

Signed-off-by: Phil Reid <preid@electromag.com.au>
Signed-off-by: Jacek Anaszewski <j.anaszewski@samsung.com>
(cherry picked from commit fa4191a609f219262a18dd8b02ab7dc30896b707)
Change-Id: I4daef4193eef8c4cad883224048fa0b9ef03558f
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
7 years agoARM: dts: rockchip: add eDP panel support for Firefly
Randy Li [Tue, 9 May 2017 01:23:54 +0000 (09:23 +0800)]
ARM: dts: rockchip: add eDP panel support for Firefly

This patch adds the supporting to the eDP panel sold by
the T-CHIP for the Firefly RK3288. I assign the VOP lite
for the eDP panel and VOP big to HDMI, as the HDMI supports
4K resolution. With a different VOP device, eDP panel
and HDMI could display a different contents.

The InvenSense MPU6050 sensor at the botton of the panel
is also enabled.

The Firefly RK3288 Reload use a different GPIO pin to enable
the power of the eDP panel.

Change-Id: Id78249f001d171ede79fe835d24c40a75ff8a0df
Signed-off-by: Randy Li <ayaka@soulik.info>
Signed-off-by: Randy Li <randy.li@rock-chips.com>
7 years agoUPSTREAM: net: stmmac: dwmac-rk: Add handling for RGMII_ID/RXID/TXID
Wadim Egorov [Wed, 29 Mar 2017 12:12:19 +0000 (14:12 +0200)]
UPSTREAM: net: stmmac: dwmac-rk: Add handling for RGMII_ID/RXID/TXID

ATM dwmac-rk will always set and enable it's internal delay lines.
Using PHY internal delays in combination with the phy-mode
rgmii-id/rxid/txid was not possible. Only rgmii was supported.

Now we can disable rockchip's gmac delay lines and also use
rgmii-id/rxid/txid.

Tested only with a RK3288 based board.

Signed-off-by: Wadim Egorov <w.egorov@phytec.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit eaf70ad14cbbb99d46b78b1307628a16a3f6075d)
Change-Id: Id0152a9f048cbc810b62c252d4105594ed1895df
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
7 years agoFROMLIST: usb: dwc2: resume root hub to handle disconnect of device
William Wu [Sat, 27 May 2017 03:23:36 +0000 (11:23 +0800)]
FROMLIST: usb: dwc2: resume root hub to handle disconnect of device

When handle disconnect of the hcd during bus_suspend, hcd
needs to resume its root hub, otherwise the root hub will
not disconnect the existing devices under its port.

This issue always happens when connecting with usb devices
which support auto-suspend function (e.g. usb hub).

(am from https://patchwork.kernel.org/patch/9751469/)
Change-Id: I663fdea73f36e89130d9a250612363968cbff941
Signed-off-by: William Wu <william.wu@rock-chips.com>
7 years agousb: dwc_otg_310: fix reboot test fail in otg host mode
William Wu [Fri, 26 May 2017 03:54:15 +0000 (11:54 +0800)]
usb: dwc_otg_310: fix reboot test fail in otg host mode

When do reboot test with otg cable plugging in, it may
casue two issues: 1. system hung when access grstctl reg
in dwc_otg_core_reset(); 2. kernel panic when remove the
host channel from the free list in assign_and_init_hc().

This patch adds 1.5~2ms delay afer resume USB2 PHY, the
time for utmi_clk provided from USB2 PHY to stabilize,
and then we can access the usb core registers safely, it
can avoid system hung.

Also, we avoid to call otg20_hcd_connect_detect() if dwc2
is host mode except force host mode during probe, because
we will do the same work in check_id_work() later. This can
fix the issue that init usb core and host twice when boot
with otg cable and usb device, which may cause kernel panic
because of hc list is NULL.

Change-Id: I35aa36762c64b14b580b493d213610379676ab56
Signed-off-by: William Wu <william.wu@rock-chips.com>
7 years agoi2c: rk3x: Make sure the i2c transfer to be finished before system reboot
David Wu [Wed, 3 Aug 2016 03:27:31 +0000 (11:27 +0800)]
i2c: rk3x: Make sure the i2c transfer to be finished before system reboot

If the system rebooted, there might be i2c transfer at the
same time, it will make something unpredictable, because
the i2c host was reseted, but the slave device wasn't, such
as rk808 pmic, so make sure the i2c transfer to be finished
before system shutdown at the reset mode.

Change-Id: I3c09f3acbe86595c295edc191aa38351adb7d5dc
Signed-off-by: David Wu <david.wu@rock-chips.com>
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
7 years agoARM: rockchip: pm: fix compile warning
Huang, Tao [Thu, 25 May 2017 12:40:41 +0000 (20:40 +0800)]
ARM: rockchip: pm: fix compile warning

When build with ARM_LPAE enabled:
arch/arm/mach-rockchip/pm.c: In function 'rk3288_init_pmu_sram':
arch/arm/mach-rockchip/pm.c:85:23: warning: cast to pointer from
integer of different size [-Wint-to-pointer-cast]

Change-Id: I526f13439c3c7edde77a27419d488a8f79081661
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
7 years agovideo/rockchip: fix rga driver compile when LPAE
Zikim,Wei [Wed, 22 Feb 2017 14:22:14 +0000 (22:22 +0800)]
video/rockchip: fix rga driver compile when LPAE

Change-Id: Ifc50e0ae52ece8c93ab8fab4ddabc01916ace526
Signed-off-by: Zikim,Wei <wzq@rock-chips.com>
(cherry picked from commit c1f2cf28941e5a31e00b21025fe48260bb235b9a)

7 years agommc: host: rk_sdmmc_ops: fix area access error
xiaoyao [Wed, 24 May 2017 08:20:26 +0000 (16:20 +0800)]
mmc: host: rk_sdmmc_ops: fix area access error

Change-Id: Ibc0655d630e808d6daccbb4c0f76ffc2afa930a2
Signed-off-by: xiaoyao <xiaoyao@rock-chips.com>
7 years agomfd: fusb302: move notify to PD startup state
zain wang [Fri, 19 May 2017 07:24:33 +0000 (15:24 +0800)]
mfd: fusb302: move notify to PD startup state

The PD policy would take 5-7s to enter PD disabled state (send
50 times caps, the more bytes of caps cmd, the more time it
takes), So we ough to pick usb notify to PD startup state for
better user experience.

Change-Id: I3b2dc1c5df31296520685ba57e892a30ef3c28aa
Signed-off-by: zain wang <wzz@rock-chips.com>
7 years agomfd: fusb302: fix some variable following PD specification
zain wang [Fri, 19 May 2017 06:00:46 +0000 (14:00 +0800)]
mfd: fusb302: fix some variable following PD specification

In the spec:
The tTypeCSendSourceCap is defined from 100ms to 200ms.
The nCapsCount is defined 50.

Change-Id: I09bcdb7a83c353ab099d51228cf8ca13e562d839
Signed-off-by: zain wang <wzz@rock-chips.com>
7 years agomfd: fusb302: Add is_pd_support to struct fusb30x_chip
zain wang [Fri, 19 May 2017 05:47:09 +0000 (13:47 +0800)]
mfd: fusb302: Add is_pd_support to struct fusb30x_chip

As the PD spec, we ough to tell policy engine if the cable
support PD, some state would run depend on this value.

Change-Id: Ied725ecb53f71a5e367b1ca91acd7f23372c54a1
Signed-off-by: zain wang <wzz@rock-chips.com>
7 years agodrivers: vendor_storage: add retry when emmc initialize failed
wlq [Tue, 23 May 2017 11:32:42 +0000 (19:32 +0800)]
drivers: vendor_storage: add retry when emmc initialize failed

Change-Id: I28202c5e3a4eb9ab58a430f40ff5e969fd110f54
Signed-off-by: Wu Liangqing <wlq@rock-chips.com>
7 years agoarm: dts: rk3288-android: enable fiq debugger mode
chenjh [Thu, 27 Apr 2017 03:24:05 +0000 (11:24 +0800)]
arm: dts: rk3288-android: enable fiq debugger mode

Change-Id: I536439c95488eba7ff3f52e8df87d7e21eb76989
Signed-off-by: chenjh <chenjh@rock-chips.com>
7 years agoARM: rockchip_defconfig: enable CONFIG_FIQ_DEBUGGER_TRUST_ZONE
chenjh [Tue, 23 May 2017 10:04:50 +0000 (18:04 +0800)]
ARM: rockchip_defconfig: enable CONFIG_FIQ_DEBUGGER_TRUST_ZONE

Signed-off-by: chenjh <chenjh@rock-chips.com>
Change-Id: I0235b755f1e3481aa9fa326f87261c7bd39ce039

7 years agoUSB: dwc_otg_310: pcd: don't set cnak when setup stage
Feng Mingli [Tue, 23 May 2017 05:51:48 +0000 (13:51 +0800)]
USB: dwc_otg_310: pcd: don't set cnak when setup stage

Refer dwc2 databook and programming, the controller automatic
receive SETUP packet to the receive FIFO and respond to Host
ACK whether ep enabled or not. The core internally set the IN
NAK and OUT NAK bits when SETUP packet was received in order
to software process SETUP packet and transition to the next
stage.

If software has not enabled ep before the Host send the SETUP
packet, set enable ep and cnak at the same time the Host send
DATA OUT packet. Then dwc2 controller write the setup data to
the memory and disable ep, respond ACK to the Host DATA OUT
packet. The Host transition to the status stage, but we lost
the DATA OUT packet. So don't set cnak when setup stage, the
dwc2 controller respond NAK to the Host DATA OUT packet, the
Host resend ping packet and DATA OUT packet.

TEST=set gadget work as usb audio and connect to ubuntu(rk3036)

Change-Id: Id791c44baf3d363a975ceaeb7d1c879c9703ce1d
Signed-off-by: Feng Mingli <fml@rock-chips.com>
Signed-off-by: William Wu <william.wu@rock-chips.com>
7 years agoARM: dts: rockchip: add memory node for rk3229-echo-v10
Frank Wang [Wed, 24 May 2017 03:50:21 +0000 (11:50 +0800)]
ARM: dts: rockchip: add memory node for rk3229-echo-v10

when using upstream u-boot load kernel, reserves memory from early
allocator will fail if memory node is not specified.

===============================
Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0xf00
[    0.000000] Initializing cgroup subsys cpuset
[    0.000000] Initializing cgroup subsys cpu
[    0.000000] Initializing cgroup subsys cpuacctdd
...
[    0.000000] earlycon: Early serial console at MMIO32 0x11030000 (options '')
[    0.000000] bootconsole [uart0] enabled
[    0.000000] cma: Failed to reserve 16 MiB
[    0.000000] Memory policy: Data cache writealloc

This patch fix it.

Change-Id: I6a3c6b1e210bbc9a5240503ab7bf5ddab89910ba
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
7 years agoUPSTREAM: ARM: dts: rockchip: Add missing unit name to memory nodes in rk322x boards
Javier Martinez Canillas [Fri, 9 Sep 2016 14:01:07 +0000 (10:01 -0400)]
UPSTREAM: ARM: dts: rockchip: Add missing unit name to memory nodes in rk322x boards

This patch fixes the following DTC warnings:

"Node /memory has a reg or ranges property, but no unit name"

Change-Id: I140cef24b80e4ff0b9fbe6f0e07221fba1da72f0
Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
(cherry picked from commit 09fbc4a08e8c5b08540dd6758c6951f52b4b4e5f)

7 years agonet: usb: modify rx_urb_size size for dm9601
zzc [Wed, 24 May 2017 00:49:08 +0000 (08:49 +0800)]
net: usb: modify rx_urb_size size for dm9601

fix error:
[  103.825058] DWC_OTG Transfer buffer length less than actual buffer lengthactual_length 1536 , buffer_length 1522 urb->complete rx_complete+0x0/0x1cc
[  103.839742] skbuff: skb_over_panic: text:ffffff80086e1f74 len:1536 put:1536 head:ffffffc06118da80 data:ffffffc06118dac2 tail:0x642 end:0x640 dev:eth0
[  103.839960] ------------[ cut here ]------------
[  103.839989] kernel BUG at net/core/skbuff.c:104!
[  103.840027] Internal error: Oops - BUG: 0 [#1] PREEMPT SMP
[  104.008320] read channel() error: -110
[  104.218321] read channel() error: -110
[  104.428304] read channel() error: -110
[  104.638314] read channel() error: -110
[  104.848296] read channel() error: -110
[  105.058314] read channel() error: -110
[  105.268303] read channel() error: -110
[  105.280141] Modules linked in: pvrsrvkm(O)
[  105.284297] CPU: 0 PID: 0 Comm: swapper/0 Tainted: G        W  O    4.4.66 #26
[  105.291524] Hardware name: Rockchip rk3368 p9 board (DT)
[  105.296850] task: ffffff8009165090 ti: ffffff8009150000 task.ti: ffffff8009150000
[  105.304352] PC is at skb_panic+0x4c/0x50
[  105.308290] LR is at skb_panic+0x4c/0x50
[  105.312227] pc : [<ffffff80089436f8>] lr : [<ffffff80089436f8>] pstate: 604001c5
[  105.319624] sp : ffffffc07db5b890
[  105.322948] x29: ffffffc07db5b8a0 x28: 0000000000000002
[  105.328296] x27: ffffff80095805ec x26: ffffff80095805e8
[  105.333643] x25: 0000000000000002 x24: 0000000000000002
[  105.338988] x23: ffffff80095805e0 x22: ffffffc06114fb00
[  105.344335] x21: 0000000000000000 x20: ffffffc047837b40
[  105.349683] x19: ffffffc0793ac800 x18: 0000000000000000
[  105.355029] x17: 00000078da08d124 x16: ffffff80081f1438
[  105.360376] x15: 000000000000000c x14: 636666666666663a
[  105.365723] x13: 6461656820363335 x12: 313a747570203633
[  105.371071] x11: 35313a6e656c2034 x10: 3766316536383030
[  105.376417] x9 : 386666666666663a x8 : 303a646e65203234
[  105.381764] x7 : 000000000000000a x6 : 000000000000000d
[  105.387110] x5 : 0000000000000001 x4 : 0000000000000001
[  105.392455] x3 : 0000000000000007 x2 : cb88537fdc8ba642
[  105.397802] x1 : cb88537fdc8ba642 x0 : 0000000000000089

Change-Id: Ie11f20d62bec7d0d35b82d0bb5535d3c8d9213b9
Signed-off-by: zzc <zzc@rock-chips.com>
7 years agoarm: dts: rk322x-android: enable rockchip-suspend
XiaoDong Huang [Tue, 23 May 2017 09:06:56 +0000 (17:06 +0800)]
arm: dts: rk322x-android: enable rockchip-suspend

Change-Id: I49ecf3e733ec376f86dc4ab7f27f3c1e0af964eb
Signed-off-by: XiaoDong Huang <derrick.huang@rock-chips.com>
7 years agoarm: dts: rk322x: add rockchip-suspend node
XiaoDong Huang [Mon, 22 May 2017 11:40:55 +0000 (19:40 +0800)]
arm: dts: rk322x: add rockchip-suspend node

Change-Id: I1bdc66e4e8db55cdc02709bf0eb901ea037c5a60
Signed-off-by: XiaoDong Huang <derrick.huang@rock-chips.com>
7 years agosoc: rockchip: support rk322x pm config
XiaoDong Huang [Mon, 22 May 2017 11:24:42 +0000 (19:24 +0800)]
soc: rockchip: support rk322x pm config

Change-Id: I29c5685f09a846b62196ab8614ebe168bfed75ef
Signed-off-by: XiaoDong Huang <derrick.huang@rock-chips.com>
7 years agoclk: rockchip: rk3328: add flag CLK_IGNORE_UNUSED for hclk_vop_niu
Elaine Zhang [Tue, 23 May 2017 09:45:33 +0000 (17:45 +0800)]
clk: rockchip: rk3328: add flag CLK_IGNORE_UNUSED for hclk_vop_niu

Change-Id: I770a83ad357f18d3258755b6c1d43ef82248951e
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
7 years agoARM64: dts: rockchip: rk3399-opp: fix up the gpu_opp_table
Elaine Zhang [Tue, 23 May 2017 03:07:12 +0000 (11:07 +0800)]
ARM64: dts: rockchip: rk3399-opp: fix up the gpu_opp_table

Change-Id: I2e13b74ce3ff8509753605b9b0a02fb1c8d0f765
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
7 years agoarm64: dts: rk3399: sapphire: set syr83x vsel gpio type input
wlq [Thu, 11 May 2017 10:05:01 +0000 (18:05 +0800)]
arm64: dts: rk3399: sapphire: set syr83x vsel gpio type input

Change-Id: I5c809885038e81570d993ebbc94ae757ba4b9acd
Signed-off-by: Wu Liangqing <wlq@rock-chips.com>
7 years agodriver: sensor-dev: use copy_to_user&&copy_from_user to do the user point
Zorro Liu [Mon, 22 May 2017 03:48:57 +0000 (11:48 +0800)]
driver: sensor-dev: use copy_to_user&&copy_from_user to do the user point

Change-Id: Ibbff2eecc71643c95ae91d0cd8a8469fd43a3cea
Signed-off-by: Zorro Liu <lyx@rock-chips.com>
7 years agopower: rk818-charger: move irq init to the last step
chenjh [Thu, 18 May 2017 06:58:02 +0000 (14:58 +0800)]
power: rk818-charger: move irq init to the last step

init irq later than workqueue_struct and delayed_work to
avoid NULL ponint

Change-Id: I715296a715cb07149a6dce236a3b8ccafe00622e
Signed-off-by: chenjh <chenjh@rock-chips.com>
7 years agodrm/rockchip: vop: support vop dump when iommu page fault
Mark Yao [Wed, 17 May 2017 09:44:55 +0000 (17:44 +0800)]
drm/rockchip: vop: support vop dump when iommu page fault

Change-Id: I164fc7e8cb7392143959d53709bcdf61713fb3d8
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
7 years agoarm64: dts: rk3368: add dfi and dmc device nodes
Finley Xiao [Sat, 25 Mar 2017 09:34:08 +0000 (17:34 +0800)]
arm64: dts: rk3368: add dfi and dmc device nodes

Add dfi and dmc nodes in the device tree for the ARM64 rk3368 SoC.
To support ddr frequency scaling function, we need enable dmc and
dfi nodes.

Change-Id: I155b838a8773ff1842058bebb1ed2747ca8e2e0b
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agopower: rk818-charger: add TS2 voltage detect when update input current
chenjh [Wed, 17 May 2017 09:27:56 +0000 (17:27 +0800)]
power: rk818-charger: add TS2 voltage detect when update input current

rk818's input charge voltage limit function doesn't works well. If software
set input current over than charger's max support value, rk818 may cause
charger over current protect which means disconnecting.
To solve this problem, we need to detect vbus voltage by TS2 pin, if vbus
is upper than 4.4v, we can safely adjust input current step by step from
low to high until meeting the target input current value.

Change-Id: I01d63974f251ad8ef0037158b66f4b85d3928baf
Signed-off-by: chenjh <chenjh@rock-chips.com>
7 years agoASoc: hdmi_codec: fix startup error when multicodecs are used
zhangjun [Thu, 18 May 2017 01:35:40 +0000 (09:35 +0800)]
ASoc: hdmi_codec: fix startup error when multicodecs are used

due to playback and capture will call startup at the same time
when voip call, but hdmi_codec driver only support playback

[   51.134149] hdmi-audio-codec hdmi-audio-codec.6.auto: hdmi_codec_startup()
[   51.134179] hdmi-audio-codec hdmi-audio-codec.6.auto: Only one simultaneous stream supported!
[   51.134197] hdmi-audio-codec hdmi-audio-codec.6.auto: ASoC: can't open codec i2s-hifi: -22
[   51.143250] hdmi-audio-codec hdmi-audio-codec.6.auto: hdmi_codec_startup()
[   51.143277] hdmi-audio-codec hdmi-audio-codec.6.auto: Only one simultaneous stream supported!
[   51.143294] hdmi-audio-codec hdmi-audio-codec.6.auto: ASoC: can't open codec i2s-hifi: -22
[   51.157546] hdmi-audio-codec hdmi-audio-codec.6.auto: hdmi_codec_startup()
[   51.157584] hdmi-audio-codec hdmi-audio-codec.6.auto: Only one simultaneous stream supported!
[   51.157603] hdmi-audio-codec hdmi-audio-codec.6.auto: ASoC: can't open codec i2s-hifi: -22

Change-Id: I970695dbe19f070579aacd044e6a01c44e687a2e
Signed-off-by: zhangjun <zhangjun@rock-chips.com>
7 years agoarm64: dts: rk3368: add wakeup-config in rockchip-suspend
XiaoDong Huang [Thu, 18 May 2017 12:06:35 +0000 (20:06 +0800)]
arm64: dts: rk3368: add wakeup-config in rockchip-suspend

Change-Id: Ibf4ba154d59e99332e68ca5451b0045e15fa850d
Signed-off-by: XiaoDong Huang <derrick.huang@rock-chips.com>
7 years agonet: wireless: rockchip_wlan: enable GET_CUSTOM_MAC_ENABLE
zzc [Thu, 18 May 2017 01:28:20 +0000 (09:28 +0800)]
net: wireless: rockchip_wlan: enable GET_CUSTOM_MAC_ENABLE

Change-Id: I544df96a365ab62b12388e5df3c2fcfa23204e32
Signed-off-by: zzc <zzc@rock-chips.com>
7 years agoarm64: rockchip_defconfig: fix softap error
zzc [Tue, 16 May 2017 07:22:29 +0000 (15:22 +0800)]
arm64: rockchip_defconfig: fix softap error

fix error:
05-16 06:42:05.688   347   596 V NatController: runCmd(/system/bin/ip6tables -w -t raw -A natctrl_raw_PREROUTING -i wlan0 -m rpfilter --invert ! -s fe80::/64 -j DROP) res=1
05-16 06:42:05.726   347   596 E NatController: Error setting forward rules
05-16 06:42:05.791   602   622 E TetherInterfaceSM: Exception enabling Nat: java.lang.IllegalStateException: command '53 nat enable wlan0 eth0 1 192.168.43.0/24' failed with '400 53 Nat op
eration failed (No such device)'
05-16 06:42:05.794   347   841 D TetherController: Sending update msg to dnsmasq [update_ifaces|wlan0]
05-16 06:42:05.796   347   596 D TetherController: untetherInterface(wlan0)

Change-Id: Iae2ec50bef0915aecc1b2befb014a87731e61643
Signed-off-by: zzc <zzc@rock-chips.com>
7 years agocpufreq: rockchip: fix warning caused by passing invalid cpu id
Finley Xiao [Thu, 18 May 2017 08:28:56 +0000 (16:28 +0800)]
cpufreq: rockchip: fix warning caused by passing invalid cpu id

------------[ cut here ]------------
[  105.026874] WARNING: at drivers/cpufreq.c:290
[  105.026883] Modules linked in: pvrsrvkm(O)
[  105.026900]
[  105.026915] CPU: 0 PID: 1 Comm: init Tainted: G   O    4.4.66 #1875
[  105.026924] Hardware name: Rockchip Sheep board (DT)
[  105.026937] task: ffffffc07b490000 ti: ffffffc07b484000 task.ti:
ffffffc07b484000
[  105.026964] PC is at cpufreq_cpu_get+0x20/0x8c
[  105.026978] LR is at cpufreq_update_policy+0x28/0x130
[  105.026989] pc : [<ffffff80088246bc>] lr : [<ffffff80088273b8>]
pstate: 60400145
[  105.026997] sp : ffffffc07b487a60
[  105.027004] x29: ffffffc07b487a60 x28: ffffffc07b484000
[  105.027017] x27: ffffff8008b82000 x26: 000000000000008e
[  105.027028] x25: 000000000000011d x24: 0000000000000001
[  105.027039] x23: 0000000000000008 x22: 0000000000000008
[  105.027051] x21: ffffff8009166000 x20: ffffff800923cd50
[  105.027063] x19: ffffffc07a71c600 x18: 0000000000ffffeb

Change-Id: I45de2f755617a5a5903dc5f15e289f8705ceb80d
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agoi2c: rk3x: fix to dev_warn_ratelimited
Jianqun Xu [Thu, 18 May 2017 01:12:32 +0000 (09:12 +0800)]
i2c: rk3x: fix to dev_warn_ratelimited

In some case, the log will look bad such as:
[   12.393926] rk3x-i2c ff150000.i2c: irq in STATE_IDLE, ipd = 0x51
[[[[[[[[[[[[.[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[

Let's limit the printk:
[  180.446547] rk3x_i2c_irq: 1726030 callbacks suppressed
[  180.446592] rk3x-i2c ff150000.i2c: irq in STATE_IDLE, ipd = 0x51

Change-Id: Ie91163ad3085e5dba127790b50e3beb359510120
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
7 years agoarm64: dts: rockchip: rk3328-evb: add gpio control for vcc_sd
xiaoyao [Thu, 18 May 2017 01:16:09 +0000 (09:16 +0800)]
arm64: dts: rockchip: rk3328-evb: add gpio control for vcc_sd

Change-Id: Ib504aa0505bd6bea328c5fdd73d237baddcf17a5
Signed-off-by: xiaoyao <xiaoyao@rock-chips.com>
7 years agoarm: dts: rk322x-android: enable u2phy1 otg-port
William Wu [Wed, 17 May 2017 09:00:48 +0000 (17:00 +0800)]
arm: dts: rk322x-android: enable u2phy1 otg-port

Change-Id: Ib6caa6366704509ca5c708a6bfee0e9fc6d26abe
Signed-off-by: William Wu <william.wu@rock-chips.com>
7 years agoarm: dts: rockchip: add u2phy1 otg-port node for rk322x SoC
William Wu [Wed, 17 May 2017 08:56:50 +0000 (16:56 +0800)]
arm: dts: rockchip: add u2phy1 otg-port node for rk322x SoC

Change-Id: I42efd4227428df38c643c174fb2babcd61064a72
Signed-off-by: William Wu <william.wu@rock-chips.com>
7 years agophy: rockchip-inno-usb2: add cfgs for phy1 port1 of rk322x SoC
William Wu [Wed, 17 May 2017 08:34:38 +0000 (16:34 +0800)]
phy: rockchip-inno-usb2: add cfgs for phy1 port1 of rk322x SoC

This patch adds port configuration for usb2 phy1 port1 of rk322x
SoC. For the current rockchip inno usb2 phy driver framework, it
can only support usb2 phy which comprises with one otg-port and
one host-port.

However, rk322x SoC usb2 phy1 comprises with two host-ports, so
we use otg id index for phy1 port1 configuration, and make phy1
port1 work the same as otg-port host mode.

Change-Id: Iaa10c2438c6b7b052c7f3830252ba4ebd91ff23f
Signed-off-by: William Wu <william.wu@rock-chips.com>
7 years agoARM: rockchip: Add workaround for unknown write of thread_info
Huang, Tao [Thu, 18 May 2017 02:51:27 +0000 (10:51 +0800)]
ARM: rockchip: Add workaround for unknown write of thread_info

We see the cpu of thread_info was changed by unknown reason sometimes,
which cause rq spinlock deadlock while schedule. Until we found the
root cause, we have to add this workaround.

Change-Id: Ib943ccb47a57fe4b267a1da853366363cd7f1f52
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
7 years agoPM / devfreq: rockchip_dmc: add unify params for ddr frequency scanning.
Tang Yun ping [Tue, 16 May 2017 12:19:43 +0000 (20:19 +0800)]
PM / devfreq: rockchip_dmc: add unify params for ddr frequency scanning.

1. add unify params for ddr frequency scanning.
2. add dram side and phy side odt disable frequency configurate
independent.

Change-Id: Ied97dbee8d30a1a6e95d4c252986121092c484d8
Signed-off-by: Tang Yun ping <typ@rock-chips.com>
7 years agoclk: rockchip: using unify parameters for ddr frequency scanning.
Tang Yun ping [Tue, 16 May 2017 12:11:32 +0000 (20:11 +0800)]
clk: rockchip: using unify parameters for ddr frequency scanning.

Change-Id: Ibd3befd3cd674af263402f6984ee6d605eb087c8
Signed-off-by: Tang Yun ping <typ@rock-chips.com>
7 years agocpufreq: rockchip: limit frequency when reboot
Finley Xiao [Tue, 16 May 2017 09:00:04 +0000 (17:00 +0800)]
cpufreq: rockchip: limit frequency when reboot

If i2c driver adds a shutdown callback function, the callback will be
executed before cpu's shutdown callback when reboot system, it will
fail to scale voltage like the following.
rk3x-i2c ff650000.i2c: Access denied - device already shutdown
rk3x-i2c ff650000.i2c: Access denied - device already shutdown
rk3x-i2c ff650000.i2c: Access denied - device already shutdown
rk3x-i2c ff650000.i2c: Access denied - device already shutdown
cpu cpu4: _set_opp_voltage: failed to set voltage
(950000 950000 1350000 mV):-5

So add a reboot notifier to limit frequency before i2c's shutdown callback,
and the cpu's shutdown callback will do nothing.

Change-Id: Ic5bb21b511c6f799dc62fd9db237d90522b7d4ee
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agonet: stmmac: dwmac-rk: read mac address from devinfo first
Zhangbin Tong [Tue, 2 May 2017 10:46:32 +0000 (18:46 +0800)]
net: stmmac: dwmac-rk: read mac address from devinfo first

Change-Id: I2888dcfc57c2e5a266fdf1058f9ab70e04034f22
Signed-off-by: Zhangbin Tong <zebulun.tong@rock-chips.com>
7 years agocpufreq: rockchip: optimize rockchip_cpufreq_driver_init()
Finley Xiao [Tue, 16 May 2017 02:53:46 +0000 (10:53 +0800)]
cpufreq: rockchip: optimize rockchip_cpufreq_driver_init()

Actually there is no need to use two loops.

Change-Id: Ieafdc265307e21fc7195f3d80b42483a2d53d413
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agoARM64: dts: rockchip: modify battery sample register value of rk3368-p9 according...
Zorro Liu [Wed, 17 May 2017 07:25:53 +0000 (15:25 +0800)]
ARM64: dts: rockchip: modify battery sample register value of rk3368-p9 according to hardware board

Change-Id: I50fc124f06b8c2b5af20d5e44a93f68d28d748a0
Signed-off-by: Zorro Liu <lyx@rock-chips.com>
7 years agoARM64: dts: rk3399: android: add compatible for stb_devinfo node
Zhangbin Tong [Mon, 15 May 2017 02:45:26 +0000 (10:45 +0800)]
ARM64: dts: rk3399: android: add compatible for stb_devinfo node

Change-Id: Ib45c5ff21f884fba12e39be63740f90bfc4bbc27
Signed-off-by: Zhangbin Tong <zebulun.tong@rock-chips.com>
7 years agoPM / devfreq: rockchip_dmc: Avoid glitches due to slow CPU
Finley Xiao [Mon, 15 May 2017 02:12:34 +0000 (10:12 +0800)]
PM / devfreq: rockchip_dmc: Avoid glitches due to slow CPU

We weren't giving enough time for DMC to change frequencies
when the CPU was running slow.

Change-Id: I84e1a4ad7b5ccddafb0016f3d5d6eef147a58591
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agoPM / devfreq: Lock CPU online/offline in rockchip_dmcfreq_target()
Finley Xiao [Mon, 15 May 2017 01:42:29 +0000 (09:42 +0800)]
PM / devfreq: Lock CPU online/offline in rockchip_dmcfreq_target()

To protect against races with concurrent CPU online/offline, call
get_online_cpus() before change frequency.

Change-Id: I5b97cd7eff6a1c4828ab30bc165fb2aa8b460bb3
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agoarm64: dts: rk3368: p9: set mipi_dsi_host delay 200ms
wlq [Tue, 16 May 2017 12:22:12 +0000 (20:22 +0800)]
arm64: dts: rk3368: p9: set mipi_dsi_host delay 200ms

Change-Id: Ibed9c624072f590ed2aeee8529e133a505624e8d
Signed-off-by: Wu Liangqing <wlq@rock-chips.com>
7 years agoarm64: dts: rk3368-sheep: add rk818 battery node
Xu Jianqun [Tue, 16 May 2017 08:55:52 +0000 (16:55 +0800)]
arm64: dts: rk3368-sheep: add rk818 battery node

Change-Id: I7e0f0ea93a2019ea022c9fe8e72f412af0ec6be9
Signed-off-by: Xu Jianqun <jay.xu@rock-chips.com>
7 years agoarm: dts: rk322x-android: update shut mode and enable this module
Rocky Hao [Tue, 16 May 2017 02:18:57 +0000 (10:18 +0800)]
arm: dts: rk322x-android: update shut mode and enable this module

gpio is not connected by default and we suggest cru mode as the default
shut mode.

Change-Id: I74593092b145e51e5f5b52ab028e650b7fe67f5e
Signed-off-by: Rocky Hao <rocky.hao@rock-chips.com>
7 years agoarm: dts: rockchip: rk322x: update tsadc's frequence setting
Rocky Hao [Tue, 16 May 2017 02:15:33 +0000 (10:15 +0800)]
arm: dts: rockchip: rk322x: update tsadc's frequence setting

update freq of tsadc's working clock as 32768 hz, if not set, tsadc
will work at a default frequence.

Change-Id: I04f3ee230819af1fce44518b5cbee7700c4d67fd
Signed-off-by: Rocky Hao <rocky.hao@rock-chips.com>
7 years agodrivers: inv_mpu: remove no use debug
Zorro Liu [Tue, 16 May 2017 08:47:45 +0000 (16:47 +0800)]
drivers: inv_mpu: remove no use debug

Change-Id: Ife1fae1323e2ed262a2f7063e5bb313cb304033f
Signed-off-by: Zorro Liu <lyx@rock-chips.com>
7 years agoUPSTREAM: dma-buf: Add ioctls to allow userspace to flush
Daniel Vetter [Thu, 11 Feb 2016 22:04:51 +0000 (20:04 -0200)]
UPSTREAM: dma-buf: Add ioctls to allow userspace to flush

The userspace might need some sort of cache coherency management e.g. when CPU
and GPU domains are being accessed through dma-buf at the same time. To
circumvent this problem there are begin/end coherency markers, that forward
directly to existing dma-buf device drivers vfunc hooks. Userspace can make use
of those markers through the DMA_BUF_IOCTL_SYNC ioctl. The sequence would be
used like following:
     - mmap dma-buf fd
     - for each drawing/upload cycle in CPU 1. SYNC_START ioctl, 2. read/write
       to mmap area 3. SYNC_END ioctl. This can be repeated as often as you
       want (with the new data being consumed by the GPU or say scanout device)
     - munmap once you don't need the buffer any more

BackPort:
  upstream kernel change dma-buf api with the commit(831e9da
  dma-buf: Remove range-based flush), avoid effect too much to
  current kernel, Just compatible dma-buf api to current version.

v2 (Tiago): Fix header file type names (u64 -> __u64)
v3 (Tiago): Add documentation. Use enum dma_buf_sync_flags to the begin/end
dma-buf functions. Check for overflows in start/length.
v4 (Tiago): use 2d regions for sync.
v5 (Tiago): forget about 2d regions (v4); use _IOW in DMA_BUF_IOCTL_SYNC and
remove range information from struct dma_buf_sync.
v6 (Tiago): use __u64 structured padded flags instead enum. Adjust
documentation about the recommendation on using sync ioctls.
v7 (Tiago): Alex' nit on flags definition and being even more wording in the
doc about sync usage.
v9 (Tiago): remove useless is_dma_buf_file check. Fix sync.flags conditionals
and its mask order check. Add <linux/types.h> include in dma-buf.h.

Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: David Herrmann <dh.herrmann@gmail.com>
Cc: Sumit Semwal <sumit.semwal@linaro.org>
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
Link: http://patchwork.freedesktop.org/patch/msgid/1455228291-29640-1-git-send-email-tiago.vignatti@intel.com
(cherry picked from commit c11e391da2a8fe973c3c2398452000bed505851e)

Change-Id: I92916babe7fb0ab3bf3ce9dc966408f2e05fe83d
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
7 years agorockchip: clk: rk3368: remove the flag ROCKCHIP_PLL_SYNC_RATE for CPLL
Elaine Zhang [Tue, 16 May 2017 07:39:37 +0000 (15:39 +0800)]
rockchip: clk: rk3368: remove the flag ROCKCHIP_PLL_SYNC_RATE for CPLL

to slove the display shaking, when uboot logo display to kernel show.

Change-Id: I5856581fabd0171be09993878ffb4ef1af0fb204
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
7 years agofirmware: rockchip: use 'nsec_ctx->und_lr' to deliver fiq break point's PC
chenjh [Mon, 15 May 2017 02:02:31 +0000 (10:02 +0800)]
firmware: rockchip: use 'nsec_ctx->und_lr' to deliver fiq break point's PC

'nsec_ctx->mon_lr' is not the fiq break point's PC, because it will
be override as 'sip_fiq_debugger_uart_irq_tf_cb' for optee-os to
jump to fiq_debugger handler. As 'nsec_ctx->und_lr' is not used for
kernel, optee-os uses it to deliver fiq break point's PC.

Change-Id: I5a831638e8228766d03d92674e3e29facdd116f8
Signed-off-by: chenjh <chenjh@rock-chips.com>
7 years agoarm64: dts: rockchip: rk3328-evb: add clk dts node for rk805
Elaine Zhang [Mon, 15 May 2017 06:34:30 +0000 (14:34 +0800)]
arm64: dts: rockchip: rk3328-evb: add clk dts node for rk805

Change-Id: I30f061a8325d7207133bfd0ab7d82b79664262cf
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
7 years agoarm: dts: rk3229-echo-v10: add clk dts node for rk805
Elaine Zhang [Mon, 15 May 2017 06:33:32 +0000 (14:33 +0800)]
arm: dts: rk3229-echo-v10: add clk dts node for rk805

Change-Id: Idff25c5e311f282c67f8dbabbd104019f19bbb6a
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
7 years agomfd: rk808: add rk808-clkout mfd cell for rk805
Elaine Zhang [Mon, 15 May 2017 06:31:05 +0000 (14:31 +0800)]
mfd: rk808: add rk808-clkout mfd cell for rk805

support rk805 two clk output,xin32k and rk805-clkout2.

Change-Id: If4f820f53feaf6ab2804f4acd0cce925667b7bc0
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
7 years agoRevert "arm64: rockchip_defconfig: enable CONFIG_IKCONFIG"
Huang, Tao [Mon, 15 May 2017 08:05:00 +0000 (16:05 +0800)]
Revert "arm64: rockchip_defconfig: enable CONFIG_IKCONFIG"

This reverts commit 28f4152aad7fc402f6f545f07f4193aac7a05087.

For pass Android 7.1 CTS:
android.security.cts.KernelSettingsTest#testNoConfigGz

Change-Id: I9bd7d4c6c06b7d43fa51a7f02eecca8cedc61c1d
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
7 years agoRevert "ARM: rockchip_defconfig: enable CONFIG_IKCONFIG"
Huang, Tao [Mon, 15 May 2017 08:01:40 +0000 (16:01 +0800)]
Revert "ARM: rockchip_defconfig: enable CONFIG_IKCONFIG"

This reverts commit b90c069d1edf02a11533cf6ba401316e36b6702b.

For pass Android 7.1 CTS:
android.security.cts.KernelSettingsTest#testNoConfigGz

Change-Id: Ia45a95bbb9aafaf0b38b7bd4647f20878403eaae
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
7 years agoarm: dts: rk3288: add dts for rk3288 evb with act8846 and edp
Xu Jianqun [Mon, 15 May 2017 02:48:58 +0000 (10:48 +0800)]
arm: dts: rk3288: add dts for rk3288 evb with act8846 and edp

Change-Id: I861ebd4f6fbe04809f1d450d1a6fd139125c9f67
Signed-off-by: Xu Jianqun <jay.xu@rock-chips.com>
7 years agoarm64: dts: rk3399-android-6.0: use ion for iep
buluess.li [Mon, 8 May 2017 08:01:45 +0000 (16:01 +0800)]
arm64: dts: rk3399-android-6.0: use ion for iep

Change-Id: If3dd5da95abb462ac15d56de26aaeff1b95f5a65
Signed-off-by: buluess.li <buluess.li@rock-chips.com>
7 years agoarm: dts: add gpio power-key support for rk322x SoC
Frank Wang [Fri, 12 May 2017 03:17:48 +0000 (11:17 +0800)]
arm: dts: add gpio power-key support for rk322x SoC

Change-Id: I45d6e0ffe5444b26165324048c0e88d6fca19bab
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
7 years agoARM64: dts: rockchip: reduce cma size of rk3368-android
Zorro Liu [Fri, 12 May 2017 09:22:58 +0000 (17:22 +0800)]
ARM64: dts: rockchip: reduce cma size of rk3368-android

Change-Id: I33407879b63acfaf6da994a5c99633b3e2ad388b
Signed-off-by: Zorro Liu <lyx@rock-chips.com>
7 years agosoc: rockchip: add devinfo parser driver
Zhangbin Tong [Tue, 2 May 2017 10:44:56 +0000 (18:44 +0800)]
soc: rockchip: add devinfo parser driver

Change-Id: I8e16d5ee8a1456de43e46e68bee60e7fb2a7b266
Signed-off-by: Zhangbin Tong <zebulun.tong@rock-chips.com>
7 years agoARM64: dts: rk3399: android: add memory reserved for deviceinfo
Zhangbin Tong [Tue, 2 May 2017 10:41:04 +0000 (18:41 +0800)]
ARM64: dts: rk3399: android: add memory reserved for deviceinfo

Change-Id: Iff4cdc07f1a79d832af85dc23ed1001002fe2e6a
Signed-off-by: Zhangbin Tong <zebulun.tong@rock-chips.com>
7 years agoARM: dts: rk322x: fix i2s1 pinctrl error
Sugar Zhang [Fri, 12 May 2017 09:20:43 +0000 (17:20 +0800)]
ARM: dts: rk322x: fix i2s1 pinctrl error

Change-Id: I29fa27ea159b86d3cdfbaf6d9c620e53bc52afd9
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
7 years agoARM: dts: rk322x: add spdif node
Sugar Zhang [Fri, 12 May 2017 09:17:04 +0000 (17:17 +0800)]
ARM: dts: rk322x: add spdif node

Change-Id: Id8ccff720d3e42e0df8fa8fd5007127fa9af2147
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
7 years agoASoC: rockchip: add support for rk3228 spdif
Sugar Zhang [Fri, 12 May 2017 09:16:26 +0000 (17:16 +0800)]
ASoC: rockchip: add support for rk3228 spdif

Change-Id: I3f0ae976ef055086f48c2b95b5e45a9eac7487ad
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
7 years agodrm/rockchip: vop: add line_flag 0/1 for ddr freq change
Mark Yao [Fri, 24 Mar 2017 11:46:46 +0000 (19:46 +0800)]
drm/rockchip: vop: add line_flag 0/1 for ddr freq change

Change-Id: Icae9fe3d3600a478f68220545c17b393b4aff1ec
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
7 years agomfd: fusb302: Don't mistake meaningful packets for Good_CRC
zain wang [Thu, 11 May 2017 07:46:25 +0000 (15:46 +0800)]
mfd: fusb302: Don't mistake meaningful packets for Good_CRC

If a partner port sends a packet at approximately the same time as we
send a packet, we may end up with the initial packet followed by the
GOOD_CRC reply in our HW FIFO. Don't automatically discard the first
packet in the FIFO. Instead, discard the packet only if it's a GOOD_CRC
packet. And, modify our get_message function to automatically discard
GOOD_CRC in search of a meaningful packet.

In addition, due to interrupt latency, we can't rely on receiving one
interrupt per incoming packet. If our Rx FIFO is non-empty, assume that
it contains at least one packet.

Change-Id: Iaad80a4c55eea3e9e2791d81d7c5d28ce97bd2f5
Signed-off-by: zain wang <wzz@rock-chips.com>
7 years agoARM64: dts: rk3368: add rk3368-sheep-lvds.dts for sheep board
Huang Jiachai [Wed, 19 Apr 2017 13:04:36 +0000 (21:04 +0800)]
ARM64: dts: rk3368: add rk3368-sheep-lvds.dts for sheep board

Change-Id: Iaf65b8c8f928397e1a3641a7521ee2efed230d31
Signed-off-by: Huang Jiachai <hjc@rock-chips.com>
7 years agoarm: rockchip_defconfig: enable CONFIG_KEYBOARD_GPIO
Frank Wang [Fri, 12 May 2017 06:26:38 +0000 (14:26 +0800)]
arm: rockchip_defconfig: enable CONFIG_KEYBOARD_GPIO

This adds enable CONFIG_KEYBOARD_GPIO to support gpio-keys driver.

Change-Id: Ib2e127a3d017ad69b1bf6c0b0a795d0bce44af0e
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
7 years agodrm/rockchip: vop: correct rk322x vop define
Mark Yao [Fri, 12 May 2017 06:23:12 +0000 (14:23 +0800)]
drm/rockchip: vop: correct rk322x vop define

Change-Id: If4c3b2e54f3621f7b1120401d9a049d780aa9b4f
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
7 years agoarm: dts: rk322x: Add io-domain support for rk3229-evb and rk3229-echo-v10
David Wu [Fri, 12 May 2017 06:15:51 +0000 (14:15 +0800)]
arm: dts: rk322x: Add io-domain support for rk3229-evb and rk3229-echo-v10

The power domain of VCCIO3 is selected from maskrom,
so we don't need to configure it.

Change-Id: I11f87fe6f178943daa5ec9dcc22f4f505fe58163
Signed-off-by: David Wu <david.wu@rock-chips.com>
7 years agoarm: dts: rk322x: Add io-domain node
David Wu [Fri, 12 May 2017 03:31:46 +0000 (11:31 +0800)]
arm: dts: rk322x: Add io-domain node

Change-Id: I1707bc7e4ed166b1aee14d69c7e25a57ab535d83
Signed-off-by: David Wu <david.wu@rock-chips.com>
7 years agoPM / AVS: rockchip-io: Add rk322x io-domains support
David Wu [Fri, 12 May 2017 03:30:37 +0000 (11:30 +0800)]
PM / AVS: rockchip-io: Add rk322x io-domains support

Change-Id: Iaa91c932fdd9a9589945b0c6e19bc73517f7b322
Signed-off-by: David Wu <david.wu@rock-chips.com>
7 years agoARM: dts: rk3229-evb: enable GPU device
chenzhen [Fri, 12 May 2017 02:00:04 +0000 (10:00 +0800)]
ARM: dts: rk3229-evb: enable GPU device

Change-Id: Ifab6284e56d1e833990b53d1aa555f55b520c955
Signed-off-by: chenzhen <chenzhen@rock-chips.com>
7 years agoarm: dts: rk3229-echo-v10: enable GPU device
chenzhen [Tue, 9 May 2017 07:40:49 +0000 (15:40 +0800)]
arm: dts: rk3229-echo-v10: enable GPU device

Change-Id: I4336bd134afea2b8ad55ebb104c877548c16b582
Signed-off-by: chenzhen <chenzhen@rock-chips.com>
7 years agoarm: dts: rk322x: add mali-400 GPU device
chenzhen [Tue, 9 May 2017 07:39:39 +0000 (15:39 +0800)]
arm: dts: rk322x: add mali-400 GPU device

Change-Id: I4fb5d27a34e57bb17db2c79ffdc655223ce8c338
Signed-off-by: chenzhen <chenzhen@rock-chips.com>
7 years agoARM: rockchip_defconfig: enable driver for Mali400 GPU
chenzhen [Tue, 9 May 2017 03:42:36 +0000 (11:42 +0800)]
ARM: rockchip_defconfig: enable driver for Mali400 GPU

Change-Id: Idcccf39fc0a5d2d340325e1b3445c8c0d3dcbcc3
Signed-off-by: chenzhen <chenzhen@rock-chips.com>
7 years agoARM: dts: rk322x: add 'nvmem-cells' property for opp_table0
Finley Xiao [Thu, 11 May 2017 08:26:06 +0000 (16:26 +0800)]
ARM: dts: rk322x: add 'nvmem-cells' property for opp_table0

This patch adds nvmem-cells property to opp_table0 node so that
cpufreq driver can get cpu leakage value.

Change-Id: Ic39525de46762dfe867ecb86123be6fa7ccad95c
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agoARM: dts: rockchip: add efuse device node for rk322x
Finley Xiao [Thu, 11 May 2017 08:05:10 +0000 (16:05 +0800)]
ARM: dts: rockchip: add efuse device node for rk322x

Add a efuse node in the device tree for the rk322x SoC.

Change-Id: I9a771c2065bb222b754f5a37b193edd4abb3f3a7
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agoarm64: rockchip_defconfig: enable HDMI_ANALOG
zhangjun [Thu, 11 May 2017 06:27:48 +0000 (14:27 +0800)]
arm64: rockchip_defconfig: enable HDMI_ANALOG

Change-Id: Icae9ce3e01f063c8b6e169b9d386b6eeeed54961
Signed-off-by: zhangjun <zhangjun@rock-chips.com>
7 years agoASoC: rockchip: add machine driver for built-in hdmi and codec IC
zhangjun [Thu, 11 May 2017 03:31:14 +0000 (11:31 +0800)]
ASoC: rockchip: add machine driver for built-in hdmi and codec IC

this patch is used for rockchip built-in HDMI and audio codec
IC which are wired to the same i2s line(such as rk3368).
so we use a DAI link CPU to multicodecs.

Change-Id: Ibc5fdeb2091836dc28675aacdc099d76e0b7d752
Signed-off-by: zhangjun <zhangjun@rock-chips.com>
7 years agodt-bindings: suspend: rockchip: add PMU_USB_LINESTAE_WAKEUP_EN config for wakeup
shengfei Xu [Fri, 21 Apr 2017 03:31:34 +0000 (11:31 +0800)]
dt-bindings: suspend: rockchip: add PMU_USB_LINESTAE_WAKEUP_EN config for wakeup

Change-Id: I73b992b57344f24eb37b360bc479264996ff72d1
Signed-off-by: shengfei Xu <xsf@rock-chips.com>
7 years agoPM / devfreq: rockchip_dmc: Fix error handling
Finley Xiao [Thu, 11 May 2017 10:06:12 +0000 (18:06 +0800)]
PM / devfreq: rockchip_dmc: Fix error handling

It never has the mutex_lock counterpart before goto.

Change-Id: I937e79bc65433cb1c173fe0cb221e7d69586046c
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agoarm: dts: rk3288-evb: enable rockchip-suspend node
shengfei Xu [Fri, 5 May 2017 07:43:53 +0000 (15:43 +0800)]
arm: dts: rk3288-evb: enable rockchip-suspend node

Change-Id: I1bc5f75d3bf49b7f5a532d7dbe7206edc6932c36
Signed-off-by: shengfei Xu <xsf@rock-chips.com>
7 years agoarm: dts: rk3288: add rockchip-suspend node
shengfei Xu [Fri, 5 May 2017 07:38:27 +0000 (15:38 +0800)]
arm: dts: rk3288: add rockchip-suspend node

Change-Id: Id5700548a6034248ed5ad3226dd652d0833eec13
Signed-off-by: shengfei Xu <xsf@rock-chips.com>
7 years agosoc: rockchip: support rk3288 pm config
shengfei Xu [Fri, 5 May 2017 07:34:14 +0000 (15:34 +0800)]
soc: rockchip: support rk3288 pm config

Change-Id: Icbd23af68bdf7a4fcad59a5d227988a13b2873af
Signed-off-by: shengfei Xu <xsf@rock-chips.com>
7 years agonvmem: rockchip-efuse: add support for rk322x-efuse
Finley Xiao [Thu, 11 May 2017 08:01:10 +0000 (16:01 +0800)]
nvmem: rockchip-efuse: add support for rk322x-efuse

This adds the necessary data for handling efuse on the rk322x.

Change-Id: Iadd37923f5949a03630a936d5a41b955d443b2d8
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agoARM: dts: rk3229: add cpu-supply property for cpu node in evb board
Finley Xiao [Thu, 11 May 2017 08:08:30 +0000 (16:08 +0800)]
ARM: dts: rk3229: add cpu-supply property for cpu node in evb board

This patch adds the cpu-supply property so that cpu can do dvfs

Change-Id: I6cfc1c8e467652ad9b748c6a9980b00006181910
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
7 years agoARM: dts: rk3229: add cpu-supply property for cpu node in echo-v1 board
Finley Xiao [Thu, 11 May 2017 03:37:31 +0000 (11:37 +0800)]
ARM: dts: rk3229: add cpu-supply property for cpu node in echo-v1 board

This patch adds the cpu-supply property so that cpu can do dvfs

Change-Id: I5edff7fabd1de23407e8fcb7d70e3b0eeee2ee0e
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>