Commit Graph

847432 Commits

Author SHA1 Message Date
William Wu
dc70652f46 usb: gadget: f_uac2: fix some issues for Windows recognized
We find that the UAC2 gadget can't be recognized on Windows 10.
It's because that the descriptors of UAC2 doesn't meet the
requirements of Windows.

According to the USB Audio 2.0 Drivers of Windows [1], if the
bmAttributes of OUT-EP in the audio stream interface is set
to asynchronous (use USB_ENDPOINT_SYNC_ASYNC), then a feedback
endpoint must be implemented in the respective alternate setting
of the AS interface. The Windows driver does not support implicit
feedback.

However, it's difficult to implement the feedback endpoint now.
So the patch changes the bmAttributes of OUT-EP to adaptive, and
changes the bmAttributes of IN-EP to synchronous at the same time.

This patch also sets the wTerminalType of terminal descriptor to
microphone and speaker by default.

With this patch, we also fix the wTotalLength of the ac_hdr_desc.

[1] https://docs.microsoft.com/en-us/windows-hardware/drivers/audio/usb-2-0-audio-drivers

Change-Id: I3597d5f321235fcbce56dbfbfe95172d02e58892
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
Andreas Pape
01c1d8f735 UPSTREAM: usb: gadget: f_uac2: disable IN/OUT ep if unused
Via p_chmask/c_chmask the user can define whether uac2 shall support
playback and/or capture. This has only effect on the  created ALSA device,
but not on the USB descriptor. This patch adds playback/capture descriptors
dependent on that parameter.

Change-Id: I396b4238e6a8f2b4a32a57780acea4f23dc0c081
Signed-off-by: Andreas Pape <apape@de.adit-jv.com>
Signed-off-by: Eugeniu Rosca <erosca@de.adit-jv.com>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
Signed-off-by: William Wu <william.wu@rock-chips.com>
(cherry picked from commit 3fa4eaa6c0)
2019-11-14 11:15:51 +08:00
William Wu
f3db2b6e55 usb: uas: ignore UAS for Seagate Expansion Portable Drive
The Seagate Expansion Portable Drive HDD (idVendor=0bc2, idProduct=2321) is reported to fail to work on rockchip platforms
with the following error message when do read/write operation by dd command:

xhci-hcd xhci-hcd.11.auto: Ring expansion failed

According to tkaiser's suggestion[1], we can try to increase the kernel's
coherent-pool memory size to fix this issue. The kernel coherent-pool memory
size was limited at 256KB by default. When set the DEFAULT_DMA_COHERENT_POOL_SIZE
to 1MB, the error "Ring expansion failed" can be fixed, but it still not
work with the other error message:

xhci-hcd xhci-hcd.12.auto: ERROR Unknown event condition 34 for slot 1 ep 3 , HC probably busted
sd 0:0:0:0: [sda] tag#16 uas_eh_abort_handler 0 uas-tag 17 inflight: CMD OUT
...
scsi host0: uas_eh_bus_reset_handler start
xhci-hcd xhci-hcd.12.auto: ERROR Transfer event for disabled endpoint slot 1 ep 6 or incorrect stream ring

Falling back to USB mass storage can solve this problem, so ignore UAS
function of this HDD.

[1] https://forum.armbian.com/topic/4811-uas-mainline-kernel-coherent-pool-memory-size/

Change-Id: I0d817cc3aaea548c2060b323c3077c6cbbd3bb6e
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
Wu Liang feng
349bb1466b usb: gadget: accessory: add compat_ioctl
Add compat_ioctl for accessory to work on 64-bit platforms.

Change-Id: I805395c35017111bf0c462847f11765c7088d266
Signed-off-by: Wu Liang feng <wulf@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
ccc5c5b34c usb: gadget: uvc: add compat_ioctl
This allows 32 bit owners of uvc video to make ioctls
into a 64 bit kernel.

All of the current uvc ioctls can be handled with the
same struct definitions as regular ioctl.

