All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next] scsi: fcoe: use netif_is_bond_master() instead of open code
@ 2021-10-15 14:20 MichelleJin
  2021-10-15 18:07 ` Lee Duncan
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: MichelleJin @ 2021-10-15 14:20 UTC (permalink / raw)
  To: jejb, martin.petersen; +Cc: hare, linux-scsi

'netdev->priv_flags & IFF_BONDING && netdev->flags & IFF_MASTER'
is defined as netif_is_bond_master() in netdevice.h.
So, replace it with netif_is_bond_master() for cleaning code.

Signed-off-by: MichelleJin <shjy180909@gmail.com>
---
 drivers/scsi/fcoe/fcoe.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/scsi/fcoe/fcoe.c b/drivers/scsi/fcoe/fcoe.c
index 5ae6c207d3ac..6415f88738ad 100644
--- a/drivers/scsi/fcoe/fcoe.c
+++ b/drivers/scsi/fcoe/fcoe.c
@@ -307,7 +307,7 @@ static int fcoe_interface_setup(struct fcoe_interface *fcoe,
 	}
 
 	/* Do not support for bonding device */
-	if (netdev->priv_flags & IFF_BONDING && netdev->flags & IFF_MASTER) {
+	if (netif_is_bond_master(netdev)) {
 		FCOE_NETDEV_DBG(netdev, "Bonded interfaces not supported\n");
 		return -EOPNOTSUPP;
 	}
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH net-next] scsi: fcoe: use netif_is_bond_master() instead of open code
  2021-10-15 14:20 [PATCH net-next] scsi: fcoe: use netif_is_bond_master() instead of open code MichelleJin
@ 2021-10-15 18:07 ` Lee Duncan
  2021-10-17  2:28 ` Martin K. Petersen
  2021-10-21  3:42 ` Martin K. Petersen
  2 siblings, 0 replies; 4+ messages in thread
From: Lee Duncan @ 2021-10-15 18:07 UTC (permalink / raw)
  To: MichelleJin, jejb, martin.petersen; +Cc: hare, linux-scsi

On 10/15/21 7:20 AM, MichelleJin wrote:
> 'netdev->priv_flags & IFF_BONDING && netdev->flags & IFF_MASTER'
> is defined as netif_is_bond_master() in netdevice.h.
> So, replace it with netif_is_bond_master() for cleaning code.
> 
> Signed-off-by: MichelleJin <shjy180909@gmail.com>
> ---
>  drivers/scsi/fcoe/fcoe.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/scsi/fcoe/fcoe.c b/drivers/scsi/fcoe/fcoe.c
> index 5ae6c207d3ac..6415f88738ad 100644
> --- a/drivers/scsi/fcoe/fcoe.c
> +++ b/drivers/scsi/fcoe/fcoe.c
> @@ -307,7 +307,7 @@ static int fcoe_interface_setup(struct fcoe_interface *fcoe,
>  	}
>  
>  	/* Do not support for bonding device */
> -	if (netdev->priv_flags & IFF_BONDING && netdev->flags & IFF_MASTER) {
> +	if (netif_is_bond_master(netdev)) {
>  		FCOE_NETDEV_DBG(netdev, "Bonded interfaces not supported\n");
>  		return -EOPNOTSUPP;
>  	}
> 

Reviewed-by: Lee Duncan <lduncan@suse.com>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH net-next] scsi: fcoe: use netif_is_bond_master() instead of open code
  2021-10-15 14:20 [PATCH net-next] scsi: fcoe: use netif_is_bond_master() instead of open code MichelleJin
  2021-10-15 18:07 ` Lee Duncan
@ 2021-10-17  2:28 ` Martin K. Petersen
  2021-10-21  3:42 ` Martin K. Petersen
  2 siblings, 0 replies; 4+ messages in thread
From: Martin K. Petersen @ 2021-10-17  2:28 UTC (permalink / raw)
  To: MichelleJin; +Cc: jejb, martin.petersen, hare, linux-scsi


> 'netdev->priv_flags & IFF_BONDING && netdev->flags & IFF_MASTER' is
> defined as netif_is_bond_master() in netdevice.h.  So, replace it with
> netif_is_bond_master() for cleaning code.

Applied to 5.16/scsi-staging, thanks!

-- 
Martin K. Petersen	Oracle Linux Engineering

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH net-next] scsi: fcoe: use netif_is_bond_master() instead of open code
  2021-10-15 14:20 [PATCH net-next] scsi: fcoe: use netif_is_bond_master() instead of open code MichelleJin
  2021-10-15 18:07 ` Lee Duncan
  2021-10-17  2:28 ` Martin K. Petersen
@ 2021-10-21  3:42 ` Martin K. Petersen
  2 siblings, 0 replies; 4+ messages in thread
From: Martin K. Petersen @ 2021-10-21  3:42 UTC (permalink / raw)
  To: MichelleJin, jejb; +Cc: Martin K . Petersen, hare, linux-scsi

On Fri, 15 Oct 2021 14:20:06 +0000, MichelleJin wrote:

> 'netdev->priv_flags & IFF_BONDING && netdev->flags & IFF_MASTER'
> is defined as netif_is_bond_master() in netdevice.h.
> So, replace it with netif_is_bond_master() for cleaning code.
> 
> 

Applied to 5.16/scsi-queue, thanks!

[1/1] scsi: fcoe: use netif_is_bond_master() instead of open code
      https://git.kernel.org/mkp/scsi/c/b3ef4a0e40df

-- 
Martin K. Petersen	Oracle Linux Engineering

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-10-21  3:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-15 14:20 [PATCH net-next] scsi: fcoe: use netif_is_bond_master() instead of open code MichelleJin
2021-10-15 18:07 ` Lee Duncan
2021-10-17  2:28 ` Martin K. Petersen
2021-10-21  3:42 ` Martin K. Petersen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.