Re: [PATCH 16/22] arm64: Add function to create identity mappings

2014-02-17 Thread Mark Salter
On Fri, 2014-02-14 at 17:42 +, Catalin Marinas wrote: > On Wed, Feb 05, 2014 at 05:04:07PM +, Leif Lindholm wrote: > > +void __init create_id_mapping(phys_addr_t addr, phys_addr_t size, int > > map_io) > > +{ > > + pgd_t *pgd = &idmap_pg_dir[pgd_index(addr)]; > > + > > + if (pgd >= &id

Re: [PATCH 16/22] arm64: Add function to create identity mappings

2014-02-14 Thread Catalin Marinas
On Wed, Feb 05, 2014 at 05:04:07PM +, Leif Lindholm wrote: > +void __init create_id_mapping(phys_addr_t addr, phys_addr_t size, int map_io) > +{ > + pgd_t *pgd = &idmap_pg_dir[pgd_index(addr)]; > + > + if (pgd >= &idmap_pg_dir[ARRAY_SIZE(idmap_pg_dir)]) { > + pr_warn("BUG: n

[PATCH 16/22] arm64: Add function to create identity mappings

2014-02-05 Thread Leif Lindholm
From: Mark Salter At boot time, before switching to a virtual UEFI memory map, firmware expects UEFI memory and IO regions to be identity mapped whenever kernel makes runtime services calls. The exisitng early boot code creates an identity map of kernel text/data but this is not sufficient for UE