From: Marek Vasut <marex@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/3] common: add ifdefs around bouncebuf.c body
Date: Tue, 6 Nov 2012 01:54:03 +0100 [thread overview]
Message-ID: <201211060154.03822.marex@denx.de> (raw)
In-Reply-To: <1352156642-7975-1-git-send-email-swarren@wwwdotorg.org>
Dear Stephen Warren,
> From: Stephen Warren <swarren@nvidia.com>
>
> If a U-Boot config file enables CONFIG_BOUNCE_BUFFER only for the main
> U-Boot build and not for the SPL, then config.mk will contain
> CONFIG_BOUNCE_BUFFER=y, so common/Makefile will build bouncebuf.c for
> both the SPL and main U-Boot, but config.h won't set CONFIG_BOUNCE_BUFFER
> for the SPL, so bouncebuf.h will provide static inline functions, which
> will conflict with the compiled bouncebuf.c. Solve this by guarding the
> body of bouncebuf.c with the ifdef to avoid conflicts.
Uh, don't you want the bounce buffer not compiled in for SPL? Then maybe add
CONFIG_SPL_BOUNCE_BUFFER to force BB to be compiled into SPL or something ...
> Signed-off-by: Stephen Warren <swarren@nvidia.com>
> ---
> This series is based on u-boot/master. I've CC'd the MMC and Tegra
> maintainers since they'll presumably need to ack the changes in order for
> these patches to all be applied in one place. Marek seems to be the main
> MXS MMC maintainer as far as I can tell.
What did I get myself into ... ;-)
> common/bouncebuf.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/common/bouncebuf.c b/common/bouncebuf.c
> index 4f827f8..ffd3c90 100644
> --- a/common/bouncebuf.c
> +++ b/common/bouncebuf.c
> @@ -27,6 +27,7 @@
> #include <errno.h>
> #include <bouncebuf.h>
>
> +#ifdef CONFIG_BOUNCE_BUFFER
> static int addr_aligned(void *data, size_t len)
> {
> const ulong align_mask = ARCH_DMA_MINALIGN - 1;
> @@ -90,3 +91,4 @@ int bounce_buffer_stop(void **data, size_t len, void
> **backup, uint8_t flags)
>
> return 0;
> }
> +#endif
Best regards,
Marek Vasut
next prev parent reply other threads:[~2012-11-06 0:54 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-05 23:04 [U-Boot] [PATCH 1/3] common: add ifdefs around bouncebuf.c body Stephen Warren
2012-11-05 23:04 ` [U-Boot] [PATCH 2/3] common: rework bouncebuf implementation Stephen Warren
2012-11-05 23:54 ` Simon Glass
2012-11-06 18:44 ` Stephen Warren
2012-11-06 19:30 ` Stephen Warren
2012-11-05 23:04 ` [U-Boot] [PATCH 3/3] mmc: tegra: use bounce buffer APIs Stephen Warren
2012-11-06 0:00 ` Simon Glass
2012-11-06 18:50 ` Stephen Warren
2012-11-06 19:03 ` Simon Glass
2012-11-05 23:47 ` [U-Boot] [PATCH 1/3] common: add ifdefs around bouncebuf.c body Simon Glass
2012-11-06 18:04 ` Stephen Warren
2012-11-06 0:54 ` Marek Vasut [this message]
2012-11-06 18:07 ` Stephen Warren
2012-11-06 22:43 ` Marek Vasut
2012-11-06 22:49 ` Stephen Warren
2012-11-06 22:57 ` Marek Vasut
2012-11-06 23:13 ` Stephen Warren
2012-11-07 13:21 ` Marek Vasut
2012-11-07 17:00 ` Stephen Warren
2012-11-08 1:20 ` Marek Vasut
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=201211060154.03822.marex@denx.de \
--to=marex@denx.de \
--cc=u-boot@lists.denx.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.