HP-UX Reference (11i v3 07/02) - 3 Library Functions N-Z (vol 7)

u
uc_access(3)
Integrity Systems Only
uc_access(3)
The following Control Registers may be specified:
Reg Register Notes
17 CR_ISR
20 CR_IFA Only valid for certain types of interruptions.
22 CR_IIPA
If the context was created in a syscall, the control registers will read as 0.
__uc_get_rsebs()
, __uc_set_rsebs()
,
__uc_get_rsebs64()
, __uc_set_rsebs64
When a signal handler is invoked, the kernel attempts to write all dirty RSE registers to the ori-
ginal RSE backing store. If it is unable to do this (that is, if the memory is not mapped) the ker-
nel will write remaining dirty registers to an overflow area within the
ucontext_t . These
interfaces are provided to access those values saved in this overflow area.
Use
__uc_get_ar()
to fetch the AR.BSP and AR.BSPSTORE values.
If the address of the value you want is Use
addr < AR.BSPSTORE direct read/write
AR.BSPSTORE <= addr < AR.BSP __uc_[gs]et_rsebs{64}()
Special case for the last NaT collection: __uc_[gs]et_rsebs{64}()
addr == AR.BSP | 0x1f8
The NaT bits may be split between the AR.RNAT value and the overflow area.
Address Where to find the NaT
addr < AR.BSPSTORE & ˜0x1ff direct read/write of backing store
AR.BSPSTORE & ˜0x1ff <= addr < AR.BSP __uc_[gs]et_rsebs{64}(addr|0x1f8)
For 32-bit callers, __uc_get_rsebs()
and __uc_set_rsebs() will swizzle the addr
argument.
__uc_[gs]et_rsebs64()
are provided for 32-bit callers reading a ucontext_t gen-
erated within a 64-bit application. They differ from
__uc_[gs]et_rsebs()
in that the addr
argument will not be swizzled.
__uc_[gs]et_rsebs64()
are only included in 32-bit ver-
sions of the library.
RETURN VALUE
Upon successful completion, all the interfaces return 0 to indicate success and return [EINVAL] if passed
invalid arguments.
ERRORS
The Ucontext Access interfaces will fail if any of the following conditions are encountered:
[EINVAL] For any of the interfaces listed above, the
ucp argument is NULL, or points to a
ucontext_t with an invalid version or size.
[EINVAL] For the __uc_get_grs()
or __uc_set_grs() calls the range of registers
specified by
first and count included a value outside the range 1 to 31 inclusive.
[EINVAL] For the __uc_set_grs() call, ucp was created by a syscall and the range of regis-
ters specified by
first and count included a scratch register.
[EINVAL] For the __uc_get_frs() or __uc_set_frs()
calls the range of registers
specified by
first and count included a value outside the range 2 to 127 inclusive.
[EINVAL] For the __uc_set_frs() call, ucp was created by a syscall and the range of regis-
ters specified by
first and count included a scratch register or an attempt is made
to set bits {127:82} of an FP value.
[EINVAL] For the __uc_set_prs() call, ucp was created by a syscall and
value included a
set scratch bit or bits.
[EINVAL] For the
__uc_get_brs() or __uc_set_brs()
calls the range of registers
specified by
first and count included a value outside the range 0 to 7 inclusive.
[EINVAL] For the __uc_set_brs() call, ucp was created by a syscall and the range of regis-
ters specified by first and count included a scratch register.
588 Hewlett-Packard Company 6 HP-UX 11i Version 3: February 2007