unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Chris Marusich <cmmarusich@gmail.com>
To: Danny Milosavljevic <dannym@scratchpost.org>
Cc: guix-devel <guix-devel@gnu.org>
Subject: Re: gnu/system/u-boot.scm
Date: Fri, 22 Jul 2016 02:59:34 -0700	[thread overview]
Message-ID: <87wpke3se1.fsf@gmail.com> (raw)
In-Reply-To: <20160721223501.3a989d55@scratchpost.org> (Danny Milosavljevic's message of "Thu, 21 Jul 2016 22:35:01 +0200")

[-- Attachment #1: Type: text/plain, Size: 2298 bytes --]

Danny Milosavljevic <dannym@scratchpost.org> writes:

> Hi,
>
> below is my (untested!) attempt at an u-boot-configuration for use like this
>
>   (bootloader (u-boot-configuration (device "/dev/sda")))

Neat!  Kudos to you for getting the ball rolling.  I'm not familiar with
u-boot, but based on recent emails, it sounds like it's important for
getting GuixSD to run on ARM.

> Now how do I make u-boot-configuration available in my /etc/config.scm
> ? :)

A mechanism exists for installing the bootloader and its configuration
files.  You can see it in guix/gnu/build/install.scm (where we actually
execute the install-grub [1] program) and guix/guix/scripts/system.scm.
It seems the code currently assumes that grub is the bootloader.  To
actually install u-boot, you'll probably need to add support for u-boot
somewhere in there.

[1] https://www.gnu.org/software/grub/manual/html_node/Installing-GRUB-using-grub_002dinstall.html#Installing-GRUB-using-grub_002dinstall

I wonder if it would be possible to create a bootloader abstraction of
some kind so that the installation mechanism can work with either u-boot
or grub, without caring about which one it uses?  It would be nice if
the installation mechanism were generic enough so that the same
mechanism could be used to install either bootloader.

> (define-record-type* <u-boot-configuration>
>   u-boot-configuration make-u-boot-configuration
>   u-boot-configuration?
>   (board           u-boot-configuration-board)           ; string ; not optional!
>   (u-boot          u-boot-configuration-u-boot           ; package
>                    (default (@ (gnu packages u-boot) (make-u-boot-package board))))
>   (device          u-boot-configuration-device)        ; string
>   (menu-entries    u-boot-configuration-menu-entries   ; list
>                    (default '()))
>   (default-entry   u-boot-configuration-default-entry  ; integer
>                    (default 0))
>   (timeout         u-boot-configuration-timeout        ; integer
>                    (default 5)))

This looks a little different from the grub-configuration record type
(defined in guix/gnu/system/grub.scm).  How do you intend to integrate
it with the existing bootloader installation mechanism?

-- 
Chris

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 818 bytes --]

  reply	other threads:[~2016-07-22  9:59 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-21 20:35 gnu/system/u-boot.scm Danny Milosavljevic
2016-07-22  9:59 ` Chris Marusich [this message]
2016-07-22 18:21   ` gnu/system/u-boot.scm Danny Milosavljevic
2016-07-26 20:49 ` gnu/system/u-boot.scm Ludovic Courtès
2016-07-27  9:32   ` gnu/system/u-boot.scm Danny Milosavljevic
2016-07-27 20:29     ` guix bootloader selection - wip patch Danny Milosavljevic
2016-07-28 12:34       ` Ludovic Courtès
2016-07-29  8:21         ` Danny Milosavljevic
2016-08-02  9:49           ` Ludovic Courtès
2016-08-02  9:49           ` Ludovic Courtès
2016-07-28 12:26     ` gnu/system/u-boot.scm Ludovic Courtès
2016-10-06  8:12   ` gnu/system/u-boot.scm Danny Milosavljevic
2016-10-06 17:24     ` gnu/system/u-boot.scm David Craven

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87wpke3se1.fsf@gmail.com \
    --to=cmmarusich@gmail.com \
    --cc=dannym@scratchpost.org \
    --cc=guix-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).