Skip to contentSkip to conversation

dp8393x: Mask EOL bit from descriptor addresses, take 2

PATCH Applied Finn Thain 4 participants 6 messages Mar 4, 2020 – Mar 9, 2020

lore
Share & tools
lore

Finn Thain

author
#0 lore raw

PATCH 1/1 dp8393x: Mask EOL bit from descriptor addresses, take 2

A portion of a recent patch got lost due to a merge snafu. That patch is now commit 88f632fbb1 ("dp8393x: Mask EOL bit from descriptor addresses"). This patch restores the portion that got lost.

---
 hw/net/dp8393x.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
hw/net/dp8393x.c +2 -2
index 8a3504d962..81fc13ee9f 100644
@@ -525,8 +525,8 @@ static void dp8393x_do_transmit_packets(dp8393xState *s)
                                  * (4 + 3 * s->regs[SONIC_TFC]),
                                MEMTXATTRS_UNSPECIFIED, s->data,
                                size);
-            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0) & ~0x1;
-            if (dp8393x_get(s, width, 0) & SONIC_DESC_EOL) {
+            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0);
+            if (s->regs[SONIC_CTDA] & SONIC_DESC_EOL) {
                 /* EOL detected */
                 break;
             }
Signature · 1 line
2.24.1
Reviewed-by on v1 1/1
#1 lore raw

Le 04/03/2020 à 04:23, Finn Thain a écrit :

Quoted 15 lines

A portion of a recent patch got lost due to a merge snafu. That patch is now commit 88f632fbb1 ("dp8393x: Mask EOL bit from descriptor addresses"). This patch restores the portion that got lost.

---
 hw/net/dp8393x.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
hw/net/dp8393x.c +0 -0
index 8a3504d962..81fc13ee9f 100644

hw/net/dp8393x.c static void dp8393x_do_transmit_packets(dp8393xState *s) · line 532

Quoted 10 lines
hw/net/dp8393x.c +2 -2
@@ -525,8 +525,8 @@ static void dp8393x_do_transmit_packets(dp8393xState *s)
                                  * (4 + 3 * s->regs[SONIC_TFC]),
                                MEMTXATTRS_UNSPECIFIED, s->data,
                                size);
-            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0) & ~0x1;
-            if (dp8393x_get(s, width, 0) & SONIC_DESC_EOL) {
+            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0);
+            if (s->regs[SONIC_CTDA] & SONIC_DESC_EOL) {
                 /* EOL detected */
                 break;
             }
Reviewed-by on v1 1/1
#2 lore raw
In reply to Finn Thain
Quoted 15 lines · Finn Thain

A portion of a recent patch got lost due to a merge snafu. That patch is now commit 88f632fbb1 ("dp8393x: Mask EOL bit from descriptor addresses"). This patch restores the portion that got lost.

---
  hw/net/dp8393x.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
hw/net/dp8393x.c +0 -0
index 8a3504d962..81fc13ee9f 100644

hw/net/dp8393x.c static void dp8393x_do_transmit_packets(dp8393xState *s) · line 532

Quoted 10 lines
hw/net/dp8393x.c +2 -2
@@ -525,8 +525,8 @@ static void dp8393x_do_transmit_packets(dp8393xState *s)
                                   * (4 + 3 * s->regs[SONIC_TFC]),
                                 MEMTXATTRS_UNSPECIFIED, s->data,
                                 size);
-            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0) & ~0x1;
-            if (dp8393x_get(s, width, 0) & SONIC_DESC_EOL) {
+            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0);
+            if (s->regs[SONIC_CTDA] & SONIC_DESC_EOL) {
                  /* EOL detected */
                  break;
              }
#3 lore raw
In reply to Finn Thain

Le 04/03/2020 à 04:23, Finn Thain a écrit :

Quoted 15 lines

A portion of a recent patch got lost due to a merge snafu. That patch is now commit 88f632fbb1 ("dp8393x: Mask EOL bit from descriptor addresses"). This patch restores the portion that got lost.

---
 hw/net/dp8393x.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
