The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: kstailey@yahoo.com (Kenneth Stailey)
Subject: [TUHS] Re: 4.3 BSD version in the Unix Archive
Date: Wed, 1 Oct 2003 09:56:00 -0700 (PDT)	[thread overview]
Message-ID: <20031001165600.32320.qmail@web10010.mail.yahoo.com> (raw)
In-Reply-To: <PMEAIMBALAHKECEIMJFGAEOFMCAA.jmbw@nather.com>


--- Markus Weber <jmbw at nather.com> wrote:
> I found out a bit more.
> 
> For any non-OpenVMS OS I tried on simh/vax (read: different flavors of BSD),
> disk initialization is a common problem area. NetBSD glitches on mounting
> the installation CD/disk, Quasijarus has a hard time deciding which disks
> are online and which are not, and finally OpenBSD installs without problem,
> but fails when mounting the root filesystem when it boots off ra0a. I can
> however boot off the install-time kernel on the floppy disk and access the
> partitions on ra0 just fine.
> 
> It became apparent that OpenBSD's in-core disk label defaulted to data
> matching the c partition where the a partition should have been. After more
> digging, it seemed that ra_putonline was called, but rx_putonline must have
> failed somehow. To add insult to injury, after adding a few printf
> statements to rx_putonline the OpenBSD sort-of-GENERIC kernel now boots.
> 
> Here's the relevant block of code:
> 
> rx_putonline(rx)
>         struct rx_softc *rx;
> {
>         struct  mscp *mp;
>         struct  mscp_softc *mi = (struct mscp_softc *)rx->ra_dev.dv_parent;
>         volatile int i;
> 
> printf("entered rx_putonline\n");
>         rx->ra_state = DK_CLOSED;
>         mp = mscp_getcp(mi, MSCP_WAIT);
>         mp->mscp_opcode = M_OP_ONLINE;
>         mp->mscp_unit = rx->ra_hwunit;
>         mp->mscp_cmdref = 1;
>         *mp->mscp_addr |= MSCP_OWN | MSCP_INT;
> 
>         /* Poll away */
>         i = bus_space_read_2(mi->mi_iot, mi->mi_iph, 0);
>         if (tsleep(&rx->ra_dev.dv_unit, PRIBIO, "rxonline", 100*100))
>                 rx->ra_state = DK_CLOSED;
> printf("rx->ra_state = %d\n",rx->ra_state);
>         if (rx->ra_state == DK_CLOSED)
>                 return MSCP_FAILED;
> printf("rx_putonline returns DONE\n");
>         return MSCP_DONE;
> }
> 
> My guess is that the very first printf upsets the emulation timing just
> enough to make things work. I'd have to read more code and RQDX3
> documentation to take this further, but maybe this is enough to go on to
> make it obvious to somebody else why Quasijarus on simh exhibits these
> awfully long disk probe timeouts. I hope that once this problem has been
> narrowed down a bit more, a fix to simh/vax will make all BSDs happy.

My first guess would be that there should be more "volatile" keywords used.  I
think the printf()s cause the compiler to not discard some varibles.  Does it
work without the printf()s if you don't use "-O" (or "-O2", etc) optimization? 
I think gcc does not elminitate varibles ever when the code is not optimized.

> -----Original Message-----
> From: Michael Sokolov [mailto:msokolov at ivan.Harhan.ORG]
> Sent: Friday, September 26, 2003 3:48 PM
> To: jmbw at nather.com; tuhs at tuhs.org
> Subject: RE: [TUHS] Re: 4.3 BSD version in the Unix Archive
> 
> 
> [...] If so, SIMH's MSCP emulation must be lacking in quality.
> 
> [...]But I will grant the possibility that the kernel is not w/o fault
> either in that
> perhaps it's going south (dereferencing a garbage pointer and crashing) when
> the
> MSCP controller (in this case SIMH's poor emulation) is doing something it
> doesn't expect.
> ---
> Outgoing mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.520 / Virus Database: 318 - Release Date: 9/18/2003
> 
> _______________________________________________
> TUHS mailing list
> TUHS at minnie.tuhs.org
> http://minnie.tuhs.org/mailman/listinfo/tuhs


__________________________________
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search
http://shopping.yahoo.com


  reply	other threads:[~2003-10-01 16:56 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-09-26 20:47 Michael Sokolov
2003-10-01 15:33 ` Markus Weber
2003-10-01 16:56   ` Kenneth Stailey [this message]
2003-10-01 21:07     ` Markus Weber
  -- strict thread matches above, loose matches on Subject: below --
2003-10-01 14:39 Michael Sokolov
2003-10-02 15:48 ` Robert Brockway
     [not found] <PMEAIMBALAHKECEIMJFGAENNMCAA.jmbw@nather.com>
2003-10-01  1:00 ` Gregg C Levine
2003-10-01  2:46   ` Markus Weber
2003-10-01  3:13     ` Robert Brockway
2003-10-01  7:10     ` Jochen Kunz
2003-09-29 18:50 Joseph F. Young
2003-09-30 13:04 ` Markus Weber
2003-09-30 19:02   ` Gregg C Levine
2003-09-26 18:35 Michael Sokolov
2003-09-26 20:24 ` Markus Weber
2003-09-26 11:47 Michael Sokolov
2003-09-26 17:48 ` Markus Weber
2003-09-24  2:40 [TUHS] ctcompare 1.2 is up Warren Toomey
     [not found] ` <PMEAIMBALAHKECEIMJFGMELBMCAA.jmbw@nather.com>
2003-09-26  3:03   ` [TUHS] Re: 4.3 BSD version in the Unix Archive Warren Toomey

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20031001165600.32320.qmail@web10010.mail.yahoo.com \
    --to=kstailey@yahoo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).