入口
    OF 1/2 の場合
    OF 3 の場合
      設置後すぐ
      CDROM 無で
    Mac OS の場合
    その他
  NetBSD
  Booting Media
Primary
  bootxx
Secondary
  xcf/elf
    release(7)
    /usr/mdec
ofwboot
  Locore.c
  boot.c
    main()
    boot-file
    chain()
    OF_chain()
kernel(1)
  locore.S
  machdep.c
    initppc()
kernel(2)
  init_main.c
    main()
その他
  installboot
    旧版
    新版
    実例
  DEFAULT CATCH
GENERIC_MD
  mdsetimage

NetBSD/macppc booting

kernel(1)

locore.S

sys/arch/macppc/macppc/locore.S | ( ts 版 )

kernel に制御が移ると、次の 143 行目の _start から、

    129 /*      
    130  * This symbol is here for the benefit of kvm_mkdb, and is supposed to
    131  * mark the start of kernel text.
    132  */     
    133         .text   
    134         .globl  _C_LABEL(kernel_text)
    135 _C_LABEL(kernel_text):
    136  
    137 /* 
    138  * Startup entry.  Note, this must be the first thing in the text
    139  * segment!
    140  */     
    141         .text   
    142         .globl  __start
    143 __start:
init_main の中の main() に行くはずなのだが、 その前に機種(arch) 特有の作業がある。 それは以下の 200 行目付近で呼び出される initppc に書いてある。 つまり Locore.S の 最後の(以下の例では) 213 行目で initppc が呼ばれる
    212         mr      5,6                     /* args string */
    213         bl      _C_LABEL(initppc)
    214         bl      _C_LABEL(main)
    215         b       _C_LABEL(OF_exit)
Last Update: Sat, 04 May 2019 00:45:20 GMT 1.66 2008/03/08