Skip to content

Instantly share code, notes, and snippets.

@runlevel5
runlevel5 / replacing_sudo_with_run0_on_fedora.md
Created December 4, 2026 08:08
Replacing sudo with run0 on Fedora

Replacing sudo with run0 on Fedora

run0 is systemd's alternative to sudo. Instead of a setuid binary that reads /etc/sudoers, it asks the service manager to start your command as a temporary service. Polkit decides who may do that. The command runs in a clean environment, with no setuid code and no environment inherited from your shell.

This guide moves a Fedora machine from "wheel can sudo without a password" to "wheel can run0 without a password", and covers the traps found along the

@runlevel5
runlevel5 / super_mario_sunshine_4k_ppc64le.md
Created October 27, 2026 12:43
Super Mario Sunshine PC port 4k guide for OpenPOWER platforms (like POWER9 or Power10)

Super Mario Sunshine in 4K on POWER9

How to build the Super Mario Sunshine PC port natively on a POWER9 (ppc64le) Fedora machine, add 4K textures and HD cutscenes, and set it up for 4K play.

Everything lives in ~/sms-p9/. The game reads its files from ~/sms-p9/sms-pc-port.

What this was tested on

@runlevel5
runlevel5 / chimera-linux-ppc64-qemu-install.md
Created July 2, 2026 09:18
Installing Chimera Linux (ppc64, big-endian) on a QEMU/libvirt VM

Installing Chimera Linux (ppc64, big-endian) on a QEMU/libvirt VM

This documents a from-scratch install of Chimera Linux on a pseries QEMU/KVM VM running on a POWER9 host, with a PReP boot partition and GRUB (powerpc-ieee1275 target).

Verification status: the GRUB/PReP step (grub-install /dev/vda1) and overall flow have been run for real and reported straightforward. Package names and dinit-specific commands below are verified against Chimera's actual repo and official docs, but the full sequence hasn't been run

@runlevel5
runlevel5 / arch-power-ppc64-install.md
Last active November 8, 2026 11:58
Installing Arch POWER (ppc64 (big-endian) or ppc64le (little-endian)) on a QEMU/libvirt VM

Installing Arch POWER (ppc64 (big-endian) or ppc64le (little-endian)) on a QEMU/libvirt VM

This documents a from-scratch install of Arch POWER Linux distribution on a pseries QEMU/KVM VM running on a POWER9 host, with a PReP boot partition and GRUB (powerpc-ieee1275 target). It also captures every pitfall hit along the way — each one cost real debugging time, so they're called out explicitly rather than silently avoided.

Endianness note: this was run and verified end-to-end on powerpc64 (big-endian). Arch POWER also publishes a powerpc64le (little-endian)

@runlevel5
runlevel5 / gist:8b4bbff69df87eeb9d25fcf0e29339cf
Created May 11, 2026 02:02
Raptor Blackbird firmware: upstream vs downstream forks
# op-build (open-power) vs Raptor downstream — comparison
Date: 2026-05-11
Our tree: `~/Work/op-build` on branch `bump-linux-6.12.87` / `amdgpu-navi23` (forks from open-power/op-build master @ `59464d53`)
Raptor tree: `~/Work/op-build-blackbird` at tag `raptor-v2.10` (Feb 15, 2024)
Raptor repo URLs:
- `gitlab.raptorengineering.com/openpower-firmware/machine-talos-ii/op-build.git` (used by our local clone)
- `gitlab.raptorengineering.com/openpower-firmware/machine-blackbird/op-build.git` (Blackbird-specific variant, shares most code)
@runlevel5
runlevel5 / nacl-ppc64le-porting.md
Created March 27, 2026 02:07
NaCl SFI Design for ppc64le

NaCl SFI Design for ppc64le

Overview

Google Native Client (NaCl) uses Software Fault Isolation (SFI) to sandbox untrusted native code. Each supported architecture has a unique SFI implementation. The closest existing analogy for ppc64le is the MIPS 32-bit port: both use fixed-length instructions, pure software isolation (no hardware segments), and dedicated mask registers.

NaCl currently supports: x86-32 (hardware segments), x86-64 (base register + zero-extension), ARM 32-bit (bic masking), and MIPS 32-bit (mask registers). No PPC support has ever existed.

Common SFI Invariants (All Architectures)

@runlevel5
runlevel5 / gog_installer_unsupported_platform.md
Last active February 25, 2026 05:51
How to run GOG Installer (mojosetup) on unsupported architecture?

Installing GOG Games on Unsupported Architecture with Native MojoSetup

GOG's Linux game installers (.sh files) are Makeself archives that bundle a custom mojosetup binary (x86_64) to handle the installation UI and file extraction. On non-x86 architectures like PPC64LE or RISCV, the bundled binary won't run natively. This document describes how to compile mojosetup from source for your architecture and use it to run any GOG .sh installer, with support for stdio, ncurses (TUI), GTK2, GTK3, and GTK4 (graphical) interfaces.

Background

@runlevel5
runlevel5 / vinsertd_vextractd_ppc64le.md
Created February 19, 2026 12:05
PPC64LE's behaviour of vinsertd/vextractd

test_vinsertd.c:

#include <stdio.h>
#include <stdint.h>
#include <altivec.h>
typedef union {
    vector unsigned char v;
    uint64_t u64[2];
    uint32_t u32[4];
@runlevel5
runlevel5 / PLAN.md
Created February 8, 2026 13:17
Improvement plan to speed up Yamagi Quake 2 software renderer

SIMD Optimization Plan for the Software Renderer

This document covers the feasibility analysis and implementation plan for adding SIMD acceleration to the Yamagi Quake II software renderer (src/client/refresh/soft/).

Table of Contents

  1. Architecture Overview
  2. Current Bottlenecks