mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Steffen Trumtrar <s.trumtrar@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH v4 3/3] include: net: align PKTSIZE to 64 bytes
Date: Fri, 01 Dec 2023 14:51:29 +0100	[thread overview]
Message-ID: <20231201-v2023-08-0-topic-macb-v4-3-b4f5d64de1ad@pengutronix.de> (raw)
In-Reply-To: <20231201-v2023-08-0-topic-macb-v4-0-b4f5d64de1ad@pengutronix.de>

PKTSIZE is used to allocate network packet storage.
Make it fill a cache line so drivers using it don't accidentally flush
adjacent packets.

Suggested-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de>
---
 include/net.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/net.h b/include/net.h
index a0ef8bee04..63109465f9 100644
--- a/include/net.h
+++ b/include/net.h
@@ -236,9 +236,9 @@ struct icmphdr {
  * Maximum packet size; used to allocate packet storage.
  * TFTP packets can be 524 bytes + IP header + ethernet header.
  * Lets be conservative, and go for 38 * 16.  (Must also be
- * a multiple of 32 bytes).
+ * a multiple of 64 bytes).
  */
-#define PKTSIZE			1518
+#define PKTSIZE			1536
 
 /**********************************************************************/
 /*

-- 
2.40.1




  parent reply	other threads:[~2023-12-01 13:53 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-01 13:51 [PATCH v4 0/3] net: macb: fix dma usage Steffen Trumtrar
2023-12-01 13:51 ` [PATCH v4 1/3] net: macb: fix dma_alloc for rx_buffer Steffen Trumtrar
2023-12-01 13:51 ` [PATCH v4 2/3] net: macb: convert to volatile accesses Steffen Trumtrar
2023-12-01 13:51 ` Steffen Trumtrar [this message]
2023-12-05  8:04 ` [PATCH v4 0/3] net: macb: fix dma usage Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231201-v2023-08-0-topic-macb-v4-3-b4f5d64de1ad@pengutronix.de \
    --to=s.trumtrar@pengutronix.de \
    --cc=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox