Files
Daniel Golle ba45d608b2 rockchip: add support for Herospeed RV1126 IMX415 Base
The Herospeed RV1126 IMX415 "Base" is an IP camera built on a Rockchip
38x38 V10 EMMC DDR3 board, which is also found in cameras of other
makes and is therefore described by a separate dtsi. The stock firmware
identifies itself as ONVIF manufacturer "HeroSpeed", firmware family
RV1126_IMX415_BASE. This adds the 32-bit armv7 subtarget for the
Cortex-A7 based RV11xx SoCs. The camera keeps its stock U-Boot, which
boots an Android boot image from one of two boot/system slots.

Hardware
--------
SoC: Rockchip RV1126, 4x Cortex-A7
RAM: 1 GiB DDR3
Flash: eMMC, 8 GB class, two boot/system slots
Ethernet: 1x 10/100 Mbit/s, JL1101 PHY on RMII
Sensor: Sony IMX415, 4 lane MIPI CSI-2
RTC: PCF8563
LEDs: white illumination LEDs on one PWM output (V4L2 flash)
Buttons: none
UART: 1.8 V TTL on UART2, 1500000 baud 8N1, 90-degree JST-SH connector
at the bottom edge of the board, facing the edge and hidden underneath
the MIPI CSI cable
Power: PoE (IEEE 802.3af) or 12 V 1 A DC through the barrel connector
on the cable whip

Installation
------------
1. Open the web interface of the stock firmware (192.168.1.168 by
   default) and log in as admin.
2. Upload openwrt-rockchip-armv7-herospeed_rv1126-imx415-squashfs-
   factory-RV1126_IMX415.fls on the firmware upgrade page.
3. The camera reboots into OpenWrt at 192.168.1.1.

Later upgrades use the sysupgrade image, which is written to the
inactive slot. The stock firmware can be restored from OpenWrt with
"sysupgrade -F -n" and the original .FLS file.

MAC address
-----------
eth0 uses the label MAC, stored as MAC=xx:xx:xx:xx:xx:xx in net.conf on
the ext4 "param" partition. U-Boot passes a different, derived address
to Linux, which is replaced by the stored one.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2026-10-13 10:58:21 +01:00

267 lines
8.4 KiB
Makefile

