Difference between revisions of "NixOS on ARM/PINE64 Pinebook"

From NixOS Wiki
Jump to: navigation, search
m (Adds partitioning notes)
m (rollback unauthorized mass edits)
Tag: Rollback
 
(6 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{ARM/breadcrumb}}
+
This page has been moved to the official NixOS Wiki:
<div class="infobox">
 
{|class="table"
 
!colspan="2" class="title"|PINEBOOK
 
|-
 
|colspan="2"|[[File:Pinebook-a64-11-glamour.jpg|frameless|256px|A Pinebook 11".]]
 
|-
 
!Manufacturer
 
|PINE64 (Pine Microsystems Inc.)
 
|-
 
!Architecture
 
|AArch64
 
|-
 
!Bootloader
 
|Upstream U-Boot<ref>https://github.com/NixOS/nixpkgs/pull/61652</ref>
 
|-
 
!Boot order
 
|SD, eMMC
 
|-
 
!Maintainer
 
|[[User:samueldr|samueldr]]
 
|}
 
</div>
 
  
The Pinebook (sometimes referred as pinebook-a64) is a laptop design based on the Allwinner A64 SoC. It was available in two sizes, 11.6" and 14", but is now only available as 11.6". The 11.6" has two resolutions, first models had a 1366×768 panel, while the more recent ones have a 1920×1080 panel.
+
    ⇒ '''[https://wiki.nixos.org/wiki/NixOS_on_ARM/PINE64_Pinebook NixOS on ARM/PINE64 Pinebook]'''
  
It can boot from SD or from an included and replaceable eMMC module.
+
''— samueldr, Lead of NixOS on ARM.''
 
 
== Status ==
 
 
 
Upstream NixOS AArch64 image boots on the PINE A64-LTS, using the proper upstream U-Boot.
 
 
 
U-boot support [https://github.com/NixOS/nixpkgs/pull/61652 has been added 2019-05-18]. The bootloader has not been built for now.
 
 
 
== Board-specific installation notes ==
 
 
 
First follow the [[NixOS_on_ARM#Installation|generic installation steps]] to get the installer image on an SD card. Copying to the eMMC directly should work, but requires disassembly of the computer.
 
 
 
U-Boot needs to be copied to specific sectors on the microSD card with <code>dd</code>. Download U-Boot for the board (<code>sopine-u-boot-sunxi-with-spl.bin</code>), and copy it to the correct location with (again, replace <code>/dev/sdX</code> with the correct path to the SD card device):
 
 
 
<syntaxhighlight lang="bash" style="clear:both">sudo dd if=sopine-u-boot-sunxi-with-spl.bin of=/dev/sdX bs=1024 seek=8</syntaxhighlight>
 
 
 
=== Partitioning ===
 
 
 
The internal storage needs to be partitioned in a way that that the bootloader will not interfere with nor be interfered by a partition.
 
 
 
==== By copying the sd image internally ====
 
 
 
This is an easy solution, that also allows booting and installing as one would from an SD card on a generic Allwinner platform. Simply <code>dd</code> the SD image to the internal storage. The internal storage is likely to be <code>/dev/mmcblk2</code>.
 
 
 
==== MBR partition scheme ====
 
 
 
{{expansion|Installation instructions need to be written up to keep space for embedding the bootloader to the SPL.}}
 
 
 
==== GPT partition scheme ====
 
 
 
The [[NixOS_on_ARM/Allwinner_GPT_Installation|Allwinner GPT Installation]] instruction explains how to create a GPT partition table while allowing the isntallation of u-boot at the required offset.
 
 
 
== Serial console==
 
 
 
Details about the pinout for the headphone jack are available [https://wiki.pine64.org/index.php/1080P_Pinebook_Main_Page#Pinebook_Schematics_and_Certifications on the PINE64 wiki]. It is [https://store.pine64.org/?product=pinebook-serial-console also available on their store]. The serial settings are the usual Allwinner settings.
 
 
 
On early models<sup>[Which?]</sup> serial needs to be toggled via software. On recent models, a physical switch is present on the main board. The linux-sunxi wiki's Pinebook page [http://linux-sunxi.org/Pine_Pinebook#Adding_a_serial_port has details about serial access].
 
 
 
== Compatibility notes ==
 
 
 
{| class="table arm-compatibility"
 
!colspan="2" style="background: #fafafa"| Mainline kernel
 
|-
 
! Display
 
|
 
* Does not work yet with the upstream kernel as of 5.1.
 
|-
 
! HDMI
 
|
 
* Hasn't been tested.
 
|}
 
 
 
=== Downstream kernel ===
 
 
 
{{note|Keep in mind that using non-upstream forks of the kernel always incurs some risk as far as security goes.}}
 
 
 
{{expansion|Find and document use of a kernel with the added capabilities.}}
 
 
 
== USB booting with u-boot ==
 
 
 
You will need to either have mainline U-Boot installed to the eMMC or to an SD card.
 
 
 
Stop the boot process when prompted (by pressing a key). Then, do the following:
 
 
 
<pre>
 
Hit any key to stop autoboot:  0
 
=> setenv boot_targets usb0
 
=> boot
 
</pre>
 
 
 
This sets the boot order for this boot only. U-Boot can boot (among others) either of the NixOS sd-image or EFI iso from USB.
 
 
 
== Resources ==
 
 
 
* [https://www.pine64.org/pinebook/ Official product page]
 
* [linux-sunxi.org/Pine_Pinebook linux-sunxi wiki page]
 

Latest revision as of 10:59, 6 April 2024

This page has been moved to the official NixOS Wiki:

    ⇒ NixOS on ARM/PINE64 Pinebook

— samueldr, Lead of NixOS on ARM.