Commit Graph

1058722 Commits

Author SHA1 Message Date
Simon Xue
b6cd53a3a2 init: defer free large memblock to Buddy allocator when CONFIG_ROCKCHIP_THUNDER_BOOT=y
The physical memory of a system is divided into several types, like
memory reserved for device, for kernel pagetable, etc. The remaining
area is for Buddy allocator. Normally, The memory for Buddy is consist
of different size blocks, so, under meeting the memory request of kernel
booting, we can defer free the large block size to Buddy which can be
done later in work queue in parallel to other kernel threads, and the
size of the large block can be defined in kernel command line

Save boot time about 6ms on 512MB rv1126 evb.

Change-Id: Ie7a8d3122d8d92ad918e8bf680f5949412709f37
Signed-off-by: Simon Xue <xxm@rock-chips.com>
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2021-06-25 16:41:06 +08:00
Finley Xiao
4498c05042 soc: rockchip: system_monitor: Drop FB_EARLY_EVENT_BLANK support
Change-Id: I4fd76bc67578fbf12acaa9ed3004b4a565dd7a75
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2021-06-25 15:05:50 +08:00
Tao Huang
582f79266f Merge remote branch 'android12-5.10' of https://android.googlesource.com/kernel/common
* android12-5.10: (2274 commits)
  FROMGIT: mm: slub: move sysfs slab alloc/free interfaces to debugfs
  ANDROID: gki - CONFIG_NET_SCH_FQ=y
  ANDROID: GKI: Kconfig.gki: Add GKI_HIDDEN_ETHERNET_CONFIGS
  FROMLIST: media: Kconfig: Fix DVB_CORE can't be selected as module
  ANDROID: Update ABI and symbol list
  Revert "net: usb: cdc_ncm: don't spew notifications"
  ANDROID: Fips 140: move fips symbols entirely in own list
  ANDROID: core of xt_IDLETIMER send_nl_msg support
  ANDROID: start to re-add xt_IDLETIMER send_nl_msg support
  ANDROID: add fips140.ko symbols to module ABI
  ANDROID: inject correct HMAC digest into fips140.ko at build time
  ANDROID: crypto: fips140 - perform load time integrity check
  FROMLIST: crypto: shash - stop comparing function pointers to avoid breaking CFI
  ANDROID: arm64: module: preserve RELA sections for FIPS140 integrity selfcheck
  ANDROID: arm64: simd: omit capability check in may_use_simd()
  ANDROID: kbuild: lto: permit the use of .a archives in LTO modules
  ANDROID: arm64: only permit certain alternatives in the FIPS140 module
  ANDROID: crypto: lib/aes - add vendor hooks for AES library routines
  ANDROID: crypto: lib/sha256 - add vendor hook for sha256() routine
  UPSTREAM: KVM: arm64: Mark the host stage-2 memory pools static
  ...

Conflicts:
	drivers/mmc/core/mmc_ops.c
	drivers/usb/gadget/function/f_uac1.c
	drivers/usb/gadget/function/f_uac2.c
	drivers/usb/gadget/function/f_uvc.c
2021-06-25 11:32:04 +08:00
Finley Xiao
4aa418868f soc: rockchip: system_monitor: Use compat_only_sysfs_link_entry_to_kobj
Change-Id: I24b7b1a0158054c6867080c363fc73a2ca8d2506
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
2021-06-25 09:37:51 +08:00
Tao Huang
915d7e128c Revert "dt-bindings: mtd: add Rockchip NAND controller V9 documentation"
This reverts commit 910d9e3f54.

Replaced by commit 9b45a7e697 ("UPSTREAM: dt-bindings: mtd: Describe Rockchip RK3xxx NAND flash controller").

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ic2f3dd56a843b4fe2e73c63b7bca6b3847955b3b
2021-06-25 09:06:13 +08:00
Tao Huang
463ee4c817 Revert "drivers: mtd: nand: add rockchip nandc v9 driver"
This reverts commit 90594ac897.