Change-Id: Ia31b26147ab619f0673f94b6662eaf181a9eb5dd
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
cbb0b7c4f6 phy: rockchip-inno-combphy: avoid reinit usb3 phy
When the combphy work as USB3 PHY (e.g. RK1808 EVB USB3 port),
the PHY init and exit ops are called dynamically in the runtime
process of USB3 controller driver.

Because it only needs to init the USB3 PHY once in the PHY init,
and reinit the USB3 PHY in the runtime process may cause USB3 work
abnormally, so this patch doesn't clear the phy_initialized flag
for USB3 in the PHY exit ops.

Change-Id: Ifc2eb3edac25bd10db6d47b4c9e197cc15c4aef7
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
a69578350c usb: storage: add Genesys Logic 05e3:0749 to unusual_devs.h
When test more than three Genesys Logic usb3 storages
(VID : PID = 0x05e3 : 0x0749) on rockchip platforms with
usb3 host port (e.g. rk3328/rk3399) at the same time,

test commands like this:
for dev in `ls /dev/sd?1 | sed -e 's,1$,,'`; do
	echo dd if=$dev of=/dev/null
	dd if=$dev of=/dev/null &
	sleep 1
done

The test fail with the following error log:
xhci-hcd xhci-hcd.9.auto: xHCI host not responding to stop endpoint command.
xhci-hcd xhci-hcd.9.auto: Assuming host is dying, halting host.
xhci-hcd xhci-hcd.9.auto: Host not halted after 16000 microseconds.
xhci-hcd xhci-hcd.9.auto: Non-responsive xHCI host is not halting.
xhci-hcd xhci-hcd.9.auto: Completing active URBs anyway.
xhci-hcd xhci-hcd.9.auto: HC died; cleaning up

This patch sets the max_sectors to 128 (64K) to workaround
this issue, and it doesn't affect the transmission rate.

Change-Id: Idd9cc81659d27c12b142f6c4375558c2262e800d
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
e33b4f652b usb: gadget: f_uvc: add extension unit descriptor
Add extension unit descriptor for uvc. Support 3
controls in this extension unit. The rockchip IQ
tool use it to transfer vendor specific control
data.

Change-Id: I219e12616629bc75548b30ce63d46136aeac6561
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
e93bc82bf2 usb: quirks: add quirk for Kingston DataTraveler 3.0 with broken LPM
Kingston DataTraveler 3.0 sometime would be disconnected
or not be enumerated successfully by xHCI controller when
LPM was enabled.

This patch adds an USB_QUIRK_NO_LPM quirk for this device.

Change-Id: I8ffa8d46ee242ab9665ce70565df7718b20ca87c
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
d0365ad742 dt-bindings: phy: rockchip: add support of rk1808 usb
Support rockchip,rk1808-usb2phy-grf for rk1808 board.

Change-Id: I9f3cc8300bf2653689c07734b81bcf7ff9aac4eb
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
a8f399e965 usb: uas: Add JMicron JMS583 and CHIPFANCIER to unusual device
These two devices give the following error on detection.
Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
xhci-hcd xhci-hcd.5.auto: ERROR Transfer event for disabled endpoint
or incorrect stream ring

The same error is not seen when it is added to unusual_device
list with US_FL_NO_REPORT_OPCODES and US_FL_BROKEN_FUA passed.

Change-Id: Ia1035ea597c65ad7112f68f5cbdd792875ee2995
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
154e7b74ec 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>
2019-11-14 11:15:51 +08:00
William Wu
9bf1f56462 usb: gadget: f_uac1_legacy: set period size and buffer size
The default period size is only 64 frames, this
will cause usb audio playback with noise via
internal audio codec. This patch sets the period
size to (snd->rate / 10), and also sets the buffer
size to snd->rate.

Change-Id: I4a4eb1b4dd79aec65f5c44eacd8a2fa101dfbd1b
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
200de9028d usb: gadget: f_uac1_legacy: disable ep in f_audio_disable()
The f_audio_disable() doesn't disable usb ep, and
this cause usb enumeration fail. So add usb ep
disable operation.

