Commit Graph

1267962 Commits

Author SHA1 Message Date
Sugar Zhang
13dde084df ASoC: rockchip: i2s-tdm: Fix channels order for TDM_ONE_FRAME
This patch fix multi-channels order for TDM_ONE_FRAME on SLAVE
mode.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: Ib6543cf0740516d5df1570245abf07fcce9082c3
2024-01-18 10:53:30 +08:00
Sugar Zhang
ce189549b0 ASoC: rockchip: i2s-tdm: Use GPIOD_ASIS for TDM_MULTI_LANES
Situation for 'i2s-lrck':

Should use flag GPIOD_ASIS not to reclaim LRCK pin as GPIO function,
because we use the same PIN and just read EXT_PORT value which show
the pin status.

Situation for 'tdm-fsync':

A. when the pin is a generic gpio as the ref signal pin which is drived from
   external. should use flag GPIOD_IN to reclaim as GPIO_IN function.

B. when the pin is the same pin from the 'clk-src' on the same SoC, we can
   use the 'clk-src' fsync out signal as the 'tdm-fsync' to query status.
   in this case, should use flag GPIOD_ASIS not to reclaim it as GPIO.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I529d982a7e49cb90c02b7670a58759607f4e4f32
2024-01-18 10:53:30 +08:00
Sugar Zhang
d774d063e1 ASoC: rockchip: i2s-tdm: Fix warning
This patch fix resources from of_iomap() not released.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I46a7f4996bc751ade34071727a350137a313b446
2024-01-18 10:53:30 +08:00
Sugar Zhang
682920cb81 ASoC: rockchip: i2s-tdm: Simplify clk sync on TRCM mode
There are clk sync issue on TRCM mode for RK3308/RK1808/PX30,
and the previous soluation is to make TX/RX reset at the same
time to fix that. Unfortunately, it fails on PX30-I2S0, because
the reset-TX and reset-RX bits can't be addressed at the same time.

Now, we use another way to fix it:

  reset_control_assert(i2s_tdm->tx_reset);
  reset_control_assert(i2s_tdm->rx_reset);
                   |
          gate the i2s src clk
                   |
  reset_control_deassert(i2s_tdm->tx_reset);
  reset_control_deassert(i2s_tdm->rx_reset);
                   |
         ungate the i2s src clk

as shown above, use the pair gate/ungate src clk to make the
TX/RX reset at the same time.

Change-Id: Ib320ad13350516100eb11c7717e1bd9005abaf39
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2024-01-18 10:53:30 +08:00
Sugar Zhang
12e4a906dc ASoC: rockchip: i2s-tdm: Fix multi-channels order for TRCM
TRCM on Master mode require TX/RX enabled at the same time,
or need the one which provide clk enabled at first. In this
situation, one direction's FIFO maybe XRUN which may break
the channels order.

This patch add dmaengine for this mode to handle this situation.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I831aead0371228661620b54188048e4f3daa717e
2024-01-18 10:53:30 +08:00
Sugar Zhang
269ae19c7a ASoC: rockchip: Add dmaengine for TRCM mode
TRCM require TX/RX enabled at the same time, or need the one
which provide clk enabled at first. In this situation, one
direction's FIFO maybe XRUN which may break the channels order.

This patch add dmaengine for this mode to handle this situation.

Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
Change-Id: I30b4ec134b06516d80de4c1d0ccaf916513294ab
2024-01-18 10:53:30 +08:00
Tao Huang
94d6e37417 Merge commit 'ca4e22208b9d2053301e90ff69b526694253b989'
* commit 'ca4e22208b9d2053301e90ff69b526694253b989':
  media: i2c: sc530ai: update gain map according to datasheet
  hwspinlock: rockchip: object to unlocking someone else's lock
  hwspinlock: rockchip: support to set hwlock user in dt
  dt-bindings: hwlock: rockchip: add hwlock user id property

Change-Id: I43eec243d439257fd3d334874e60859e34f99ec3
2024-01-17 19:09:21 +08:00
Tao Huang
0f33ed4a08 Merge commit '0a30d6ee1e899f25801c651a6e7612c07cdf4922'
* commit '0a30d6ee1e899f25801c651a6e7612c07cdf4922':
  drm/rockchip: dw-dp: filter yuv420 when display mode not support

