]> git.dujemihanovic.xyz Git - dujemihanovic.xyz.git/blob - content/projects/pxa1908/index.md
Fixes for tiny (<300px wide) screens
[dujemihanovic.xyz.git] / content / projects / pxa1908 / index.md
1 ---
2 title: "Mainline Linux on Marvell PXA1908"
3 date: 2023-09-10T22:23:48+02:00
4 ---
5 The Marvell PXA1908 was Marvell's first ARM64 SoC released sometime around 2014
6 or 2015. The SoC is used in some of Samsung's entry level 2015 phones such as
7 the [Core Prime VE
8 LTE](https://wiki.postmarketos.org/wiki/Samsung_Galaxy_Core_Prime_VE_LTE_(samsung-coreprimevelte))
9 and the [Xcover 3
10 LTE](https://wiki.postmarketos.org/wiki/Samsung_Galaxy_Xcover_3_(samsung-xcover3lte)).
11 The PXA1908 currently has out-of-tree support for booting mainline Linux.
12
13 ## Links
14
15 * [Latest version of patchset
16 (v10)](https://lore.kernel.org/20240424-pxa1908-lkml-v10-0-36cdfb5841f9@skole.hr)
17 * [Main Git
18 repository](https://gitlab.com/LegoLivesMatter/linux/-/tree/mainline)
19 * [postmarketOS SoC page](https://wiki.postmarketos.org/wiki/Marvell_PXA1908)
20
21 ## Building outside pmbootstrap
22
23 1. Clone and compile [pxa-mkbootimg](https://github.com/osm0sis/pxa-mkbootimg)
24 1. Clone repository
25 1. Checkout `coreprimevelte`
26 1. Get [kernel
27 config](https://gitlab.com/postmarketOS/pmaports/-/raw/master/device/testing/linux-samsung-coreprimevelte/config-samsung-coreprimevelte.aarch64)
28 from pmaports
29 1. `make` the kernel and create a boot.img using the below script
30
31 ## Script for creating boot.img
32 Written to be run from `out/arch/arm64/boot`. Adapt to your needs.
33
34 ```sh
35 #!/bin/sh
36
37 mkimage -A arm64 -C gzip -a 0x1000000 -e 0x1000000 -n "pxa1928dkb linux" -d Image.gz uImage
38 ~/code/pxa-mkbootimg/pxa1908-dtbTool -p ../../../scripts/dtc/ -s 2048 -o dt.img dts/marvell/
39 ~/code/pxa-mkbootimg/pxa-mkbootimg \
40 --kernel uImage \
41 --base 0x10000000 \
42 --ramdisk /tmp/postmarketOS-export/initramfs \
43 --ramdisk_offset 0x1000000 \
44 --pagesize 2048 \
45 --dt dt.img \
46 --second_offset 0xf00000 \
47 --tags_offset 0x100 \
48 -o boot.img
49 ```
50
51 ## Todo
52 Moved [here](https://gitlab.com/LegoLivesMatter/linux/-/issues/1)