All Projects → raphael → Linux Samus

raphael / Linux Samus

Licence: gpl-2.0
Linux 4.16 on Chromebook Pixel 2015

Programming Languages

c
50402 projects - #5 most used programming language

Projects that are alternatives of or similar to Linux Samus

Sphinx-Beryllium
Sphinx Custom Kernel for Pocophone F1 (Beryllium)
Stars: ✭ 23 (-87.15%)
Mutual labels:  kernel, linux-kernel
Diamorphine
LKM rootkit for Linux Kernels 2.6.x/3.x/4.x/5.x (x86/x86_64 and ARM64)
Stars: ✭ 725 (+305.03%)
Mutual labels:  kernel, linux-kernel
Kernel Exploits
Various kernel exploits
Stars: ✭ 397 (+121.79%)
Mutual labels:  kernel, linux-kernel
Microdot
The Microdot Project guides you to create a fully functional but compact Linux system from scratch
Stars: ✭ 41 (-77.09%)
Mutual labels:  kernel, linux-kernel
Traceshark
This is a tool for Linux kernel ftrace and perf events visualization
Stars: ✭ 63 (-64.8%)
Mutual labels:  kernel, linux-kernel
kernel-ci
Continuous integration for the Linux Kernel - Built within Docker
Stars: ✭ 34 (-81.01%)
Mutual labels:  kernel, linux-kernel
Paper collection
Academic papers related to fuzzing, binary analysis, and exploit dev, which I want to read or have already read
Stars: ✭ 710 (+296.65%)
Mutual labels:  kernel, linux-kernel
OpenHarmony
华为鸿蒙分布式操作系统(Huawei OpenHarmony)开发技术交流,鸿蒙技术资料,手册,指南,共建国产操作系统万物互联新生态。
Stars: ✭ 373 (+108.38%)
Mutual labels:  kernel, linux-kernel
Linux Kernel Utilities
👷 Utilities to compile and / or update linux kernels for Debian and derivatives (e.g. Ubuntu, LinuxMint, etc.)
Stars: ✭ 166 (-7.26%)
Mutual labels:  kernel, linux-kernel
Sutekh
An example rootkit that gives a userland process root permissions
Stars: ✭ 62 (-65.36%)
Mutual labels:  kernel, linux-kernel
linux kernel wiki
linux内核学习资料:200+经典内核文章,100+内核论文,50+内核项目,500+内核面试题,80+内核视频
Stars: ✭ 1,653 (+823.46%)
Mutual labels:  kernel, linux-kernel
Linux 0.11
A heavily commented linux kernel source code in Chinese.
Stars: ✭ 81 (-54.75%)
Mutual labels:  kernel, linux-kernel
execmon
Advanced process execution monitoring utility for linux (procmon like)
Stars: ✭ 77 (-56.98%)
Mutual labels:  kernel, linux-kernel
camflow-dev
Generates kernel patch for CamFlow Linux Provenance Capture.
Stars: ✭ 19 (-89.39%)
Mutual labels:  kernel, linux-kernel
Sphinx-Dipper
Sphinx Custom Kernel for Mi 8 (Dipper)
Stars: ✭ 17 (-90.5%)
Mutual labels:  kernel, linux-kernel
Spy
👀 Linux kernel mode debugfs keylogger
Stars: ✭ 546 (+205.03%)
Mutual labels:  kernel, linux-kernel
w1-gpio-cl
Command line configured kernel mode 1-wire bus master driver. w1-gpio standard Linux module enhancement/substitution.
Stars: ✭ 17 (-90.5%)
Mutual labels:  kernel, linux-kernel
Linux-Kernel-Exploitation
Linux kernel development & exploitation lab.
Stars: ✭ 130 (-27.37%)
Mutual labels:  kernel, linux-kernel
Proton zf6
Proton Kernel for the Asus Zenfone 6 (2019), codename Kirin and also known as I01WD and ZS630KL.
Stars: ✭ 42 (-76.54%)
Mutual labels:  kernel, linux-kernel
Simplefs
A simple file system for Linux kernel
Stars: ✭ 65 (-63.69%)
Mutual labels:  kernel, linux-kernel

Linux for Chromebook Pixel 2015

This repository contains packages for Debian and Arch Linux that installs the Linux kernel v4.10 with a config that is somewhat optimized for the Chromebook Pixel 2015.

As of v4.9 there is no need to patch the kernel sources to get sound support.

Current kernel version: v4.16.13

Installation

The easiest way to get going is to install the packages if you are running Ubuntu, Debian or Arch Linux.

Ubuntu / Debian

$ git clone --depth=1 https://github.com/raphael/linux-samus
$ cd linux-samus/build/debian
$ sudo dpkg -i *.deb

Arch Linux