Change-Id: I3e1343baaa1cc4c7c914a6390dba6274a6ac948f
2024-01-17 19:09:07 +08:00
Zhang Yubing
5c0f10ac1c drm/rockchip: dw-dp: filter yuv420 when display mode not support
Change-Id: I1aead8dcd05dffdf89c62c162524bfde9c63f86e
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-01-17 19:00:19 +08:00
Tao Huang
0d01978085 Merge commit 'f13fe816e0bb2f683b1d0da80451d6fdcc65d450'
* commit 'f13fe816e0bb2f683b1d0da80451d6fdcc65d450':
  arm64: dts: rockchip: rk3588-vehicle-evb: move port dts to bridge node for rohm
  mfd: display-serdes: fix compile errors on kernel-6.1
  media: rockchip: isp: fix isp32 lost buf
  arm64: dts: rockchip: rk3562-evb1: add rgb 1024x600p60 panel display board
  arm64: dts: rockchip: rk3588-evb: add edp 4k panel display board
  PCI: rockchip: dw-ep: Resize bar after hot reset
  mtd: spinand: unim: The nand flash does not support 84H and 34H command
  mtd: spinand: XINCUN: Fix XCSP1AAPK read id method
  arm64: dts: rockchip: rk3562-evb1: add sii902x bt1120/bt656 to hdmi board

Change-Id: Id3242f40a7d54218eba80e6dd5a5b52495c6263e
2024-01-17 18:55:13 +08:00
Tao Huang
a81d62b3eb Merge commit '1c6c2f66f3bfb9a9d1ca789c48816e283b7aa828'
Merge made by the 'ours' strategy.

* commit '1c6c2f66f3bfb9a9d1ca789c48816e283b7aa828':
  mfd: rk808: remove rtc stop for pre init

Change-Id: I301a09edee4790eab24a40fdf987eb968076f44e
2024-01-17 18:48:52 +08:00
Elaine Zhang
8276bea0c1 mfd: rk808: remove rtc stop for pre init
If RTC has been started, stop rtc in pre init will affect
the rtc function and accuracy.

Change-Id: Ic601e8e2d622de95638ca1710c1cff8c5c1a90d5
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2024-01-17 18:38:44 +08:00
Tao Huang
b52c42154d Merge commit '289b59b0e9859ce5746b1d6411e57d49470c1608'
* commit '289b59b0e9859ce5746b1d6411e57d49470c1608':
  drm/rockchip: drv: rename drm_atomic_helper_connector_commit()
  net: rfkill-bt: add power up func when waked by bt-irq only.
  PCI: rockchip: dw: Fix NULL pointer of hot_rst_work
  spi: rockchip-sfc: Support chip select 1 extension

Change-Id: I9761124eb5791a13779230233a529e050464f7c3
2024-01-17 18:36:39 +08:00
Tao Huang
fc6fba9821 Merge commit '3aa3879e5e9d97a18cd1e735045f5ea42896d2e1'
* commit '3aa3879e5e9d97a18cd1e735045f5ea42896d2e1':
  media: i2c: maxim: local: maxim2c: driver version v3.00.00
  arm64: dts: rockchip: rk3399-evb-ind-lpddr4-v13-android-avb: add tc35874x configuration
  arm64: dts: rockchip: rk3399-evb-ind-lpddr4-android-avb: add tc35874x configuration
  arm64: dts: rockchip: rk3399-ind: tc358749x use dummy codec
  ARM: fiq_glue: save/restore r6 in fiq_glue_setup
  media: i2c: techpoint: fix tp9951 2 lane ecc error

Change-Id: Ic1705a7ccf3ad23071ab44f130754cfcd4f192cb
2024-01-17 18:34:09 +08:00
Tao Huang
11c0b921d0 Merge commit '89ba14ab7c6296c499fc3c5c22d252da0a0a4137'
Merge made by the 'ours' strategy.

* commit '89ba14ab7c6296c499fc3c5c22d252da0a0a4137':
  ASoC: rockchip: i2s: Add support for pinctrl idle state

