The following code creates three new data blocks within
a shared memory map.
For the callable service, see
__map_service (BPX1MMS, BPX4MMS) — Mapped megabyte area services. For the
data structure, see
BPXYMMG — Map interface for _map_init and _map_service.
AMODE 64 callers
use
BPX4MMS (__map_service) example.
LA R3,SRVCPARM Set address of init parm list
ST R3,SRVCADDR
USING _MMG_SERVICE_PARM,R3
XC _MMG_SERVICE_PARM(_MMG_SERVICE_PARM_LEN),_MMG_SERVICE_PARM
LA R4,MMG_NEWBLOCK Request that a block be created
STH R4,_MMG_SERVICETYPE
LA R3,_MMG_SERVICE_PARM_LEN(R3) Bump to next entry
STH R4,_MMG_SERVICETYPE Create a second block
LA R3,_MMG_SERVICE_PARM_LEN(R3) Bump to next entry
STH R4,_MMG_SERVICETYPE Create the third block
SPACE ,
CALL BPX1MMS, +
(=A(MMG_SERVICE), Input: Function code +
SRVCADDR, Input: __map_service parm list +
=F'3', Input: Three requests to process +
_MMG_MAPTOKEN, Map area token from INIT call +
RETVAL, Return value: 0, -1 +
RETCODE, Return code +
RSNCODE), Reason code +
VL,MF=(E,PLIST) ----------------------------------