[openib-general] [PATCH] Allow setting of NodeDescription

Roland Dreier rolandd at cisco.com
Wed Sep 14 18:56:07 PDT 2005


    Roland>  - Allows userspace to set node_desc by writing into sysfs file, eg.
    Roland>      echo -n `hostname` >> /sys/class/infiniband/mthca0/node_desc

    Hal> Shouldn't there be a non volatile way to do this ?

I'm not sure what "non volatile" means in this context.  For Mellanox
HCAs, one can already set a permanent NodeDescription in the flash
when burning firmware.  Also, the echo command above was just an
example; a hotplug script could also do

    cat /my/permanent/node_desc > /sys/class/infiniband/mthca0/node_desc

or anything more elaborate it wants.

    Hal> Are there issues with userspace being able to do this or is
    Hal> the access rights on /sys/class/infiniband/mthca0/node_desc
    Hal> sufficient ?

No, there are no issues.  The node_desc file is owned by root and has
perms 0644, and root can already change the node_desc by more
nefarious means anyway.

 - R.



More information about the general mailing list