NixOS on ARM/Banana Pi: Difference between revisions

imported>NickHu
Add instructions to build and write U-Boot to disk
 
Pigs (talk | contribs)
m Add category
 
(6 intermediate revisions by 5 users not shown)
Line 1: Line 1:
{{ARM/breadcrumb}}
== Building U-Boot ==
== Building U-Boot ==


Line 4: Line 5:
$ git clone git://git.denx.de/u-boot.git
$ git clone git://git.denx.de/u-boot.git
$ cd u-boot
$ cd u-boot
$ nix-shell -p ubootTools gcc-arm-embedded dtc flex bison python swig
$ nix-shell -p ubootTools gcc-arm-embedded dtc flex bison swig 'python311.withPackages(ps: with ps; [ setuptools ])' openssl libuuid gnutls
$ make -j4 ARCH=arm CROSS_COMPILE=arm-none-eabi- Bananapi_defconfig  
$ make -j4 ARCH=arm CROSS_COMPILE=arm-none-eabi- Bananapi_defconfig  
$ make -j4 ARCH=arm CROSS_COMPILE=arm-none-eabi-
$ make -j4 ARCH=arm CROSS_COMPILE=arm-none-eabi-
Line 18: Line 19:


Then, install using the [[NixOS_on_ARM#NixOS_installation_.26_configuration|installation and configuration steps]].
Then, install using the [[NixOS_on_ARM#NixOS_installation_.26_configuration|installation and configuration steps]].
[[Category:NixOS on ARM]]
== SATA Port multiplier (PMP) ==
It [http://forum.lemaker.org/thread-9207-1-1.html used to be necessary] to make some changes to the kernel source and recompile, but on recent linux versions (including the one shipped with the NixOS arm image) this is no longer necessary. Instead, all that is required is merely to set <syntaxhighlight lang="nix">boot.kernelParams = ["ahci_sunxi.enable_pmp=1"]</syntaxhighlight> in <code>configuration.nix</code>. Note that this will prevent the use of a hard drive connected to the SATA port directly without a port multiplier in between.
See [https://linux-sunxi.org/SATA#PMP_support_-_using_SATA_port_multipliers_with_sunxi_devices here] for more details.