Change-Id: I57f89f225efe91416c370a5e6aa508d9b4174e91
2024-01-17 18:32:44 +08:00
Sugar Zhang
a3d49e9543 ASoC: rockchip: i2s: Add support for pinctrl idle state
This patch switch pinctrl to idle state when runtime suspend.

At the moment, it's used for workaround for I2S0/2/3 (PD_AUDIO)
slave IO issue on RK3588 SoCs.

The issue acts like that when PD_AUDIO off, the BCLK/LRCK pin
will pull down the external clk to half-level.

The root cause is that when PD_AUDIO off, the BCLK/LRCK pin
are clamped as drive output low.

This patch also try to solve clk leak for master output mode.

OTOH, the ASoC framework set pinctrl state first and then do
runtime PM resume (enable PD). it's reasonable, but for the
current issue, a few half-level cycles leak after resume, so,
we split pinctrl-clk out to control it separately.

  snd_pcm_open

      for_each_rtd_components(rtd, i, component)
      	pinctrl_pm_select_default_state(component->dev);

      ret = snd_soc_pcm_component_pm_runtime_get(rtd, substream);

e.g. pinctrl idle for i2s0

i2s0_gpio: i2s0-gpio {
	rockchip,pins =
		/* i2s0_lrck_gpio */
		<1 RK_PC5 0 &pcfg_pull_none>,
		/* i2s0_sclk_gpio */
		<1 RK_PC3 0 &pcfg_pull_none>;
};

&i2s0_8ch {
	pinctrl-names = "default", "idle", "clk";
	pinctrl-1 = <&i2s0_gpio>;
	pinctrl-2 = <&i2s0_lrck
		     &i2s0_sclk>;
};

cat /sys/kernel/debug/pinctrl/pinctrl-handles

device: fe470000.i2s current state: idle
  state: default
    type: MUX_GROUP controller rockchip-pinctrl group: i2s0-sdi0 (26) function: i2s0 (24)
    type: CONFIGS_PIN controller rockchip-pinctrl pin gpio1-28 (60)config 00000001
    type: MUX_GROUP controller rockchip-pinctrl group: i2s0-sdi1 (27) function: i2s0 (24)
    type: CONFIGS_PIN controller rockchip-pinctrl pin gpio1-27 (59)config 00000001
    type: MUX_GROUP controller rockchip-pinctrl group: i2s0-sdi2 (28) function: i2s0 (24)
    type: CONFIGS_PIN controller rockchip-pinctrl pin gpio1-26 (58)config 00000001
    type: MUX_GROUP controller rockchip-pinctrl group: i2s0-sdi3 (29) function: i2s0 (24)
    type: CONFIGS_PIN controller rockchip-pinctrl pin gpio1-25 (57)config 00000001
    type: MUX_GROUP controller rockchip-pinctrl group: i2s0-sdo0 (30) function: i2s0 (24)
    type: CONFIGS_PIN controller rockchip-pinctrl pin gpio1-23 (55)config 00000001
    type: MUX_GROUP controller rockchip-pinctrl group: i2s0-sdo1 (31) function: i2s0 (24)
    type: CONFIGS_PIN controller rockchip-pinctrl pin gpio1-24 (56)config 00000001
  state: idle
    type: MUX_GROUP controller rockchip-pinctrl group: i2s0-idle (23) function: i2s0 (24)
    type: CONFIGS_PIN controller rockchip-pinctrl pin gpio1-21 (53)config 00000001
    type: CONFIGS_PIN controller rockchip-pinctrl pin gpio1-19 (51)config 00000001
  state: clk
    type: MUX_GROUP controller rockchip-pinctrl group: i2s0-lrck (24) function: i2s0 (24)
    type: CONFIGS_PIN controller rockchip-pinctrl pin gpio1-21 (53)config 00000001
    type: MUX_GROUP controller rockchip-pinctrl group: i2s0-sclk (25) function: i2s0 (24)
    type: CONFIGS_PIN controller rockchip-pinctrl pin gpio1-19 (51)config 00000001

