Hi! > I'm playing with S4 mini, and I can get to init/main.c: > > writel(0xffffff, (void *) 0x88100030); > print_kernel_cmdline(saved_command_line); > > I'm not sure I have right .config or pass right parameters to > mkbootimg.
After lot of debugging, I got 6.15 to work. I knew address in dts was
wrong, but I only fixed it in one place, and it needed fixing in
two. Now I have blinking cursor.
As a side effect, I have now patches that can print "hello world" from
first code in init/main.c. I hope to never use them again :-).
+++ b/arch/arm/boot/dts/qcom/qcom-msm8930-samsung-serranolte.dts
@@ -27,7 +27,7 @@ chosen {
framebuffer0: framebuffer@88300000 {
compatible = "simple-framebuffer";
- reg = <0x88300000 0x300000>;
+ reg = <0x88100000 0x300000>;
clocks = <&mmcc DSI_M_AHB_CLK>,
<&mmcc DSI_S_AHB_CLK>,
@@ -144,7 +144,7 @@ touchkey@20 {
reserved-memory {
framebuffer@88300000 {
- reg = <0x88300000 0x300000>;
+ reg = <0x88100000 0x300000>;
no-map;
};
};
I'm booting from patched lk2nd, and using this build script:
rootfs.cpio _is_ required, probably due to lk2nd bug.
#!/bin/bash
set -e
make -j 25 ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- oldconfig zImage dtbs
cat arch/arm/boot/zImage
arch/arm/boot/dts/qcom/qcom-msm8930-samsung-serranolte.dtb > kernel.bin
mkbootimg -o boot.img --pagesize 2048 --base 0x80200000 --kernel_offset
0x00008000 --ramdisk_offset 0x02000000 --second_offset 0x00f00000 --tags_offset
0x00000100 --kernel kernel.bin --ramdisk ../rootfs.cpio.gz --cmdline
"console=ttyMSM0,115200 pmos_boot_uuid=55d29927-32a0-4d9a-b36a-93ba3c8bd2f2
pmos_root_uuid=88c36245-5986-4837-883c-6f8e6736b6d8 pmos_rootfsopts=defaults"
#mkbootimg -o boot.img --pagesize 4096 --base 0x80200000 --kernel_offset
0x00008000 --ramdisk_offset 0x02000000 --second_offset 0x00f00000 --tags_offset
0x00000100 --kernel kernel.bin --ramdisk ../rootfs.cpio.gz --cmdline
"earlycon=earlyfb"
fastboot boot boot.img
#fastboot flash boot boot.img
This should be required lk2nd patch:
diff --git a/app/aboot/aboot.c b/app/aboot/aboot.c
index a4514431..f9de979a 100644
--- a/app/aboot/aboot.c
+++ b/app/aboot/aboot.c
@@ -3415,9 +3415,12 @@ void cmd_boot(const char *arg, void *data, unsigned sz)
#if DEVICE_TREE
scratch_offset = image_actual + page_size + out_len;
/* find correct dtb and copy it to right location */
+ /*
ret = copy_dtb(data, scratch_offset);
dtb_copied = !ret ? 1 : 0;
+ */
+ dtb_copied = 0;
#else
if (check_aboot_addr_range_overlap(hdr->tags_addr, MAX_TAGS_SIZE) ||
check_ddr_addr_range_bound(hdr->tags_addr, MAX_TAGS_SIZE))
@@ -3443,9 +3446,12 @@ void cmd_boot(const char *arg, void *data, unsigned sz)
*/
if (!dtb_copied) {
void *dtb;
+ /*
dtb = dev_tree_appended((void*)(ptr + page_size),
hdr->kernel_size, dtb_offset,
(void *)hdr->tags_addr);
+ */
+ dtb = 0;
#if WITH_LK2ND_DEVICE_2ND
if (!dtb && lk2nd_device2nd_have_atags())
boot_type |= BOOT_ATAGS_COPY;
I'm using this tree
commit f26b1f93ec570209ece47c957339152010ab1392 (HEAD, origin/msm8227-6.15)
Merge: 1178196dd6f3 858b82a40626
Author: rva3 <[email protected]>
Date: Sat Oct 25 11:59:15 2025 +0300
Merge pull request #4 from julianrother/msm8227-6.15-samsung-serranolte
Samsung Galaxy S4 Mini LTE (samsung-serranolte) support
commit 858b82a40626660bc2a4c36b71ff7811bdf26a03
Author: Julian Rother <[email protected]>
Date: Fri Oct 24 23:29:06 2025 +0200
I'm using lk2nd based on this:
commit 792a6b489fad1f247fd29dba81d1f27595ac4778 (origin/main, origin/HEAD)
Author: Erikas Bitovtas <[email protected]>
Date: Sun Dec 28 15:56:27 2025 +0200
dts: msm8939: asus-z00t: fix typo
Signed-off-by: Erikas Bitovtas <[email protected]>
I'm attaching my .config in case someone wants to repeat all this.
Best regards, and thanks for all the help,
Pavel
--
I don't work for Nazis and criminals, and neither should you.
Boycott Putin, Trump, Netanyahu and Musk!
config.gz
Description: application/gzip
signature.asc
Description: PGP signature

