You're pointing to a pointer; load SYSIB into a register. ________________________________________ From: IBM Mainframe Assembler List <ASSEMBLER-LIST@LISTSERV.UGA.EDU> on behalf of Guillaume <guilla...@boesel.fr> Sent: Wednesday, March 8, 2023 10:54 AM To: ASSEMBLER-LIST@LISTSERV.UGA.EDU Subject: STSI use ?
Hi, I don't know if it's the right place to ask this kind of assembler question but I'm trying to use STSI instruction and I miserabily fail to do it and only get a S0C6 when I try a SYSIB x.x.x different than 0. CSRSI works well but I would like to detect the CP Polarity information (as I don't even succeed to use STSI, to get SYSIB 15.1.2 is a dream, I know...). In the PoO, it seems that the only requisites are that the SYSIB should be 4k bytes long and begin at a 4k bytes boundary. Otherwise STSI returns a Specification Exception. Of course, it returns me a S0C6 (storage boundary alignment problem ?) I thought that my code fills the requisites but it's not the case and I can't see where it fails. I tried GETMAIN and STORAGE OBTAIN of 4k and SYSIB aligned at x'1000' thanks to "ORG STSIINFO+4096". I didn't find it in the PoO but are there others requisites that the SYSIB ones (4k bytes long and 4k bytes boundary aligned) ? For example a special subpool to use ? Or is somebody could say me where is/are the problem(s) in the code below, please ? Thank you very much, Guillaume (learning assembler since less than 1 year, therefore sorry if my question looks trivial) STSIINFO AMODE 31 STSIINFO RMODE 24 R0 EQU 0 ... R15 EQU 15 ********************************************* PRINT NOGEN BASR R10,0 USING *,R10,R11 LAY R11,4096(0,R10) START EQU * * * STORAGE OBTAIN or GETMAIN of 4k at a 4k boundary ** STORAGE OBTAIN,LENGTH=ONE_PAGE,ADDR=SYSIB,BNDRY=PAGE L R2,QUERYLEN QUERYLEN = 4 k GETMAIN EC,LV=(R2),A=SYSIB,BNDRY=PAGE LTR R15,R15 GETMAIN OK (R15=0) ? BNZ GETMAIN_KO No ? End * MODESET KEY=ZERO,MODE=SUP ** XR R0,R0 ** XR R1,R1 L R0,=X'10000001' L R1,=X'00000001' STSI SYSIB S0C6 MODESET KEY=NZERO,MODE=PROB * * * FREEMAIN or Storage Release FREEMEM EQU * L R2,QUERYLEN FREEMAIN EU,LV=(R2),A=SYSIB ** STORAGE RELEASE,LENGTH=ONE_PAGE,ADDR=SYSIB * B END ********************************************* END EQU * LM R14,R12,R12(R13) RETURN RC=0 * BR R9 *************************************** GETMAIN_KO WTO 'STSIINFO : GETMAIN KO' B END *************************************** LTORG QUERYLEN DC A(4096) 4k for SYSIB GETMAIN ONE_PAGE EQU 4096 4k for SYSIB STORAGE OBTAIN GETMAIN_LEN DS F ORG STSIINFO+4096 Location Counter = 4k (0 + 4096) SYSIB DS F *************************************** END Location of SYSIB during assembling = x'1000' Symbol Length Value Id STSIINFO 1 00000000 00000001 SYSIB 4 00001000 00000001 =X'00000001' 4 000000BC 00000001 =X'10000001' 4 000000B8 00000001