Fixes: 89e11e98f4 ("arm64: dts: rockchip: rk3588: Add pinctrl idle for I2S0/2/3")
Change-Id: I41dcdabd8e4015c7bd7285a03a24a3765a0b576f
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2024-01-17 11:14:58 +08:00
Su Yuefu
ca4e22208b media: i2c: sc530ai: update gain map according to datasheet
Change-Id: I842a776b4f668848a81a2b928f136df1acc5227f
Signed-off-by: Su Yuefu <yuefu.su@rock-chips.com>
2024-01-16 18:26:25 +08:00
Frank Wang
99111d8fb2 hwspinlock: rockchip: object to unlocking someone else's lock
Check hwlock user id and object to unlocking someone else's lock
when invoking unlock() API.

Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
Change-Id: I46c256fd703fa56ce3d175ff2d721f53d3615ec0
2024-01-16 16:19:07 +08:00
Frank Wang
3229c7d5d5 hwspinlock: rockchip: support to set hwlock user in dt
With this commit, we can set hwlock user id in DT with
"rockchip,hwlock-user-id" property, if it is not set, the driver
use default value 0x01 instead.

Change-Id: Ib7ecc3eaf23ba79d85dc82182a9db0760c6d830c
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2024-01-16 16:18:54 +08:00
Frank Wang
fa524e432a dt-bindings: hwlock: rockchip: add hwlock user id property
Set hwlock user id with the "rockchip,hwlock-user-id" property.

Change-Id: I46327ff4146e9c0999def48d67a3538462b82bfb
Signed-off-by: Frank Wang <frank.wang@rock-chips.com>
2024-01-16 16:18:41 +08:00
Zhang Yubing
0a30d6ee1e drm/rockchip: dw-dp: filter yuv420 when display mode not support
Change-Id: I1aead8dcd05dffdf89c62c162524bfde9c63f86e
Signed-off-by: Zhang Yubing <yubing.zhang@rock-chips.com>
2024-01-16 15:45:21 +08:00
Luo Wei
f13fe816e0 arm64: dts: rockchip: rk3588-vehicle-evb: move port dts to bridge node for rohm
Signed-off-by: Luo Wei <lw@rock-chips.com>
Change-Id: I7c51267923b82791a6f70b8086f08d5b661399fa
2024-01-16 15:44:38 +08:00
Luo Wei
5d0970aacb mfd: display-serdes: fix compile errors on kernel-6.1
Signed-off-by: Luo Wei <lw@rock-chips.com>
Change-Id: Id52ed6fe9779cef2fe08c781cbe46f68b621844f
2024-01-16 15:36:36 +08:00
Cody Xie
2d0fac2bdb gpio: nca9539: Make remove return void
Change-Id: Iea6faa2956a5fa334e43b94cf47f8c609c9e317e
Signed-off-by: Cody Xie <cody.xie@rock-chips.com>
2024-01-15 19:21:56 +08:00
Cai YiWei
81fdd2b9d6 media: rockchip: isp: fix isp32 lost buf
Change-Id: I81f32f3d1c98c30f32fb862eaa4a31bbbcbb2412
Signed-off-by: Cai YiWei <cyw@rock-chips.com>
2024-01-15 18:13:59 +08:00
Damon Ding
748a301cd4 arm64: dts: rockchip: rk3562-evb1: add rgb 1024x600p60 panel display board
RGB panel Q7050ITH2641AA1T with 24-bit color depth.

Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
Change-Id: Ieaf626a2d20c9f30640985c61d48187cf637b0fe
2024-01-15 17:58:54 +08:00
Shawn Lin
4208d76e0c PCI: dw: rockchip: Remove EP support from RC driver
EP support have been moved to pcie-dw-ep-rockchip.c since 5.10 kernel,
so remove the old EP code from RC driver now.

Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Change-Id: Ia1a5907493a38cf6be5f1a97c5690dd9ecaad3c4
2024-01-15 16:03:12 +08:00
Damon Ding
090d4f484b arm64: dts: rockchip: rk3588-evb: add edp 4k panel display board
EDP panel NV140QUM-N61 supports 3840x2160p60 with 4lanes.

Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
Change-Id: Ie21e227418c95ba0e190964716f70409505b4e71
2024-01-15 16:01:17 +08:00
Jon Lin
b2da6c9353 PCI: rockchip: dw-ep: Resize bar after hot reset
Change-Id: I079d354422b9e1c4895ac75781e33c924467991d
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2024-01-15 15:59:23 +08:00
Tao Huang
586634361d Merge commit '08d8bee9b88ec07aa6692a6305df115bd7caed26'
* commit '08d8bee9b88ec07aa6692a6305df115bd7caed26':
  arm64: dts: rockchip: rk3588-vehicle-maxim-cameras-s66.dtsi: support i2c-mux
  arm64: dts: rockchip: rk3588-vehicle-evb-maxim-max9671(/2)2-d(c)phy0(/3).dtsi: support i2c-mux
  media: i2c: maxim: remote: add ox03j10 sensor driver
  media: i2c: maxim: remote: add ov2311/ov2312 sensor driver
  media: i2c: maxim: remote: add ox01f10 sensor driver
  media: i2c: maxim: remote: add sc320at sensor driver
  media: i2c: maxim: remote: serializer driver version v3.00.00
  media: i2c: maxim: local: maxim4c: driver version v3.00.00

