mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-04-13 04:12:33 -05:00
fix: swanstation ps1_rom.bin accepts multiple sizes
SwanStation accepts PS1 (512KB), PS2 (4MB), and PS3 (0x3E66F0) BIOS sizes but only uses the first 512KB. MD5 validates the extracted content, not the full file. List all accepted sizes to eliminate the false size mismatch discrepancy. validation.py: support size as list in emulator profiles. generate_site.py: handle list sizes in emulator page display. All 18 original hash mismatches are now resolved: 0 discrepancies.
This commit is contained in:
@@ -70,11 +70,12 @@ files:
|
||||
aliases: []
|
||||
|
||||
- name: "ps1_rom.bin"
|
||||
description: "PS3 (v5.0 06-23-03 A)"
|
||||
description: "PS3 embedded PS1 BIOS (v5.0 06-23-03 A)"
|
||||
region: "Auto"
|
||||
required: false
|
||||
md5: "81bbe60ba7a3d1cea1d48c14cbcc647b"
|
||||
size: 4089584
|
||||
size: [524288, 4194304, 4089584]
|
||||
validation: [size, md5]
|
||||
source_ref: "src/core/bios.cpp:70"
|
||||
note: "Accepts PS1 (512KB), PS2 (4MB), and PS3 (0x3E66F0) sizes. Only first 512KB used."
|
||||
source_ref: "src/core/bios.h:9, src/core/bios.cpp:70,83"
|
||||
aliases: []
|
||||
|
||||
@@ -1176,7 +1176,10 @@ def generate_emulator_page(
|
||||
if fsystem:
|
||||
details.append(f"System: {_system_link(fsystem, '../')}")
|
||||
if size:
|
||||
size_str = _fmt_size(size)
|
||||
if isinstance(size, list):
|
||||
size_str = " / ".join(_fmt_size(s) for s in size)
|
||||
else:
|
||||
size_str = _fmt_size(size)
|
||||
if fmin or fmax:
|
||||
bounds = []
|
||||
if fmin:
|
||||
|
||||
@@ -102,8 +102,12 @@ def _build_validation_index(profiles: dict) -> dict[str, dict]:
|
||||
index[fname]["crypto_only"].update(c for c in checks if c in _CRYPTO_CHECKS)
|
||||
# Size checks
|
||||
if "size" in checks:
|
||||
if f.get("size") is not None:
|
||||
index[fname]["sizes"].add(f["size"])
|
||||
raw_size = f.get("size")
|
||||
if raw_size is not None:
|
||||
if isinstance(raw_size, list):
|
||||
index[fname]["sizes"].update(raw_size)
|
||||
else:
|
||||
index[fname]["sizes"].add(raw_size)
|
||||
if f.get("min_size") is not None:
|
||||
cur = index[fname]["min_size"]
|
||||
index[fname]["min_size"] = (
|
||||
|
||||
Reference in New Issue
Block a user