[PATCH v4 05/10] net/ps3_gelic: Add vlan_id structure

Geoff Levand geoff at infradead.org
Sat Jul 24 06:31:47 AEST 2021


In an effort to make the PS3 gelic driver easier to maintain, add
a definition for the vlan_id structure.

Signed-off-by: Geoff Levand <geoff at infradead.org>
---
 drivers/net/ethernet/toshiba/ps3_gelic_net.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ethernet/toshiba/ps3_gelic_net.c b/drivers/net/ethernet/toshiba/ps3_gelic_net.c
index 946e9bfa071b..54e50ad9e629 100644
--- a/drivers/net/ethernet/toshiba/ps3_gelic_net.c
+++ b/drivers/net/ethernet/toshiba/ps3_gelic_net.c
@@ -1614,13 +1614,14 @@ static struct gelic_card *gelic_alloc_card_net(struct net_device **netdev)
 static void gelic_card_get_vlan_info(struct gelic_card *card)
 {
 	struct device *dev = ctodev(card);
+	unsigned int i;
 	u64 v1, v2;
 	int status;
-	unsigned int i;
-	struct {
+	struct vlan_id {
 		int tx;
 		int rx;
-	} vlan_id_ix[2] = {
+	};
+	struct vlan_id vlan_id_ix[2] = {
 		[GELIC_PORT_ETHERNET_0] = {
 			.tx = GELIC_LV1_VLAN_TX_ETHERNET_0,
 			.rx = GELIC_LV1_VLAN_RX_ETHERNET_0
-- 
2.25.1




More information about the Linuxppc-dev mailing list