From 78e4a0fada7fdeddcd748f77177cc9777f374a6c Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Wed, 29 May 2019 12:14:50 -0700 Subject: [PATCH] net/atlantic: remove unnecessary cast The device private pointer (dev_private) is of type void * therefore no cast is necessary in C. Cc: stable@dpdk.org Signed-off-by: Stephen Hemminger Reviewed-by: Ferruh Yigit --- drivers/net/atlantic/atl_ethdev.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/net/atlantic/atl_ethdev.c b/drivers/net/atlantic/atl_ethdev.c index d110e351ec..fdc0a7f2db 100644 --- a/drivers/net/atlantic/atl_ethdev.c +++ b/drivers/net/atlantic/atl_ethdev.c @@ -371,8 +371,7 @@ atl_disable_intr(struct aq_hw_s *hw) static int eth_atl_dev_init(struct rte_eth_dev *eth_dev) { - struct atl_adapter *adapter = - (struct atl_adapter *)eth_dev->data->dev_private; + struct atl_adapter *adapter = eth_dev->data->dev_private; struct rte_pci_device *pci_dev = RTE_ETH_DEV_TO_PCI(eth_dev); struct rte_intr_handle *intr_handle = &pci_dev->intr_handle; struct aq_hw_s *hw = ATL_DEV_PRIVATE_TO_HW(eth_dev->data->dev_private); @@ -1015,8 +1014,7 @@ static int atl_dev_xstats_get(struct rte_eth_dev *dev, struct rte_eth_xstat *stats, unsigned int n) { - struct atl_adapter *adapter = - (struct atl_adapter *)dev->data->dev_private; + struct atl_adapter *adapter = dev->data->dev_private; struct aq_hw_s *hw = &adapter->hw; struct get_stats req = { 0 }; struct macsec_msg_fw_request msg = { 0 }; @@ -1352,8 +1350,7 @@ atl_dev_interrupt_action(struct rte_eth_dev *dev, { struct atl_interrupt *intr = ATL_DEV_PRIVATE_TO_INTR(dev->data->dev_private); - struct atl_adapter *adapter = - (struct atl_adapter *)dev->data->dev_private; + struct atl_adapter *adapter = dev->data->dev_private; struct aq_hw_s *hw = &adapter->hw; if (!(intr->flags & ATL_FLAG_NEED_LINK_UPDATE)) -- 2.20.1