Replaced by commit d8d1943c7e ("UPSTREAM: mtd: rawnand: rockchip: NFC driver for RK3308, RK2928 and others").

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: Ic54177f92e9b5ed3fcb29bdc117322fb48f67180
2021-06-25 09:06:13 +08:00
Tao Huang
fa0c5bcd3f Revert "dt-bindings: mtd: add Rockchip NAND controller V6 documentation"
This reverts commit f6c33463b6.

Replaced by commit 9b45a7e697 ("UPSTREAM: dt-bindings: mtd: Describe Rockchip RK3xxx NAND flash controller").

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I71a9c3d6094fea13f8e8cda168b98bd6b42eefa3
2021-06-25 09:06:13 +08:00
Tao Huang
b38935144e Revert "drivers: mtd: nand : add rockchip nandc v6 driver"
This reverts commit f96997730d.

Replaced by commit d8d1943c7e ("UPSTREAM: mtd: rawnand: rockchip: NFC driver for RK3308, RK2928 and others").

Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I1061437e4092bb415532eb6a4b8a040fbfd20a69
2021-06-25 09:06:13 +08:00
Jon Lin
d62e7a804b soc: rockchip: Add rockchip thunder boot sfc driver
This driver aimed at starting decompression as soon as
possible.

Change-Id: Iadf07e54047430153bc66fb1f92f85beaecf2c0d
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2021-06-24 20:27:59 +08:00
Jon Lin
cc770c4e7a ubifs: Recovery for cases of unclean reboot
After power lost, spinand may work in a unkonw state and result in
bit flip, including:
1.Write to cache invalid and dirty cache data write to page's array
which result in node CRC error for some pages.
2.One page write fail but the next page write success result in
empty space corruption.

Change-Id: I212c237202b32de0217efc8dd5a4e84174953a3f
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2021-06-24 20:25:10 +08:00
Simon Xue
91db0733d7 drm/rockchip: gem: add IOMMU_TLB_SHOT_ENTIRE when call iommu_map_sg
Add IOMMU_TLB_SHOT_ENTIRE prot for iommu_map_sg, this shoot down entire
iommu tlb one time after iommu_map_sg.This may save about 5ms when DRM
mapping 12MB buffer.

Change-Id: I618aff1b3928bd1ec1dd3d896db746e09e96acdc
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-24 20:00:58 +08:00
Simon Xue
253196ff1f init: Add support directly parse cpio data decompressed by hardware decompressor
The working flow of new feature is:
->bootloader decompress ramdisk.gz to cpio data first and start kernel.
  ->decompressor driver notify initramfs that cpio data ready.
    ->initramfs continue to flush cpio data to rootfs.

Change-Id: I9cd5708fc93270ce77376c26d9da5a5c219996c1
Signed-off-by: Simon Xue <xxm@rock-chips.com>
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2021-06-24 19:52:17 +08:00
Yifeng Zhao
d8d1943c7e UPSTREAM: mtd: rawnand: rockchip: NFC driver for RK3308, RK2928 and others
This driver supports Rockchip NFC (NAND Flash Controller) found on RK3308,
RK2928, RKPX30, RV1108 and other SOCs. The driver has been tested using
8-bit NAND interface on the ARM based RK3308 platform.

Support Rockchip SoCs and NFC versions:
- PX30 and RK3326(NFCv900).
	ECC: 16/40/60/70 bits/1KB.
	CLOCK: ahb and nfc.
- RK3308 and RV1108(NFCv800).
	ECC: 16 bits/1KB.
	CLOCK: ahb and nfc.
- RK3036 and RK3128(NFCv622).
	ECC: 16/24/40/60 bits/1KB.
	CLOCK: ahb and nfc.
- RK3066, RK3188 and RK2928(NFCv600).
	ECC: 16/24/40/60 bits/1KB.
	CLOCK: ahb.

Supported features:
- Read full page data by DMA.
- Support HW ECC(one step is 1KB).
- Support 2 - 32K page size.
- Support 8 CS(depend on SoCs)

Limitations:
- No support for the ecc step size is 512.
- Untested on some SoCs.
- No support for subpages.
- No support for the builtin randomizer.
- The original bad block mask is not supported. It is recommended to use
  the BBT(bad block table).

