Xiaomi Redmi Note 9 / Redmi 10X 4G (xiaomi-merlin)
This device runs a Downstream kernel. Some UIs will not work, and most features (3D acceleration, audio, etc.) may be broken. |
![]() The device, running XFCE4 | |
Manufacturer | Xiaomi |
---|---|
Name |
Redmi Note 9 Redmi 10X 4G |
Codename | xiaomi-merlin |
Model | M2003J15Sx |
Released | 2020 |
Type | handset |
Hardware | |
Chipset | MediaTek Helio G85 (MT6769Z) |
CPU |
Octa-core (2x2.0 GHz Cortex-A75 6x1.8 GHz Cortex-A55) |
GPU | Mali-G52 MC2 |
Display | 1080x2340 IPS LCD |
Storage | 64GB/128GB |
Memory | 3GB/4GB/6GB |
Architecture | aarch64 |
Software | |
Original software The software and version the device was shipped with. |
Android (MIUI) 10 (MIUI 11) |
Extended version The most recent supported version from the manufacturer. |
Android (MIUI) 12 (Mi Pilot MIUI 14) |
FOSS bootloader | partial |
postmarketOS | |
Category | downstream |
Mainline Instead of a Linux kernel fork, it is possible to run (Close to) Mainline. |
no |
pmOS kernel The kernel version that runs on the device's port. |
4.14.320 |
Unixbench score Unixbench Whetstone/Dhrystone score. See Unixbench. |
2610.7 |
Device package |
![]() |
Kernel package |
![]() |
Flashing It is possible to flash the device with pmbootstrap flasher . |
Works
|
---|---|
USB Networking After connecting the device with USB to your PC, you can connect to it via telnet (initramfs) or SSH (booted system). |
Works
|
Internal storage eMMC, SD cards, UFS, ... |
Works
|
SD card Also includes other external storage cards |
Works
|
Battery Charging and battery level reporting works |
Partial
|
Screen Display works. Ideally with sleep mode and brightness control. |
Partial
|
Touchscreen |
Partial
|
Multimedia | |
3D Acceleration |
Partial
|
Audio Audio playback, microphone, headset and buttons. |
Partial
|
Camera |
Broken
|
Camera Flash |
Untested
|
IR TX |
Untested
|
Connectivity | |
WiFi |
Broken
|
Bluetooth |
Broken
|
GPS |
Broken
|
NFC Near Field Communication |
Untested
|
Modem | |
Calls |
Broken
|
SMS |
Broken
|
Mobile data |
Broken
|
Miscellaneous | |
FDE Full disk encryption and unlocking with unl0kr. |
Untested
|
USB OTG USB On-The-Go or USB-C Role switching |
Broken
|
Sensors | |
Accelerometer Auto screen rotation works in desktops e.g. Phosh or Plasma Mobile |
Untested
|
Magnetometer Sensor to measure magnetism |
Untested
|
Ambient Light |
Untested
|
Proximity |
Untested
|
Haptics |
Untested
|
Contributors
- natsunemimi
- Tjari
Users owning this device
- Tjari (Notes: M2003J15SS; watchdog gets triggered on first boot)
Know your variant
Model | Codename | Model Number | Has NFC? |
---|---|---|---|
Redmi 10X 4G | merlin | M2003J15SC | N |
Redmi Note 9 (NFC) | merlinnfc/merlin_eea | M2003J15SG | Y |
Redmi Note 9 | merlin | M2003J15SS | N |
How to enter flash mode
Press and hold
+ simultaneously while device is powered off.Firmware
To simplify things let's call the lk (Little Kernel), md1img (baseband), preloader (second-stage bootloader), scp, spmfw, sspm, and tee (ARM Trusted Firmware) blobs a "firmware". Most custom ROMs and postmarketOS require MIUI 12.5 firmware. You can obtain this firmware by manually flashing images or by using the image for recovery. You may sometimes encounter NON-OSS/Q/R/S vendor naming, which corresponds to MIUI 11, 12.0, 12.5, and 13/14 firmware.
MIUI 14 ATF doesn't seem to be different from the MIUI 13.
Mainline kernel
WARNING: Before booting the mainline kernel, make sure to back up the nvram, nvdata, and nvcfg partitions using mtkclient, or Android won't work anymore. User:Tjari reports nvdata corruption on the M2003J15SS 6/128 phone model. If you don't have a backup and lost IMEI, you'll need to format the nvdata partition and restore IMEI using engineering firmware, which doesn't work well with MIUI versions newer than 11. |
Components status
Component | Model | Is driver available | Notes |
---|---|---|---|
Panel | nt36672A | Y | Needs driver hacking to support 1080x2340 |
Touchscreen | NVT-ts | Y | Out of tree module exists, needs hacking to support mediatek/xiaomi changes |
Charger | smb1351 | N | |
NFC | pn553 | Y | Power on timeout |
Audio amplifier | cs35l41 | Y | |
Fingerprint | goodix | N | Out of tree module exists |
Backlight | lm3697 | Y | Needs driver hacking |
Main camera | s5kgm1sp | N | |
Wide camera | ov13b10 | Y | |
Macro camera | ov2180 | N | |
Depth camera | gc02m1 | N | |
Front camera | s5k4h7yx | N |
Firmware
The mainline kernel should work with all versions, though there are some differences in PSCI and memory map: MIUI 13/14 firmware can shut down secondary CPU cores but cannot bring them back, while 12.5 cannot shut down at all.
The recommended version is still 12.5 because the MIUI 13/14 kernel has not yet been published. Additionally, the mainline is currently tested only with 12.5 and 13/14 firmware, so you will encounter issues with other versions.
Installation
Unlocking the bootloader
Unlock the bootloader using the official method with Mi Unlock Tool (beware, the app is Windows-only and you'll need to link your device with your Xiaomi account and wait around 7 to 30 days to unlock the device. You probably also need to upgrade your device to MIUI 13 due to Xiaomi's new unlock requirements).
Alternatively, you can also unlock the phone's bootloader using mtkclient.
Flashing postmarketOS
Type pmbootstrap init
on a terminal window and choose the following in the wizard:
Release channel: edge Vendor: xiaomi Device codename: merlin
After choosing a user interface and the rest, type the below command to begin downloading and preparing postmarketOS for installation:
$ pmbootstrap install
Then, turn off the device, hold
+ , and connect it to the computer with a USB cable.After doing this, type the following commands to flash postmarketOS to your device.
$ pmbootstrap flasher flash_rootfs
$ pmbootstrap flasher flash_kernel
For mainline:
$ pmbootstrap flasher flash_dtbo
For downstream, flash LineageOS's DTBO by typing:
$ fastboot flash dtbo dtbo.img
After the flashing is finished, finally type
$ fastboot reboot
to exit fastboot.
Flashing Android over postmarketOS
You have to flash stock super.img
, dtbo.img
, and boot.img
with the following commands.
$ fastboot flash super super.img
$ fastboot flash dtbo dtbo.img
$ fastboot flash boot boot.img
Working UIs
Downstream
Mainline
Hardware status
Touchscreen
This device's pmaports do not include the necessary touchscreen firmware, so you have to include them on the rootfs yourself (for now).
The touchscreen works on downstream, however mainline needs new driver (because touchscreen is wired over SPI, not I2C).
Battery
The battery percentage is always at 0%.
Screen
The screen works with a MediaTek DRM driver on mainline, however brightness controls aren't supported (yet). It also can't be turned off.
On mainline, screen output gets garbled and goes blank after the kernel disables regulators. Adding regulator_ignore_unused
to kernel cmdline ignores unused regulators and allows the screen to output properly.
Suspend
The device seems to hang after a few moments with downstream kernel.
Audio
The audio codec is probed on mainline, but it can't output any sound due to missing MediaTek AFE driver.
Partitions (128GB flash)
Label | Offset | Length | Description (for uncommon partitions) |
---|---|---|---|
recovery | 0x0000000000008000 | 0x0000000004000000 | |
misc | 0x0000000004008000 | 0x0000000000080000 | |
para | 0x0000000004088000 | 0x0000000000080000 | Reboot mode (?) |
expdb | 0x0000000004108000 | 0x0000000001400000 | Exception database (?) |
frp | 0x0000000005508000 | 0x0000000000100000 | Google account lock |
vbmeta | 0x0000000005608000 | 0x0000000000800000 | AVB metadata |
vbmeta_system | 0x0000000005e08000 | 0x0000000000800000 | AVB metadata for system.img |
vbmeta_vendor | 0x0000000006608000 | 0x0000000000800000 | AVB metadata for vendor.img |
md_udc | 0x0000000006e08000 | 0x000000000169a000 | Android encryption metadata (mounted as /metadata )
|
metadata | 0x00000000084a2000 | 0x0000000002000000 | Not related to the metadata partition used by Android (md_udc) |
nvcfg | 0x000000000a4a2000 | 0x0000000002000000 | Modem NVRAM configuration |
nvdata | 0x000000000c4a2000 | 0x0000000004000000 | Modem NVRAM data (if corrupted, causes the modem to panic) |
persist | 0x00000000104a2000 | 0x0000000003000000 | |
persistbak | 0x00000000134a2000 | 0x0000000003000000 | Calibration data |
protect1 | 0x00000000164a2000 | 0x0000000000800000 | SIM lock (?) |
protect2 | 0x0000000016ca2000 | 0x0000000000b5e000 | SIM2 lock (?) |
seccfg | 0x0000000017800000 | 0x0000000000800000 | Bootloader lock status |
sec1 | 0x0000000018000000 | 0x0000000000200000 | |
proinfo | 0x0000000018200000 | 0x0000000000300000 | Product info |
boot_para | 0x0000000018500000 | 0x0000000001a00000 | Reboot mode (?) |
nvram | 0x0000000019f00000 | 0x0000000004000000 | Modem NVRAM (contains IMEI & Wi-Fi MAC; MIUI 12/13/14 require Xiaomi's key if IMEI1 is present) |
logo | 0x000000001df00000 | 0x0000000000800000 | Vendor logo shown by the LK |
md1img | 0x000000001e700000 | 0x0000000008000000 | Modem firmware |
spmfw | 0x0000000026700000 | 0x0000000000100000 | System Power Manager firmware |
scp1 | 0x0000000026800000 | 0x0000000000600000 | System Companion Processor firmware |
scp2 | 0x0000000026e00000 | 0x0000000000600000 | Backup of scp1
|
sspm_1 | 0x0000000027400000 | 0x0000000000100000 | |
sspm_2 | 0x0000000027500000 | 0x0000000000100000 | |
gz1 | 0x0000000027600000 | 0x0000000001000000 | GenieZone hypervisor (unused because all cores start at EL2?) |
gz2 | 0x0000000028600000 | 0x0000000001000000 | Backup of gz1
|
lk | 0x0000000029600000 | 0x0000000000200000 | Little Kernel |
lk2 | 0x0000000029800000 | 0x0000000000200000 | Backup of lk
|
boot | 0x0000000029a00000 | 0x0000000004000000 | |
dtbo | 0x000000002da00000 | 0x0000000001000000 | |
tee1 | 0x000000002ea00000 | 0x0000000000500000 | ARM Trusted Firmware |
tee2 | 0x000000002ef00000 | 0x0000000000500000 | Backup of tee1
|
gsort | 0x000000002f400000 | 0x0000000001000000 | |
minidump | 0x0000000030400000 | 0x0000000008000000 | Stores kernel panic/oops coredumps, only used by engineering firmware |
exaid | 0x0000000038400000 | 0x0000000018000000 | |
cust | 0x0000000050400000 | 0x0000000040000000 | Preinstalled bloatware for MIUI |
devinfo | 0x0000000090400000 | 0x0000000000800000 | |
ffu | 0x0000000090c00000 | 0x0000000000c00000 | |
super | 0x0000000091800000 | 0x00000001c0000000 | Houses Android dynamic partitions (system, vendor, product, system_ext) |
cache | 0x0000000251800000 | 0x000000001b000000 | |
userdata | 0x000000026c800000 | 0x0000001aaecf8000 | |
otp | 0x0000001d1b4f8000 | 0x0000000002b00000 | |
flashinfo | 0x0000001d1dff8000 | 0x0000000001000000 |
See also
- pmaports!4808 Initial merge request