[dpdk-dev] [PATCH v3] net/e1000: fix link status update
Lu, Wenzhuo
wenzhuo.lu at intel.com
Tue Nov 19 07:43:01 CET 2019
Hi Lunyuan,
> -----Original Message-----
> From: Cui, LunyuanX
> Sent: Monday, November 18, 2019 10:58 PM
> To: dev at dpdk.org
> Cc: Lu, Wenzhuo <wenzhuo.lu at intel.com>; Cui, LunyuanX
> <lunyuanx.cui at intel.com>; stable at dpdk.org
> Subject: [PATCH v3] net/e1000: fix link status update
>
> Unassigned variable should not be used as judgment, and there is no need
Don't understand "Unassigned variable should not be used as judgment ". Which one is this " Unassigned variable"?
> to update link status according to old link status.
Don't understand why " no need to update link status according to old link status ".
Please add more info about what problem this patch wants to fix. Thanks.
> This patch fix the issue.
>
> Change the variable from link_check to link_up.
>
> Fixes: 80ba61115e77 ("net/e1000: use link status helper functions")
> Cc: stable at dpdk.org
>
> Signed-off-by: Lunyuan Cui <lunyuanx.cui at intel.com>
> ---
> v3:
> * Change the variable from link_check to link_up.
>
> v2
> * Delete incorrect judgment
> ---
> drivers/net/e1000/em_ethdev.c | 16 ++++++++--------
> 1 file changed, 8 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/net/e1000/em_ethdev.c
> b/drivers/net/e1000/em_ethdev.c index 9a88b50b2..080cbe2df 100644
> --- a/drivers/net/e1000/em_ethdev.c
> +++ b/drivers/net/e1000/em_ethdev.c
>
> /* Now we check if a transition has happened */
Looks like this comment need to be removed if the below check changes. But still, don't know why we should change the check.
> - if (link_check && (link.link_status == ETH_LINK_DOWN)) {
> + if (link_up) {
More information about the dev
mailing list