This patch also reinitializes the opts->bound flag
to false in f_audio_free(), and then it can setup
ALSA audio device again in f_audio_bind().

Change-Id: I7b10630f5085b1a03792bc4b9e7eabb02d2bd5a2
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
7ce0853813 uvcvideo: add quirk for dev parent with broken auto suspend
If the parent of uvc device has a quirk for broken
auto-suspend function (e.g. rk3328 usb 3.0 root hub),
we also need to disable auto-suspend for the uvc device.

Change-Id: Ida8d05a411f49f39e13cad3ec837a56598b4a630
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
Meng Dongyang
fe8c3cd311 usb: gadget: configfs: send connect detective event when get descriptor
In current code, the connect detective event will be send before the
connect state of controller change. The event is sent when receive
the first setup packet and the connect state of controller is changed
when receive set address command. So if disconnect interrupt trigger
between the first setup packet and set address command, the disconnect
process will not be done, while the application state has been changed
and keep in connected. As a result, the UI may still show the USB connect
option event if the device has been disconnect from PC. This patch send
the connect uevent when get descriptor of configuration which follow
set address command to make sure the application state change after
controller.

Change-Id: Icf2124327db93687b4b644672edb0dbecc8f127a
Signed-off-by: Meng Dongyang <daniel.meng@rock-chips.com>
2019-11-14 11:15:51 +08:00
Meng Dongyang
6bcccf1b5b dt-bindings: rockchip: usb: Document for px30
Change-Id: I3d1ca71cad98226999dd115f515df4a31b095ee1
Signed-off-by: Meng Dongyang <daniel.meng@rock-chips.com>
2019-11-14 11:15:51 +08:00
Frank Wang
d92128c853 phy: rockchip: disable commononn for ehci-phy on rk3288
We found that the system was blocked in EHCI when perform suspend or
reboot on RK3288 platform, the root cause is that EHCI (auto) suspend
causes the corresponding usb-phy into suspend mode which would power
down the inner PLL blocks in usb-phy if the COMMONONN is set to 1'b1.

The PLL output clocks contained CLK480M, CLK12MOHCI, CLK48MOHCI, PHYCLOCK0
and so on, these clocks are not only supplied for EHCI and OHCI, but also
supplied for GPU and other external modules, so setting COMMONONN to 1'b0
to keep the inner PLL blocks in usb-phy always powered.

Change-Id: Ifb7f3d233cf72155aa54d20b15a62b683944a526
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2019-11-14 11:15:51 +08:00
Douglas Anderson
23bcddc7ff FROMLIST: phy: rockchip-typec: Try to turn the PHY on several times
Bind / unbind stress testing of the USB controller on rk3399 found
that we'd often end up with lots of failures that looked like this:

  phy phy-ff800000.phy.9: phy poweron failed --> -110
  dwc3 fe900000.dwc3: failed to initialize core
  dwc3: probe of fe900000.dwc3 failed with error -110

Those errors were sometimes seen at bootup too, in which case USB
peripherals wouldn't work until unplugged and re-plugged in.

I spent some time trying to figure out why the PHY was failing to
power on but I wasn't able to.  Possibly this has to do with the fact
that the PHY docs say that the USB controller "needs to be held in
reset to hold pipe power state in P2 before initializing the Type C
PHY" but that doesn't appear to be easy to do with the dwc3 driver
today.  Messing around with the ordering of the reset vs. the PHY
initialization in the dwc3 driver didn't seem to fix things.

I did, however, find that if I simply retry the power on it seems to
have a good chance of working.  So let's add some retries.  I ran a
pretty tight bind/unbind loop overnight.  When I did so, I found that
I need to retry between 1% and 2% of the time.  Overnight I found only
a small handful of times where I needed 2 retries.  I never found a
case where I needed 3 retries.

