August 15, 2025

Sun 3 bootrom souce - Merge the pull request from Romain

He titles this "This makes the bootrom usable in tme-0.8".

The first thing I do is to commit all my changes, then clone the repository so I have a copy "pre-Romain" to compare to. Then I get busy trying to figure out how to make Github merge the changes for me. I thought this was supposed to be easy? Here is a description he supplied with the pull. I see that he did 23 commits to his fork!

With those set of changes, the built bootrom can boot NetBSD in tme-0.8 (+ pkgsrc patches).
This includes:

-- some minor fixes (headers included twice, ...)
-- packing of many structure to make the C and ASM code behave the same and see the same offsets
-- erroneous values produced from bitfields by genassym (corrected in assym.h only), genassym also need to be 32-bits code
-- current gcc doesn't add an underscore in front of function names, so removed in romvec.s
-- workaround for mod3read clobbering caller-saved registers
-- bunch of memory-clobbering asm volatile to preserve order of in the reset function and some other places (maybe too many)
-- padding and checksumming
Github is clueless and impossible. I log out and back in again. I go to the sun-bootrom project, and it shows 1 pull request at the top. I click on this and get a more or less usless page that lists all the pull requests (just one). I click on the name of the request and get a big fancy looking page. But, there is no merge button as I was led to expect. It looks like this is due to conflicts. There is a resolve conflicts button that is greyed out.

Here is his commit list:

avoid multiple inclusion
missing name
dump binary rom, pad to 64 kiB
fix value for PME_INVALID (endianess?)
no repeat
align column for readability, fix some values (beware the file was au… …
all entries, remove spurious _ in front of C function
padding
compile as 32 bits to get the appropriate pointer size
__attribute__ ((packed)), plus one volatile
updated (with previous, enough to get the logo but no text)
__attribute__ ((packed)), plus some asm volatile for ordering
bunch of olatile that may or may not be useful
missing function, that happens to do the display of characters on scr… …
-O1 for testing
test_mem works at -O2 (and -O0), but not -O1 !?!
binary that boots NetBSD in TME
fix test_mem issue, extra comments in Makefile
drop old binary
update binary
build properly checksummed 'bootrom' directly
check 3/60 (FERRARI) ROM binary vs. source code in diag.s, mostly beh… …
check 3/60 (FERRARI) ROM binary vs. source code in trap.s

Fall back to the command line

Here is what Github says to do.
In my project repository:
git checkout -b MelkhiorVintageComputing-master master
git pull git@github.com:MelkhiorVintageComputing/sun3-bootrom.git master
Then, once it all looks good.
git checkout master
git merge --no-ff MelkhiorVintageComputing-master
git push origin master

Feedback? Questions? Drop me a line!

Tom's Computer Info / tom@mmto.org