summaryrefslogtreecommitdiffstats
path: root/src/include
diff options
context:
space:
mode:
authorMichael Brown2006-04-25 14:11:36 +0200
committerMichael Brown2006-04-25 14:11:36 +0200
commitcf3783b4caf3551d6ebb153f5a93a8ed57035af1 (patch)
tree97ea2747009e223dd09c1f1ec9dec51ba028a5f6 /src/include
parentUpdate to use POSIX-like API. (diff)
downloadipxe-cf3783b4caf3551d6ebb153f5a93a8ed57035af1.tar.gz
ipxe-cf3783b4caf3551d6ebb153f5a93a8ed57035af1.tar.xz
ipxe-cf3783b4caf3551d6ebb153f5a93a8ed57035af1.zip
Actually, it's probably a good idea to have packet buffers avoid 4kB
crossings.
Diffstat (limited to 'src/include')
-rw-r--r--src/include/gpxe/pkbuff.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/include/gpxe/pkbuff.h b/src/include/gpxe/pkbuff.h
index 895367ae..646b540d 100644
--- a/src/include/gpxe/pkbuff.h
+++ b/src/include/gpxe/pkbuff.h
@@ -17,6 +17,17 @@
struct net_protocol;
struct ll_protocol;
+/**
+ * Packet buffer alignment
+ *
+ * Packet buffers allocated via alloc_pkb() are guaranteed to be
+ * physically aligned to this boundary. Some cards cannot DMA across
+ * a 4kB boundary. With a standard Ethernet MTU, aligning to a 2kB
+ * boundary is sufficient to guarantee no 4kB boundary crossings. For
+ * a jumbo Ethernet MTU, a packet may be larger than 4kB anyway.
+ */
+#define PKBUFF_ALIGN 2048
+
/** A packet buffer
*
* This structure is used to represent a network packet within gPXE.