User talk:HP LSX

From linux-sunxi.org
Jump to navigation Jump to search

Last Modified: 2017-12-18 @ 11h09 (SGT) by HP_LSX
Last Modified: 2017-12-16 @ h (SGT) by HP_LSX

First Created: 2017-12-15 @ h (SGT) by HP_LSX



Hi, my name is "HP", as people find easier to call me so... ;-)

This is my personal page (and contribution?)on the Wiki.


About me

I am basically an Electrical Engineer who started learning on his own electronic and IT, around 25 years ago. (...)

I discovered the Cubieboard 2 - aka CB2 around 2 years ago when someone sold an old stock at a very attractive price.

Now, I can't stop imagining new project ideas based on these little boards since still very decent for most (if not all) of my needs...


Current Project

 Like many people, I'm building my own Home Automation system on my own and, since having a bunch of CB2 (more than 20...), I decided to
 give them a second life.
 
 So, I started to "play" with them around a year ago by using the uSD card + serial console approach to make them boot OpenSUSE, then
 Arch Linux (my preferred one, at the moment ;-) )
 
 These days, I am trying to learn how to make the CB2 booting from the following options:
   - NAND
   - Network / PXE
 
 I need to do this for security reasons when the CB2 are exposed to outdoor world: No uSD card = No "sensitive" data leaking too easily
 in the wild... ;-)
 
 I may be wrong about the security improvement (the NAND memory can still be read by someone...), but I found this NAND and PXE boot
 options quite interesting on their own... So, here I am ! ;-)


Targeted Points

  • Booting and running from NAND (while using uSD card for writes)
    => Getting access to the NAND memory
    => Creating special Boot-able uSD card from scratch
  • Getting access to the NAND memory
    • Making use of LiveSuit
    • Making use of a special U-Boot version built from scratch
      • Mainline/UpStream Kernel => NAND access may be (not) (yet/well) (?) supported from readings from "here and there" in the Wiki (...)
      • Legacy/ Kernel => NAND supported but Obsolete and un-maintained Kernel...
    • Creating special Boot-able uSD card from scratch
      • NAND Memory Access Driver
      • Device Tree Blob (DTB) needed
      • Customised Kernel needed
      • Customised U-Boot needed

General Progress


  • Learning about the Boot Process
 - 
  • Software tools ready. (? didn't use them yet...)
 - Cross compiling toolchain    ( http://linux-sunxi.org/Toolchain )
 - Sunxi-Tools for NAND         ( http://linux-sunxi.org/Sunxi-tools )
 -

Progress with Linux-Sunxi

 Starting point:
 - http://linux-sunxi.org/NAND
    => Legacy un-maintained U-Boot-Sunxi        - http://linux-sunxi.org/NAND
    => Mainline Kernel version                  - http://linux-sunxi.org/MTD_Driver
 
 Mainline Kernel version targeted:
 - http://linux-sunxi.org/MTD_Driver



Personal Knowledge Base

NAND Memory Access Support

Two options exist:

  • By using the Legacy un-maintained Kernels and U-Boot versions
    (which would be deprecated for Internet security reasons...)
  • By using the current Mainline Kernels and U-Boot versions
    (which are preferable)

By Mainline Kernel

NAND support may be (not) (yet/well) possible (?), based on the following:

2017-12-16 @ 08h55 (SGT): The red banner atop the "Installing_to_NAND" page says the following:

MBOX icon important.png This page provides installation instructions for the legacy unmaintained u-boot-sunxi and sunxi-3.4 kernel forks. Although it contains useful information how things work, driver for mainline kernel (3.14+) has its own page here.

2017-12-16 @ 08h57 (SGT): The red banner atop the "MTD_Driver" page says the following:

MBOX icon important.png This work is not stable at the moment. This both means that these instructions might change arbitrarily in the future, and that you might lose data by upgrading your kernel to some newer work or because they got corrupt.

By Legacy Kernel

>>> ToDo <<<

U-Boot versions

u-boot-sunxi is said legacy unmaintained (see the red banner in "Installing to NAND" page)

Sunxi Kernel versions


Encountered Issues with Linux-Sunxi's Wiki

Here is my humble participation to help maintaining the accuracy of this site while just being a "lambda" user.

Missing Information

>>> ToDo <<<

Unclear for me

 in http://linux-sunxi.org/Device_Tree#Compiling_the_Device_Tree :
 
   * IDE=<your-device-name>
   
     Q1: What is supposed to be <your-device-name> ?
     Q2: Could it be any arbitrary name or something following particular rules, as it is usually... ?
     Q3: Any example ??
  
     A1, A2:  After reading some more around, especially there: http://linux-sunxi.org/Mainline_Kernel_Howto#Boot , my guess is that any
              arbitrary name may do the job.
              =>> To be confirmed by real world experience ! <<=

ToDo

>>> ToDo <<<

Dead links

 in http://linux-sunxi.org/Toolchain#External_links :
   * [Direct download] - http://sourcery.mentor.com/public/gnu_toolchain/ = "HTTP Error 403: Forbidden"
 
 in http://linux-sunxi.org/Device_Tree#Get_the_Device-tree_Compiler :
   * [standalone version] - https://www.devicetree.org/Device_Tree_Compiler = "HTTP Error 404: Page Not Found"