Skip to content

Commit

Permalink
start arm chromebook confs
Browse files Browse the repository at this point in the history
  • Loading branch information
nothingneko committed Jun 14, 2024
1 parent 58d6442 commit 056d8ff
Show file tree
Hide file tree
Showing 9 changed files with 107 additions and 0 deletions.
25 changes: 25 additions & 0 deletions katsu/modules/ports/chromebook/chromebook.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
builder: dnf

scripts:
post:
- id: cleanup
name: Clean up system
file: ../base/cleanup.sh
- id: selinux-setup
name: Set up SELinux
file: ../base/selinux.sh
chroot: false
- id: buildstamp
name: Generate buildstamp
file: ../base/buildstamp.sh
- id: submarine
name: Set up ChromeOS bootloader
file: submarine.sh

dnf:
releasever: 40
packages:
- cros-keyboard-map
- depthcharge-tools
- vboot-utils
- submarine
10 changes: 10 additions & 0 deletions katsu/modules/ports/chromebook/mt8183/mt8183.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
builder: dnf

import:
- ../chromebook.yaml

dnf:
releasever: 40
packages:
- kernel-mt8183
- kernel-mt8183-devel
3 changes: 3 additions & 0 deletions katsu/modules/ports/chromebook/mt8183/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Jacuzzi and Kukui Families (mt8183)

This is our most complete port. Our reference device is the Lenovo Chromebook Duet (Krane).
10 changes: 10 additions & 0 deletions katsu/modules/ports/chromebook/mt8192/mt8192.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
builder: dnf

import:
- ../chromebook.yaml

dnf:
releasever: 40
packages:
- kernel-mt8192
- kernel-mt8192-devel
7 changes: 7 additions & 0 deletions katsu/modules/ports/chromebook/mt8192/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Asurada Family (mt8192)

Our reference device is the Asus Chromebook Flip CM3 (Hayato).

## Known Issues

- [Submarine doesn't initialize the display](https://github.com/FyraLabs/submarine/issues/10)
7 changes: 7 additions & 0 deletions katsu/modules/ports/chromebook/sc7180/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Strongbad and Trogdor Families (QC-7C/sc7180)

Our reference device is the Lenovo IdeaPad Duet 3 (wormdingler)

## Known Issues

- WiFi may be flaky.
10 changes: 10 additions & 0 deletions katsu/modules/ports/chromebook/sc7180/sc7180.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
builder: dnf

import:
- ../chromebook.yaml

dnf:
releasever: 40
packages:
- kernel-sc7180
- kernel-sc7180-devel
10 changes: 10 additions & 0 deletions katsu/modules/ports/chromebook/stoney/stoney.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
builder: dnf

import:
- ../chromebook.yaml

dnf:
releasever: 40
packages:
- kernel-stoneyridge
- kernel-stoneyridge-devel
25 changes: 25 additions & 0 deletions katsu/modules/ports/chromebook/submarine.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#!/bin/bash
set -x

# Find bootloader partition and umount
blpart="$(findmnt -n -o SOURCE /mnt)"
rootdev="$(basename `readlink -f "/sys/class/block/$(basename $blpart)/.."`)"
partnum="$(echo $(basename $blpart) | sed 's/'"$rootdev"'//;s/p//')"
umount $blpart

# Remove /mnt from fstab
sed -i '/mnt/d' /etc/fstab

# Flash bootloader
submarine="/usr/share/submarine/submarine"
if [ $(uname -m ) == 'x86_64' ]; then
submarine="$submarine-x86.kpart"
elif [ $(uname -m ) == 'aarch64' ]; then
submarine="$submarine-a64.kpart"
fi

dd if=$submarine of=$blpart
cgpt add -i $partnum -t kernel -P 15 -T 1 -S 1 /dev/$rootdev

# Workaround for katsu trying to unmount /mnt
mount -o bind /mnt /mnt

0 comments on commit 056d8ff

Please sign in to comment.