Subject: Open Firmware reference
From: Avinash Gupta (agupta@mediaone.net)
Date: Sun Jan 06 2002 - 09:52:18 MST
Recently, a lot of people on have been asking questions about Open Firmware
and any documentation on OF. Here are a few links that may be helpful:
Fundamentals of Open Firmware, Part I: The User Interface
http://developer.apple.com/technotes/tn/tn1061.html
Fundamentals of Open Firmware, Part II: The Device Tree
http://developer.apple.com/technotes/tn/tn1062.html
There are two important variables for selecting the boot device and file:
boot-device
boot-file
The boot-device specifies the "device or disk" that you want to boot from.
The boot-file specifies the name of the file on the boot device that will be
used to boot.
e.g.
setenv boot-device 'scsi/sd@0:0'
setenv boot-file ' /boot/vmlinux root=/dev/sda5' // Note leading space!
This specifies to boot from the internal HD at SCSI ID 0:partition 0. This is
where the boot loader lives, Linux itself is pointed to by the boot-file
value, in this case to /boot/vmlinux on partition 5 of the first device of
the SCSI chain (/dev/sda5).
Some useful commands in OF (remember that it is case sensitive):
devalias lists the aliases you can use for your devices
dev / ls prints out your device tree
dev [device name] .properties lists some data about a certain device
words lists "commands" for the current device
boot [device] tries to boot off that device
bye boots you into Mac OS
printenv prints your nvram settings
setenv [variable] [setting] sets your nvram settings
set-defaults reset Open Firmware settings
eject fd eject the floppy
reset-all reboots the computer
shut-down shut down the system
-- Avinash Gupta (agupta@mediaone.net)
This archive was generated by hypermail 2a24 : Sun Jan 06 2002 - 10:06:13 MST