OK so got a little further . I decided I wanted to build my own kernel (linux-stable 5.15.11 at the time of wrinting) so I downloaded the .dts file and started building. I got to the point where I’ve got the lib/ directory with modules and an uImage file.
Some (a lot of) questions I have now, because I’m not sure how to proceed:
- How should I connect the pins of the serial console? There are soldering connections named JP2 then another one, then 1 to be left empty and then another one. Which pin is which?
- I think I need a ramdisk of some sort, how do I create it? This should be something like this?
I downloaded an old uRamdisk from 3.2.40 from the website of @Fox_exe . I have no idea if I’m doing something useful (using an old ramdisk image) on the last line in the code below, but at least the command was successful
user@htpc:~/Documents/wdmcm-compile/linux-stable$ mkimage -A arm -O linux -T ramdisk -C gzip -d init.cpio.gz initramfs.uImage
mkimage: Can't open init.cpio.gz: No such file or directory
user@htpc:~/Documents/wdmcm-compile/linux-stable$ mkimage -A arm -O linux -T ramdisk -C gzip initramfs.uImage
mkimage: Can't open (null): Bad address
user@htpc:~/Documents/wdmcm-compile/linux-stable$ mkimage -A arm -O linux -T ramdisk -C gzip -d ramdisk-of-mybooklive-linux.3.2.40-not-sure-if-useful initramfs.uImage
Image Name:
Created: Sat Dec 25 08:35:12 2021
Image Type: ARM Linux RAMDisk Image (gzip compressed)
Data Size: 2680272 Bytes = 2617.45 KiB = 2.56 MiB
Load Address: 00000000
Entry Point: 00000000
user@htpc:~/Documents/wdmcm-compile/linux-stable$ binwalk initramfs.uImage
DECIMAL HEXADECIMAL DESCRIPTION
--------------------------------------------------------------------------------
0 0x0 uImage header, header size: 64 bytes, header CRC: 0x6352C42D, created: 2021-12-25 09:01:53, image size: 2680272 bytes, Data Address: 0x0, Entry Point: 0x0, data CRC: 0xC998FD87, OS: Linux, CPU: ARM, image type: RAMDisk Image, compression type: gzip72 bytes, Da, image name: "": "" a Address: 0x0, Entry Point: 0x0, data CRC: 0xC998FD87,OS: Linux, CPU: ARM, image type: RAMDisk Image, compression type: gzip
64 0x40 uImage header, header size: 64 bytes, header CRC: 0xEA7F7217, created: 2016-04-13 00:40:12, image size: 2680207 bytes, Da 07 bytes, Data Address: 0xE00000, Entry Point: 0xE00000, data CRC: 0x8B2C08D7, OS: Linux, CPU: ARM, image type: RAMDisk Image, compressionimage name:a Address: 0xE00000, Entry Point: 0xE00000, data CRC: 0x8B2C08D7, OS: Linux, CPU: ARM, image type: RAMDisk Image, compression
type: lzma, image name: "Ramdisk"
128 0x80 LZMA compressed data, properties: 0x5D, dictionary size: 16777216 bytes, uncompressed size: -1 bytes
After the creation, do I
- uImage and uRamdisk should go inside a boot/ folder on a FAT32 formatted usb stick. Is that correct?
- If I want to make the boot permanent, on which partitions do I install uRamdisk and uImage?
- Once I got it to boot, how do I put on a “vanilla” debian on it?
parted /dev/sdb
mklabel gpt
mkpart primary 1049kB 2149MB
mkpart primary 8591MB -1MB
mkpart primary 7517MB 8591MB
mkpart primary 2149MB 3222MB
mkpart primary 3222MB 4296MB
mkpart primary 4296MB 6443MB
mkpart primary 6443MB 7517MB