# SPDX-License-Identifier: GPL-2.0-only
define KernelPackage/drm-rockchip
SUBMENU:=$(VIDEO_MENU)
TITLE:=Rockchip DRM support
DEPENDS:=@TARGET_rockchip video-support +kmod-drm-kms-helper \
+kmod-drm-dma-helper \
+kmod-drm-display-helper +kmod-drm-analogix-dp \
+kmod-drm-dw-dp +kmod-drm-dw-hdmi +kmod-drm-dw-hdmi-qp \
+kmod-drm-dw-mipi-dsi +kmod-drm-dw-mipi-dsi2
KCONFIG:= \
CONFIG_DRM_ROCKCHIP \
CONFIG_ROCKCHIP_VOP=y \
CONFIG_ROCKCHIP_VOP2=y \
CONFIG_ROCKCHIP_ANALOGIX_DP=y \
CONFIG_ROCKCHIP_CDN_DP=n \
CONFIG_ROCKCHIP_DW_DP=y \
CONFIG_ROCKCHIP_DW_HDMI=y \
CONFIG_ROCKCHIP_DW_HDMI_QP=y \
CONFIG_ROCKCHIP_DW_MIPI_DSI=y \
CONFIG_ROCKCHIP_DW_MIPI_DSI2=y \
CONFIG_ROCKCHIP_INNO_HDMI=n \
CONFIG_ROCKCHIP_LVDS=n \
CONFIG_ROCKCHIP_RGB=n \
CONFIG_ROCKCHIP_RK3066_HDMI=n
FILES:=$(LINUX_DIR)/drivers/gpu/drm/rockchip/rockchipdrm.ko
AUTOLOAD:=$(call AutoProbe,rockchipdrm,1)
endef
define KernelPackage/drm-rockchip/description
Direct Rendering Manager (DRM) support for the Rockchip VOP and VOP2
display controllers with their eDP, DP, HDMI, HDMI QP, MIPI DSI and
MIPI DSI2 outputs.
endef
$(eval $(call KernelPackage,drm-rockchip))
define KernelPackage/drm-rocket
SUBMENU:=$(VIDEO_MENU)
TITLE:=Rockchip NPU accelerator support
DEPENDS:=@TARGET_rockchip accel-support +kmod-drm-sched +kmod-drm-shmem-helper
KCONFIG:= \
CONFIG_DRM_ACCEL=y \
CONFIG_DRM_ACCEL_ROCKET
FILES:=$(LINUX_DIR)/drivers/accel/rocket/rocket.ko
AUTOLOAD:=$(call AutoProbe,rocket)
endef
define KernelPackage/drm-rocket/description
Compute acceleration driver for the Rockchip RKNN neural processing units.
endef
$(eval $(call KernelPackage,drm-rocket))
define KernelPackage/phy-rockchip-samsung-hdptx
SUBMENU:=$(VIDEO_MENU)
TITLE:=Rockchip Samsung HDMI/eDP combo PHY
DEPENDS:=@TARGET_rockchip
KCONFIG:=CONFIG_PHY_ROCKCHIP_SAMSUNG_HDPTX
FILES:=$(LINUX_DIR)/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.ko
AUTOLOAD:=$(call AutoProbe,phy-rockchip-samsung-hdptx,1)
endef
$(eval $(call KernelPackage,phy-rockchip-samsung-hdptx))
define KernelPackage/phy-rockchip-samsung-dcphy
SUBMENU:=$(VIDEO_MENU)
TITLE:=Rockchip Samsung MIPI DCPHY
DEPENDS:=@TARGET_rockchip
KCONFIG:=CONFIG_PHY_ROCKCHIP_SAMSUNG_DCPHY
FILES:=$(LINUX_DIR)/drivers/phy/rockchip/phy-rockchip-samsung-dcphy.ko
AUTOLOAD:=$(call AutoProbe,phy-rockchip-samsung-dcphy)
endef
$(eval $(call KernelPackage,phy-rockchip-samsung-dcphy))
define KernelPackage/phy-rockchip-inno-csidphy
SUBMENU:=$(VIDEO_MENU)
TITLE:=Rockchip Innosilicon MIPI CSI DPHY
DEPENDS:=@TARGET_rockchip
KCONFIG:=CONFIG_PHY_ROCKCHIP_INNO_CSIDPHY
FILES:=$(LINUX_DIR)/drivers/phy/rockchip/phy-rockchip-inno-csidphy.ko
AUTOLOAD:=$(call AutoProbe,phy-rockchip-inno-csidphy)
endef
$(eval $(call KernelPackage,phy-rockchip-inno-csidphy))
define KernelPackage/video-rockchip-vdec
TITLE:=Rockchip video decoder support
DEPENDS:=@TARGET_rockchip +kmod-video-mem2mem +kmod-video-dma-contig \
+kmod-video-vmalloc +kmod-video-v4l2-h264 +kmod-video-v4l2-vp9
KCONFIG:=CONFIG_VIDEO_ROCKCHIP_VDEC
FILES:=$(LINUX_DIR)/drivers/media/platform/rockchip/rkvdec/rockchip-vdec.ko
AUTOLOAD:=$(call AutoProbe,rockchip-vdec)
$(call AddDepends/video)
endef
define KernelPackage/video-rockchip-vdec/description
Stateless V4L2 decoder driver for the Rockchip RKVDEC H.264, HEVC and
VP9 video decoders.
endef
$(eval $(call KernelPackage,video-rockchip-vdec))
define KernelPackage/video-rockchip-rga
TITLE:=Rockchip RGA 2D graphics acceleration
DEPENDS:=@TARGET_rockchip +kmod-video-mem2mem +kmod-video-dma-sg
KCONFIG:=CONFIG_VIDEO_ROCKCHIP_RGA
FILES:=$(LINUX_DIR)/drivers/media/platform/rockchip/rga/rockchip-rga.ko
AUTOLOAD:=$(call AutoProbe,rockchip-rga)
$(call AddDepends/video)
endef
$(eval $(call KernelPackage,video-rockchip-rga))
define KernelPackage/video-synopsys-hdmirx
TITLE:=Synopsys DesignWare HDMI receiver support
DEPENDS:=@TARGET_rockchip +kmod-video-dma-contig +kmod-cec-core
KCONFIG:= \
CONFIG_VIDEO_SYNOPSYS_HDMIRX \
CONFIG_VIDEO_SYNOPSYS_HDMIRX_LOAD_DEFAULT_EDID=y
FILES:=$(LINUX_DIR)/drivers/media/platform/synopsys/hdmirx/synopsys-hdmirx.ko
AUTOLOAD:=$(call AutoProbe,synopsys-hdmirx)
$(call AddDepends/video)
endef
$(eval $(call KernelPackage,video-synopsys-hdmirx))
define KernelPackage/video-dw-mipi-csi2rx
TITLE:=Synopsys DesignWare MIPI CSI-2 receiver
DEPENDS:=@TARGET_rockchip +kmod-video-fwnode
KCONFIG:=CONFIG_VIDEO_DW_MIPI_CSI2RX
FILES:=$(LINUX_DIR)/drivers/media/platform/synopsys/dw-mipi-csi2rx.ko
AUTOLOAD:=$(call AutoProbe,dw-mipi-csi2rx)
$(call AddDepends/video)
endef
define KernelPackage/video-dw-mipi-csi2rx/description
The CSI-2 receiver that feeds the video capture unit on RK3568 and
RK3588, taking its data from the MIPI D-PHY.
endef
$(eval $(call KernelPackage,video-dw-mipi-csi2rx))
define KernelPackage/video-rockchip-cif
TITLE:=Rockchip Camera Interface (VICAP)
DEPENDS:=@TARGET_rockchip +kmod-video-dma-contig +kmod-video-fwnode \
+kmod-video-dw-mipi-csi2rx
KCONFIG:=CONFIG_VIDEO_ROCKCHIP_CIF
FILES:=$(LINUX_DIR)/drivers/media/platform/rockchip/rkcif/rockchip-cif.ko
AUTOLOAD:=$(call AutoProbe,rockchip-cif)
$(call AddDepends/video)
endef
define KernelPackage/video-rockchip-cif/description
Camera capture for the video input unit found on PX30, RK3568 and
RK3588. A camera also needs its sensor driver and a device tree that
describes the connection.
endef
$(eval $(call KernelPackage,video-rockchip-cif))
define KernelPackage/leds-pwm-flash
SUBMENU:=$(LEDS_MENU)
TITLE:=PWM driven flash LED support
DEPENDS:=@TARGET_rockchip @PWM_SUPPORT +kmod-video-core +kmod-video-async
KCONFIG:= \
CONFIG_LEDS_CLASS_FLASH \
CONFIG_V4L2_FLASH_LED_CLASS \
CONFIG_LEDS_PWM_FLASH
FILES:= \
$(LINUX_DIR)/drivers/leds/led-class-flash.ko \
$(LINUX_DIR)/drivers/media/v4l2-core/v4l2-flash-led-class.ko \
$(LINUX_DIR)/drivers/leds/flash/leds-pwm-flash.ko
AUTOLOAD:=$(call AutoProbe,led-class-flash v4l2-flash-led-class \
leds-pwm-flash)
endef
define KernelPackage/leds-pwm-flash/description
Flash LED whose brightness is set by the duty cycle of a PWM channel,
exposed as a V4L2 flash subdevice for the camera sensor that refers
to it.
endef
$(eval $(call KernelPackage,leds-pwm-flash))
define KernelPackage/crypto-hw-rockchip2
TITLE:=Rockchip Crypto V2 hardware crypto engine
DEPENDS:=@TARGET_rockchip +kmod-crypto-engine +kmod-crypto-hash \
+kmod-crypto-cbc +kmod-crypto-ctr +kmod-crypto-ecb +kmod-crypto-xts \
+kmod-crypto-md5 +kmod-crypto-sha1 +kmod-crypto-sha256 \
+kmod-crypto-sha512
KCONFIG:= \
CONFIG_CRYPTO_HW=y \
CONFIG_CRYPTO_DEV_ROCKCHIP2
FILES:=$(LINUX_DIR)/drivers/crypto/rockchip/rk_crypto2.ko
AUTOLOAD:=$(call AutoLoad,90,rk_crypto2)
$(call AddDepends/crypto)
endef
define KernelPackage/crypto-hw-rockchip2/description
Hardware crypto engine of the Rockchip RK3568, RK3588 and RV1126. It
offloads AES in ECB, CBC, CTR and XTS modes and the MD5, SHA-1, SHA-256
and SHA-512 digests.
endef
$(eval $(call KernelPackage,crypto-hw-rockchip2))
define KernelPackage/sound-soc-rockchip-i2s
TITLE:=Rockchip I2S support
DEPENDS:=@TARGET_rockchip +kmod-sound-soc-core
KCONFIG:=CONFIG_SND_SOC_ROCKCHIP_I2S
FILES:=$(LINUX_DIR)/sound/soc/rockchip/snd-soc-rockchip-i2s.ko
AUTOLOAD:=$(call AutoProbe,snd-soc-rockchip-i2s)
$(call AddDepends/sound)
endef
$(eval $(call KernelPackage,sound-soc-rockchip-i2s))
define KernelPackage/sound-soc-rockchip-i2s-tdm
TITLE:=Rockchip I2S/TDM support
DEPENDS:=@TARGET_rockchip +kmod-sound-soc-core
KCONFIG:=CONFIG_SND_SOC_ROCKCHIP_I2S_TDM
FILES:=$(LINUX_DIR)/sound/soc/rockchip/snd-soc-rockchip-i2s-tdm.ko
AUTOLOAD:=$(call AutoProbe,snd-soc-rockchip-i2s-tdm)
$(call AddDepends/sound)
endef
$(eval $(call KernelPackage,sound-soc-rockchip-i2s-tdm))
define KernelPackage/sound-soc-rockchip-spdif
TITLE:=Rockchip S/PDIF support
DEPENDS:=@TARGET_rockchip +kmod-sound-soc-core
KCONFIG:=CONFIG_SND_SOC_ROCKCHIP_SPDIF
FILES:=$(LINUX_DIR)/sound/soc/rockchip/snd-soc-rockchip-spdif.ko
AUTOLOAD:=$(call AutoProbe,snd-soc-rockchip-spdif)
$(call AddDepends/sound)
endef
$(eval $(call KernelPackage,sound-soc-rockchip-spdif))
define KernelPackage/rockchip-dfi
SUBMENU:=$(OTHER_MENU)
TITLE:=Rockchip DDR monitor (DFI) devfreq event driver
DEPENDS:=@TARGET_rockchip
KCONFIG:=CONFIG_DEVFREQ_EVENT_ROCKCHIP_DFI
FILES:=$(LINUX_DIR)/drivers/devfreq/event/rockchip-dfi.ko
AUTOLOAD:=$(call AutoProbe,rockchip-dfi)
endef
$(eval $(call KernelPackage,rockchip-dfi))