Feature #10898

Add topo method to determine occupant status

Added by Rob Johnston over 1 year ago. Updated about 1 year ago.

Start date:
Due date:
% Done:


Estimated time:
Gerrit CR:


There are a number of topo node types that represent FRU containers. For example. "bay" and "slot" nodes. It would be useful if there was a node method one could invoke on such nodes to determine whether or not the FRU occupant was present.

One use case involves code which manages drive bay indicators (LEDs). It's common for drive bay indicators to not be controllable when the drive bay is not occupied. Thus it would be useful to have a method one could invoke on a "bay" node to determine if that bay was occupied. before attempting to set the drive bay indicator states.

This ticket it to cover adding a new method TOPO_METH_OCCUPIED which can be registered onto FRU container nodes.

As part of this work we will also extend the "-S" option fmtopo to invoke this method and print the result on each node as it walks the tree.

Finally we'll add a new API - topo_node_occupied() - which wraps the code to invoke TOPO_METH_OCCUPIED on a node.

We will also update various enumerator modules to register this new method onto nodes, where appropriate.



Updated by Rob Johnston over 1 year ago

This change has already been integrated into illumos-joyent via the commit below:

commit e6c7580c6215121cdb3e00cf18843f8010beda6c
Author: Rob Johnston <>
Date:   Thu Mar 21 03:50:37 2019 +0000

    OS-7676 Add topo method to determine occupant status
    Reviewed by: Robert Mustacchi <>
    Approved by: Jordan Hendricks <>

Thus, this issue is simply to track pushing the above change upstream.

See the SmartOS ticket for details on how this change was tested.


Updated by Electric Monk about 1 year ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100

git commit 8abca89f418632e2ebd3bcbc8b0d814c394ebef1

commit  8abca89f418632e2ebd3bcbc8b0d814c394ebef1
Author: Rob Johnston <>
Date:   2019-05-14T19:01:56.000Z

    10898 Add topo method to determine occupant status
    Reviewed by: Robert Mustacchi <>
    Reviewed by: Toomas Soome <>
    Approved by: Gordon Ross <>

Also available in: Atom PDF