Suggested-by: Johan Jonker <jbx6244@gmail.com>
Signed-off-by: Yifeng Zhao <yifeng.zhao@rock-chips.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20201210002134.5686-3-yifeng.zhao@rock-chips.com
(cherry picked from commit 058e0e847d)
Change-Id: I3454acff6b221e17d3417476b48ff770a0d9d158
2021-06-24 16:33:17 +08:00
Yifeng Zhao
9b45a7e697 UPSTREAM: dt-bindings: mtd: Describe Rockchip RK3xxx NAND flash controller
Documentation support for Rockchip RK3xxx NAND flash controllers

Change-Id: Ic4b50fd3fd302bda0d038aed6606a4ef7392c20c
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Yifeng Zhao <yifeng.zhao@rock-chips.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20201210002134.5686-2-yifeng.zhao@rock-chips.com
(cherry picked from commit 2007ac9e68)
2021-06-24 16:24:08 +08:00
Huicong Xu
6cb87c69a1 arm64: dts: rockchip: rk3399: add HDMI DDC/CEC pinctrl
Change-Id: Ic3417a5153ceabad3f9c69ffe5b6fa542e7a84c1
Signed-off-by: Huicong Xu <xhc@rock-chips.com>
Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
2021-06-24 16:17:28 +08:00
Yifeng Zhao
3e6cf0d71a phy: rockchip: naneng-combphy: modify SSC config for SATA
Signed-off-by: Yifeng Zhao <yifeng.zhao@rock-chips.com>
Change-Id: Icdb2079028df1edb8973608ad08a51113e1c9ce8
2021-06-24 16:15:18 +08:00
Yifeng Zhao
0bf3a98dc9 phy: rockchip: add naneng combo phy for RK3568
This patch implements a combo phy driver for Rockchip SoCs
with NaNeng IP block. This phy can be used as pcie-phy, usb3-phy,
sata-phy or sgmii-phy.

Signed-off-by: Yifeng Zhao <yifeng.zhao@rock-chips.com>
Change-Id: I86726e7eee643ea4cb3fadc56b0ee729903afc4f
2021-06-24 16:15:18 +08:00
Simon Xue
f1c8124be2 ion: reorder pages for scatterlist
Change-Id: I3a25eba9d65ac1345471321f61ae9d7a959a1be6
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-24 16:05:49 +08:00
Joseph Chen
e4ff4df380 mfd: rk808: set fall event higher priority than rise event
When PMIC irq occurs, regmap-irq.c will traverse all PMIC child
interrupts from low index 0 to high index, we give fall interrupt
high priority to be called earlier than rise, so that it can be
override by late rise event. This can helps to solve key release
glitch which make a wrongly fall event immediately after rise.

Change-Id: Ieda1d6fd3c50cc36742a4740504ec7ce12ea509b
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2021-06-24 15:34:34 +08:00
Joseph Chen
8b27909476 ARM: dts: rockchip: rk3308-dot-rk816-v10-aarch32: remove RKPM_DBG_FSM_SOUT
RKPM_DBG_FSM_SOUT enables PMU FSM state signal output through
GPIO4_D5/SDMMC_CLK during sleep, mainly for debug PMU FSM flow.

Some one may use this pin as LED light, it's fine to drop it
to avoid influence on LED.

Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: I54705292226d82829bc37db0758aa0d9a9995658
2021-06-24 15:24:07 +08:00
Joseph Chen
bd8543b249 arm64: dts: rockchip: rk3308: remove RKPM_DBG_FSM_SOUT
RKPM_DBG_FSM_SOUT enables PMU FSM state signal output through
GPIO4_D5/SDMMC_CLK during sleep, mainly for debug PMU FSM flow.

