Guardian Procedure Calls Reference Manual

It is possible for DEVICE_GETINFOBYLDEV_ to return an error value of 0 (information
successfully returned) while the IOP reports an error in the status field. In that case, the
error value of 0 indicates that communication with the IOP was successful, while the IOP
status value reflects the validity of the returned information.
Searching logical devices
To perform a search of logical devices, you must specify options.<15> = 1.
DEVICE_GETINFOBYLDEV_ searches logical device numbers starting with the number
immediately following ldevnum. Information is returned for the next device found.
To search all logical devices, set the initial value of ldevnum to -1; for each iteration of the
search, update ldevnum to the logical device number of the last device for which information
was returned. The logical device number of a device is returned in logical-info (see
Device Attributes and Value Representations (page 304)).
When match-type is supplied (in combination with options.<14> equal to 1), or when
match-subtype is supplied (in combination with options.<13> equal to 1), the search
returns information only for a device of the specified type or subtype. match-type and
match-subtype can be used together; in that case, a device must match both the specified
type and subtype to be selected by the search.
When a search can find no more devices, an error value of 4 is returned and
error-detail contains 19 (no more devices).
Example
! obtain logical and physical attributes for
! logical device 10.
logical^device := 10;
error := DEVICE_GETINFOBYLDEV_ (
logical^device,
l^info, l^info^maxlen, l^info^len, p^info,
p^info^maxlen, p^info^len,
b^info, b^info^maxlen, b^info^len );
Related Programming Manual
For programming information about the DEVICE_GETINFOBYLDEV_ procedure, see the Guardian
Programmer's Guide.
308 Guardian Procedure Calls (D-E)