Commit Graph

610950 Commits

Author SHA1 Message Date
Finley Xiao
56707bc0df clk: rockchip: px30: Set max parent rate for uart fractional divider
Change-Id: Ia77fe3a34de60246ed43c1e43e60ec6fb15dcb19
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2018-08-08 18:16:14 +08:00
Dingqiang Lin
125b3c4345 drivers: rkflash: add new spi flash
1.SPI nand including HYF, MXIC, XTX
2.SPI nor including XMC, ESMT, MXIC

Change-Id: I35197254e70f65ad85475a8f952ea24111e3499a
Signed-off-by: Dingqiang Lin <jon.lin@rock-chips.com>
2018-08-08 12:56:21 +08:00
Dingqiang Lin
3cf664dd57 drivers: rkflash: make printk macro configurable
Change-Id: If4b768f0ebe8186a79b08ec424fd0b70a79f9c83
Signed-off-by: Dingqiang Lin <jon.lin@rock-chips.com>
2018-08-08 09:38:55 +08:00
Wyon Bi
f377325281 drm/rockchip: rgb: Fix connector type
Change-Id: I4d4f76b21f2e805f68961416fe8caffd22e529e4
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
2018-08-07 11:13:25 +08:00
Wyon Bi
654b9da60f drm/rockchip: dsi: Remove hardcode link skew
Change-Id: I73e4bbd89e0c688ce708d009526221312bce27d5
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
2018-08-07 11:07:28 +08:00
Wyon Bi
bd920c36fc drm/rockchip: dsi: Don't hardcode/bypass phy default parameters
The parameters of Synopsys PHY is programmed with the default values
for the corresponding hsfreqrange (test code 8'h44, HS RX Control of Lane 0)

Change-Id: I92c6bb0a9cad55e7b1695ca600f9c68804361dac
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
2018-08-07 11:07:28 +08:00
Jian Qiu
c3a9c958ae arm64: dts: rockchip: px30-android: update bootargs
Remove androidboot.selinux=permissive

Change-Id: I6c5ff0a1abd8c4356408f14d68df8ecc1515b7a4
Signed-off-by: Jian Qiu <qiujian@rock-chips.com>
2018-08-07 10:21:25 +08:00
Zhen Chen
18166b6556 Mali: midgard: set "FMODE_UNSIGNED_OFFSET" bit in file flags of mali device file
According to commit "mmap: introduce sane default mmap limits"

Change-Id: I96bc78053c06fdeaef178662dda36770da867436
Signed-off-by: Zhen Chen <chenzhen@rock-chips.com>
2018-08-07 09:50:37 +08:00
Tao Huang
6b20cfbfee Revert "UPSTREAM: ANDROID: binder: remove 32-bit binder interface."
This reverts commit 9ffd98e815.
Which breaks 32bit Android <9
Make ANDROID_BINDER_IPC_32BIT depends on ANDROID_VERSION.

Change-Id: Ie599606ce998b27342471f31d1480d0a87135375
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2018-08-06 18:29:25 +08:00
Hu Kejun
97fd046dc2 media: rockchip: isp1: adjust isp clk by pixel rate of sensor
Change-Id: I47e56b330a8f93f77cbeadd30dde97909ef18379
Signed-off-by: Hu Kejun <william.hu@rock-chips.com>
2018-08-06 15:32:53 +08:00
Sugar Zhang
0fb42422c0 ASoC: rk3308_codec: set fmt for all adcs
This patch fixup codec slave mode work abnormal, it is
because the mode bits have not been set. and whatever,
all adcs' fmt should be the same.

Change-Id: Ie5ea7cdddc25c41790797fd2b4ef760a1f2ed727
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2018-08-03 17:28:23 +08:00
Hu Kejun
bca2464422 media: i2c: modify pixel rate of ov13850/ov4689
Change-Id: I4057edc2cb2292ef17f88c5a5787ec777deabe20
Signed-off-by: Hu Kejun <william.hu@rock-chips.com>
2018-08-03 16:42:08 +08:00
Cai YiWei
b628af5d2f media: rockchip: isp1: add suspend/resume to detach/attach isp iommu
when system goto suspend, isp will be powered off,
isp iommu will be disabled, need to attach on resume,
detach on suspend.

Change-Id: I2b5e775b44d2b72df4ddcf2db12b54518c3e1f2e
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2018-08-03 16:35:43 +08:00
Algea Cao
466bcfab4f ARM64: dts: rockchip: rk3328: assign dclk parents for vop
Change-Id: Ie3a5d9dc9aad105deb2f7ac1d1d15494512d42f3
Signed-off-by: Algea Cao <algea.cao@rock-chips.com>
2018-08-03 16:34:57 +08:00
Yao Xiao
747439a9e6 net: rockchip_wlan: rtl8189fs: support gpio to wake up for wowlan
Change-Id: I7500c96d21c07c453e4dd6e81a393c08f48728f7
Signed-off-by: Yao Xiao <xiaoyao@rock-chips.com>
2018-08-03 16:32:24 +08:00
CanYang He
16d318c502 arm64: dts: rockchip: prevent some lp4 scale frequency for rk3399 evb3 lp4
lpddr4 scale frequency when display on, cause the display shake and
vop POST_BUF_EMPTY

Change-Id: I2bfef85ae34c3c85609dcb3506272ff0e27cb0c7
Signed-off-by: CanYang He <hcy@rock-chips.com>
2018-08-03 16:30:23 +08:00
Dingqiang Lin
a4b255f987 drivers: rkflash: add 25Q64JVSSIQ and 25Q64FWSSIG nor devices
Change-Id: I3b646acd838b22ce6ab49933454eacb4822e0fa8
Signed-off-by: Dingqiang Lin <jon.lin@rock-chips.com>
2018-08-03 11:11:12 +08:00
Jianqun Xu
e1f1329235 dt-bindings: pinctrl: rockchip: Add pinctrl support for rk1808
Add pinctrl support for RK1808 SoCs.

Change-Id: I6f198904c3481b65a3e04c3b687bde7965268e09
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2018-08-03 11:08:54 +08:00
Elaine Zhang
ce94c78340 clk: rockchip: add dt-binding header for rk1808
Add the dt-bindings header for the rk1808, that gets shared between
the clock controller and the clock references in the dts.
Add softreset ID for rk1808.

Change-Id: I0eef08655037daeab92560f36e06fde4032ddd0c
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2018-08-03 11:08:06 +08:00
David Wu
ea3d412563 arm64: dts: rockchip: Add pwm node for rk1808
Change-Id: Idc7682b5badda2c1d522152bb7cca2b80a4a1139
Signed-off-by: David Wu <david.wu@rock-chips.com>
2018-08-03 11:05:24 +08:00
David Wu
a69c844831 arm64: dts: rockchip: Add i2c nodes for rk1808
Change-Id: Idc9fe2e7b339dd30d770b1fe832bb170a670b393
Signed-off-by: David Wu <david.wu@rock-chips.com>
2018-08-03 11:05:24 +08:00
Tao Huang
40aa66fc68 Merge tag 'lsk-v4.4-18.07-android' of git://git.linaro.org/kernel/linux-linaro-stable.git
LSK 18.07 v4.4-android

* tag 'lsk-v4.4-18.07-android': (254 commits)
  Linux 4.4.143
  net/nfc: Avoid stalls when nfc_alloc_send_skb() returned NULL.
  rds: avoid unenecessary cong_update in loop transport
  KEYS: DNS: fix parsing multiple options
  netfilter: ebtables: reject non-bridge targets
  MIPS: Use async IPIs for arch_trigger_cpumask_backtrace()
  MIPS: Call dump_stack() from show_regs()
  rtlwifi: rtl8821ae: fix firmware is not ready to run
  net: cxgb3_main: fix potential Spectre v1
  net/mlx5: Fix command interface race in polling mode
  net_sched: blackhole: tell upper qdisc about dropped packets
  vhost_net: validate sock before trying to put its fd
  tcp: prevent bogus FRTO undos with non-SACK flows
  tcp: fix Fast Open key endianness
  r8152: napi hangup fix after disconnect
  qed: Limit msix vectors in kdump kernel to the minimum required count.
  net: sungem: fix rx checksum support
  net/mlx5: Fix incorrect raw command length parsing
  net: dccp: switch rx_tstamp_last_feedback to monotonic clock
  net: dccp: avoid crash in ccid3_hc_rx_send_feedback()
  ...

Fix wrong merge of include/linux/compiler-gcc.h

Change-Id: I1daae1251069d2791d2e29b65942d086fb8ad0ac
2018-08-03 10:09:13 +08:00
Li Huang
9e065854a5 video/rockchip: rga: Remove MMU struct unuse member
it will set alpha_rop_mode to 0, fixup rga blend error.

Change-Id: I6c10df0e4d198ab8da8d352239151ddc3605e860
Signed-off-by: Li Huang <putin.li@rock-chips.com>
2018-08-03 09:37:44 +08:00
Hu Kejun
fad2756f8c media: rockchip: isp1: fix dq timeout
After enter->capture->video->exit->enter ...... long time test,
the shadow register of mi buffer base address can't update
automatically any more.

In application layer, we will get dq timeout error log.

Add CIF_IRCL_MI_SW_RST in rkisp1_isp_stop can fix this bug.

Change-Id: I386d6b2d2c3882fc76eb9f7283e1bc2309ee3210
Signed-off-by: Hu Kejun <william.hu@rock-chips.com>
2018-08-03 09:33:02 +08:00
Boris Brezillon
01eef91312 UPSTREAM: leds: pwm: Use pwm_get_args() where appropriate
The PWM framework has clarified the concept of reference PWM config (the
platform dependent config retrieved from the DT or the PWM lookup table)
and real PWM state.

Use pwm_get_args() when the PWM user wants to retrieve this reference
config and not the current state.

This is part of the rework allowing the PWM framework to support
hardware readout and expose real PWM state even when the PWM has just
been requested (before the user calls pwm_config/enable/disable()).

Change-Id: I8286b16dc8d828ba8a66a17675fe6fbedcba480b
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Acked-by: Jacek Anaszewski <j.anaszewski@samsung.com>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
(cherry picked from commit 1b50673dfa)
2018-08-02 19:43:16 +08:00
William Wu
cbc9f84034 ARM: rockchip_defconfig: enable usb configfs uvc
Change-Id: Iccb30e546eecc90ceaa5e4e3039c2f29f2542bde
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
William Wu
825a3df1a8 arm64: rockchip_defconfig: enable usb configfs uvc
Change-Id: Iade4b2959450e51cb1f75b1b4b1ccbe9cc3fc2e3
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
William Wu
af0dd3d28b usb: gadget: uvc: fix bFrameIndex of streaming interface descriptor
The bFrameIndex of video streaming interface descriptor
is initialized to 1 in uvcg_frame_make(), but never be
setted for different frame resolutions, this cause host
to fail to select the correct frame resolution. This patch
increases the bFrameIndex in order.

Change-Id: Ic0609976e09d9e3d6f82595c00e2ac7b356e4f5f
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
William Wu
23f0e17a96 usb: dwc_otg_310: do not clear nak when prepare for setup packet
When prepare setup packet, don't clear nak before call
ep0_out_start(), because clear nak will make the usb
core to handle OUT transaction immediately without
NAK response, this may cause OUT transaction fail.

We can reproduce this issue in the following two case:
 - Configure usb device as rndis, connect to Windows PC;
 - Configure usb device as uvc, connect to Windows PC,
   and take still image;

Use the usb analyzer to capture data in case2,we can
easily to find the problem.

Without this patch, the Class request OUT transfer is:
 - SETUP transaction
 - OUT transaction
   - OUT packet
   - DATA1 packet
   - ACK pakcet
 - IN transactions
   - IN packet
   - NAK packet (response NAK forever)

With this patch, the Class request OUT transfer is:
 - SETUP transaction
 - OUT transaction
   - OUT packet
   - DATA1 packet
   - NAK packet
 - PING transactions
 - OUT transaction
   - OUT packet
   - DATA1 packet
   - ACK pakcet
 - IN transaction
   - IN packet
   - DATA1 packet
   - ACK pakcet

Change-Id: I5ea915bc425ffa2f2a06a1a830f6f88725c94b03
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
William Wu
6e1353425b usb: dwc_otg_310: do not stop isoc ep transfer when ep dequeue
When dequeue req which already queued on the endpoint,
don't stop the transfer and also don't flush the Tx FIFO
for isoc endpoint, otherwise, it may fail when set NAK
bit and disable ep in dwc_otg_pcd_ep_stop_transfer().

Change-Id: Ib3c1215f9c9507c08cc12c966456209384811b6d
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
William Wu
f0cdce4eaa usb: dwc_otg_310: use wait-till-ready timeout loop for ep deactivate
In some error case, it may fail to set the NAK bit
or Disable bit for endpoint when do ep deactivate
operation. We need to use wait-till-ready timeout
loop for ep deactivate instead of while loop.

Change-Id: I0e5ed61b2528f89910333c5eb907677e492fe3a0
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
William Wu
94ddeb4fa9 usb: dwc_otg_310: reinit isoc ep frame num when dequeue
The frame num of isoc ep is initialized to 0xFFFFFFFF in
ep_enable and start_next_request(), and then in the NAK
interrupt handler, it will check if the ep frame num is
0xFFFFFFFF, then reset the frame num to 0 and start next
request.

But if we dequeue the isoc ep request if it's already
enqueued, if may fail to call complete_ep() -> start_
next_request(), so the isoc ep frame num can't be reinit
to 0xFFFFFFFF, this cause NAK interrupt handler check
the frame num incorrectly, and fail to start next request.

Change-Id: Iab8526f6e3979347bdbe6c49525ec0ba8130d4bc
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
William Wu
160f9f6f0a usb: dwc_otg_310: don't print info when start zl transfer
The dwc_otg_ep_start_zl_transfer() can be called from irq
handler in the top half, so don't print additional log to
avoid wasting too much time in interrupt handling.

If someone needs to dump verbose log, just set the debug
level to appropriate value.

Change-Id: If6fb8a22e0c42fb2b629c3a82d8e632254434784
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
Frank Wang
4b72b4c39f usb: dwc_otg_310: fix usb devices reconnect failed
Sometimes we found the usb device could not connect to the HUBs when
the cable plug in and out constantly, the root cause is "USB RESET"
was missed from these HUBs, and we only try 2 times to reconnect.

This patch as one workaround to increase reconnect times to 6, and
add the delay time (3.5ms-4ms) after DCTL.SftDiscon bit was clear.

Change-Id: I57cfe5dc68e6d3d67c20771423dae29542ed047d
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
William Wu
02ac9b28b5 usb: dwc_otg_310: set transmit threshold length to 16 DWORDS
According to DWC2 databook V3.10a, 5.3.5.14 Device Threshold
Control Register (DTHRCTL), it recommends that the Transmit
Threshold Length (TxThrLen) is to be the same as the programmed
AHB Burst Length (GAHBCFG.HBstLen), on Rockchip platform the
value is 16.

Change-Id: I6427e3a3fc7b57e85229cdf4b9c5fff878b919b6
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
Frank Wang
5e5c15bd6a usb: dwc_otg_310: amend last_id property to support PM suspend
Move last_id property from static to struct dwc_otg_device as a static
global variable to support PM suspend process.

Change-Id: I7729095339aed3dcca6481005f249c855ebbdb3c
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Signed-off-by: William Wu <william.wu@rock-chips.com>
2018-08-02 19:21:39 +08:00
William Wu
6b9332d6e9 usb: dwc_otg_310: pcd: don't print info if no more ISOC requests
Change-Id: I672f3246cd14e6978fec6c62f471e16b2a3863bd
Signed-off-by: William Wu <wulf@rock-chips.com>
2018-08-02 19:21:39 +08:00
William Wu
799e7f1c33 usb: dwc_otg_310: support high bandwidth endpoints
According to 'DesignWare Cores USB 2.0 Hi-Speed On-The-Go (OTG)
Programmer's Guide' 2.1.3.3 Dedicated FIFO Mode with Thresholding,
We can use threshold to support the following case:

1. To have a smaller FIFO size;
2. To have faster DMA response;

The threshold is useful for rockchip platforms which has a smaller
FIFO size and try to support three isochronous back-to-back packets
(high bandwidth).

And we also need to set GAHBCFG.HBstLen to INCR16 for high bandwidth
endpoints. If you want to support high bandwidth endpoints, it needs
to add a new property 'rockchip,high-bandwidth' in dts usb node.

Change-Id: I0c1d373cdaa51f22c15484912b752fb0b6ad4b9c
Signed-off-by: William Wu <wulf@rock-chips.com>
2018-08-02 19:21:39 +08:00
Finley Xiao
846fbdc826 arm64: dts: rockchip: rk3399: Change vdd_log to 900000uV
As 900000uV is enough for vdd_log.

Change-Id: I05194a4071aba066683f48e04c1d467f54bc77dc
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2018-08-02 19:20:43 +08:00
Finley Xiao
026df77241 arm64: dts: rockchip: Change vdd_log to 900000uV for rk3399-sapphire
As 900000uV is enough for vdd_log.

Change-Id: I479a857735e4f49141322e7635dea7c1bee0e118
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2018-08-02 19:20:43 +08:00
Wyon Bi
9f63cec05b drm/rockchip: rgb: Fix pinctrl handling
Change-Id: I473f51993b97b3f597d906044d4d61e1af2cf5a7
Signed-off-by: Wyon Bi <bivvy.bi@rock-chips.com>
2018-08-02 18:57:49 +08:00
Sugar Zhang
7c519d6367 arm64: configs: rk3308_linux_defconfig: enable spdifrx
Change-Id: I07924238245bf07be4089774244ddc579937b547
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2018-08-02 18:57:29 +08:00
Sugar Zhang
1c6a0b6fde arm64: dts: rockchip: rk3308-evb-*: add spdifrx sound
Change-Id: I90a91f9d3364d8eeb3f1c8e757a682fe079c8150
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2018-08-02 18:57:29 +08:00
Sugar Zhang
065f1b01c9 arm64: dts: rockchip: rk3308: add spdifrx node
Change-Id: I3a2423ae362b169b870afb7d8b2d2414a2297ec1
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2018-08-02 18:57:29 +08:00
Sugar Zhang
4c9189ae95 ASoC: rockchip: add support for spdif receiver
The SPDIF receiver is a self-clocking, serial, unidirectional
interface for the interconnection of digital audio equipment
for consumer and professional applications.

Change-Id: Ic73337671b37c8c45352e523a875281edd552d1b
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2018-08-02 18:57:29 +08:00
Huibin Hong
628b6a666d arm64: dts: rockchip: remove unused #dma-cells for rk3328
Change-Id: I936f240665b5c905e0af41a3e9dd97e0b7379473
Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
2018-08-02 18:56:02 +08:00
Huibin Hong
ce8a0ab67f arm64: dts: rockchip: remove unused #dma-cells for rk3308
Change-Id: I74edbf82a77e1aaccc75c196ed70714fa0182787
Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
2018-08-02 18:56:02 +08:00
Huibin Hong
884fc81020 arm64: dts: rockchip: remove unused #dma-cells for px30
Change-Id: Ibb85ffe525246285e54bb034b8acbf66025516ba
Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
2018-08-02 18:56:02 +08:00
allon.huang
e8f7b6378a media: rockchip: mipi: reorder mipi dphy configuration sequence
Reorder mipi configuration sequence for rk3288/rk3399
according to ip reference

Add comments to explain the sequence and running state

All mipi phy1 are controlled by isp

Change-Id: Ib5ad9edac4229acb5fa7f2088a9601d210a816f4
Signed-off-by: Allon Huang <allon.huang@rock-chips.com>
2018-08-02 14:05:02 +08:00
Finley Xiao
16a6e0b5ba arm64: dts: rockchip: rk3308: Raise voltage for 1008MHz, 1200MHz and 1296MHz
In order to cover the chips passed cp test program(1.3g 1.175v).

Change-Id: I4e19aefd914258e8d1e6d331b6f584aa7d0c4822
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2018-08-01 21:07:10 +08:00