netdev
[Top] [All Lists]

[PATCH net-drivers-2.6 5/11] ixgb: Reset status in the Rx descriptor pri

To: <jgarzik@xxxxxxxxx>
Subject: [PATCH net-drivers-2.6 5/11] ixgb: Reset status in the Rx descriptor prior to handing it to the controller
From: "Chilakala, Mallikarjuna" <mallikarjuna.chilakala@xxxxxxxxx>
Date: Mon, 25 Apr 2005 10:42:33 -0700
Cc: <netdev@xxxxxxxxxxx>
Sender: netdev-bounce@xxxxxxxxxxx
Thread-index: AcVF13HgtzEthMGbTdWsv95LR9Y5eg==
Thread-topic: [PATCH net-drivers-2.6 5/11] ixgb: Reset status in the Rx descriptor prior to handing it to the controller
Reset status in the Rx descriptor prior to handing it to the controller.
Leave three Rx descriptors unused

Signed-off-by: Mallikarjuna R Chilakala
<mallikarjuna.chilakala@xxxxxxxxx>
Signed-off-by: Ganesh Venkatesan <ganesh.venkatesan@xxxxxxxxx>
Signed-off-by: John Ronciak <john.ronciak@xxxxxxxxx>
diff -up net-drivers-2.6/drivers/net/ixgb/ixgb_main.c
net-drivers-2.6/drivers/net/ixgb.new/ixgb_main.c
--- net-drivers-2.6/drivers/net/ixgb/ixgb_main.c        2005-04-05
23:06:36.332229456 -0700
+++ net-drivers-2.6/drivers/net/ixgb.new/ixgb_main.c    2005-04-05
23:06:38.283932752 -0700
@@ -1977,8 +1977,8 @@ ixgb_alloc_rx_buffers(struct ixgb_adapte

        num_group_tail_writes = IXGB_RX_BUFFER_WRITE;

-       /* leave one descriptor unused */
-       while(--cleancount > 0) {
+       /* leave three descriptors unused */
+       while(--cleancount > 2) {
                rx_desc = IXGB_RX_DESC(*rx_ring, i);

                skb = dev_alloc_skb(adapter->rx_buffer_len +
NET_IP_ALIGN);
@@ -2005,6 +1933,10 @@ ixgb_alloc_rx_buffers(struct ixgb_adapte
                                   PCI_DMA_FROMDEVICE);

                rx_desc->buff_addr = cpu_to_le64(buffer_info->dma);
+               /* guarantee DD bit not set now before h/w gets
descriptor
+                * this is the rest of the workaround for h/w double
+                * writeback. */
+               rx_desc->status = 0;

                if((i & ~(num_group_tail_writes- 1)) == i) {
                        /* Force memory writes to complete before
letting h/w




<Prev in Thread] Current Thread [Next in Thread>
  • [PATCH net-drivers-2.6 5/11] ixgb: Reset status in the Rx descriptor prior to handing it to the controller, Chilakala, Mallikarjuna <=