Some one may use this pin as LED light, it's fine to drop it
to avoid influence on LED.

Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
Change-Id: I82af5fa676d6db8b81e877729c44b976bbfa9ea5
2021-06-24 15:23:16 +08:00
Joseph Chen
07b04629ac arm64: dts: rockchip: rk3308: add rockchip_suspend node
Change-Id: Ib3a2d78da9a1c6a093b1c49c6393f098b2e03a8a
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2021-06-24 15:22:59 +08:00
Joseph Chen
589096a776 arm64: dts: rockchip: rk3328-evb: enable fiq mode
Change-Id: Ic0f6f95488b6575ebb9c4466fd43bf14f7214210
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2021-06-24 15:20:10 +08:00
Joseph Chen
f9781a3fb2 ARM: dts: rk3066a-rayeager: add vdd_logic regulator
The vdd_logic is a pwm regulator. Since '#pwm-cells = <2>', there
is not polarity invert support by pwm driver, so we have to add
property 'pwm-dutycycle-range = <100 0>' to support polarity invert
by pwm regulator driver itself.

Change-Id: Ie5d2cda67ce19dc792f96263836bab658d385681
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2021-06-24 15:17:12 +08:00
Joseph Chen
cbc7fae477 ARM: dts: rk3036: enable rk3036 PSCI
Change-Id: I4c5472587583fb176d88e802d2e7fe20daf9ea48
Signed-off-by: Joseph Chen <chenjh@rock-chips.com>
2021-06-24 15:13:21 +08:00
Simon Xue
ac413a148b dt-bindings: adc: add description for rk1808 saradc
Change-Id: I047410349c527495f5b414d98054e535fc168524
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-22 18:25:12 +08:00
Liao Huaping
7be803f0d5 init: support init ramfs async
If enable ramfs function, init ramfs async,
can reduce kernel init time.

Change-Id: I95d8ca6d8b9c4e9c738c635c5ee56391cbbe7c16
Signed-off-by: Liao Huaping <huaping.liao@rock-chips.com>
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
2021-06-22 17:27:37 +08:00
Simon Xue
c3a852d019 mm/page_alloc.c: Zero all page struct in advance in memmap_init_zone when CONFIG_ROCKCHIP_THUNDER_BOOT=y
In memmap_init_zone, it check all pages valid or deferred by single page,
then zero and init the corresponding page struct. It is safe to zero all
page struct in advance at once no matter what the state of every page is.
This can save time when booting kernel.

Change-Id: Ieb5864231fbc751e9438be488a77ce442b91ce7b
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-22 16:39:02 +08:00
Simon Xue
d762833e82 arm64: dts: rockchip: miss RK3328 WDT clock
Change-Id: I4df6373a3323ebf0fed74dddabc387164cd0aa5c
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-22 16:29:40 +08:00
Simon Xue
0973411cbd phy: rockchip-pcie: enable each lane when phy_power_on
Change-Id: I9c56ee76f0c1a9c47878113d1d034760af97cc12
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-22 16:23:50 +08:00
Simon Xue
260bbeed89 iio: adc: rockchip_saradc: trigger saradc test via sys for test
Take RK3568 as an example:

start sampling:
echo "chn number" > /sys/devices/platform/fe720000.saradc/saradc_test_chn

stop sampling:
echo 8 > /sys/devices/platform/fe720000.saradc/saradc_test_chn

Change-Id: I320bee7a9a9f293dd83defdede4cd1e5974ec527
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-22 16:22:14 +08:00
Simon Xue
a1f97ed189 iio: adc: rockchip_saradc: add support for RK3568
Change-Id: I9d83351b1117eba67277cdd0a32e5d0c59ad1c7f
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-22 16:21:53 +08:00
Simon Xue
ee886e22c6 iommu: don't break detach if iommu shared by more than one master
Change-Id: I4fade6e770e124dcaca41d122965e8696f268556
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-22 16:21:01 +08:00
Simon Xue
a18904023b iommu: rockchip: update to support module
Change-Id: I4603bf635c362b07a9a1dcab3283b1ed669b581b
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-22 16:20:35 +08:00
Simon Xue
6a451a28f7 dt-bindings: iommu: add disable iommu reset and skip iommu read for rockchip iommu
Change-Id: I3f31f5745078717dfecba649ae6aca573eb7f30b
Signed-off-by: Simon Xue <xxm@rock-chips.com>
2021-06-22 16:16:30 +08:00
William Wu
cd8274c6b5 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>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2021-06-22 16:06:07 +08:00
William Wu
3c5c1b3dd0 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>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2021-06-22 16:05:48 +08:00
William Wu
9e3315b96a 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>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2021-06-22 16:05:36 +08:00
William Wu
9f6e60eee6 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>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2021-06-22 16:05:20 +08:00
William Wu
f078cc7762 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>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2021-06-22 15:42:18 +08:00
William Wu
3a4301edee 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>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2021-06-22 15:33:10 +08:00
Wu Liang feng
f21eb9cd0a 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>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2021-06-22 15:33:10 +08:00
William Wu
ee79d6800b usb: core: hub: add quirk for hub with broken autosuspend function
Some USB host controller seems to have problems with
autosuspend. For example, Rockchip rk3328 SoC USB 3.0
wouldn't handle remote wakeup correctly with external
hub after entered autosuspend, caused to resume SS
port fail.

