Port-vax archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Netboot on Vax



On 2014-01-03 20:08, Johnny Billquist wrote:
To make it clear.
objdump on a somewhat recent /boot for VAX:

GW:obj/destdir.vax> objdump -x boot

boot:     file format elf32-little
boot
architecture: UNKNOWN!, flags 0x00000102:
EXEC_P, D_PAGED
start address 0x003f0000

Program Header:
     LOAD off    0x00000054 vaddr 0x003f0000 paddr 0x003f0000 align 2**2
          filesz 0x0000e8dc memsz 0x000110dc flags rwx

[...]

Ah. My memory is coming back to me now that I look at it.
There is currently a fix checked in for this, so I think the current boot code might work over mop.

The above objdump is unhelpful, since it's a boot which I have modified.

I hope people excuse my confusing messages. The problem was the reverse from what I wrote. The image sent over mop is loaded at address 0, even though the ELF header says otherwise. However, mopd *do* pass the transfer address, which means it would jump to the wrong address.

There is a "special" symbol defined in the boot image, to solve it. "nisse" (which is a silly Swedish name used for a scrap variable name), which is set to absolute 0, and the makefile, when building boot, actually tells ld to use nisse as the transfer address, instead of what's in the image.

Thus, the "fixed" boot file will work, since it will have a start address of 0, even though it would appear that the load address is not anywhere close to 0.

(Check common/srt0.S and boot/Makefile for VAX)

I don't recall off hand right now, but I think the primary bootstrap do another trick of instead assuming that the first loaded address of the image is the start address, and do not even check the transfer address in the header, and so that also works with this apparently broken ELF image that is /boot.

Someone else is of course welcome to check and correct what I wrote. But I think I got it right this time. (I should check the primary boot block jump to make sure about that one. It jumps to hdr.elf.e_entry, which I should check to refresh myself.)

        Johnny



Home | Main Index | Thread Index | Old Index