Install the linux-samus4 package from the AUR:

$ yaourt -S linux-samus4

Other distributions

The entire kernel patched tree is located under build/linux, compile and install using the usual instructions for installing kernels. For example:

$ git clone --depth=1 https://github.com/raphael/linux-samus
$ cd linux-samus/build/linux
$ make nconfig
$ make -j4
$ sudo make modules_install
$ sudo make install

NOTE the steps above are just the standard kernel build steps and may differ depending on your distro/setup.

Post-install steps

Once installed reboot and load the kernel.

Sound

Setup

The scripts needed to enable audio and switch between the speakers and headphones are provided in the scripts/setup/audio folder.

  • Enable audio: scripts/setup/audio/enable-audio.sh
  • Switch to speakers: scripts/setup/audio/enable-speakers.sh
  • Switch to headphones: scripts/setup/audio/enable-headphones.sh
  • Toggle mute: scripts/setup/audio/mute-toggle.sh
  • Decrease volume: scripts/setup/audio/volume-down.sh
  • Increase volume: scripts/setup/audio/volume-up.sh

Users upgrading from pre-4.7 Samus kernel

To get sound working, you must unwind some of the previous samus sound settings:

  1. edit the file /etc/pulse/default.pa and ensure these lines are commentted out:
#load-module module-alsa-sink device=hw:0,0
#load-module module-alsa-source device=hw:0,1
#load-module module-alsa-source device=hw:0,2
  1. remove the following folders: /opt/samus and /usr/share/alsa/ucm/bdw-rt5677
  2. edit the file /etc/acpi/handler.sh and remove any samus entries

NOTE: settings to toggle headphone/speaker during plug) and unplug) events still need to be implemented.

Touchpad

Since Linux 4.3 the Atmel chip needs to be reconfigured to guarantee that the touchpad works. See issue #73 for details. The linux-samus/scripts/setup/touchpad directory contains a script that does the reconfig:

$ cd linux-samus/scripts/setup/touchpad
$ ./enable-atmel.sh

This is only needed to be run once.

Keyboard

Chrome OS sets up a number of useful key mappings, such as:

  • Home = Search + left arrow
  • End = Search + right arrow
  • PgUp = Search + up arrow
  • PgDn = Search + down arrow
  • Delete = Search + backspace

The keyboard.sh script will enable these mappings under standard Linux, and it will also set up mappings for special functions that do not exist on a standard 101-key PC keyboard:

  • Back = Search + F1
  • Forward = Search + F2
  • Reload = Search + F3
  • BrightnessDown = Search + F6
  • BrightnessUp = Search + F7
  • VolumeMute = Search + F8
  • VolumeDown = Search + F9
  • VolumeUp = Search + F10

i.e. the Chromebook's F-keys will produce F1-F10 without the Search modifier, and perform the marked functions with the Search modifier. F1-F3 can be handled by apps (such as a web browser) while F6-F10 tend to be handled by the desktop environment. The latter keys were tested with Xfce.

This will add a command to ~/.xsessionrc that enables the mappings on login:

$ cd linux-samus/scripts/setup/keyboard
$ ./keyboard.sh

Xorg

To enable X11 acceleration run the xaccel.sh script:

$ cd linux-samus/scripts/setup/xorg
$ ./xaccel.sh

Brightness

The script scripts/setup/brightness/brightness can be used to control the brightness level.

$ cd scripts/setup/brightness
$ ./brightness --help
Increase or decrease screen brightness
Usage: brightness --increase | --decrease

Put scripts/setup/brightness in your path and bind the F6 key to brightness --decrease and the F7 key to brightness --increase for an almost native experience.

Similarly the script script/setup/brightness/keyboard_led can be used to control the keyboard backlight, bind the ALT-F6 key to keyboard_led --decrease and ALT-F7 to keyboard_led --increase.

Both these scripts require write access to files living under /sys which get mounted read-only for non-root users on boot by default. If your system uses systemd (e.g. ArchLinux) then the file script/setup/brightness/enable-brightness.service contains the definition for a systemd service that makes the files above writable to non-root user. Run systemctl enable enable-brightness.service for the service to run on boot.

systemd
./setup.systemd.sh

The same directory also contains setup.systemd.sh. When executed, it copies scripts to /usr/local/bin and configures systemd to run the script enable-brightness.sh on boot.

OpenRC
./setup.openrc.sh

The same directory also contains setup.openrc.sh. When executed, it copies scripts to /usr/local/bin and configures OpenRC to run the script enable-brightness.sh on boot using the local service.

Contributions

This repo exists so that we can all benefit from one another's work. Thomas Sowell's linux-samus repo was both an inspiration and help in building it. The hope is that others (you) will also feel inspired and contribute back. PRs are encouraged!

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].