Change-Id: I067232e3123fa10ce28e1608a8634adabea51f57

Conflicts:
	drivers/media/i2c/Makefile
	drivers/media/i2c/maxim4c/Kconfig
2024-01-15 15:10:18 +08:00
Tao Huang
d847fc30ee Merge commit 'beb9974b6fb001eb197b613257ef57fd603db652'
* commit 'beb9974b6fb001eb197b613257ef57fd603db652':
  media: i2c: sc850sl: fix gain discontinuity issue
  media: rockchip: isp: fix resume mi no enable

Change-Id: If8e1a2004de712a6b59d64206f2a26bb92b92ea7
2024-01-15 15:02:59 +08:00
Tao Huang
5a80764225 Merge commit '982e655deb1a079300c8dd83b6678922b728e576'
Merge made by the 'ours' strategy.

* commit '982e655deb1a079300c8dd83b6678922b728e576':
  arm64: dts: rockchip: rk3568: Add nfc

Change-Id: I5e4ef3d736525cdf1068a2537e6c979c2282d0e4
2024-01-15 15:01:37 +08:00
Jon Lin
8c11a4fe4f mtd: spinand: unim: The nand flash does not support 84H and 34H command
Change-Id: Id44563e2ab35c65d879d8179e412a9b88aea6cba
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2024-01-15 14:35:12 +08:00
Jon Lin
c022f003dc mtd: spinand: XINCUN: Fix XCSP1AAPK read id method
Fixes: c08e952374 ("mtd: spinand: XINCUN: Support new device XCSP1AAPK")
Change-Id: Ifa4d4a875c45b3f20be9839f5bea0f44ff3aeb98
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2024-01-15 14:33:00 +08:00
Damon Ding
61ede000b1 arm64: dts: rockchip: rk3562-evb1: add sii902x bt1120/bt656 to hdmi board
Signed-off-by: Damon Ding <damon.ding@rock-chips.com>
Change-Id: I4a771d87694cc47e542ead825d90b50e9ae32d13
2024-01-15 11:59:34 +08:00
Elaine Zhang
1c6c2f66f3 mfd: rk808: remove rtc stop for pre init
If RTC has been started, stop rtc in pre init will affect
the rtc function and accuracy.

Change-Id: Ic601e8e2d622de95638ca1710c1cff8c5c1a90d5
Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
2024-01-15 08:58:16 +08:00
Jon Lin
7ee5a221e8 arm64: dts: rockchip: rk3568: Add nfc
Change-Id: I3fb8fae8b63925d58e6889af4df80e920b3d4881
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2024-01-12 19:06:54 +08:00
Tao Huang
c5179f362e Merge commit '08c66b08ce17798f3bbdcdee5b247628817f91d3'
* commit '08c66b08ce17798f3bbdcdee5b247628817f91d3':
  media: rockchip: isp: sync irq_ends
  mfd: rkx110_x120: cru: fix to get a avialble pll rate
  arm64: dts: rockchip: rk3562: adjust regulator-init-microvolt of vdd_cpu/vdd_logic for rk3562 boards
  arm64: dts: rockchip: rk3562: adjust low-temp-min-volt for cpu/dmc

