Re: [PATCH rdma-next 4/5] RDMA/cma: Use existing netif_is_bond_master function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Jan 28, 2018 at 11:25:32AM +0200, Leon Romanovsky wrote:
> From: Parav Pandit <parav@xxxxxxxxxxxx>
> 
> When checking whatever the current netdev is the bond master interface,
> use kernel API netif_is_bond_master() instead of hardcoding the check.
> No functionality is changed.
> 
> Reviewed-by: Mark Bloch <markb@xxxxxxxxxxxx>
> Signed-off-by: Parav Pandit <parav@xxxxxxxxxxxx>
> Signed-off-by: Leon Romanovsky <leon@xxxxxxxxxx>
> ---
>  drivers/infiniband/core/cma.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/infiniband/core/cma.c b/drivers/infiniband/core/cma.c
> index 84812b9dea9b..e66963ca58bd 100644
> --- a/drivers/infiniband/core/cma.c
> +++ b/drivers/infiniband/core/cma.c
> @@ -4294,7 +4294,7 @@ static int cma_netdev_callback(struct notifier_block *self, unsigned long event,
>  	if (event != NETDEV_BONDING_FAILOVER)
>  		return NOTIFY_DONE;
>  
> -	if (!(ndev->flags & IFF_MASTER) || !(ndev->priv_flags & IFF_BONDING))
> +	if (!netif_is_bond_master(ndev))
>  		return NOTIFY_DONE;

Reviewed-by: Yuval Shaia <yuval.shaia@xxxxxxxxxx>

>  
>  	mutex_lock(&lock);
> -- 
> 2.16.1
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux