From 497d1623017c2d5da4a067ffd20e1dc429ade2ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eric=20Gon=C3=A7alves?= Date: Thu, 2 Oct 2025 18:16:21 +0000 Subject: [PATCH] board: Add support for the Samsung Galaxy S22 --- board/Kconfig | 7 +++++++ board/Makefile | 1 + board/samsung/board-r0q.c | 31 +++++++++++++++++++++++++++++++ configs/r0q_defconfig | 6 ++++++ soc/Kconfig | 6 ++++++ 5 files changed, 51 insertions(+) create mode 100644 board/samsung/board-r0q.c create mode 100644 configs/r0q_defconfig diff --git a/board/Kconfig b/board/Kconfig index f4b0893..2dc8a8c 100644 --- a/board/Kconfig +++ b/board/Kconfig @@ -165,6 +165,13 @@ menu "Device Support" help Say Y if you want to include support for Samsung Galaxy Tab S6 Lite + config SAMSUNG_R0Q + bool "Support for Samsung Galaxy S22" + default n + depends on SM8450 + help + Say Y if you want to include support for Samsung Galaxy S22 + config SAMSUNG_R8S bool "Support for Samsung Galaxy S20 FE" default n diff --git a/board/Makefile b/board/Makefile index b967d3b..0d10321 100644 --- a/board/Makefile +++ b/board/Makefile @@ -19,5 +19,6 @@ lib-$(CONFIG_SAMSUNG_X1S) += samsung/board-x1s.o lib-$(CONFIG_SAMSUNG_J5LTE) += samsung/board-j5lte.o lib-$(CONFIG_SAMSUNG_J4LTE) += samsung/board-j4lte.o lib-$(CONFIG_SAMSUNG_GTA4XL) += samsung/board-gta4xl.o +lib-$(CONFIG_SAMSUNG_R0Q) += samsung/board-r0q.o lib-$(CONFIG_SAMSUNG_R8S) += samsung/board-r8s.o lib-$(CONFIG_VOLLA_ALGIZ) += volla/board-algiz.o diff --git a/board/samsung/board-r0q.c b/board/samsung/board-r0q.c new file mode 100644 index 0000000..66d8fb3 --- /dev/null +++ b/board/samsung/board-r0q.c @@ -0,0 +1,31 @@ +/* SPDX-License-Identifier: GPL-2.0 */ + +#include +#include +#include + +#ifdef CONFIG_SIMPLE_FB +static struct video_info r0q_fb = { + .format = FB_FORMAT_ARGB8888, + .width = 1080, + .height = 2340, + .stride = 4, + .address = (void *)0xb8000000 +}; +#endif + +int r0q_drv(void) +{ +#ifdef CONFIG_SIMPLE_FB + REGISTER_DRIVER("simplefb", simplefb_probe, &r0q_fb); +#endif + return 0; +} + +struct board_data board_ops = { + .name = "samsung-r0q", + .ops = { + .drivers_init = r0q_drv + }, + .quirks = 0 +}; diff --git a/configs/r0q_defconfig b/configs/r0q_defconfig new file mode 100644 index 0000000..6d0d2b2 --- /dev/null +++ b/configs/r0q_defconfig @@ -0,0 +1,6 @@ +CONFIG_POSITION_INDEPENDENT=y +CONFIG_SM8450=y +CONFIG_SAMSUNG_R0Q=y +CONFIG_TEXT_BASE=0x87000000 +CONFIG_PAYLOAD_ENTRY=0x80b900000 +CONFIG_RAMDISK_ENTRY=0xb6915000 diff --git a/soc/Kconfig b/soc/Kconfig index a5b3303..50d0300 100644 --- a/soc/Kconfig +++ b/soc/Kconfig @@ -132,6 +132,12 @@ config QUALCOMM select QUALCOMM help Say Y if your device uses this Qualcomm SoC + + config SM8450 + bool "Support for QUALCOMM SM8450" + select QUALCOMM + help + Say Y if your device uses this Qualcomm SoC config QEMU_SOC_VIRT bool "Support for QEMU virt aarch64 SoC"