How can I create 'pkey' on mellanox IB port?

Garrett Cooper yanegomi at gmail.com
Tue May 28 15:45:23 UTC 2013


On Tue, May 28, 2013 at 5:10 AM, Alex Liptsin <alexl at mellanox.com> wrote:

> Hello.
>
> I have FreeBSD 9.1 installed.
> There is mellanox adapter inside.
>
> [root at qa-h-vrt-030-006 ~]# pciconf -lv |grep mlx4 -A 3
> mlx4_core0 at pci0:0:5:0:  class=0x028000 card=0x005015b3 chip=0x100315b3
> rev=0x00 hdr=0x00
>     vendor     = 'Mellanox Technologies'
>     device     = 'MT27500 Family [ConnectX-3]'
>     class      = network
>
>
> OFED support is already compiled.
>
> I try to add pkeys on ib0 port.
>
> Usually in  Linux I did:
>
> echo 0x800c >  /sys/class/net/ib0/create_child
>
> ifconfig -a
> To Make sure you see a new interface: ib0.800c
>
> How can I do it on FreeBSD? There is no "/sys/class/net/ib0/create_child"
> directory.
>

Hi Alex!
    For all sysfs entries there *should* be a corresponding sysctl for it.
Do sysctl -Na | grep create_child and you might find the node that you
seek. After that all you need to do is call sysctl <node>=0x800c and it
should achieve the same thing as setting the sysfs node.
    Please note that you must be the patch attached to
http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/174213 in order for things
to function properly as the sysfs handling code is still broken on HEAD.
I've CCed Jeff Roberson about it a few times, and asked for assistance from
Xin as well as I haven't gotten any feedback from Jeff.
Thanks,
-Garrett


More information about the freebsd-infiniband mailing list