I'm completely aware of the fact that this is quite an ugly hack and I
wish I didn't have to resort to it, but I have no other real idea how
to make this hardware reliable.  If Rockchip in the future can come up
with a solution we can always revert this hack.  Until then, let's at
least have something that works.

This patch is tested atop Enric's latest dwc3 patch series ending at:
  https://patchwork.kernel.org/patch/10095527/
...but it could be applied independently of that series without any
bad effects.

For some more details on this bug, you can refer to:
  https://bugs.chromium.org/p/chromium/issues/detail?id=783464

Change-Id: I7909731247739694f56bf89ab3064889f2b34d3c
Signed-off-by: Douglas Anderson <dianders@chromium.org>
Signed-off-by: William Wu <william.wu@rock-chips.com>
(am from https://patchwork.kernel.org/patch/10105833/)
2019-11-14 11:15:51 +08:00
William Wu
f33248649a usb: quirks: add device quirk for Sonix FaceBlack device
We found that some Sonix usb cameras(e.g. idVendor=0c45,
idProduct=64ab or idProduct=64ac) can't support auto-suspend
well on rockchip platforms(e.g. rk3399).With auto-suspend,
these usb cameras MJPEG will display abnormally on all usb
controllers(DWC2/DWC3/EHCI). So we need to disable auto-
suspend for these special usb cameras.

Change-Id: I08c87cf5c9fa5ebe076b5dd3e873b74c5ec2cb83
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
William Wu
0c4afad15b usb: quirks: add device quirk for HD Camera PID 0x9320
The commit 62b2a34a21 ("uvcvideo: add quirk for devices
with broken auto suspend") introduced quirk to workaround
an issue with some HD Cameras.

There is one more model that has the same issue - idProduct
=0x9320, so applying the same quirk as well.

Change-Id: I24e3fc1746a9d21d529bc91f52fd5822e998bd93
Signed-off-by: William Wu <william.wu@rock-chips.com>
2019-11-14 11:15:51 +08:00
Wu Liang feng
1c31f7e10e uvcvideo: add quirk for devices with broken auto suspend
We found that some usb cameras(e.g. Manufacturer: HD Camera
Manufacturer, idVendor=05a3, idProduct=9230) can't support
auto-suspend well on rockchip platforms. With auto-suspend,
these usb cameras MJPEG will display abnormally on all usb
controllers(DWC2/DWC3/EHCI). So we need to disable auto
suspend for these special usb cameras.

Change-Id: Ibf50ed77edff0012a112dc42f09e022055908829
Signed-off-by: Wu Liang feng <wulf@rock-chips.com>
2019-11-14 11:15:51 +08:00
William wu
28150775bf CHROMIUM: xhci: stop roothub port polling timer in shutdown
The xhci hcd use the port polling timer (rh_timer) to poll the
roothub for port events. But we can't allow the USB core to poll
the port events during shutdown because the xhci controller may
be disable and can't be accessed in shutdown. If we access xhci
port registers with port polling timer after xhci shutdown, it
may cause kernel crash or unexpected behavior. So we need to stop
the port polling timer while shutdown xhci.

I can easily reproduce the issue on rk3399 platform, plug in a
Type-C hub and an USB ethernet dongle, then do reboot test,
result in a crash with the following backtrace.

Unhandled fault: synchronous external abort (0x96000010) at 0xffffff80002f0430
Internal error: : 96000010 [#1] PREEMPT SMP
task: ffffffc001092cb0 ti: ffffffc00107c000 task.ti: ffffffc00107c000
PC is at xhci_hub_status_data+0xec/0x1e4
LR is at xhci_hub_status_data+0xb0/0x1e4
[<ffffffc00067a210>] xhci_hub_status_data+0xec/0x1e4
[<ffffffc00063ebf8>] usb_hcd_poll_rh_status+0x54/0x148
[<ffffffc00063ed0c>] rh_timer_func+0x20/0x2c
[<ffffffc0002845cc>] call_timer_fn+0xa4/0x1c8
[<ffffffc000284964>] run_timer_softirq+0x248/0x2cc
[<ffffffc000200928>] __do_softirq+0x178/0x338
[<ffffffc000224b08>] irq_exit+0x78/0xc0
[<ffffffc00027089c>] __handle_domain_irq+0x9c/0xbc
[<ffffffc0002006f4>] gic_handle_irq+0xcc/0x188

BUG=chrome-os-partner:59111
TEST=Plug in a Type-C hub, then do reboot test, check if
kernel crash during shutdown.

Change-Id: I3ca3d12d101241cd78138ea5d995708a2893d1a0
Signed-off-by: William wu <wulf@rock-chips.com>
Reviewed-on: https://chromium-review.googlesource.com/401121
Commit-Ready: Guenter Roeck <groeck@chromium.org>
Tested-by: Guenter Roeck <groeck@chromium.org>
Reviewed-by: Guenter Roeck <groeck@chromium.org>
2019-11-14 11:15:51 +08:00
William wu
1f35d62f3c CHROMIUM: xhci: do shutdown only hcd is registered
On some sepcial platforms (e.g. rk3399 platform), they will call
usb_remove_hcd() to remove xhci hcd if no device connected, and
also call xhci_stop() to halt and reset xhci. So we don't need to
do the same thing in shutdown if hcd has been unregistered.

In addition to remove hcd, rk3399 platform will disable xhci power
domain in runtime suspend, if we try to access xhci registers in
shutdown, it might cause kernel crash or unexpected behavior.

BUG=chrome-os-partner:59111
TEST=reboot the system

Change-Id: I7ecfce068211ff1c4a884fc4a8a54ca5b84c1c09
Signed-off-by: William wu <wulf@rock-chips.com>
Reviewed-on: https://chromium-review.googlesource.com/401120
Commit-Ready: Guenter Roeck <groeck@chromium.org>
Tested-by: Guenter Roeck <groeck@chromium.org>
Reviewed-by: Guenter Roeck <groeck@chromium.org>
2019-11-14 11:15:51 +08:00
William wu
c60f89c1dd CHROMIUM: usb: xhci-plat: use usb_hcd_platform_shutdown() callback
The xhci driver provides xhci_shutdown() to be called with the main
usb_hcd (the USB3 roothub) while do reboot. But actually, xhci-plat
never call xhci_shutdwon() during reboot because it doesn't use the
usb_hcd_platform_shutdown() helper.

So we use the usb_hcd_platform_shutdown() for xhci-plat, and the
normal shutdown call trace is:
kernel_restart -> kernel_restart_prepare -> device_shutdown ->
platform_drv_shutdown -> usb_hcd_platform_shutdown -> xhci_shutdown

BUG=chrome-os-partner:59111
TEST=reboot the system

Change-Id: I9be424257ea6ba1e51521cbdd01f4698ae1752ad
Signed-off-by: William wu <wulf@rock-chips.com>
Reviewed-on: https://chromium-review.googlesource.com/401119
Commit-Ready: Guenter Roeck <groeck@chromium.org>
Tested-by: Guenter Roeck <groeck@chromium.org>
Reviewed-by: Guenter Roeck <groeck@chromium.org>
2019-11-14 11:15:51 +08:00
Meng Dongyang
a15255ee43 Documentation: bindings: add DT documentation for u2phy and u2phy grf
Due to the u2phy registers are separated from general grf, we need to
add u2phy grf node and place u2phy node in it. And on some platform,
the 480m clock may need to assign clock parent in dts in stead of
clock driver. So this patch add u2phy grf node and property of
assigned-clocks and assigned-clock-parents to assign parent for 480m
clock.

Change-Id: I88e63745e38265814169136f079a00791f5813b3
Signed-off-by: Meng Dongyang <daniel.meng@rock-chips.com>
2019-11-14 11:15:51 +08:00
Meng Dongyang
0e16bcc09c usb: dwc3: gadget: change detemination method of connect status
In current code, the connect status will be set to connected state when
reset interrupt occur and change to disconnected state in disconnect
interrupt.

But the usb charger may bring about reset signal in accident if we
connect and disconnect quickly. In this case, the dwc3 controller will
change link state and set to connect status, yet not change to
disconnected state when disconnect. So the dwc3 controller suspend
fail and result in a mistake when quick reconnect.

This patch set connect status to connected state when transfer complete
to make sure that usb is connect to PC exactly.

Change-Id: I8e5894d2e08b88bb5434222100d8f5c91c9f1a9d
Signed-off-by: Meng Dongyang <daniel.meng@rock-chips.com>
2019-11-14 11:15:51 +08:00
Joseph Chen
2114bd9e7a mfd: rk808: update RK818_ID 0x8181 => 0x8180
Ignore minor variant.

Change-Id: I14f9ad54dc81f8980a67d618daa7a314684acc3e
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2019-11-14 10:46:07 +08:00
Joseph Chen
ffc406d1d8 power: rk818-charger: support temperature charge v2
Set charge current according to bat temperature and
the v1 is abandoned on kernel 4.19.

Change-Id: I6462e5de1c153c7f774136ef67a8a17a3c7fec8a
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2019-11-14 10:46:07 +08:00
Joseph Chen
c6884c2558 power: rk816-battery: support temperature charge v2
Set charge current according to bat temperature.

Change-Id: I409bf33614c9e689f7a85382d6033af6b18755e1
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2019-11-14 10:46:07 +08:00
Joseph Chen
bfa5dfb467 power: rk816-battery: remove unused lp chrg function
Change-Id: I1a73d96f2e594081b0a44fbe981d6bb95ccdfca7
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2019-11-14 10:46:07 +08:00
Bian Jin chen
4f29b1cfa6 Revert "HID: core: move Usage Page concatenation to Main item"
This reverts commit 69f67200cf.

Test: CtsHardwareTestCases
  android.hardware.input.cts.tests.AsusGamepadTestCase#testAllKeys

fail: java.lang.AssertionError: Press BUTTON_A expected:<96> but
 was:<0>

Link: https://lkml.org/lkml/2019/6/13/1796

Change-Id: Icc2ceacdb7e398177628127277b00995f1b1da38
Signed-off-by: Bian Jin chen <kenjc.bian@rock-chips.com>
2019-11-14 09:28:31 +08:00
Ding Wei
f6d4385501 arm64: dts: rockchip: rk3399: match new video driver for 4.19
Change-Id: I56ff3ed1c49cf3524c9fe9284021c611c1a4b76c
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-11-13 20:34:59 +08:00
Ding Wei
659df9c511 arm64: dts: rockchip: px30: match new video driver for 4.19
Change-Id: Iaa282a4d154cf85cdd4124c1affb5746795613e5
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-11-13 20:34:45 +08:00
Ding Wei
18da42b5ac arm64: rockchip_defconfig: add video codec configs
add configs:
CONFIG_ROCKCHIP_MPP_RKVDEC
CONFIG_ROCKCHIP_MPP_VDPU1
CONFIG_ROCKCHIP_MPP_VDPU2
CONFIG_ROCKCHIP_MPP_VEPU1
CONFIG_ROCKCHIP_MPP_VEPU2

Change-Id: I384690294c45c88b2a9125827cb796b15f9cdba0
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-11-13 20:31:25 +08:00
Ding Wei
7cfdfe11ab video: rockchip: add path for vcodec driver
driver codec path: rockchip/mpp/

Change-Id: I1599a83097ad4c3d2c444c14fa1484497781bc23
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-11-13 20:29:28 +08:00
Ding Wei
5b15717952 video: rockchip: mpp: new video codec driver
This video codec driver used in kernel 4.19 version,
which is a new design framework.
In this version, codecs integrate similar hardware,
so are divided into vdpux vepux rkvdec rkvenc vepu22,
and so on.

Change-Id: Ic29b28cef8fce394ac9f950472204c172842a2df
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-11-13 20:22:33 +08:00
Ding Wei
f641dbbc95 dt-bindings: video: mpp: Document for video codec driver
Change-Id: I93cceb183fac592e9ea7c67c62341955f4964a8c
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2019-11-13 20:17:26 +08:00
Tao Huang
5683e16730 arm64: rockchip_defconfig: cleanup by savedefconfig
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I1eddb6875ec980b711142a6035bedc0dd48edbe3
2019-11-13 14:34:24 +08:00
LuoXiaoTan
a8ba66fd5b ASoC: rockchip: add rt5651_tc358749x driver
add rockchip_rt5651_tc358749x machine driver to
support HDMIIn function

Change-Id: Ieb0e046bec60ea0a27ee49ce1204b032ad646724
Signed-off-by: Wu Liangqing <wlq@rock-chips.com>
Signed-off-by: LuoXiaoTan <lxt@rock-chips.com>
Conflicts:
	sound/soc/rockchip/Kconfig
	sound/soc/rockchip/Makefile
	sound/soc/rockchip/rockchip_rt5651_tc358749x.c
2019-11-13 14:29:13 +08:00
Meiyou Chen
94d6a092ba ASoC: rt5651: fix hdmi-in noise
Change-Id: I23aa42b4c0775be5595a67b61ffce23845d6079b
Signed-off-by: Meiyou Chen <cmy@rock-chips.com>
2019-11-13 09:08:25 +08:00
Tao Huang
71e82aa8ac media/video: remove unused rk29xx driver
Change-Id: Ib541502c16facc6f997336c29fb73b4480e3f387
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2019-11-12 18:42:06 +08:00
Elaine Zhang
95302cb671 drm/rockchip: add more clock protect for loader logo
fix up the px30 issue when enable DDR automatic frequency.

Change-Id: I3671f4be7a8408a3830cc707f5b947d136f3452b
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2019-11-12 11:00:09 +08:00
Joseph Chen
06c8049134 arm64: dts: rk3328-rock64: add vcc supply for pmic
Change-Id: I21e98126481e0e523fa3346fe4c925031c02dd76
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2019-11-11 18:07:56 +08:00
Joseph Chen
563162f65d arm64: dts: rk3328-evb-android: add vcc supply for pmic
Change-Id: Ia3ba82a92e79e8f05467ce1c783f80a0a4ae24d4
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2019-11-11 18:07:56 +08:00
Joseph Chen
1f5a95dcf2 ARM: rockchip_defconfig: enable CONFIG_PINCTRL_RK805
Change-Id: I420e63f4ad200be6f2b9476b16001ad74f36c693
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2019-11-11 18:07:56 +08:00
Tao Huang
d98454e107 mfd: remove unused rk805 drivers
Change-Id: If55f51a681b9c0847015229af63de5d295bfd50e
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2019-11-11 18:07:56 +08:00
Joseph Chen
dd43014bfc pinctrl: rk805: add rk816 support
RK816 has 1 pin to be used as GPIO or TS function.
When used as GPIO function, the pin can be output or input.

Change-Id: I8607595826ac3125dfa2a4c7c483be6b084204c2
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2019-11-11 18:07:56 +08:00
Joseph Chen
05c69b4652 regulator: rk808: optimise/fix for rk805/816
RK805:
- correct enable/disable for suspend and runtime;
- add individual ramp delay set;
- add of_map_mode definition;
- buck4 has 2 line range group;

RK816:
- clean code;

Other: Add set/get mode for BUCKs.

Change-Id: Ife49259cc57c47fa54d078041724a69a42b0faae
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2019-11-11 18:07:56 +08:00
Joseph Chen
c45169cd08 mfd: rk808: power off system in syscore shutdown
The i2c maybe stopped before pm_power_off() is called, which
results in the PMIC power off failure issue.

Moving PMIC power off operation to syscore shutdown is better.

Change-Id: Ib43827ebd49059719b8899f90a696b6c32a6ddd1
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2019-11-11 18:07:56 +08:00