Change-Id: I49f5c03bf5edee290cf7d4d2b2d4ab2436d26f89
2024-01-12 18:58:11 +08:00
Tao Huang
2410c01daf Merge commit '5e9dee2ebe5c633887ee7d8f695259a7b5445b71'
* commit '5e9dee2ebe5c633887ee7d8f695259a7b5445b71':
  media: i2c: add sc830ai sensor driver
  dmaengine: pl330: Use tasklet_hi_schedule
  mtd: spinand: XINCUN: Support new device XCSP1AAPK
  arm64: dts: rockchip: rk3562-amp: change mcu ram address

Change-Id: Ia03dea594134a3bee9843767d63f6a9be91f1de5
2024-01-12 18:57:27 +08:00
Tao Huang
ead5797a9c Merge commit 'aa47569d066e59b2f40b29d9b9bc5106eab8833e'
* commit 'aa47569d066e59b2f40b29d9b9bc5106eab8833e':
  media: i2c: lt8668sx: add lt8668sx hdmi2csi driver
  video: rockchip: mpp: remove av1dec l2 cache
  ARM: rockchip: rv1106_pm: do wdt save/restore
  media: rockchip: isp: add buf cnt info to procfs
  media: rockchip: isp: fix wait timeout with thunderboot
  arm64: dts: rockchip: rk3528: Add thermal for macphy
  ARM: dts: rv1106: Add thermal for macphy
  net: phy: RK630: Add dynamically adjusting the configuration
  drm/bridge: dw-hdmi-qp: Fixes compilation errors when cec core is not compiled
  drm/bridge: synopsys: Fixes compilation errors when cec core is not compiled
  media: i2c: imx415 adapt sleep_wakeup
  media: rockchip: hdmirx: make sure to bind to big cpu1

Change-Id: I8b8edd66fc15b60a5b1f4a37d4e3258c7772b335
2024-01-12 18:52:58 +08:00
Tao Huang
24a25815d1 Merge commit 'ca7627f2a44b6815b2f23f4da2d0fc996bd20424'
Merge made by the 'ours' strategy.

* commit 'ca7627f2a44b6815b2f23f4da2d0fc996bd20424':
  tee: optee: interrupt an RPC depend on shutdown flag

Change-Id: Ia6a2fe4287c0f1b05518c58cb90d5e66be0205cf
2024-01-12 18:45:48 +08:00
Sandy Huang
289b59b0e9 drm/rockchip: drv: rename drm_atomic_helper_connector_commit()
drm_atomic_helper_connector_commit() is rockchip private function, so
rename to rockchip_drm_atomic_helper_connector_commit() is more reasonable.

the function is introduced by the following commit:
commit: 88ea93aeb0 ("drm/rockchip: Introduce connector commit")

Signed-off-by: Sandy Huang <hjc@rock-chips.com>
Change-Id: I7d118495024c699529e872e036930a9d3ba70610
2024-01-12 17:24:02 +08:00
Zou Dengming
19ab80fe27 net: rfkill-bt: add power up func when waked by bt-irq only.
when rtk(also some others) wifi/bt combo chips suspend, it
disconnect from bt-remote control unit(RCU). when RCU's
powerkey pressed, it will send ble broadcast to rtk bt chip.

As the rtk chips receive the broadcast, it should wake up
the host, but it can't send bt-hid powerkey to host because
it had lost communication with host.
So,it just send a IRQ pulse to host. The host should resume
from suspend.

Because the RCU just send a IRQ pulse, so rk chips just resume
by IRQ and then go to sleep again for no power-key event.
this is not expected. we expect to power up system wholly.

With this path, we try to power up the system. so we add a
power-up key event when BT IRQ received.

We also can control the "/proc/bluetooth/sleep/powerupkey"
node to enable or disable this function.

Change-Id: Ie59b4a2c4cd2f91820d31835df86565003126465
Signed-off-by: Zou Dengming <marsow.zou@rock-chips.com>
2024-01-12 14:45:42 +08:00
Hisping Lin
b0b2892b93 tee: optee: interrupt an RPC depend on shutdown flag
Change-Id: I33f33af02afb75bda5d68c9731fe636bb97132fe
Signed-off-by: Hisping Lin <hisping.lin@rock-chips.com>
2024-01-12 08:44:25 +08:00
Shawn Lin
f98648322e PCI: rockchip: dw: Fix NULL pointer of hot_rst_work
If the hot reset was happening just before the hot_rst_work
was created, NULL pointer dereference was hit.

