[Info-vax] C... the only winning move is not to play...

Stephen Hoffman seaohveh at hoffmanlabs.invalid
Wed Feb 12 15:51:23 EST 2014


On 2014-02-12 20:32:44 +0000, David Froble said:

> After thinking about this for a while, I must confess to curiosity.
> 
> I'm assuming that by "inner mode" that you're talking about kernel mode.

Inner-mode code is supervisor-, executive- or kernel-mode.  You could 
reference interrupt mode if you wanted, though that's a subset of 
kernel-mode environment.

> If not, then ignore the rest of this.

Whoops.  Ignore the rest.

> I've dabbled a bit at exec mode, mainly to allow some RTL code to use 
> SYSLCK when the user didn't have that priv.  But I've never had the 
> need to run anything in kernel made.

Code that performs device hardware access or that traverses OpenVMS 
data structures.   Certain forms of OpenVMS extensions are inner-mode.  
Ancillary Control Processes (ACPs) 
<http://labs.hoffmanlabs.com/node/213> involve user- and kernel-mode 
code, too.

One of the classic examples of accessing inner-mode data structures 
involves code that provides the caller with the analog of the SHOW 
LOGICAL * command output, but there are many other triggers.     There 
are other (and dumber?) reasons.  Here 
<http://labs.hoffmanlabs.com/node/815> is some example kernel code that 
patches a kernel data cell to allow a software kit to install.

Implicit privileges are provided to any code executing in executive and 
kernel modes, as well.  That code acquires at least SETPRV, CMKRNL, 
SYSNAM, and SYSLCK, IIRC.

> What would you be doing that would require running in kernel mode?  I'm 
> assuming that you're working on some type of application, and not 
> modifying something in VMS.

VAXman has already indicated DCL and RMS-level chatter, which covers 
supervisor and executive.

> My understanding, and it's vague, is that you'd never want to invoke 
> any code that might throw an error while running in kernel mode.

Not true.  You just need to handle all of those errors, or badness 
typically ensues.  Fielding an error in an inner mode is entirely 
permissible, but you don't want to pass a fatal error through to 
OpenVMS to deal with.  Not unless you want to go fetch some coffee or 
tea while you wait for the box to reboot.

> As Steve mentioned elsewhere, that leaves out any of the language 
> modules, RTL modules, and such.  I'd think that that would also exclude 
> STR$CONCAT and such.

Pretty much anything that has RTL VM services underneath it somewhere; 
anything that mixes or shares data across modes.


-- 
Pure Personal Opinion | HoffmanLabs LLC




More information about the Info-vax mailing list