Project

General

Profile

Feature #10898

Add topo method to determine occupant status

Added by Rob Johnston 6 months ago. Updated 5 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
-
Start date:
2019-05-01
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
needs-triag

Description

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.

History

#1

Updated by Rob Johnston 6 months ago

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

commit e6c7580c6215121cdb3e00cf18843f8010beda6c
Author: Rob Johnston <rob.johnston@joyent.com>
Date:   Thu Mar 21 03:50:37 2019 +0000

    OS-7676 Add topo method to determine occupant status
    Reviewed by: Robert Mustacchi <rm@joyent.com>
    Approved by: Jordan Hendricks <jordan.hendricks@joyent.com>

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

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

https://smartos.org/bugview/OS-7676

#2

Updated by Electric Monk 5 months ago

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

git commit 8abca89f418632e2ebd3bcbc8b0d814c394ebef1

commit  8abca89f418632e2ebd3bcbc8b0d814c394ebef1
Author: Rob Johnston <rob.johnston@joyent.com>
Date:   2019-05-14T19:01:56.000Z

    10898 Add topo method to determine occupant status
    Reviewed by: Robert Mustacchi <rm@joyent.com>
    Reviewed by: Toomas Soome <tsoome@me.com>
    Approved by: Gordon Ross <gwr@nexenta.com>

Also available in: Atom PDF