snd_timer_notify1() is called outside the spinlock and it retakes the
lock after the unlock. This is rather racy, and it's safer to move
snd_timer_notify() call inside the main spinlock.
The patch also contains a slight refactoring / cleanup of the code.
Now all start/stop/continue/pause look more symmetric and a bit better
readable.
Bug: 37240993
Change-Id: Ib90099f88c8b04928a8cdd2808cd9e16da6d519c
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Siqi Lin <siqilin@google.com>
Use regmap method instead of iomap for dwc_otg_310 driver.
Change-Id: I78e91f99196f7619c84b53a579909925167b145c
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Since the DWC USB2.0 host of Rockchip use dwc2 driver instead of
dwc_otg_310 driver, so delete these legacy hack code which contain
the old cru-soft-rst API directly.
Change-Id: I2990c111481a14084c8aa96a54192b9fe88aa61c
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
1) coding style
2) gsensor calibration by user
3) make sensor rate setting effective
Change-Id: I123674ad2fde72b0aa84e6135669ce1f44d5229d
Signed-off-by: Zorro Liu <lyx@rock-chips.com>
We found the usb-phy lost devices detected ability after continuously
disconnect/connect, this patch add usb2-phy reset/deassert as one part
of previous workaround (commit c1ebf31) to fix it.
Change-Id: Ib7112047eb0f5030406389aa9c8ebd599f8118be
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
According to xHCI spec v1.1 section 6.4.5 TRB Completion Codes,
the standard XHCI controller provide a TRB Completion Status
'USB Transaction Error' to asserted in the case where the host
did not receive a valid response from the device, it's useful
to handle pending URBs on the endpoint when the USB device is
plugged out.
Unfortunately, some SOCs USB 3.0 modules lose the ability to
assert the 'USB Transaction Error' status when USB 3.0 device
disconnect. This may cause the pending URBs unhandled, even
lead to USB class driver stalled in waiting for URBs complete.
This patch flush pending URBs in usb_disable_device() when
USB 3.0 device disconnect, it will call xhci_urb_dequeue()
-> xhci_queue_stop_endpoint() to cancel pending URBs and
giveback URB status immediately.
Change-Id: If8acac59bc1f2c10a41ee390ccbeb84b2e7743c1
Signed-off-by: Feng Mingli <fml@rock-chips.com>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Some special SoCs (e.g. rk322xh) USB3 PHY have problem to detect
disconnection, they lose the ability to detect an absence of Rx
termination specified in USB3 spec Table 6-21, fortunately, the
USB3 PHY can detect port link state change when USB3 device is
unplugged, so we can do soft disconnect according to the PLC.
Change-Id: I2cbd62fddc8a1f9c5a264d705db43fb0cf3e035c
Signed-off-by: William Wu <wulf@rock-chips.com>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
RK bootloader does not put a correct size to cmdline, hack the initramfs,
directly return when we get a good initrd.
Change-Id: Ia1199a1c47f1c0789268971c9f2c9b55bf81ca05
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Only affects RK3288, which is not supported on 4.4.
Change-Id: I35a2bd8325a22add75a7ec381cfdac2374d9bc1b
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
On some scenes, win lite area may flush with short width.
As the Technical Reference Manual description, need enable
axi outstanding function if use IOMMU.
From testing, after setting axi outstanding max number to 30
solve windows flush problem.
Change-Id: Id4ea7b5f5dae334e88cf1fb106c0b7bc6af9b8d0
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
The USB kerneldoc says that the actual_length field "is read in
non-iso completion functions", but the usbfs driver uses it for all
URB types in processcompl(). Since not all of the host controller
drivers set actual_length for isochronous URBs, programs using usbfs
with some host controllers don't work properly. For example, Minas
reports that a USB camera controlled by libusb doesn't work properly
with a dwc2 controller.
It doesn't seem worthwhile to change the HCDs and the documentation,
since the in-kernel USB class drivers evidently don't rely on
actual_length for isochronous transfers. The easiest solution is for
usbfs to calculate the actual_length value for itself, by adding up
the lengths of the individual packets in an isochronous transfer.
(cherry picked from git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-next
commit 2ef47001b3)
Change-Id: Id0f62d26ab8bad746c267366b936790c7ae3aed8
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
CC: Minas Harutyunyan <Minas.Harutyunyan@synopsys.com>
Reported-and-tested-by: wlf <wulf@rock-chips.com>
CC: <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
The MDC clock is divider from APB Clock for rockchip's socs, if it
was from mac_clk, the mdc clk range might not be between the frequency
range 1.0 MHz - 2.5 MHz.
Change-Id: I4e4fcb1be239a8d78a39fc1f4e2af5bb87258798
Signed-off-by: David Wu <david.wu@rock-chips.com>
As the emmc is supplyed power by vcc_io, that's 3.3v voltage.
the default 1.8v volatge will cause the emmc error. as the following:
[ 17.096082 ] mmcblk1: error -115 sending stop command, original cmd
response 0x900, card status 0xb00
[ 17.127022 ] mmcblk1: error -110 transferring data, sector 664720, nr
72, cmd response 0x900, card status 0xb00
Remove the mmc-ddr-1_8v to keep the default the 3.3v voltage.
Change-Id: I9e2539d63fd93e72d9febbb311fbd686c5a11d09
Signed-off-by: Caesar Wang <wxt@rock-chips.com>
Use regmap_write to access grf register and reset_control_assert
to reset hdmi controller.
Change-Id: I0c61635bbba8885a93361776836e69697d4d231e
Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
3126 need set grf to change hardware, and set
register should via regmap_write
Change-Id: I49b9baf9cdd442689183d59cdc594f81bcc6bbba
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
HDR_PANEL_METADATA is used to indicate HDR capacity of sink device.
Change-Id: I598a7bb5634f14b57f94135fd3be6b0ad2075116
Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
HDR_SOURCE_METADATA property is used to set source hdr metadata,
which will be sent to sink though HDMI DRM infoframe.
Change-Id: If3500cb505c16c2f0caf66b8e64b4d80b93b228f
Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
The blob_id is used to get blob data of hdr_source_metadata_property.
Change-Id: I8383265e50261438cf8484bd731e42fc23c24c51
Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>