27.04.2013 Views

MVS Jan 2005.p65 - CBT Tape

MVS Jan 2005.p65 - CBT Tape

MVS Jan 2005.p65 - CBT Tape

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

CNOP Ø,4<br />

*=================================================================*<br />

* Trap program : *<br />

* Display GRØ,1,2 and PSW contents *<br />

* If R2 =2 it updates the PSW pointed instruction (so BCT ) *<br />

* with a PR to end program. *<br />

* *<br />

* Chaining : *<br />

* TCB->STCB->DUCT=> DUCT+X'44' => Trap Control Block Addr(TRCB) *<br />

* TCRB+X'ØC' => Trap Save Area addr(TRSA) *<br />

* TRSA+X'1Ø' => PSW 128bits *<br />

* Instruction to after TRAP *<br />

* TRSA+X'2Ø' => GRØØ-15 *<br />

* Resume Program: *<br />

* RP parmlist layout Ø-12 *<br />

* X'13'Bit P => Specify PSW size Ø=8 1=16 *<br />

* X 14'Bit R => if Ø, GR field is 4bytes *<br />

* => if 1 and Bit15=Ø GR field is *<br />

* 8bytes *<br />

* => if 1 and Bit15=1 in both *<br />

* GR field and field 2. *<br />

* X'15'Bit D => see above *<br />

* X'1Ø'Offset to psw fld *<br />

* X'2Ø'Offset to AR fld *<br />

* X'3Ø'Offset to GR fld *<br />

* X'4Ø'Offset to GR fld additional (see b15) *<br />

*=================================================================*<br />

PGM EQU *<br />

OPEN (SYSTRAP,OUTPUT) Open<br />

L R1,PSATOLD-PSA(,Ø) Current TCB<br />

L R1,TCBSTCB-TCB(,R1) Get STCB<br />

L R5,STCBDUCV-STCB(,R1) Get DUCT in R5<br />

L R5,44(,R5) Get TRAP2 CB<br />

BCTR R5,Ø Align on DW<br />

L R4,12(,R5) Get TRAP2 TRSA<br />

CLC X'28'(4,R4),=F'2' If R2=2 instr at<br />

BNE NOUPDT PSW (BCT) is overw<br />

L R3,X'1C'(R4) ritten with (PR) to<br />

MVC Ø(2,R3),=XL2'Ø1Ø1' end main loop<br />

MVC MSGGRØØ(16),=CL16'chg instr at psw'<br />

NOUPDT EQU *<br />

* Edit GRs and PSW<br />

UNPK MSGGR+4(9),X'2Ø'(5,R4) Unpk RØ<br />

TR MSGGR+4(8),TAB Edit RØ<br />

MVI MSGGR+12,X'4Ø' Clear<br />

UNPK MSGGR+13(9),X'24'(5,R4) Unpk R1<br />

TR MSGGR+13(8),TAB Edit R1<br />

MVI MSGGR+21,X'4Ø' Clear<br />

UNPK MSGGR+22(9),X'28'(5,R4) Unpk R2<br />

TR MSGGR+22(8),TAB Edit R2<br />

© 2005. Reproduction prohibited. Please inform Xephon of any infringement.<br />

5

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!