Unverified Commit 730e6b32 authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!5726 [OLK-6.6] Fix warnings for RNPVF driver

Merge Pull Request from: @dong-yibo 
 
1 Fix Mucse Network adapter (RNPVF) driver warnings
update files:
drivers/net/ethernet/mucse/rnpvf/ethtool.c
drivers/net/ethernet/mucse/rnpvf/mbx.c
drivers/net/ethernet/mucse/rnpvf/rnpvf_main.c
drivers/net/ethernet/mucse/rnpvf/vf.c

https://gitee.com/openeuler/kernel/issues/I9DTS3 
 
Link:https://gitee.com/openeuler/kernel/pulls/5726

 

Reviewed-by: default avatarYue Haibing <yuehaibing@huawei.com>
Signed-off-by: default avatarZheng Zengkai <zhengzengkai@huawei.com>
parents e053d517 4526712d
Loading
Loading
Loading
Loading
+7 −19
Original line number Diff line number Diff line
@@ -100,12 +100,6 @@ struct rnpvf_rx_queue_ring_stat {
	(RNPVF_GLOBAL_STATS_LEN + RNP_QUEUE_STATS_LEN + \
	 RNPVF_HWSTRINGS_STATS_LEN)

static const char rnp_gstrings_test[][ETH_GSTRING_LEN] = {
	"Register test  (offline)", "Link test   (on/offline)"
};

#define RNPVF_TEST_LEN (sizeof(rnp_gstrings_test) / ETH_GSTRING_LEN)

enum priv_bits {
	padding_enable = 0,
};
@@ -128,7 +122,8 @@ static int rnpvf_get_link_ksettings(struct net_device *netdev,
	struct rnpvf_hw *hw = &adapter->hw;
	bool autoneg = false;
	bool link_up;
	u32 supported, advertising;
	u32 supported = 0;
	u32 advertising = 0;
	u32 link_speed = 0;

	ethtool_convert_link_mode_to_legacy_u32(&supported,
@@ -220,7 +215,7 @@ static int rnpvf_get_link_ksettings(struct net_device *netdev,
	ethtool_convert_legacy_u32_to_link_mode(cmd->link_modes.supported,
						supported);
	ethtool_convert_legacy_u32_to_link_mode(cmd->link_modes.advertising,
						supported);
						advertising);
	return 0;
}

@@ -246,7 +241,7 @@ static void rnpvf_get_drvinfo(struct net_device *netdev,
	drvinfo->n_priv_flags = RNPVF_PRIV_FLAGS_STR_LEN;
}

void rnpvf_get_ringparam(struct net_device *netdev,
static void rnpvf_get_ringparam(struct net_device *netdev,
				struct ethtool_ringparam *ring,
				struct kernel_ethtool_ringparam __always_unused *ker,
				struct netlink_ext_ack __always_unused *extack)
@@ -262,11 +257,8 @@ void rnpvf_get_ringparam(struct net_device *netdev,
static void rnpvf_get_strings(struct net_device *netdev, u32 stringset,
			      u8 *data)
{
	struct rnpvf_adapter *adapter = netdev_priv(netdev);
	char *p = (char *)data;
	int i;
	struct rnpvf_ring *ring;
	u16 queue_idx;

	switch (stringset) {
	case ETH_SS_STATS:
@@ -286,8 +278,6 @@ static void rnpvf_get_strings(struct net_device *netdev, u32 stringset,

		for (i = 0; i < RNPVF_NUM_TX_QUEUES; i++) {
			/* ====  tx ======== */
			ring = adapter->tx_ring[i];
			queue_idx = ring->rnpvf_queue_idx;
			sprintf(p, "\n     queue%u_tx_packets", i);
			p += ETH_GSTRING_LEN;
			sprintf(p, "queue%u_tx_bytes", i);
@@ -322,8 +312,6 @@ static void rnpvf_get_strings(struct net_device *netdev, u32 stringset,
			p += ETH_GSTRING_LEN;

			/* ====  rx ======== */
			ring = adapter->rx_ring[i];
			queue_idx = ring->rnpvf_queue_idx;
			sprintf(p, "\n     queue%u_rx_packets", i);
			p += ETH_GSTRING_LEN;
			sprintf(p, "queue%u_rx_bytes", i);
+10 −0
Original line number Diff line number Diff line
@@ -11,6 +11,7 @@ static s32 rnpvf_poll_for_ack(struct rnpvf_hw *hw, bool to_cm3);
 *  @hw: pointer to the HW structure
 *  @msg: The message buffer
 *  @size: Length of buffer
 *  @to_cm3: mbx to cm3 or not
 *
 *  returns 0 if it successfully received a message notification and
 *  copied it into the receive buffer.
@@ -38,6 +39,7 @@ static s32 rnpvf_read_posted_mbx(struct rnpvf_hw *hw, u32 *msg, u16 size,
 *  @hw: pointer to the HW structure
 *  @msg: The message buffer
 *  @size: Length of buffer
 *  @to_cm3: mbx to cm3 or not
 *
 *  returns 0 if it successfully copied message into the buffer and
 *  received an ack to that message within delay * timeout period
@@ -123,6 +125,7 @@ static inline void rnpvf_mbx_inc_vfack(struct rnpvf_hw *hw, bool to_cm3)
/**
 *  rnpvf_check_for_msg_vf - checks to see if the PF has sent mail
 *  @hw: pointer to the HW structure
 *  @to_cm3: mbx to cm3 or not
 *
 *  returns 0 if the PF has set the Status bit or else ERR_MBX
 **/
@@ -152,6 +155,7 @@ static s32 rnpvf_check_for_msg_vf(struct rnpvf_hw *hw, bool to_cm3)
/**
 *  rnpvf_poll_for_msg - Wait for message notification
 *  @hw: pointer to the HW structure
 *  @to_cm3: mbx to cm3 or not
 *
 *  returns 0 if it successfully received a message notification
 **/
@@ -171,6 +175,7 @@ static s32 rnpvf_poll_for_msg(struct rnpvf_hw *hw, bool to_cm3)
/**
 *  rnpvf_poll_for_ack - Wait for message acknowledgment
 *  @hw: pointer to the HW structure
 *  @to_cm3: mbx to cm3 or not
 *
 *  returns 0 if it successfully received a message acknowledgment
 **/
@@ -194,6 +199,7 @@ static s32 rnpvf_poll_for_ack(struct rnpvf_hw *hw, bool to_cm3)
/**
 *  rnpvf_check_for_rst_msg_vf - checks to see if the PF has ACK'd
 *  @hw: pointer to the HW structure
 *  @to_cm3: mbx to cm3 or not
 *
 *  returns 0 if the PF has set the ACK bit or else ERR_MBX
 **/
@@ -344,6 +350,7 @@ static s32 rnpvf_check_for_rst_msg_vf(struct rnpvf_hw *hw, bool to_cm3)
/**
 *  rnpvf_check_for_ack_vf - checks to see if the PF has ACK'd
 *  @hw: pointer to the HW structure
 *  @to_cm3: mbx to cm3 or not
 *
 *  returns 0 if the PF has set the ACK bit or else ERR_MBX
 **/
@@ -373,6 +380,7 @@ static s32 rnpvf_check_for_ack_vf(struct rnpvf_hw *hw, bool to_cm3)
/**
 *  rnpvf_obtain_mbx_lock_vf - obtain mailbox lock
 *  @hw: pointer to the HW structure
 *  @to_cm3: mbx to cm3 or not
 *
 *  return 0 if we obtained the mailbox lock
 **/
@@ -403,6 +411,7 @@ static s32 rnpvf_obtain_mbx_lock_vf(struct rnpvf_hw *hw, bool to_cm3)
 *  @hw: pointer to the HW structure
 *  @msg: The message buffer
 *  @size: Length of buffer
 *  @to_cm3: mbx to cm3 or not
 *
 *  returns 0 if it successfully copied message into the buffer
 **/
@@ -456,6 +465,7 @@ static s32 rnpvf_write_mbx_vf(struct rnpvf_hw *hw, u32 *msg, u16 size,
 *  @hw: pointer to the HW structure
 *  @msg: The message buffer
 *  @size: Length of buffer
 *  @to_cm3: mbx to cm3 or not
 *
 *  returns 0 if it successfully read message from buffer
 **/
+38 −70
Original line number Diff line number Diff line
@@ -101,11 +101,10 @@ static void rnpvf_put_rx_buffer(struct rnpvf_ring *rx_ring,
#endif /* OPTM_WITH_LARGE */

/**
 * rnpvf_set_ivar - set IVAR registers - maps interrupt causes to vectors
 * rnpvf_set_ring_vector - set maps interrupt causes to vectors
 * @adapter: pointer to adapter struct
 * @direction: 0 for Rx, 1 for Tx, -1 for other causes
 * @queue: queue to map the corresponding interrupt to
 * @msix_vector: the vector to map to the corresponding queue
 * @rnpvf_queue: queue to map the corresponding interrupt to
 * @rnpvf_msix_vector: the vector to map to the corresponding queue
 */
static void rnpvf_set_ring_vector(struct rnpvf_adapter *adapter,
				  u8 rnpvf_queue, u8 rnpvf_msix_vector)
@@ -124,7 +123,7 @@ static void rnpvf_set_ring_vector(struct rnpvf_adapter *adapter,
	rnpvf_wr_reg(hw->ring_msix_base + RING_VECTOR(rnpvf_queue), data);
}

void rnpvf_unmap_and_free_tx_resource(struct rnpvf_ring *ring,
static void rnpvf_unmap_and_free_tx_resource(struct rnpvf_ring *ring,
					     struct rnpvf_tx_buffer *tx_buffer)
{
	if (tx_buffer->skb) {
@@ -462,7 +461,7 @@ static inline int rnpvf_skb_pad(void)
#endif

/**
 * rnp_clean_rx_ring - Free Rx Buffers per Queue
 * rnpvf_clean_rx_ring - Free Rx Buffers per Queue
 * @rx_ring: ring to free buffers from
 **/
static void rnpvf_clean_rx_ring(struct rnpvf_ring *rx_ring)
@@ -793,7 +792,6 @@ static unsigned int rnpvf_get_headlen(unsigned char *data,

/**
 * rnpvf_pull_tail - rnp specific version of skb_pull_tail
 * @rx_ring: rx descriptor ring packet is being transacted on
 * @skb: pointer to current skb being adjusted
 *
 * This function is an rnp specific version of __pskb_pull_tail.  The
@@ -1018,7 +1016,6 @@ void rnpvf_alloc_rx_buffers(struct rnpvf_ring *rx_ring, u16 cleaned_count)
 * rnpvf_is_non_eop - process handling of non-EOP buffers
 * @rx_ring: Rx ring being processed
 * @rx_desc: Rx descriptor for current buffer
 * @skb: Current socket buffer containing buffer in progress
 *
 * This function updates next to clean.  If the buffer is an EOP buffer
 * this function exits returning false, otherwise it will place the
@@ -1208,7 +1205,7 @@ static struct sk_buff *rnpvf_build_skb(struct rnpvf_ring *rx_ring,
}

/**
 * rnp_clean_rx_irq - Clean completed descriptors from Rx ring - bounce buf
 * rnpvf_clean_rx_irq - Clean completed descriptors from Rx ring - bounce buf
 * @q_vector: structure containing interrupt and ring information
 * @rx_ring: rx descriptor ring to transact packets on
 * @budget: Total limit on number of packets to process
@@ -1362,7 +1359,8 @@ static int rnpvf_clean_rx_irq(struct rnpvf_q_vector *q_vector,
 * @rx_ring: ring to place buffers on
 * @cleaned_count: number of buffers to replace
 **/
void rnpvf_alloc_rx_buffers(struct rnpvf_ring *rx_ring, u16 cleaned_count)
static void rnpvf_alloc_rx_buffers(struct rnpvf_ring *rx_ring,
				   u16 cleaned_count)
{
	union rnp_rx_desc *rx_desc;
	struct rnpvf_rx_buffer *bi;
@@ -1636,7 +1634,7 @@ static void rnpvf_rx_buffer_flip(struct rnpvf_ring *rx_ring,
}

/**
 * rnp_clean_rx_irq - Clean completed descriptors from Rx ring - bounce buf
 * rnpvf_clean_rx_irq - Clean completed descriptors from Rx ring - bounce buf
 * @q_vector: structure containing interrupt and ring information
 * @rx_ring: rx descriptor ring to transact packets on
 * @budget: Total limit on number of packets to process
@@ -1656,7 +1654,6 @@ static int rnpvf_clean_rx_irq(struct rnpvf_q_vector *q_vector,
	unsigned int driver_drop_packets = 0;
	struct rnpvf_adapter *adapter = q_vector->adapter;
	u16 cleaned_count = rnpvf_desc_unused(rx_ring);
	bool xdp_xmit = false;
	struct xdp_buff xdp;

	xdp.data = NULL;
@@ -1740,7 +1737,6 @@ static int rnpvf_clean_rx_irq(struct rnpvf_q_vector *q_vector,

		if (IS_ERR(skb)) {
			if (PTR_ERR(skb) == -RNPVF_XDP_TX) {
				xdp_xmit = true;
				rnpvf_rx_buffer_flip(rx_ring, rx_buffer,
						     size);
			} else {
@@ -1942,7 +1938,7 @@ static irqreturn_t rnpvf_msix_clean_rings(int irq, void *data)
	return IRQ_HANDLED;
}

void update_rx_count(int cleaned, struct rnpvf_q_vector *q_vector)
static void update_rx_count(int cleaned, struct rnpvf_q_vector *q_vector)
{
	struct rnpvf_adapter *adapter = q_vector->adapter;

@@ -2188,6 +2184,7 @@ static int rnpvf_free_msix_irqs(struct rnpvf_adapter *adapter)
 * rnpvf_update_itr - update the dynamic ITR value based on statistics
 * @q_vector: structure containing interrupt and ring information
 * @ring_container: structure containing ring performance data
 * @type: tx or rx
 *
 *      Stores a new ITR value based on packets and byte
 *      counts during the last interrupt.  The advantage of per interrupt
@@ -2410,23 +2407,20 @@ static void rnpvf_update_itr(struct rnpvf_q_vector *q_vector,
}

/**
 * rnpvf_write_eitr - write EITR register in hardware specific way
 * rnpvf_write_eitr_rx - write EITR register in hardware specific way
 * @q_vector: structure containing interrupt and ring information
 *
 * This function is made to be called by ethtool and by the driver
 * when it needs to update EITR registers at runtime.  Hardware
 * specific quirks/differences are taken care of here.
 */
void rnpvf_write_eitr_rx(struct rnpvf_q_vector *q_vector)
static void rnpvf_write_eitr_rx(struct rnpvf_q_vector *q_vector)
{
	struct rnpvf_adapter *adapter = q_vector->adapter;
	struct rnpvf_hw *hw = &adapter->hw;
	// int v_idx = q_vector->v_idx;
	//  u32 itr_reg = q_vector->itr & RNP_MAX_EITR;
	u32 itr_reg = q_vector->itr_rx >> 2;
	struct rnpvf_ring *ring;

	// printk("update %d itr %d\n", q_vector->v_idx, itr_reg);
	itr_reg = itr_reg * hw->usecstocount; // 150M

	rnpvf_for_each_ring(ring, q_vector->rx) {
@@ -2520,7 +2514,7 @@ static inline void rnpvf_irq_disable(struct rnpvf_adapter *adapter)
 *
 * Configure the Tx descriptor ring after a reset.
 **/
void rnpvf_configure_tx_ring(struct rnpvf_adapter *adapter,
static void rnpvf_configure_tx_ring(struct rnpvf_adapter *adapter,
				    struct rnpvf_ring *ring)
{
	struct rnpvf_hw *hw = &adapter->hw;
@@ -2586,19 +2580,19 @@ static void rnpvf_configure_tx(struct rnpvf_adapter *adapter)

#define RNP_SRRCTL_BSIZEHDRSIZE_SHIFT 2

void rnpvf_disable_rx_queue(struct rnpvf_adapter *adapter,
static void rnpvf_disable_rx_queue(struct rnpvf_adapter *adapter,
				   struct rnpvf_ring *ring)
{
	ring_wr32(ring, RNP_DMA_RX_START, 0);
}

void rnpvf_enable_rx_queue(struct rnpvf_adapter *adapter,
static void rnpvf_enable_rx_queue(struct rnpvf_adapter *adapter,
				  struct rnpvf_ring *ring)
{
	ring_wr32(ring, RNP_DMA_RX_START, 1);
}

void rnpvf_configure_rx_ring(struct rnpvf_adapter *adapter,
static void rnpvf_configure_rx_ring(struct rnpvf_adapter *adapter,
				    struct rnpvf_ring *ring)
{
	struct rnpvf_hw *hw = &adapter->hw;
@@ -2733,13 +2727,12 @@ static int rnpvf_vlan_rx_kill_vid(struct net_device *netdev,
	struct rnpvf_adapter *adapter = netdev_priv(netdev);
	struct rnpvf_hw *hw = &adapter->hw;
	struct rnp_mbx_info *mbx = &hw->mbx;
	int err = -EOPNOTSUPP;

	if (vid) {
		spin_lock_bh(&adapter->mbx_lock);
		set_bit(__RNPVF_MBX_POLLING, &adapter->state);
		/* remove VID from filter table */
		err = hw->mac.ops.set_vfta(hw, vid, 0, false);
		hw->mac.ops.set_vfta(hw, vid, 0, false);
		clear_bit(__RNPVF_MBX_POLLING, &adapter->state);
		spin_unlock_bh(&adapter->mbx_lock);
		hw->ops.set_veb_vlan(hw, 0, VFNUM(mbx, hw->vfnum));
@@ -3304,13 +3297,6 @@ static int rnpvf_acquire_msix_vectors(struct rnpvf_adapter *adapter,
				      int vectors)
{
	int err = 0;
	int vector_threshold;

	/* We'll want at least 2 (vector_threshold):
	 * 1) TxQ[0] + RxQ[0] handler
	 * 2) Other (Link Status Change, etc.)
	 */
	vector_threshold = MIN_MSIX_COUNT;

	/* The more we get, the more we will assign to Tx/Rx Cleanup
	 * for the separate queues...where Rx Cleanup >= Tx Cleanup.
@@ -3453,7 +3439,6 @@ static enum hrtimer_restart irq_miss_check(struct hrtimer *hrtimer)
	struct rnpvf_ring *ring;
	struct rnp_tx_desc *eop_desc;
	struct rnpvf_adapter *adapter;
	struct rnpvf_hw *hw;

	int tx_next_to_clean;
	int tx_next_to_use;
@@ -3464,7 +3449,6 @@ static enum hrtimer_restart irq_miss_check(struct hrtimer *hrtimer)
	q_vector = container_of(hrtimer, struct rnpvf_q_vector,
				irq_miss_check_timer);
	adapter = q_vector->adapter;
	hw = &adapter->hw;

	/* If we're already down or resetting, just bail */
	if (test_bit(__RNPVF_DOWN, &adapter->state) ||
@@ -3916,7 +3900,7 @@ static int rnpvf_reset_subtask(struct rnpvf_adapter *adapter)

/**
 * rnpvf_watchdog - Timer Call-back
 * @data: pointer to adapter cast into an unsigned long
 * @t: timer_list pointer
 **/
static void rnpvf_watchdog(struct timer_list *t)
{
@@ -4587,8 +4571,11 @@ int rnpvf_close(struct net_device *netdev)
	return 0;
}

void rnpvf_tx_ctxtdesc(struct rnpvf_ring *tx_ring, u16 mss_seg_len,
		       u8 l4_hdr_len, u8 tunnel_hdr_len, int ignore_vlan,
static void rnpvf_tx_ctxtdesc(struct rnpvf_ring *tx_ring,
			      u16 mss_seg_len,
			      u8 l4_hdr_len,
			      u8 tunnel_hdr_len,
			      int ignore_vlan,
			      u16 type_tucmd, bool crc_pad)
{
	struct rnp_tx_ctx_desc *context_desc;
@@ -5036,7 +5023,7 @@ static int __rnpvf_maybe_stop_tx(struct rnpvf_ring *tx_ring, int size)
	return 0;
}

void rnpvf_maybe_tx_ctxtdesc(struct rnpvf_ring *tx_ring,
static void rnpvf_maybe_tx_ctxtdesc(struct rnpvf_ring *tx_ring,
				    struct rnpvf_tx_buffer *first,
				    int ignore_vlan, u16 type_tucmd)
{
@@ -5086,7 +5073,7 @@ static void rnpvf_force_src_mac(struct sk_buff *skb,
	return;
}

netdev_tx_t rnpvf_xmit_frame_ring(struct sk_buff *skb,
static netdev_tx_t rnpvf_xmit_frame_ring(struct sk_buff *skb,
					 struct rnpvf_adapter *adapter,
					 struct rnpvf_ring *tx_ring,
					 bool tx_padding)
@@ -5481,8 +5468,6 @@ static void rnpvf_get_stats64(struct net_device *netdev,
{
	struct rnpvf_adapter *adapter = netdev_priv(netdev);
	int i;
	u64 ring_csum_err = 0;
	u64 ring_csum_good = 0;

	rcu_read_lock();
	for (i = 0; i < adapter->num_rx_queues; i++) {
@@ -5495,8 +5480,6 @@ static void rnpvf_get_stats64(struct net_device *netdev,
				start = u64_stats_fetch_begin(&ring->syncp);
				packets = ring->stats.packets;
				bytes = ring->stats.bytes;
				ring_csum_err += ring->rx_stats.csum_err;
				ring_csum_good += ring->rx_stats.csum_good;
			} while (u64_stats_fetch_retry(&ring->syncp,
						       start));
			stats->rx_packets += packets;
@@ -5577,7 +5560,7 @@ static const struct net_device_ops rnpvf_netdev_ops = {
	.ndo_fix_features = rnpvf_fix_features,
};

void rnpvf_assign_netdev_ops(struct net_device *dev)
static void rnpvf_assign_netdev_ops(struct net_device *dev)
{
	/* different hw can assign difference fun */
	dev->netdev_ops = &rnpvf_netdev_ops;
@@ -5616,21 +5599,6 @@ static u8 rnpvf_vfnum(struct rnpvf_hw *hw)
#endif
}

static inline unsigned long rnpvf_tso_features(struct rnpvf_hw *hw)
{
	unsigned long features = 0;

	if (hw->feature_flags & RNPVF_NET_FEATURE_TSO)
		features |= NETIF_F_TSO;
	if (hw->feature_flags & RNPVF_NET_FEATURE_TSO)
		features |= NETIF_F_TSO6;
	features |= NETIF_F_GSO_PARTIAL;
	if (hw->feature_flags & RNPVF_NET_FEATURE_TX_UDP_TUNNEL)
		features |= RNPVF_GSO_PARTIAL_FEATURES;

	return features;
}

static int rnpvf_add_adpater(struct pci_dev *pdev,
			     const struct rnpvf_info *ii,
			     struct rnpvf_adapter **padapter)
+8 −26
Original line number Diff line number Diff line
@@ -253,7 +253,6 @@ static s32 rnpvf_reset_hw_vf(struct rnpvf_hw *hw)
 **/
static s32 rnpvf_stop_hw_vf(struct rnpvf_hw *hw)
{
	u32 number_of_queues;
	u16 i;
	struct rnpvf_adapter *adapter = hw->back;
	struct rnpvf_ring *ring;
@@ -269,9 +268,6 @@ static s32 rnpvf_stop_hw_vf(struct rnpvf_hw *hw)
		ring_wr32(ring, RNP_DMA_RX_START, 0);
	}

	/* Disable the transmit unit.  Each queue must be disabled. */
	number_of_queues = hw->mac.max_tx_queues;

	return 0;
}

@@ -368,7 +364,7 @@ static s32 rnpvf_get_mac_addr_vf(struct rnpvf_hw *hw, u8 *mac_addr)
/**
 *  rnpvf_get_queues_vf - Read device MAC address
 *  @hw: pointer to the HW structure
 *  @mac_addr: pointer to storage for retrieved MAC address
 *
 **/
static s32 rnpvf_get_queues_vf(struct rnpvf_hw *hw)
{
@@ -483,7 +479,7 @@ static void rnpvf_write_msg_read_ack(struct rnpvf_hw *hw, u32 *msg,
		mbx->ops.read_posted(hw, retmsg, size, false);
}

u8 *rnpvf_addr_list_itr(struct rnpvf_hw __maybe_unused *hw,
static u8 *rnpvf_addr_list_itr(struct rnpvf_hw __maybe_unused *hw,
			       u8 **mc_addr_ptr)
{
	struct netdev_hw_addr *mc_ptr;
@@ -677,23 +673,9 @@ void rnpvf_rlpml_set_vf(struct rnpvf_hw *hw, u16 max_size)
	rnpvf_write_msg_read_ack(hw, msgbuf, 2);
}

/**
 *  rnpvf_negotiate_api_version - Negotiate supported API version
 *  @hw: pointer to the HW structure
 *  @api: integer containing requested API version
 **/
int rnpvf_negotiate_api_version(struct rnpvf_hw *hw, int api)
{
	return 0;
}

int rnpvf_get_queues(struct rnpvf_hw *hw, unsigned int *num_tcs,
		     unsigned int *default_tc)
{
	return -1;
}

void rnpvf_set_veb_mac_n10(struct rnpvf_hw *hw, u8 *mac, u32 vfnum,
static void rnpvf_set_veb_mac_n10(struct rnpvf_hw *hw,
				  u8 *mac,
				  u32 vfnum,
				  u32 ring)
{
	int port;
@@ -715,7 +697,7 @@ void rnpvf_set_veb_mac_n10(struct rnpvf_hw *hw, u8 *mac, u32 vfnum,
	}
}

void rnpvf_set_vlan_n10(struct rnpvf_hw *hw, u16 vid, u32 vf_num)
static void rnpvf_set_vlan_n10(struct rnpvf_hw *hw, u16 vid, u32 vf_num)
{
	int port;