report 1 tx queue to net core to workaround the tx hang
issue reported in Xen environment.
The change is only limited to dom0 and baremetal is left unchanged.
Orabug:
22171500
Signed-off-by: Ethan Zhao <ethan.zhao@oracle.com>
Signed-off-by: Guru Anbalagane <guru.anbalagane@oracle.com>
#include <linux/prefetch.h>
#include <scsi/fc/fc_fcoe.h>
#include <net/vxlan.h>
+#include <xen/xen.h>
#ifdef CONFIG_OF
#include <linux/of_net.h>
else
queues = adapter->num_tx_queues;
- err = netif_set_real_num_tx_queues(netdev, queues);
+ err = netif_set_real_num_tx_queues(netdev, xen_initial_domain() ? 1 : queues);
if (err)
goto err_set_queues;