[    2.366623] Unable to handle kernel NULL pointer dereference at virtual address 0000000000000100
[    2.367402] Mem abort info:

...8<...

[    2.380736] Call trace:
[    2.380960]  __queue_work+0x30/0x5a0
[    2.381282]  queue_work_on+0x88/0xa4
[    2.381607]  rk_pcie_sys_irq_handler+0x1ec/0x280
[    2.382019]  __handle_irq_event_percpu+0x80/0x250
[    2.382440]  handle_irq_event+0x64/0x120
[    2.382796]  handle_fasteoi_irq+0xc8/0x204
[    2.383162]  __handle_domain_irq+0x78/0xe0
[    2.383528]  gic_handle_irq+0xf8/0x364

Fix it by masking all misc interrupts before registering rk_pcie_sys_irq_handler.
And later, they will be unmasked already.

Fixes: 679557456b ("PCIe: dw: rockchip: Delaying the link training after hot reset")
Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
Change-Id: I1667e956526faa046a49323ee57b59fdb7a6451d
2024-01-10 16:05:45 +08:00
Jon Lin
8730136b26 spi: rockchip-sfc: Support chip select 1 extension
Part of the SOC supports FSPI CS1N and supports two external devices
for a single FSPI controller. The software provides targeted support.

Change-Id: I1bedf5864b664e94d280a2bc34e7d07212c774d3
Signed-off-by: Jon Lin <jon.lin@rock-chips.com>
2024-01-10 16:05:25 +08:00
Tao Huang
06dab2ccf7 Merge commit '5f0de7c5d524f0934c83848c6d20526364fc5bb9'
Merge made by the 'ours' strategy.

* commit '5f0de7c5d524f0934c83848c6d20526364fc5bb9':
  drm/rockchip: vop2: Add devfreq support

Change-Id: I184a624c00cf2bade2a64a929c5d32dd15d75302
2024-01-10 15:36:26 +08:00
Tao Huang
14caa4fb96 Merge commit '44ee8c59b5db9d4421709a581d30ceea24ad5b87'
* commit '44ee8c59b5db9d4421709a581d30ceea24ad5b87':
  MALI: bifrost: log: Disable WARNINGs in validate_tracepoint_data()
  Mali: bifrost: Fix: When calling devfreq_add_device(), restore passing of '&ondemand_data'

Change-Id: I85be6940359cb6f4f77ed59189fd9ba65461f300
2024-01-10 15:34:35 +08:00
Tao Huang
9c1fb62faa Merge commit 'a94d0b968ad6275250a6b6bd66f75dcb688ef253'
Merge made by the 'ours' strategy.

* commit 'a94d0b968ad6275250a6b6bd66f75dcb688ef253':
  MALI: rockchip: upgrade bifrost DDK to g21p0-01eac0, from g18p0-01eac0

Change-Id: I01e96d04dd801e7f9d05ac35f934886ca949c1dc
2024-01-10 15:33:39 +08:00
Tao Huang
568fc8768a Merge commit 'e2f9938790a6d9eed3c285c90be45575b6e4c70f'
* commit 'e2f9938790a6d9eed3c285c90be45575b6e4c70f':
  phy: rockchip-samsung-hdptx-hdmi: Calculate the pll frequency based on the register value
  drm/rockchip: analogix_dp: add dual channel mode support
  media: rockchip: vicap: support use reserved mem for aov when run with thunderboot mode
  mfd: rkx110_x120: reset dsi tx host when generator pattern
  media: i2c: cam-sleep-wakeup: optimize sensor wakeup workflow for reset
  mfd: rkx110_x120: disable phy when stop video stream
  media: i2c: os04d10: add reg list of 1440p@30fps and 360p@120fps
  media: i2c: os04d10: fix adapter fastboot issue

Change-Id: I03320bfe99fb028b977197dc04d490288dcc4c34
2024-01-10 15:31:15 +08:00