Skip to content
/ wiki Public

docs: tell Hi3518EV200 owners to check DDR2 vs DDR3 before flashing - #493

Merged
openipc-ai merged 1 commit into
masterfrom
ev200-ddr3-check
Aug 27, 2026
Merged

docs: tell Hi3518EV200 owners to check DDR2 vs DDR3 before flashing#493
openipc-ai merged 1 commit into
masterfrom
ev200-ddr3-check

Conversation

@openipc-ai

Copy link
Copy Markdown
Collaborator

Follow-up to OpenIPC/u-boot-hi3516cv200#9, which started publishing
u-boot-hi3518ev200-ddr3-{universal,recovery}.bin.

Hi3518EV200 boards ship with either DDR2 or DDR3, and the bootloaders are
not interchangeable — the DRAM type is fixed in a register table baked
into the image, so the wrong one leaves the board with no working memory
at all. The failure is nasty precisely because it looks like something
else: the flash writes and verifies byte-for-byte, and then nothing
boots.

In OpenIPC/firmware#2299 that cost the reporter about a week, a UART
recovery session and a register dump out of their vendor bootloader
before we worked out that the board was DDR3 and every OpenIPC
hi3518ev200 image was DDR2.

md.l 0x20111050 1 from any working HiSilicon U-Boot — including the
vendor's own, before OpenIPC is installed — answers it in one command:
the last hex digit is 5 for DDR2 and 6 for DDR3, per
DMC_CFG_DRAM_TYPE_MASK in drivers/ddr/ddr_ddrc_v500.h. This puts that
check immediately before the bootloader-flashing commands in the Danger
zone section.

Two other things it says, both learned the hard way in that issue:

  • Do not identify the images by size or checksum. The U-Boot build
    generates U_BOOT_DATE/U_BOOT_TIME from date, so the compressed
    payload shifts a few bytes between builds of identical source. The
    published DDR2 and DDR3 sizes have already swapped round once between
    two builds an hour apart.
  • -recovery.bin is not a thing to flash. It is built to fit the
    boot ROM's SRAM window for UART upload to a board that will not boot.

Rendered wording is in the diff; no existing text is changed, only
inserted ahead of the mw.b/tftp/sf write block.

This SoC ships with either kind of memory, and OpenIPC now publishes a
bootloader for each. They are not interchangeable: the DRAM type is fixed
in a register table inside the image, so the wrong one leaves the board
with no working memory at all. It flashes and verifies perfectly and then
boots nothing, which reads as a bad flash or a dead chip and is neither.
That is a week of debugging for the person it happens to -- see
OpenIPC/firmware#2299, where it took a UART recovery session and a
register dump out of the vendor bootloader to identify.

`md.l 0x20111050 1` from any working HiSilicon U-Boot answers it in one
command, so put it next to the flashing instructions rather than leaving
people to find out afterwards.

Also warns against telling the two images apart by size or checksum: the
build embeds a timestamp, so both change between builds of identical
sources and the sizes have already been observed to swap round.

Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
@qodo-free-for-open-source-projects

Copy link
Copy Markdown

PR Summary by Qodo

Document DDR2/DDR3 bootloader selection for Hi3518EV200

📝 Documentation 🕐 Less than 10 minutes

Grey Divider

AI Description

• Adds a DDR register check before Hi3518EV200 bootloader flashing.
• Maps DDR2 and DDR3 boards to the correct universal image.
• Warns against volatile artifact fingerprints and flashing UART-only recovery images.
Diagram

graph TD
  A["Working U-Boot"] --> B["Read DRAM register"] --> C{"Last digit?"}
  C -->|5| D["DDR2 image"] --> F["Flash universal"]
  C -->|6| E["DDR3 image"] --> F
Loading
High-Level Assessment

Placing the hardware check immediately before the destructive flashing commands is the safest and most discoverable approach. A separate troubleshooting page or artifact-identification guidance would be easier to miss, while size and checksum matching is explicitly unreliable because builds embed timestamps.

Files changed (1) +30 / -0

Documentation (1) +30 / -0
install-hisi.mdAdd Hi3518EV200 DRAM detection and bootloader safety guidance +30/-0

Add Hi3518EV200 DRAM detection and bootloader safety guidance

• Documents how to read the memory-controller register and map DDR2 or DDR3 boards to the matching universal bootloader. It also explains why file size and checksum are unreliable identifiers and warns that recovery images are only for UART SRAM upload, not flash installation.

en/install-hisi.md

@qodo-free-for-open-source-projects

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)

Grey Divider

Great, no issues found!

Qodo reviewed your code and found no material issues that require review

Grey Divider

Tip of the day
💡 Did you know, you can ask Qodo to dismiss a finding you disagree with, with your reason on record

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

Qodo Logo

@openipc-ai
openipc-ai merged commit 6be3db8 into master Aug 27, 2026
@openipc-ai
openipc-ai deleted the ev200-ddr3-check branch August 27, 2026 11:05
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