Amiga Booting

Kas1e explains in this issue of Jurassic Pack what happens in detail when an Amiga computer executes its startup sequence.

Greetings dinosaurs! Today I’d like to talk about Amiga booting. But stop! Do not jump over to the next article. I think you can find some interesting infos here. So..

Of course there exists tons of books about hardware, software, etc for the Amiga. I talk about classic Amiga machines of course. But what you can find in these kind of books? Only that the Amiga has a boot sector called RDB. Maybe the format/structure of RDB. But we all want, I hope, to know how Amiga booting exactly works from begining to the happy end. Well, let’s go back a little bit to the past, and try to remember some basic facts.

If you set up one or more partitions for your harddisk, you will have a RDB – Rigid Disk Block. Generally these boot blocks are used and there, they’ve placed tons of good informations, like:

a). how many partitions you have
b). where is the boot block of these partition(s)
c). physical/logical hdd info.
d). etc, etc.

Take a look on the RDB structure:

work:> cd sc:include/devices/
work:> sc/include/devices> type hardblocks.h | more

…skip some introducing words…

struct RigidDiskBlock {
ULONG rdb_ID; /* 4 character identifier / ULONG rdb_SummedLongs; / size of this checksummed structure / LONG rdb_ChkSum; / block checksum (longword sum to zero) / ULONG rdb_HostID; / SCSI Target ID of host / ULONG rdb_BlockBytes; / size of disk blocks / ULONG rdb_Flags; / see below for defines / / block list heads / ULONG rdb_BadBlockList; / optional bad block list / ULONG rdb_PartitionList; / optional first partition block / ULONG rdb_FileSysHeaderList; / optional file system header block / ULONG rdb_DriveInit; / optional drive-specific init code / / DriveInit(lun,rdb,ior): „C“ stk & d0/a0/a1 / ULONG rdb_Reserved1[6]; / set to $ffffffff / / physical drive characteristics / ULONG rdb_Cylinders; / number of drive cylinders / ULONG rdb_Sectors; / sectors per track / ULONG rdb_Heads; / number of drive heads / ULONG rdb_Interleave; / interleave / ULONG rdb_Park; / landing zone cylinder / ULONG rdb_Reserved2[3]; ULONG rdb_WritePreComp; / starting cylinder: write precompensation / ULONG rdb_ReducedWrite; / starting cylinder: reduced write current / ULONG rdb_StepRate; / drive step rate / ULONG rdb_Reserved3[5]; / logical drive characteristics / ULONG rdb_RDBBlocksLo; / low block of range reserved for hardblocks / ULONG rdb_RDBBlocksHi; / high block of range for these hardblocks / ULONG rdb_LoCylinder; / low cylinder of partitionable disk area / ULONG rdb_HiCylinder; / high cylinder of partitionable data area / ULONG rdb_CylBlocks; / number of blocks available per cylinder / ULONG rdb_AutoParkSeconds;/ zero for no auto park / ULONG rdb_HighRDSKBlock; / highest block used by RDSK / / (not including replacement bad blocks) / ULONG rdb_Reserved4; / drive identification */
char rdb_DiskVendor[8];
char rdb_DiskProduct[16];
char rdb_DiskRevision[4];
char rdb_ControllerVendor[8];
char rdb_ControllerProduct[16];
char rdb_ControllerRevision[4];
ULONG rdb_Reserved5[10];

Well, it is a RDB. Take a look at my example: I have fastata3, and for my 40 gb hdd, I have ten splitted it into parts by 4gb each.

So that the scsi.device thinks that I would have ten harddisks, and for any new ‚hdd‘ it will create a new RDB.

Here is sample of my RDB from my „first“ Amiga ‚hdd‘:

Offset 0 1 2 3 4 5 6 7 8 9 A B C D E F

00000000 52 44 53 4B 00 00 00 40 54 6E E4 C2 00 00 00 07 RDSK…@Tn€‚….
00000010 00 00 02 00 00 00 00 10 FF FF FF FF 00 00 00 01 ……..ïïïï….
00000020 00 00 00 02 FF FF FF FF FF FF FF FF FF FF FF FF ….ïïïïïïïïïïïï
00000030 FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF ïïïïïïïïïïïïïïïï
00000040 00 00 20 82 00 00 00 3F 00 00 00 10 00 00 00 01 .. ‚…?……..
00000050 00 00 20 82 00 00 00 00 00 00 00 00 00 00 00 00 .. ‚…………
00000060 00 00 20 82 00 00 20 82 00 00 00 03 00 00 00 00 .. ‚.. ‚……..
00000070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 …………….
00000080 00 00 00 00 00 00 07 DF 00 00 00 02 00 00 20 81 …….Ÿ…… _
00000090 00 00 03 F0 00 00 00 00 00 00 00 D1 00 00 00 00 …à…….‘….
000000A0 53 54 33 34 30 30 31 36 41 20 20 20 20 20 20 20 ST340016A
000000B0 20 20 20 20 20 20 20 20 34 47 31 39 00 00 00 00 4G19….
000000C0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 …………….