hw/net/dp8393x.c +0 -0
index 8a3504d962..81fc13ee9f 100644

hw/net/dp8393x.c static void dp8393x_do_transmit_packets(dp8393xState *s) · line 532

Quoted 10 lines
hw/net/dp8393x.c +2 -2
@@ -525,8 +525,8 @@ static void dp8393x_do_transmit_packets(dp8393xState *s)
                                  * (4 + 3 * s->regs[SONIC_TFC]),
                                MEMTXATTRS_UNSPECIFIED, s->data,
                                size);
-            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0) & ~0x1;
-            if (dp8393x_get(s, width, 0) & SONIC_DESC_EOL) {
+            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0);
+            if (s->regs[SONIC_CTDA] & SONIC_DESC_EOL) {
                 /* EOL detected */
                 break;
             }

Jason,

as it's a trivial bug fixes (only a diff between the commit and the patch), will you merge it via the network queue or do you want I take it via trivial queue?

Thanks,
Laurent

#4 lore raw
Quoted 28 lines · Laurent Vivier

Le 04/03/2020 à 04:23, Finn Thain a écrit :

Quoted 15 lines

A portion of a recent patch got lost due to a merge snafu. That patch is now commit 88f632fbb1 ("dp8393x: Mask EOL bit from descriptor addresses"). This patch restores the portion that got lost.

---
  hw/net/dp8393x.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
hw/net/dp8393x.c +0 -0
index 8a3504d962..81fc13ee9f 100644

hw/net/dp8393x.c static void dp8393x_do_transmit_packets(dp8393xState *s) · line 532

Quoted 10 lines
hw/net/dp8393x.c +2 -2
@@ -525,8 +525,8 @@ static void dp8393x_do_transmit_packets(dp8393xState *s)
                                   * (4 + 3 * s->regs[SONIC_TFC]),
                                 MEMTXATTRS_UNSPECIFIED, s->data,
                                 size);
-            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0) & ~0x1;
-            if (dp8393x_get(s, width, 0) & SONIC_DESC_EOL) {
+            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0);
+            if (s->regs[SONIC_CTDA] & SONIC_DESC_EOL) {
                  /* EOL detected */
                  break;
              }

Jason,

Quoted 3 lines

as it's a trivial bug fixes (only a diff between the commit and the patch), will you merge it via the network queue or do you want I take it via trivial queue?

Hi Laurent:

Please merge it.

Thanks

Quoted 4 lines

Thanks,
Laurent

#5 lore raw

Le 09/03/2020 à 03:51, Jason Wang a écrit :

Quoted 32 lines · Laurent Vivier
Quoted 30 lines

Le 04/03/2020 à 04:23, Finn Thain a écrit :

Quoted 25 lines

A portion of a recent patch got lost due to a merge snafu. That patch is now commit 88f632fbb1 ("dp8393x: Mask EOL bit from descriptor addresses").
This patch restores the portion that got lost.

---
  hw/net/dp8393x.c | 4 ++--

  1 file changed, 2 insertions(+), 2 deletions(-)
hw/net/dp8393x.c +2 -2
index 8a3504d962..81fc13ee9f 100644
@@ -525,8 +525,8 @@ static void
 dp8393x_do_transmit_packets(dp8393xState *s)
                                    * (4 + 3 * s->regs[SONIC_TFC]),
                                  MEMTXATTRS_UNSPECIFIED, s->data,
                                  size);
-            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0) & ~0x1;
-            if (dp8393x_get(s, width, 0) & SONIC_DESC_EOL) {
+            s->regs[SONIC_CTDA] = dp8393x_get(s, width, 0);
+            if (s->regs[SONIC_CTDA] & SONIC_DESC_EOL) {
                   /* EOL detected */
                   break;
Quoted 2 lines

              }

Jason,

Quoted 8 lines
Quoted 3 lines

as it's a trivial bug fixes (only a diff between the commit and the patch), will you merge it via the network queue or do you want I take it via trivial queue?

Hi Laurent:

Please merge it.

Applied to my trivial-patch branch.

Thanks,
Laurent