﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
375	dump_segment/ring_zero_dump should call new cv_ptr_$for_dump_segment	Gary Dixon	Gary Dixon	"For many years, dump_segment.pl1 (with entry points for ring_zero_dump, dump_seg_, dump_segment_, etc) has used an internal quite old version of the cv_ptr_ subroutine rather than calling the cv_ptr_ in bound_conversion_rtns_.  The reason for this internal cv_ptr_ was to access corrected  code for addressing ring-0 and inner-ring segments.  Instead of correcting the external subroutine, the programmer chose to include an earlier cv_ptr_ version in which he made a minor change.  This permitted a quick fix without fully retesting the external cv_ptr_ routine.

This internal-to-dump_segment version of cv_ptr_ has gotten quite out-of-sync with the current cv_ptr_.  It should be removed from dump_segment.pl1.  Dump segment relied on some non-visible data gathered by this internal cv_ptr_ as it located the external pointer.  To make equivalent data available from the latest external cv_ptr_ implementation, a new cv_ptr_$for_dump_segment entry point could be added to return the equivalent data for use by the dump_segment code.

Proposed calling sequence for the new cv_ptr_ entry point is shown below.


{{{
/* ==================================================

    FUNCTION ENTRY POINT:  cv_ptr_$for_dump_segment

   ================================================== */

cv_ptr_$for_dump_segment:                                   /* Subroutine entrypoint:  cv_ptr_$for_dump_segment       */
     entry( Astring, Acode,                                 /*  Input data supplied by dump_segment.                  */
            Aprocedure_name, Aversion, Aarg_list_ptr,
            Adirname, Aename, Aepname,                      /*  Output data needed by dump_segment stemming from      */
            Alength_in_words, Aread_bracket, Asegno,        /*   initiating seg pointed to by the converted Astring   */
            AhardcoreS, Ainner_ringS, Aneeds_termS )
       returns( ptr );

/*dcl  Astring                char (*) parameter,           /* virtual pointer character string.                (In)  *
       Acode                  fixed bin(35) parameter;      /* status code.                                     (Out) */
  dcl  Aprocedure_name        char (*) parameter;           /* Name of calling command on whose behalf cv_ptr_  (In)  */
                                                            /*   will operate.                                        */
  dcl  Aversion               char (*) parameter;           /* Version of that command used in creating ssu_    (In)  */
                                                            /*   standalone invocation.                               */
  dcl  Aarg_list_ptr          pointer parameter;            /* Pointer to argument list to be passed to               */
                                                            /*   ssu_$standalone_invocation so it can tell            */
                                                            /*   how caller invoked: as command or active function.   */
  dcl  Adirname               char (*) parameter;           /* Directory   name of Astring segment.             (Out) */
  dcl  Aename                 char (*) parameter;           /* Entry       name of Astring segment.             (Out) */
  dcl  Aepname                char (*) parameter;           /* Entry point name of Astring segment.             (Out) */
  dcl  Alength_in_words       fixed bin(19) parameter;      /* Maximum length (words) existing in segment.      (Out) */
  dcl  Aread_bracket          fixed bin(6) unsigned unaligned parameter;
                                                            /* Max ring in which segment is readable.           (Out) */
  dcl  Asegno                 fixed bin(12) parameter;      /* Segment number identified by Astring.            (Out) */
  dcl  AhardcoreS             bit(1) aligned parameter;     /* Segment resides in ring-0.                       (Out) */
  dcl  Ainner_ringS           bit(1) aligned parameter;     /* Segment resides in ring-1 ... ring-I where I     (Out) */
                                                            /*   is < get_ring_(): ring-of-execution of caller.       */
  dcl  Aneeds_termS           bit(1) aligned parameter;     /* Caller needs to call cv_ptr_$terminate once done (Out) */
                                                            /*   using the segment.                                   */

}}}
"	enhancement	closed	major	MR12.9	Tools	MR12.5	fixed		