                     ...skip zeroes...

000001E0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 …………….
000001F0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 …………….
00000200 50 41 52 54 00 00 00 40 62 EE 90 5A 00 00 00 07 PART…@b®_Z….
00000210 FF FF FF FF 00 00 00 01 00 00 00 00 00 00 00 00 ïïïï…………
00000220 00 00 00 00 03 44 48 30 30 45 5F 4D 45 00 00 00 …..DH00E_ME…
…skip zeroes…

00000280 00 00 00 10 00 00 00 80 00 00 00 00 00 00 00 10 …….…….. 00000290 00 00 00 01 00 00 00 3F 00 00 00 02 00 00 00 00 …….?…….. 000002A0 00 00 00 00 00 00 00 02 00 00 20 81 00 00 01 2C ………. …,
000002B0 00 00 00 00 00 FF FF FF 7F FF FF FE 00 00 00 00 …..ïïïïïî….
000002C0 53 46 53 00 00 00 00 00 00 00 00 00 00 00 00 00 SFS………….
000002D0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 …………….
000002E0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 …………….
000002F0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 …………….
00000300 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 …………….

So, just for brief look on first block of RDB we can see:

  1. ST340016A
  2. DH0 (my bootable partion)
  3. my partition is SFS

Okay, after rdb handling the Amiga goes to boot partition (of course taking arguments from rdb, like boot priority, place of boot block of partitions, etc).

And, we almost come close to some interesting moment of my article. I said in that the boot block of the boot partition executes s:startup-sequence in the end.

Here’s the moment of truth. I’m always interested ‚how wb loads exactly‘. I mean, of course we all know the loading procedure of the startup-sequence and user-startup. But how does that exactly take place?

Of course reading tons of syscalls is not the best way of understanding, but the snoopy tool helped me.

So, please don`t hesitate to take a look at the logfile of my snoopdos clone in the /bonus/Amiga_booting/ directory of JP to understand what’s going on after the boot block started to execute the startup-sequence.

The main idea behind this article was to look deeply on Amiga booting. Of course it is not as deep as it could be, but I think some moments were interesting for someone, I hope.

See you!

Kas1e – e-mail: kas1e@yandex.ru

(*) Alle mit einem Stern gekennzeichneten Links sind Affiliate-Links. Wenn Du über diese Links Produkte oder Abonnements kaufst, erhält Tarnkappe.info eine kleine Provision. Dir entstehen keine zusätzlichen Kosten. Wenn Du die Redaktion anderweitig finanziell unterstützen möchtest, schau doch mal auf unserer Spendenseite oder in unserem Online-Shop vorbei.

Lars Sobiraj

Über

Lars Sobiraj fing im Jahr 2000 an, als Quereinsteiger für verschiedene Computerzeitschriften tätig zu sein. 2006 kamen neben gulli.com noch zahlreiche andere Online-Magazine dazu. Er ist der Gründer von Tarnkappe.info. Außerdem brachte Ghandy, wie er sich in der Szene nennt, seit 2014 an verschiedenen Hochschulen und Fortbildungseinrichtungen den Teilnehmern bei, wie das Internet funktioniert.