[Simh] Write sector headers to disk
Johnny Billquist
bqt at softjar.se
Tue Jun 25 16:16:21 EDT 2019
On 2019-06-25 08:31, Lars Brinkhoff wrote:
> Hello,
>
> Some of DEC's disks allow reading and writing the sector headers. ITS'
> disk formatting program, SALV (the Salvager), uses this to make a new
> file structure on a pack, and to verify its integrity.
>
> This isn't fully supported by SIMH. The file PDP10/pdp10_rp.c has the
> comment "23-Aug-01 RMS Added read/write header stubs for ITS", and the
> stub is in "case FNC_WRITEH" in rp_svc. It's a no-op that just sets the
> DONE flag.
>
> What is supposed to happen is that SALV wants to write two header words
> with geometry information and then the sector data with a particular bit
> pattern. The verification phase reads back and checks the bit pattern.
> Since those bits aren't written, the verification fails.
>
> This isn't so bad since SALV offers to skip the verification. But now
> this has come up again using Rich Cornwell's upcoming KA10 addition to
> SIMH. The KA10 version of SALV does the same with an RP04 disk, but
> does not have the option to skip the verification. SALV also writes
> some information to the key fields in the headers, which is later read
> back.
>
> I'm wondering what your opinions are reagarding this? I see some options:
>
> 1. Do not change SIMH. Patch SALV to skip the verification. Obviously
> this is quite quick and painless, but leaves me with a slightly
> dissatisfied feeling. Some historical software isn't running properly.
>
> 2. Add header words to the disk image file. An incompatible change, but
> should of course be optional.
>
> 3. Store header words out of band somehow. Last in the image file?
> In another file?
>
> I understand the case for making changes to SIMH is quite weak if
> running SALV is the one and only use case. Are there any other programs
> that reads or writes the headers?
The fourth option is to treat this as a normal write. Essentially,
unless I remember wrong, that is pretty much the end result on real
hardware. Yes, you rewrite the headers, but the headers are pretty much
forced to look a certain way, and is not something software normally
tries to read. But the headers have to be correct for the disk to be
usable. Not all disks can even write down the headers in the field. But
a write with headers also do a normal write, in addition to
rewriteing/refreshing the headers.
And I suspect all software beyond that point only expects that the
written patterns in the data area are as expected after the write.
Reading the headers out would essentially just become a question of
verifying that the hardware works. I've played with a few disks back in
the day that could write the headers as well as read them, but there
were no ability to store arbitrary data there, so what would be returned
on a read headers could be computed when needed. But maybe you are
playing with some special disk that actually can store some amount of
arbitrary data in the header? (The ones I think I looked at/played with
are the RK05, RP06 and RP07.)
Johnny
--
Johnny Billquist || "I'm on a bus
|| on a psychedelic trip
email: bqt at softjar.se || Reading murder books
pdp is alive! || tryin' to stay hip" - B. Idol
More information about the Simh
mailing list