From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marek Vasut Date: Fri, 16 Mar 2012 03:50:08 +0100 Subject: [U-Boot] [PATCH] net: force PKTALIGN to ARCH_DMA_MINALIGN In-Reply-To: <1331760956-3901-1-git-send-email-eric.nelson@boundarydevices.com> References: <1331760956-3901-1-git-send-email-eric.nelson@boundarydevices.com> Message-ID: <201203160350.08910.marex@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Eric Nelson, > This will prevent the need for architectures whose DMA alignment > is greater than 32 to have bounce buffers. > > Signed-off-by: Eric Nelson > --- > include/net.h | 3 ++- > 1 files changed, 2 insertions(+), 1 deletions(-) > > diff --git a/include/net.h b/include/net.h > index e4d42c2..ff428d0 100644 > --- a/include/net.h > +++ b/include/net.h > @@ -16,6 +16,7 @@ > #include > #endif /* CONFIG_8xx */ > > +#include > #include /* for nton* / ntoh* stuff */ > > > @@ -31,7 +32,7 @@ > # define PKTBUFSRX 4 > #endif > > -#define PKTALIGN 32 > +#define PKTALIGN ARCH_DMA_MINALIGN > > /* IPv4 addresses are always 32 bits in size */ > typedef u32 IPaddr_t; Won't this break retarded hardware that has ARCH_DMA_MINALIGN smaller than 32 ? Best regards, Marek Vasut