From: Tom Rini <trini@konsulko.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [U-Boot,17/27] sandbox: Use asm-generic/io.h
Date: Thu, 13 Oct 2016 12:16:03 -0400 [thread overview]
Message-ID: <20161013161603.GA17506@bill-the-cat> (raw)
In-Reply-To: <20161001141931.32354-18-paul.burton@imgtec.com>
On Sat, Oct 01, 2016 at 03:19:20PM +0100, Paul Burton wrote:
> Convert the sandbox architecture to make use of the new asm-generic/io.h
> to provide address mapping functions. As sandbox actually performs
> non-identity mapping between physical & virtual addresses we can't
> simply make use of the generic mapping functions, but are able to
> implement phys_to_virt() & make use of it from map_physmem().
[snip]
> +phys_addr_t virt_to_phys(void *vaddr)
> +{
> + return (phys_addr_t)(vaddr - gd->arch.ram_buf);
../arch/sandbox/cpu/cpu.c: In function ?virt_to_phys?:
../arch/sandbox/cpu/cpu.c:65:29: error: invalid operands to binary - (have ?void *? and ?uint8_t *?)
return (phys_addr_t)(vaddr - gd->arch.ram_buf);
[snip]
> -/*
> - * Given a physical address and a length, return a virtual address
> - * that can be used to access the memory range with the caching
> - * properties specified by "flags".
> - */
> -#define MAP_NOCACHE (0)
> -#define MAP_WRCOMBINE (0)
> -#define MAP_WRBACK (0)
> -#define MAP_WRTHROUGH (0)
[snip]
> @@ -71,6 +69,7 @@ static inline void _outsw(volatile u16 *port, const void *buf, int ns)
> #define out16(addr, val)
> #define in16(addr) 0
>
> +#include <asm-generic/io.h>
... but we use MAP_WRBACK in map/unmap_sysmem which are before we
include this so they don't compile.
Please fix and run test/py/test.py for sandbox when you're done to
ensure it's still all happy, thanks!
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161013/b913d81b/attachment.sig>
next prev parent reply other threads:[~2016-10-13 16:16 UTC|newest]
Thread overview: 46+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-01 14:19 [U-Boot] [PATCH 00/27] Clean up address mapping functions & CONFIG_SYS_SDRAM_BASE Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 01/27] Provide a generic io.h & address mapping functions Paul Burton
2016-10-02 6:49 ` Angelo Dureghello
2016-10-03 21:49 ` Simon Glass
2016-11-17 15:32 ` Paul Burton
2016-11-19 13:47 ` Simon Glass
2016-10-01 14:19 ` [U-Boot] [PATCH 02/27] arc: Use asm-generic/io.h Paul Burton
2016-10-03 9:13 ` Alexey Brodkin
2016-10-01 14:19 ` [U-Boot] [PATCH 03/27] arm: " Paul Burton
2016-10-03 21:49 ` Simon Glass
2016-10-01 14:19 ` [U-Boot] [PATCH 04/27] blackfin: " Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 05/27] m68k: " Paul Burton
2016-10-02 6:36 ` Angelo Dureghello
2016-10-01 14:19 ` [U-Boot] [PATCH 06/27] microblaze: " Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 07/27] nds32: " Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 08/27] openrisc: " Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 09/27] sh: " Paul Burton
2016-11-24 1:49 ` Vladimir Zapolskiy
2016-11-27 21:17 ` Vladimir Zapolskiy
2016-10-01 14:19 ` [U-Boot] [PATCH 10/27] sparc: " Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 11/27] x86: " Paul Burton
2016-10-03 21:49 ` Simon Glass
2016-10-01 14:19 ` [U-Boot] [PATCH 12/27] xtensa: " Paul Burton
2016-10-03 18:22 ` Max Filippov
2016-10-01 14:19 ` [U-Boot] [PATCH 13/27] mips: " Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 14/27] mips: Fix map_physmem for cached mappings Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 15/27] nios2: Use asm-generic/io.h Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 16/27] powerpc: " Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 17/27] sandbox: " Paul Burton
2016-10-03 21:49 ` Simon Glass
2016-10-13 16:16 ` Tom Rini [this message]
2016-10-01 14:19 ` [U-Boot] [PATCH 18/27] board_f: Account for CONFIG_SYS_SDRAM_BASE being physical Paul Burton
2016-10-03 21:49 ` Simon Glass
2016-10-01 14:19 ` [U-Boot] [PATCH 19/27] image: " Paul Burton
2016-10-03 21:49 ` Simon Glass
2016-10-01 14:19 ` [U-Boot] [PATCH 20/27] image: Use ram_top, not bi_memsize, in getenv_bootm_size Paul Burton
2016-10-03 21:49 ` Simon Glass
2016-10-01 14:19 ` [U-Boot] [PATCH 21/27] mips: Use ram_top, not bi_memsize, in arch_lmb_reserve Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 22/27] mips: Ensure stack is at a virtual address Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 23/27] boston: Provide physical CONFIG_SYS_SDRAM_BASE Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 24/27] malta: Use a " Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 25/27] xilfpga: " Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 26/27] mips: Use a physical CONFIG_SYS_SDRAM_BASE for remaining boards Paul Burton
2016-10-01 14:19 ` [U-Boot] [PATCH 27/27] mips: Remove virt_to_phys call on bi_memstart Paul Burton
2016-10-02 13:46 ` [U-Boot] [PATCH 00/27] Clean up address mapping functions & CONFIG_SYS_SDRAM_BASE Masahiro Yamada
2016-10-03 10:41 ` Paul Burton
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=20161013161603.GA17506@bill-the-cat \
--to=trini@konsulko.com \
--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.