On Fri, 12 Jan 2024 at 09:24, Eric D Rossman <[email protected]> wrote:

> There is no documentation because this is not a supported interface. It
> has been suggested in passing but has never been put forward as an official
> requirement.
>
> All LE-capable applications have access to the CSFDLLxx (where xx is
> 31,3X,64) libraries and the csfbext.h C/C++ header to call directly
>
> All non-LE applications have the CSN* and CSN*6 (plus CSF*/CSF*6)
> assembler stubs.
>
> Eric Rossman
> ICSF Architect
>

IBM has been quite mixed in its documentation for the various "new"
callable services that ship with stub routines. UNIX and RACF document the
offsets and calling procedures, and some others (Unicode services) sort of
mention it but don't have a table of routines:offsets. IBM explicitly or
implicitly supports using these offsets in that there is no requirement
(and it would be unreasonable to have one) to re-bind with new stubs upon
every z/OS release.

Many years ago I wrote a macro I called BPXCALL that knew how to invoke any
of the UNIX CSRs by name. Later I extended it to support RACF and then
Unicode services and a few other handy things, and renamed it to CSRCALL.
It's my former employer's, so I can't post it here, but it's certainly not
difficult to write one. For the UNIX version I was able to cut&paste from
the book into the macro. I used some of the HLASM features to make the
generated call code look nice, e.g. it generates (once) and then uses a
symbol for every routine it calls so you don't see a bunch of undocumented
numeric offsets starting from the CVT amd ending in a BASR.

I find the whole "bind it with a stub" scheme causes all kinds of packaging
issues, and IMHO IBM should just document all the calls (as UNIX and RACF
do) and perhaps even provide their own CSRCALL-type macro.

Tony H.

-----Original Message-----
> From: IBM Mainframe Discussion List <[email protected]> On Behalf
> Of Binyamin Dissen
> Sent: Friday, January 12, 2024 3:26 AM
> To: [email protected]
> Subject: [EXTERNAL] Direct branch entry to ICSF routines
>
> I have been looking but I have not yet found the explicit doc that shows
> how to call ICSF routines via the CSFCCVT.
>
> Looking at a few of the stub routines I see that they create a linkage
> stack entry and then call the real routine via CSFCCVT but the labels in
> the CSFCCVT are not obviously related to the name of the stub routine.
>
> I am expecting to find something like for the name/token routines, where
> the stub can be used but the direct entry is also documented.
>
> Further research shows that the several routine that I am interested all
> branch to the same EP, but the stub loads a different value into R0. Don't
> ask me why there aren't a list of equated  values for the various functions
> and a parameter with the function code. At any rate, high level language
> routines cannot set R0 but assembler routines certainly can.
>
> ----------------------------------------------------------------------
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to [email protected] with the message: INFO IBM-MAIN
>

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to