|
@@ -394,7 +394,13 @@ static void gfar_init_mac(struct net_device *ndev)
|
|
|
if (ndev->features & NETIF_F_IP_CSUM)
|
|
|
tctrl |= TCTRL_INIT_CSUM;
|
|
|
|
|
|
- tctrl |= TCTRL_TXSCHED_PRIO;
|
|
|
+ if (priv->prio_sched_en)
|
|
|
+ tctrl |= TCTRL_TXSCHED_PRIO;
|
|
|
+ else {
|
|
|
+ tctrl |= TCTRL_TXSCHED_WRRS;
|
|
|
+ gfar_write(®s->tr03wt, DEFAULT_WRRS_WEIGHT);
|
|
|
+ gfar_write(®s->tr47wt, DEFAULT_WRRS_WEIGHT);
|
|
|
+ }
|
|
|
|
|
|
gfar_write(®s->tctrl, tctrl);
|
|
|
|
|
@@ -1160,6 +1166,9 @@ static int gfar_probe(struct platform_device *ofdev)
|
|
|
priv->rx_filer_enable = 1;
|
|
|
/* Enable most messages by default */
|
|
|
priv->msg_enable = (NETIF_MSG_IFUP << 1 ) - 1;
|
|
|
+ /* use pritority h/w tx queue scheduling for single queue devices */
|
|
|
+ if (priv->num_tx_queues == 1)
|
|
|
+ priv->prio_sched_en = 1;
|
|
|
|
|
|
/* Carrier starts down, phylib will bring it up */
|
|
|
netif_carrier_off(dev);
|