[dpdk-dev] [PATCH] net/mlx5: fix link state update

Matan Azrad matan at nvidia.com
Thu Nov 19 09:30:20 CET 2020


+ at Asaf Penso

From: Benoit Ganne 
> >> 2. To change documentation of ethdev API to say that only link status
> >> is mandatory report. (all others "nice to have" or "best effort"):
> >> 	This is for you - I suggest to send prior patch to ethdev
> >> 	for this and let the community to decide.
> > Matan, Benoit, I guess nobody tried to update ethdev API doc yet?
> > I can do it if you prefer.
> 
> My understanding was that this [1] was basically saying 'returning UNKNOWN
> is ok'. But if this is not what you had in mind, I'll be glad you can take care of it
> 😊
> 
> [1]
> https://eur03.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmails.dpdk
> .org%2Farchives%2Fdev%2F2020-
> April%2Fthread.html%23161538&data=02%7C01%7Cmatan%40mellanox.c
> om%7Cee2c8eebc00d4ea3106b08d7daf97473%7Ca652971c7d2e4d9ba6a4d149
> 256f461b%7C0%7C0%7C637218637252717747&sdata=JSFaHkmSzE1tWB7
> DqEaqVI5B1pIZuIdDrfw0SFyUE8s%3D&reserved=0
> 
> Best
> ben


Hi
Now, when the API is updated that the speed value is best effort using ETH_SPEED_NUM_UNKNOWN new value,

You can go for your approach:
In case the link is up and speed is invalid by kernel we can return link up and ETH_SPEED_NUM_UNKNOWN.

In case applications wants a valid speed they should call the API again.
Need to update it in mlx5 release notes section.

The original patch should be rebased and updated.

Matan







More information about the dev mailing list