This patch introduces a new quirk flag for hub that
should remain disabled for autosuspend.

Change-Id: I6d14222b2c5025583fea811a6afd6abd22f41cb9
Signed-off-by: William Wu <wulf@rock-chips.com>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2021-06-22 15:33:10 +08:00
William Wu
b5f3551f96 tools: ffs-aio-example: add superspeed descriptors
This patch adds superspeed descriptors in device
applications to support USB 3.0 ffs gadget.

Change-Id: I5a364c935b1d30e2e929791ff16a34cf0d1c87e1
Signed-off-by: William Wu <william.wu@rock-chips.com>
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2021-06-22 15:19:23 +08:00
Jon Lin
8c3cf7cb12 spi: rockchip: Stop spi slave dma receiver when cs inactive
The spi which's version is higher than ver 2 will automatically
enable this feature.

If the length of master transmission is uncertain, the RK spi slave
is better to automatically stop after cs inactive instead of waiting
for xfer_completion forever.

Change-Id: If99e51d35391b824f48e31a3e4508db036593c8a
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2021-06-21 18:13:20 +08:00
Jon Lin
e813e95f5f spi: rockchip: Support SPI_CS_HIGH
1.Add standard spi-cs-high support
2.Refer to spi-controller.yaml for details

Change-Id: I899bce8d9418ee99c784726bb56534aaed27c00b
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2021-06-21 18:12:27 +08:00
Jon Lin
73d5e1d445 spi: rockchip: Support cs-gpio
1.Add standard cs-gpio support
2.Refer to spi-controller.yaml for details

Change-Id: I8f839189038afd77d534d767d938c845aa54fedb
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2021-06-21 16:48:45 +08:00
Jon Lin
c434048c2e FROMLIST: spi: rockchip: Wait for STB status in slave mode tx_xfer
After ROCKCHIP_SPI_VER2_TYPE2, SR->STB is a more accurate judgment
bit for spi slave transmission.

Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
Link: https://patchwork.kernel.org/project/linux-arm-kernel/patch/20210615033213.14241-5-jon.lin@rock-chips.com/
Change-Id: I39fe2b9e5a84304e7d0320842399a02a4b0743a0
2021-06-21 09:43:39 +08:00
Jon Lin
1458738a72 FROMLIST: spi: rockchip: Set rx_fifo interrupt waterline base on transfer item
The error here is to calculate the width as 8 bits. In fact, 16 bits
should be considered.

Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
Link: https://patchwork.kernel.org/project/linux-arm-kernel/patch/20210615033213.14241-4-jon.lin@rock-chips.com/
Change-Id: Ia141ce99b14f8728302535d0748af66d597a2fdc
2021-06-21 09:40:57 +08:00
Jon Lin
0c936c1801 FROMLIST: dt-bindings: spi: spi-rockchip: add description for rv1126
The description below will be used for rv1126.dtsi or compatible one in
the future

Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
Acked-by: Rob Herring <robh@kernel.org>
Link: https://patchwork.kernel.org/project/linux-arm-kernel/patch/20210615033213.14241-2-jon.lin@rock-chips.com/
Change-Id: Ibf4452a6fb03643cc8f3ded0677db863e9a986ab
2021-06-18 18:04:36 +08:00