Skip to content

Panfrost GPU stack for ODROID-M1 (B안) — PanVK 서피스 생성 실패로 폐기 - #3

Open
Pyohwan wants to merge 26 commits into
odroid-m1-bsp-kernelfrom
odroid-m1-panfrost
Open

Panfrost GPU stack for ODROID-M1 (B안) — PanVK 서피스 생성 실패로 폐기#3
Pyohwan wants to merge 26 commits into
odroid-m1-bsp-kernelfrom
odroid-m1-panfrost

Conversation

@Pyohwan

@Pyohwan Pyohwan commented Aug 8, 2026

Copy link
Copy Markdown
Owner

목적

A안(벤더 blob, Mali-G52 kbase)에서 확정된 GameCube/PSX-swanstation GPU 폴트(DATA_INVALID_FAULT)와 Wayland-client EGL 초기화 실패가 blob 고유 문제인지, SoC/렌더링 파이프라인 자체 한계인지 판별하기 위해 메인라인 Panfrost(drm/panfrost + Mesa)로 GPU 스택을 교체.

커밋 (공통 조상 41f34e4dfd 대비, 전체 목록은 git log 참고)

  • ed3452f3ec: GPU 스택을 Mali-G52 blob → Mesa panfrost로 전환 (BR2_PACKAGE_MALI_G52_ODROIDM1 제거, Mesa3D+LLVM+panfrost 갤리엄 드라이버 추가)
  • a62a86e63b: batocera-system의 TRX 자동선택 조건을 blob 패키지명 대리변수에서 실제 desktop-GL 능력치 기준으로 수정 (공용 파일 버그, GPU 무관)
  • a730397160: Panfrost 이미지 빌드 중 발견된 Kconfig 갭 수정 (LLVM 누락 시 조용히 GLES/EGL 빠지는 문제 등)
  • 2fc7b7d8b9: .board의 커널 저장소 버전을 panfrost-enable 브랜치로 연결 (v1 빌드 때 이 포인터가 베이스 브랜치를 계속 가리키고 있어서 커널 DTS 수정이 전혀 반영 안 됐던 버그 수정)
  • 160dc66cfb: panfrost-enable 커널을 브랜치명 대신 커밋 해시로 고정(재현성) + 반복 개발용 KERNEL_SRCDIR 마운트 추가
  • 2dd848754a: SSD 마이그레이션 이후 local.mk.exampleKERNEL_SRCDIR 경로 수정
  • 6417b0c3dc: show_fps 켜져 있으면 GALLIUM_HUD=fps를 항상 주입(에뮬레이터 자체 fps 표시 위에 얹는 Mesa 그래프)
  • 1246f4761d: B(panfrost) 브랜치에서 PanVK + Vulkan 가능 시스템 활성화
  • c5bb8532f6: vkquake2를 B에서 비활성화 — 이 GLES 전용 보드에 없는 desktop LIBGLU를 하드 셀렉트하고 있었음
  • 38ab148c34: GLES 전용 Vulkan 빌드를 막던 vkquake2/pcsx2의 desktop-GL 블로커 수정
  • 04c0e462f6: libretro-flycastvl 제거 — 이 보드용 ARM 플랫폼 배선이 없는 스테일 포크
  • 370edb0a00: libretro-parallel-n64에 RK3568 보드 브랜치 추가 — x86 SSE 빌드 실패 수정
  • 5f1cf74e76: libretro-ps2 제거 — CMake가 우리 크로스컴파일 아키텍처를 식별 못함
  • 284a895027: RK3568에서 실제 PPSSPP Vulkan 활성화 — ARM_NO_VULKAN으로 강제 비활성화돼 있었음
  • 20925ba07c: odroidm1 기본 global.powermode를 highperformance로
  • 0b0bb0245c: pcsx2 기본 에뮬레이터 수정 + 컴포지터 없는 보드용 eglfs
  • 69407743f1: dolphin도 컴포지터 없는 보드용 eglfs (duckstation/pcsx2와 동일 패턴)
  • c41b08978c: RetroArch의 exit_emulator를 Start와 같은 버튼에 바인딩
  • 506ab9af6d: 보드 전용 BATOCERA_TARGET_BSP_ODROIDM1 Kconfig 심볼 신설 — BR2_PACKAGE_UBOOT_ODROID_M1을 "이 보드 아님" 프록시로 쓰던 게 공유 11보드 타겟에서 rocknix-joypad/SDL3_X11을 조용히 떨어뜨리던 버그 수정 (A안과 동일 수정, PR ODROID-M1 dedicated target: hardkernel BSP kernel + Mali-G52 blob + VU8M overlays #1 참고)
  • 9d0d091d9c: docker.mk에 실재하지 않는 EXTRA_SRCDIR_MOUNTS 변수를 언급하던 주석 정리
  • 7c6e0c3d07: BATOCERA_TARGET_BSP_ODROIDM1 심볼에 prompt 추가 — prompt 없는 bool은 defconfig에서 직접 값이 안 먹는 버그 수정(A안과 동일, 2차 리뷰 검증까지 완료)

현재 상태 — 최종 차단 요인까지 규명, 폐기 확정 (draft로 유지하는 이유)

초기 부팅 행(v1~v4, OP-TEE Secondary CPU 초기화 부근 완전 무응답)은 이후 커밋(위 panfrost-enable 커밋 해시 고정 등)으로 해소되어 v9까지 진행됨 — PanVK가 KHR_display 서피스 생성 단계에서 막히는 것을 v9 실기에서 확인(C안 PR #4 본문의 "목적" 절 참고, 같은 조사의 교차 결과). 즉 최종 차단 요인은 부팅 행이 아니라 PanVK의 Vulkan 서피스 생성 실패로 확정됨 — 이것이 g29p1 벤더 blob 기반의 C안(Vulkan 실제 화면 출력 성공)으로 완전히 전환하게 된 근거.

⚠️ 이번 세션에서는 v9 이후 상태를 실기로 재검증하지 않았음 — 위 결론은 이 브랜치와 PR #4 본문 교차 확인 기준. 초기 부팅 행 관련 진단 히스토리는 Joplin B안 노트 참고.

머지 대상 아님 — 조사 완료, C안으로 전환 후 영구 보류된 디버깅 체크포인트 겸 리뷰/코멘트용 draft.

Pyohwan and others added 18 commits August 7, 2026 18:52
Static compatibility check before flipping anything: panfrost's
of_match_table matches this board's DTS gpu node exactly ("arm,mali-
bifrost"), the driver's unnamed clk_get grabs the first listed clock
(the SCMI-backed "clk_mali", so no clk-scmi -517 risk - CONFIG_COMMON_
CLK_SCMI is already =y), and panfrost's default regulator name ("mali")
matches the board's "mali-supply" property exactly. The board dtsi
override only adds mali-supply + status=okay, no custom kbase-only
properties - this DTS was effectively already mainline-shaped, which
was the main open risk per the Panfrost integration plan (Joplin "시스템별
ROM 테스트 → Panfrost 통합 지시서").

Kernel side (linux-defconfig.config): CONFIG_DRM_PANFROST m->y,
CONFIG_MALI_BIFROST unset (child options under its menuconfig will be
dropped by the standard olddefconfig pass during build).

buildroot side: disable BR2_PACKAGE_MALI_G52_ODROIDM1, enable full
BR2_PACKAGE_MESA3D with the panfrost gallium driver + EGL/GLES, which
takes over as the HAS_LIBEGL/HAS_LIBGLES/HAS_LIBGBM provider. No Vulkan
driver enabled - the A/B plan explicitly excludes Vulkan on both sides
(blob has none, Mesa's PanVK is non-conformant on G52) to keep the
comparison scoped to GLES only. Kronos's mesa3d-headers-vs-mesa3d
conflict no longer applies on this branch (noted but not re-enabled,
to keep this diff scoped to the GPU driver swap).

Not yet boot-tested - this is the config-only half of the swap, before
an actual hardware smoke test.
…, not the odroid-m1 blob package by name

TRX (Tomb Raider I-III) was excluded on this board via `!BR2_PACKAGE_
MALI_G52_ODROIDM1` (commit c0d2cc9) as a stand-in for "no desktop
GL here" - correct at the time (only the blob existed), but using the
package name instead of the actual capability flag meant disabling
that package (for the Panfrost A/B swap) flipped the condition back on,
hard-stopping the build: TRX still unconditionally selects libglew
(package/batocera/ports/trx/Config.in has no guard of its own), which
needs BR2_PACKAGE_HAS_LIBGL - false for both GPU stacks on this board
(blob is GLES-only; the panfrost gallium driver here only has
OPENGL_ES/OPENGL_EGL enabled, no desktop OPENGL) - so the custom
dependency-consistency check ("libgl is in the dependency chain of
libglew that has added it to its _DEPENDENCIES variable without
selecting it") fires regardless of which stack backs the board.

Switched the condition to check BR2_PACKAGE_HAS_LIBGL directly, which
is correct for both stacks (and any future one) without needing a
per-package name check.
…ing up the Panfrost image

- batocera-system/Config.in: rocknix-joypad and sdl3's X11 backend were
  gated on !BR2_PACKAGE_MALI_G52_ODROIDM1 as a stand-in for "this is the
  odroid-m1 board", which flipped back on and hard-stopped the dependency
  chain once the blob package was disabled. Their real reasons (a kernel-
  header incompatibility, an upstream SDL3/XInput2 bug) are unrelated to
  the GPU driver, so swap in the always-present BR2_PACKAGE_UBOOT_ODROID_M1
  board identifier instead. (moonlight-qt's similar guard is left as-is -
  its exclusion reason, a blob-specific eglGetPlatformDisplay gap, is
  genuinely GPU-driver-specific and worth re-testing under Panfrost.)
- .board: add a host-machine BR2_JLEVEL=4 cap - BR2_JLEVEL=0 (auto =
  nproc+1) drove ~8GB of swap building LLVM+Mesa3D on a 16-core/15GB host.
- buildroot (submodule): HOST_MESA3D_CONF_OPTS never matched Mesa's C++
  RTTI setting to LLVM's the way MESA3D_CONF_OPTS already did, so host-
  mesa3d's meson configure failed once it needed -Dllvm=enabled for its
  panfrost host tool.

Panfrost image now builds and produces a bootable
batocera-rk3568-bsp-odroidm1-44-20260807.img.gz. Hardware smoke test and
A/B ROM matrix against the Mali-G52 blob are next.
The panfrost-enable kernel branch was created at the start of this work
but BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION was never actually updated to
point at it - the first panfrost build silently used the shared
fix-hdmi-dsi-dual-livelock branch instead (same one track A/blob uses).
CONFIG_DRM_PANFROST=y still took effect via the defconfig merge, so the
driver compiled in, but the DTS gpu node it got was the vendor-kbase-
oriented one (wrong interrupt-names case, Rockchip-gated OPP table) -
see the panfrost-enable branch's rk356x.dtsi fix for the real-hardware
dmesg trace that surfaced this.
…R dev mount

BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION was a branch name - buildroot's git
download cache keys its dl/ tarball off that literal string, not the
commit it resolves to, so pushing new commits to panfrost-enable was
invisible to buildroot forever once the first tarball existed. v2/v3/v4
all silently rebuilt v2's tree this way (dl/linux/git stayed pinned at
1139cde0 through two more real pushes) - the "OPP/devfreq isn't the
cause" conclusion drawn from those three "different" real-hardware boots
was invalid, since they were all the same binary.

Pin to the current HEAD (13fcfde92, the GPU clock fix) for archival
builds, and add docker.mk's KERNEL_SRCDIR opt-in mount + a local.mk
template for the actual fix going forward: buildroot's own
OVERRIDE_SRCDIR mechanism for iterative kernel development, which
bypasses the download cache entirely instead of fighting it.

Also bumped BR2_JLEVEL 4->8: docker stats showed ~2.7GiB/15GiB used
during a kernel-only rebuild even at JLEVEL=4, well under the swap-
triggering LLVM+Mesa3D combination JLEVEL=4 was originally set for.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
~/git_projects no longer exists (2026-08-10 SSD swap moved everything to
/mnt/2026_990pro_2tb_1_data/git_projects/, no symlink recreated on
purpose per the migration handoff).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
…side graph layered on top of each generator's existing fps display

Single injection point (right where hud_support already sets
MANGOHUD_DLSYM/MANGOHUD_CONFIGFILE) instead of touching every generator
file individually - GALLIUM_HUD is a plain env var Mesa's gallium drivers
read at process start, so it's a no-op on anything that never loads a
gallium GL/GLES context (non-GL systems, the vendor Mali blob, older Mesa
without HUD support). That makes it a natural fallback to each
generator's own show_fps wiring (retroarch's fps_show, dolphin's
ShowFPS, etc.) rather than requiring an either/or branch per emulator.

Surfaced this session testing odroid-m1's Panfrost track: no numeric
GPU-load metric is exposed anywhere on this kernel (no devfreq node - the
GPU clock is statically pinned - no debugfs, and gallium_hud itself
rejects the "GPU-load" query for this driver: "unknown driver query
'GPU-load'"), but the graph-based fps/frametime view was still strictly
better than the existing plain-number counter for judging real-time
performance during A/B testing.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
PanVK (Mesa's Panfrost Vulkan driver) is a B-only capability - the A
track's vendor blob has zero Vulkan support at all, so this was never
an A/B comparison axis and doesn't need to stay excluded for fairness.
The previous "PanVK is non-conformant on G52" comment was an unverified
assumption; Mesa 26.1.5's docs/features.txt confirms Vulkan 1.0 is fully
DONE on panvk with no Bifrost/Valhall gen restriction.

Adds, all additive to the existing GLES-tested matrix:
- BR2_PACKAGE_BATOCERA_VULKAN + MESA3D_VULKAN_DRIVER_PANFROST (PanVK)
- PCSX2 (new system, never built on this board before)
- Dolphin standalone (Vulkan gfxbackend, distinct from libretro-dolphin)
- libretro: parallel-n64, flycastvl, ppsspp, azahar, play, ps2
- vkquake/vkquake2/vkquake3 auto-select via BATOCERA_VULKAN

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
…nly board doesn't have

BR2_PACKAGE_BATOCERA_VULKAN auto-selects all three vkquake variants, but
vkquake2's Config.in unconditionally selects BR2_PACKAGE_LIBGLU (unlike
vkquake/vkquake3), which needs BR2_PACKAGE_HAS_LIBGL - false here since
Panfrost only provides GLES/EGL. buildroot hard-stops the build over this
rather than warning, confirmed via a failed build attempt.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
vkquake2 genuinely builds ref_gl.so and ref_vk.so side by side (real
dual-renderer engine), so batocera-system's auto-select for it needs
BR2_PACKAGE_HAS_LIBGL as well as BATOCERA_VULKAN/XORG7 - false on this
board (Panfrost only exposes GLES/EGL). A defconfig "is not set" line
in the board file can't override a forced Kconfig `select`, so this had
to be fixed at the actual select condition, confirmed via a failed build
("libgl is in the dependency chain of libglu... Stop.").

pcsx2's WXWIDGETS select turned out to be unrelated dead weight - its
.mk never references wx in any CMake option (OpenGL/Vulkan are already
properly gated on HAS_LIBGL/BATOCERA_VULKAN), so gated the select and
the .mk dependency on HAS_LIBGL too, matching how pcsx2 actually gates
its own optional GL support.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
… board

Confirmed via a real build failure: libretro-flycastvl.mk only has ARM
platform/ARCH branches for specific boards (RPi4/5, RK3326, H3/H5/H6),
not rk3568/odroidm1, so it silently fell through to the x86_64 default
and pulled in xbyak's x86 JIT code unconditionally ("fatal error:
cpuid.h: No such file or directory" in core/hw/aica/dsp_x64.cpp). The
pinned commit is from Oct 2021 (unmaintained), and libretro-flycast
already covers Dreamcast/Vulkan once built with BATOCERA_VULKAN=y - not
worth patching a stale duplicate core for.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
…d failure

odroidm1/rk3568 wasn't in upstream's per-board platform/ARCH table, so it
fell through to the generic default where the Makefile's own ARCH
fallback (uname -m) picks up the build host's x86_64 arch instead of the
cross-compile target, pulling in xbyak's x86-only cpuid.h unconditionally
(confirmed via a real build failure: "-msse"/"-msse2" rejected by
aarch64-buildroot-linux-gnu-g++ compiling gles2rice). Added an explicit
branch mirroring RK3588/RK3576/H5 (WITH_DYNAREC=aarch64), reusing H5's
CPUFLAGS (armv8-a+crc, cortex-a53 tuning) since it's a safe baseline
subset for RK3568's Cortex-A55 cores with no extension-gated instructions.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
Confirmed via a real build failure: libretro-ps2's own BuildParameters.
cmake fails with "Unsupported architecture: unknown" for our aarch64
cross-compile target - a deeper upstream CMake arch-detection issue, not
a quick fix. PS2 is already covered twice over (PCSX2, libretro-play).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
…ULKAN

ppsspp.mk only flips ARM_NO_VULKAN=OFF (i.e. actually allows Vulkan) for
RPi4/5; every other ARM board gets ARM_NO_VULKAN=ON regardless of the
general -DVULKAN=ON flag, silently compiling Vulkan support back out.
Confirmed via the built binary having zero Vulkan symbols despite
BATOCERA_VULKAN=y. Added RK3568 to the same allowlist as RPi4/5.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
global.powermode was never actually set in this board's default
batocera.conf - every A/B track fps measurement taken so far ran under
batocera-power-mode's unset-fallback (set_default: EPP/governor
"default"), not highperformance, despite the file's own comment already
documenting that n64/fbneo/psx/nds measurably benefited from it. Setting
the factory default here (ES's Game Settings > Power Mode menu still
overrides it live, same precedence as before).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
configgen-defaults-rk3568.yml still defaulted ps2 to libretro/play (a
stale upstream default from before PCSX2 was viable on aarch64) - our
board only registers the standalone pcsx2 emulator in es_systems.yml,
so this stale default made every PS2 launch try a nonexistent
libretro core and crash immediately ("Frontend is built for dynamic
libretro cores, but path is not set"). Confirmed live and fixed by
pointing the default at pcsx2/pcsx2 instead.

Separately, pcsx2-qt itself always defaulted to the xcb Qt platform
plugin, which aborts outright on this board (no X11, no compositor -
same failure class documented in duckstationGenerator.py for
duckstation-qt/melonDS). Reused the exact same WAYLAND_DISPLAY/DISPLAY
detection -> eglfs fallback pattern. Confirmed live: PCSX2 now reaches
its own BIOS-missing dialog instead of crashing at Qt init.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
…pcsx2

dolphin-emu (standalone) always defaulted to the xcb Qt platform plugin,
aborting outright on this board (no X11, no compositor). Confirmed live
that eglfs actually works for Dolphin (unlike pcsx2-qt, which hits a
separate "Failed to get window info from widget" Qt/eglfs multi-widget
limitation) - Dolphin ran a real GPU-rendered session via
libqeglfs-kms-integration.so + libgallium for 90+ seconds with no crash.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
writeHotKeyConfig() only ever wrote input_enable_hotkey_btn (arming the
hotkey modifier), never any joypad action bound to it - cleanControllerConfig
even actively disable_all()s input_exit_emulator* every game launch via
prefix match. Only the keyboard input_exit_emulator="escape" default
actually quit a running libretro core; Hotkey+Start (batocera's own
force-quit convention, see es_input.cfg's keyboard hotkey=select binding)
did nothing on a gamepad.

Confirmed live on ODROID-M1 (SHAKS S6b pad, FBNeo Korean core/Night
Slashers, discovered on the C track) - Select+Start did not exit until
input_exit_emulator_btn was set to Start's button id. This is shared
configgen code, not board- or GPU-track-specific, so porting to B here.

@Pyohwan Pyohwan left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AI 1차 리뷰 (참고용)

읽은 범위: 변경 파일 17개 patch 전량 + 베이스 브랜치(odroid-m1-bsp-kernel) head와의 중복 대조, configs/batocera-rk3568.board@master.

형식 코드 품질 컨벤션 테스트/CI 본문 정합
⚠️ ⚠️ ✅ (lint·unit-tests pass)

결론: WIP draft라는 점을 감안해도 본문이 브랜치 상태를 전혀 반영하지 못하고 있어 리뷰 기준점이 잡히지 않습니다. 코드 지적은 라인 인라인 6건(✅ 2건 포함)을 참고해 주세요.

1. 본문 갱신이 필요합니다

  • 본문 "## 커밋"에 4개가 적혀 있으나 실제 커밋은 19개입니다.
  • 본문 "## 현재 상태"는 "실기 부팅 미해결"인데, 그 뒤로 다음 커밋들이 붙어 있습니다.
    • Enable PanVK + Vulkan-capable systems on B(panfrost) branch
    • Enable real PPSSPP Vulkan on RK3568
    • odroidm1: default global.powermode to highperformance
    • configgen: inject GALLIUM_HUD=fps whenever show_fps is on

부팅 hang이 해소된 것인지, 아니면 hang과 무관한 작업이 계속 쌓인 것인지가 본문에서 구분되지 않습니다. WIP draft에서 본문의 유일한 역할이 "지금 어디까지 왔는가"인 만큼 이 부분만이라도 갱신 부탁드립니다.

2. 베이스 대비 diff가 오염되어 있습니다

베이스 브랜치가 이 브랜치 분기 이후로 앞서 나가면서, 이미 base에 존재하는 변경이 diff에 다시 나타납니다(BR2_JLEVEL=8, local.mk.example, docker.mkKERNEL_SRCDIR). 상세는 .board 16행 인라인에 남겼습니다.

리베이스하면 "B안 고유 변경"만 남아 A/B 비교의 근거로도 쓸 수 있게 됩니다.

3. A/B/C 비교 목표 관점

세 트랙이 GPU 스택만 다른 것이 아니라 dolphin 버전·PS2 코어·BR2_JLEVEL·커널 브랜치까지 갈라져 있습니다. 최종적으로 "이 시스템은 A, 저 시스템은 C"를 판정하려면 GPU 스택 외 변수는 공통 조상에 맞춰두는 편이 안전합니다. 위 리베이스가 그 정리를 겸합니다.

4. 형식

assignee 미지정입니다.

5. AI 한계 — 사람 확인 필요

부팅 hang의 원인(OP-TEE / Secondary CPU 초기화 구간), panfrost probe의 실기 동작, DTS 수정의 타당성은 정적 분석 범위 밖이라 판단하지 않았습니다.

🤖 Reviewed by Claude Opus 5 (1M context)


# Tomb Raider 1, 2 & 3
select BR2_PACKAGE_TRX if BR2_PACKAGE_XORG7 && !BR2_PACKAGE_MALI_G52_ODROIDM1
select BR2_PACKAGE_TRX if BR2_PACKAGE_XORG7 && BR2_PACKAGE_HAS_LIBGL

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ 프록시(!BR2_PACKAGE_MALI_G52_ODROIDM1)를 실제 능력치(BR2_PACKAGE_HAS_LIBGL)로 바꾼 것은 정확한 근본 수정입니다. .board 주석의 "fixed at the real root cause instead"에 동의합니다.

다만 같은 커밋에서 351행·2263행은 이 기준이 적용되지 않았습니다(아래 참고).

Comment thread package/batocera/core/batocera-system/Config.in Outdated
# compile. Watch `docker stats`/`free -h` again next time LLVM+Mesa3D are
# actually in the build (fresh from-scratch image, not just this kernel
# iteration loop) and drop back toward 4 if swap grows the same way.
BR2_JLEVEL=8

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

베이스 브랜치(odroid-m1-bsp-kernel)에도 같은 주석과 함께 BR2_JLEVEL=8이 이미 들어가 있습니다(위치만 다릅니다). 지금 상태로 머지하면 같은 파일에 BR2_JLEVEL=8이 두 줄 생깁니다.

local.mk.exampledocker/docker.mkKERNEL_SRCDIR#3·#4가 각각 들고 있습니다. 현재 base 위로 리베이스하면 diff가 B안 고유 변경만 남아 리뷰 비용이 크게 줄어듭니다.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이번 라운드에서는 리베이스는 안 했습니다 — B는 v9까지 진행 후 PanVK KHR_display 실패로 최종 폐기 확정된 상태라(PR 본문 갱신함, C안 PR #4와 교차 확인), 실사용 diff 정리보다 결론 기록이 우선이라고 판단했습니다. BR2_JLEVEL 중복 자체는 여전히 남아있는 상태입니다.

# PCSX2 (PS2) - never tested on this board before (no PS2 core at all
# previously - libretro-play/libretro-ps2 below are the only alternatives,
# both also new). Explicitly supports aarch64 in its own Config.in
# (depends on BR2_x86_64 || BR2_aarch64) and needs BR2_PACKAGE_XORG7, which

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

여기서는 "needs BR2_PACKAGE_XORG7, which this board already has on"이라고 되어 있는데, package/batocera/gpu/mali-g52-odroidm1/mali-g52-odroidm1.mk의 주석은 "This target has no X11 (no XWayland)"입니다. 실제로는 XORG7이 켜진 채 런타임에 쓰이지 않는 상태로 읽히는데, 그래서 공용 Config.in에 부정 조건이 세 군데나 붙었습니다.

이 타겟에서 XORG7 자체를 끌 수 있는지 확인해 보시면, SDL3_X11·TRX·moonlight-qt 특례가 한꺼번에 사라질 수 있습니다.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이것도 이번엔 안 건드렸습니다 — XORG7을 완전히 끌 수 있는지는 PCSX2 빌드 의존성까지 걸린 문제라 검증 없이 손대기엔 리스크가 커서, 지적하신 내용 그대로를 여전히 열린 질문으로 남겨둡니다.

# checkout>) to build straight from the working tree via buildroot's
# LINUX_OVERRIDE_SRCDIR - no commit/push/hash-bump per iteration. Switch
# back to a hash pin here once a build is verified good enough to archive.
BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="13fcfde92b934f0dca1905fe98d976ff003cf369"

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ 브랜치명 → 커밋 해시 고정과 그 사유(buildroot의 dl 캐시가 리터럴 문자열로 키를 만든다)는 정확합니다. local.mk.exampleLINUX_OVERRIDE_SRCDIR 안내까지 세트로 갖춰져 재발 방지 장치로 충분해 보입니다.

Comment thread docker/docker.mk Outdated
Same fix as odroid-m1-bsp-kernel: BR2_PACKAGE_UBOOT_ODROID_M1 was being
used as a "not this board" proxy in two Config.in gates (rocknix-joypad,
SDL3_X11), but the shared 11-board rk3568 target also sets that symbol,
so both gates were silently dropping rocknix-joypad and SDL3_X11 for the
other 10 boards too. Introduces a real per-target identity symbol
(BR2_PACKAGE_BATOCERA_TARGET_BSP_ODROIDM1, set only by this dedicated
target's own .board file) and switches both gates to it. Line 1228 (TRX)
already used a real capability check (BR2_PACKAGE_HAS_LIBGL) and needed
no change.
Only KERNEL_SRCDIR is actually wired up as an opt-in bind mount; the
parenthetical describing a generic <NAME>_SRCDIR=<path> mechanism via
EXTRA_SRCDIR_MOUNTS never existed.
…less bool wasn't settable from defconfig

A bare "bool" (no prompt string) config isn't directly settable via a
defconfig/.board file's "=y" line - Kconfig accepts the assignment
without error but the value never actually takes, defeating the whole
point of a board-identity symbol meant to be set from
configs/batocera-rk3568-odroidm1.board. Confirmed via a real
defconfig+conf run: rocknix-joypad/SDL3_X11 stayed dropped on the shared
rk3568 target (BSP_ODROIDM1 silently not set at all) until this fix, and
now correctly restored there while staying off on this dedicated target.

@Pyohwan Pyohwan left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AI 2차 리뷰 (참고용)

읽은 범위: 1차 리뷰 시점(c41b0897) → 현재(7c6e0c3d) 커밋 3개와 diff, head의 batocera-system/Config.in 심볼 정의·게이팅, docker/docker.mk, .board, PR 본문·제목.

1차 지적 대응 검증

# 지적 결과 검증 근거
1 본문이 브랜치 상태와 불일치 커밋 목록 전면 갱신, "현재 상태" 절이 결론(부팅 행 해소 → PanVK KHR_display 서피스 실패가 최종 차단)으로 정정됨
2 프록시 게이팅 BATOCERA_TARGET_BSP_ODROIDM1 신설·적용(A안과 동일 방식)
3 docker.mk의 EXTRA_SRCDIR_MOUNTS 주석에서 제거
4 베이스 대비 diff 오염(리베이스) 보류 사유 명시적 — B안 폐기 확정이라 결론 기록 우선. 판단 존중합니다
5 XORG7 서술 충돌 보류 PCSX2 빌드 의존성까지 걸려 검증 없이 손대기엔 위험하다는 판단. 타당합니다

특히 좋았던 점: "이번 세션에서는 v9 이후 상태를 실기로 재검증하지 않았음"이라는 단서를 본문에 직접 넣으신 것. 폐기 결론을 기록하면서 그 결론의 검증 강도까지 같이 남겨두면, 나중에 이 브랜치를 다시 열 사람이 무엇을 다시 확인해야 하는지 바로 압니다.

2차 신규 지적 (형식 2건, 인라인 없음)

  1. 제목이 본문과 반대입니다. 제목은 여전히 WIP: Panfrost GPU stack for ODROID-M1 (B안) — boot hang unresolved인데, 본문은 부팅 행이 해소됐고 최종 차단 요인은 PanVK 서피스 생성 실패라고 정정됐습니다. draft라 머지 커밋이 되지는 않지만 PR 목록·알림에서 보이는 것은 제목입니다. — PanVK 서피스 생성 실패로 폐기 정도로 바꾸면 본문과 맞습니다.

  2. 본문 "커밋 (20개)"인데 실제 22개입니다. 9d0d091d9c 뒤의 심볼 prompt 커밋(7c6e0c3d0)과 그 앞 1건이 목록에 없습니다. 1차에서 지적드린 것과 같은 종류의 drift가 다시 시작된 셈이라, 개수를 세는 표현((20개))을 빼고 목록만 두시면 이후 갱신 부담이 줄어듭니다.

판정

1차 ❌ 2건이 모두 해소됐고, 보류 2건은 사유가 명확해 이견 없습니다. 폐기 확정된 조사 브랜치라는 성격을 감안하면 남은 것은 제목·커밋 수 표기 정리뿐입니다.

🤖 Reviewed by Claude Opus 5 (1M context)

@Pyohwan Pyohwan changed the title WIP: Panfrost GPU stack for ODROID-M1 (B안) — boot hang unresolved Panfrost GPU stack for ODROID-M1 (B안) — PanVK 서피스 생성 실패로 폐기 Aug 17, 2026
@Pyohwan
Pyohwan marked this pull request as ready for review August 17, 2026 02:57
Pyohwan and others added 2 commits August 18, 2026 15:58
This pad's wireless receiver never forwards a Guide-button (BTN_MODE)
press to the OS in PC mode - confirmed live via evtest on the raw
device: a real button press showed nothing, while the one time BTN_MODE
did register turned out to be spurious (unrelated to the physical
press). Hotkey+Start was therefore unreachable on this exact pad, so
the documented "Select+Start" force-quit convention (0435f07)
silently never worked.

Rebind hotkey to id 6 / BTN_SELECT, matching batocera's own
Select=hotkey convention and this project's SHAKS S6b precedent
(bcf49a8) of overriding the build-time es_input.cfg default for a
pad actually used with this board, rather than relying on a per-user
/userdata override that a fresh reflash would wipe.

Confirmed live (Track C image): Select+Start now force-quits a running
libretro core.
Backport from Track C (odroid-m1-g29p1): logs one usec timestamp per
present to FRAMETIME_LOG (env-gated, zero overhead when unset) for the
A/B/C fps benchmark methodology. Hooked at the function-pointer level
in SDL_EGL_LoadLibraryOnly() rather than the generic SDL_EGL_SwapBuffers()
helper - Wayland/KMSDRM backends call the eglSwapBuffers pointer directly
and never go through that helper, so a hook there would never fire.
Verified against the pinned SDL2 2.32.10 source (same version A/C use)
and confirmed live on Track C. NOTE: this worktree's buildroot submodule
isn't checked out locally, so patch application against B's exact SDL2
source wasn't dry-run verified here - watch for a patch-apply failure on
B's next sdl2 build if its pinned SDL2 version differs from 2.32.10.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
Pyohwan and others added 3 commits August 18, 2026 21:37
Same fix as Track C: ES inherits FRAMETIME_LOG so its forked game
picks it up, but ES itself also links libSDL2 and does its own swaps,
so it was writing into the same log file as the game and corrupting
it with interleaved timestamps from two processes. Exclude the
frontend by /proc/self/comm so only the actual emulator logs.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
ES's Game Settings > Power Mode menu showed "auto" (no saved user
override) while highperformance was silently active underneath via the
factory default - misleading, since the menu should reflect what's
actually applied. Left unset so "auto" in the menu genuinely means auto;
the user picks High Performance there explicitly when wanted.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4zVPhdz6gmjHPNpGGTQei
@Pyohwan

Pyohwan commented Aug 23, 2026

Copy link
Copy Markdown
Owner Author

B안(odroid-m1-panfrost)은 PanVK 서피스 생성 실패로 폐기, 참고/보존용으로 브랜치만 남김. C안이 최종 선택.

@Pyohwan Pyohwan closed this Aug 23, 2026
@Pyohwan

Pyohwan commented Aug 23, 2026

Copy link
Copy Markdown
Owner Author

같은 이유로 다시 열어둠 - B안도 비교표 작업 대상.

@Pyohwan Pyohwan reopened this Aug 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant