Linux 3 on PS3

From PS3 Developer wiki
Jump to: navigation, search

Contents

[edit] Introduction

  • Linux 2.6 series is nearing EOL. Only LTS kernels continue to receive security updates, but no new features. New drivers are available only on Linux 3.
  • Linux 3 is stable and works on PS3 Slim without problems.

[edit] Compilation dependencies

Glevand provides Linux 3 kernel patches at: http://gitorious.ps3dev.net/ps3linux
Sample .config file: plan to post at pastebin

[edit] Cross-Compiling

linux-3.4.12
-------------

http://www.kernel.org/pub/linux/kernel/v3.0/linux-3.4.12.tar.bz2

tar xvjf linux-3.4.12.tar.bz2
cd linux-3.4.12
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- ps3_defconfig
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- menuconfig
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux-
mkdir -p $HOME/linux-3.4.12-build/boot
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- install INSTALL_PATH=$HOME/linux-3.4.12-build/boot
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- modules_install INSTALL_MOD_PATH=$HOME/linux-3.4.12-build
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- headers_install INSTALL_HDR_PATH=$HOME/linux-3.4.12-build/usr

linux-3.5.7
------------

http://www.kernel.org/pub/linux/kernel/v3.0/linux-3.5.7.tar.bz2

tar xvjf linux-3.5.7.tar.bz2
cd linux-3.5.7
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- ps3_defconfig
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- menuconfig
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- LOCALVERSION="-test"
mkdir -p $HOME/linux-3.5.7-build/boot
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- install INSTALL_PATH=$HOME/linux-3.5.7-build/boot
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- modules_install INSTALL_MOD_PATH=$HOME/linux-3.5.7-build
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- headers_install INSTALL_HDR_PATH=$HOME/linux-3.5.7-build/usr

linux-3.6.2
------------

http://www.kernel.org/pub/linux/kernel/v3.0/linux-3.6.2.tar.bz2

tar xvjf linux-3.6.2.tar.bz2
cd linux-3.6.2
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- ps3_defconfig
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- menuconfig
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux-
mkdir -p $HOME/linux-3.6.2-build/boot
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- install INSTALL_PATH=$HOME/linux-3.6.2-build/boot
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- modules_install INSTALL_MOD_PATH=$HOME/linux-3.6.2-build
make ARCH=powerpc CROSS_COMPILE=powerpc64-linux- headers_install INSTALL_HDR_PATH=$HOME/linux-3.6.2-build/usr

Install new kernel on target machine
-------------------------------------

cp linux-3.6.2-build/boot/vmlinux-3.6.2 /boot/
cp linux-3.6.2-build/boot/System.map-3.6.2 /boot/
rm -rf /lib/modules/3.6.2
cp -r linux-3.6.2-build/lib/modules/3.6.2 /lib/modules/
depmod -a 3.6.2

[edit] Precompiled Linux 3 Kernels