tech-kern archive

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

Re: PowerBook 5xx instability fix.



On Mon, 31 Mar 2025 13:48:37 Tetsuya Isaki wrote:
> At Sun, 30 Mar 2025 11:29:38 +1100,
> 
> Nat Sloss wrote:
> > I've done some more investigating.  It seems it is only unstable
> > when using an
> > audio kernel.  I believe there is a possibility some of the pages
> > at the top
> > on memory are being used by the ASC/EASC.
> > 
> > The crashes are easily reproducible as simple as listing a directory
> > while
> > triggering a console bell.
> 
> At Sun, 30 Mar 2025 13:39:47 +1100,
> 
> Nat Sloss wrote:
> > Is something like this OK?
> > 
> > --- a/sys/arch/mac68k/mac68k/pmap_bootstrap.c   Sat Mar 29 01:43:38
> 
> 2025 +0000
> 
> > +++ b/sys/arch/mac68k/mac68k/pmap_bootstrap.c   Sun Mar 30 13:36:45
> 
> 2025 +1100
> 
> >         maxaddr = high[numranges - 1] - m68k_ptob(1);
> > 
> > -       high[numranges - 1] -= (m68k_round_page(MSGBUFSIZE) +
> 
> m68k_ptob(1));
> 
> > +
> > +       /*
> > +        * Reduce high by an extra 7 pages which seem to be used by
> 
> the EASC
> 
> > +        * ascaudio(4) on some machines.
> 
> The above your messsage says ascaudio has issues.
> The next your message says you're not sure what's going on.
> It's better to look into it more before modifying pmap.
> With typical audio MD drivers, it's unlikely to need pmap
> modification (though I'm not sure about mac specific).
> ---
> Tetsuya Isaki <isaki%pastel-flower.jp@localhost / isaki%NetBSD.org@localhost>

Sorry I'm mistaken - ascaudio(4) does NOT have issues on the PowerBook 160 or 
520/540.  Which I have tested it throughly on. - The audio MD code does not 
modify the top of memory.

What I'm observing on the PowerBook 520 is that a portion of the top of memory 
is being used by the hardare when audio fifos are started.....This can only be 
observed when using the audio hardware on the PowerBook 520/540.

It is not an issue with all macs but as I only have a small number of machines 
to test with I cannot be certain as to which models are affected.

And for the sake of an addiotional 7 pages (56kB) it ensures that the system 
functions with an AUDIO kernel or GENERIC for all macs - should include all 
macs I cannot test on too.

Unless people with differnent hardware were to test I'm unable to refine this 
patch further :(

Best regards,

Nat


Home | Main Index | Thread Index | Old Index