]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/ipoib: Allow user space differentiate between valid dev_port
authorLeon Romanovsky <leonro@mellanox.com>
Mon, 6 May 2019 11:23:04 +0000 (14:23 +0300)
committerJason Gunthorpe <jgg@mellanox.com>
Tue, 7 May 2019 19:13:23 +0000 (16:13 -0300)
commitddf354a9fd5fe6cbd287774ec4d607c7cfa2902e
tree403a47c6404c47141bb42351fd62d2e8572a199f
parentc0173bf4c3f8162b400bc61f32b43db5a7d707e3
RDMA/ipoib: Allow user space differentiate between valid dev_port

Systemd triggers the following warning during IPoIB device load:

 mlx5_core 0000:00:0c.0 ib0: "systemd-udevd" wants to know my dev_id.
        Should it look at dev_port instead?
        See Documentation/ABI/testing/sysfs-class-net for more info.

This is caused due to user space attempt to differentiate old systems
without dev_port and new systems with dev_port. In case dev_port will be
zero, the systemd will try to read dev_id instead.

There is no need to print a warning in such case, because it is valid
situation and it is needed to ensure systemd compatibility with old
kernels.

Link: https://github.com/systemd/systemd/blob/master/src/udev/udev-builtin-net_id.c#L358
Cc: <stable@vger.kernel.org> # 4.19
Fixes: e6152b9f47df ("IB/ipoib: Log sysfs 'dev_id' accesses from userspace")
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/ulp/ipoib/ipoib_main.c