Subject: Re: PR 12547 (console break signal ignored if DDB not defined)
To: None <eeh@netbsd.org>
From: Chuck Silvers <chuq@chuq.com>
List: tech-kern
Date: 03/10/2002 23:14:06
after looking further I noticed that zs_abort() doesn't actually use
the softc pointer on any platform that I wanted to change,
so I'll just pass in NULL and not worry it.

thanks,
-Chuck


On Sun, Mar 10, 2002 at 04:30:04AM -0000, eeh@netbsd.org wrote:
> | to fix PR 12547, I propose to add an extra "cookie" argument to
> | cn_check_magic() and cn_trap().  on platforms that have a firmware
> | monitor such as the sparc, this cookie can be used to pass the
> | console driver's softc pointer to (eg.) zs_abort(), which will
> | drop into the monitor like before the cnmagic changes.
> | (currently zs_abort() is defined on several platforms but is unused).
> |
> | I've tested the attached changes on sparc and sparc64 (an ultra2).
> | the "com" parts are untested but should be harmless.
> | comments?
> 
> Since cn_trap() is specified to be a macro you can simply redefine
> it to make use of the appropriate parameter in the MD bus-specific
> attachment header file.  This prevents you from needing to change
> the signatures of the macros for every weird parameter that the
> low-level trap routine may need.  
> 
> Eduardo