lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 6 Jun 2012 15:11:23 -0700
From:	Anton Vorontsov <cbouatmailru@...il.com>
To:	Colin Cross <ccross@...roid.com>
Cc:	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Kees Cook <keescook@...omium.org>,
	Arnd Bergmann <arnd@...db.de>,
	John Stultz <john.stultz@...aro.org>, arve@...roid.com,
	Rebecca Schultz Zavin <rebecca@...roid.com>,
	Jesper Juhl <jj@...osbits.net>,
	Randy Dunlap <rdunlap@...otime.net>,
	Stephen Boyd <sboyd@...eaurora.org>,
	Thomas Meyer <thomas@...3r.de>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Marco Stornelli <marco.stornelli@...il.com>,
	WANG Cong <xiyou.wangcong@...il.com>,
	linux-kernel@...r.kernel.org, devel@...verdev.osuosl.org,
	linaro-kernel@...ts.linaro.org, patches@...aro.org,
	kernel-team@...roid.com
Subject: Re: [PATCH 06/11] persistent_ram: Make it possible to use memory
 outside of bootmem

On Wed, Jun 06, 2012 at 02:10:34PM -0700, Colin Cross wrote:
> On Fri, May 11, 2012 at 5:17 PM, Anton Vorontsov
> <anton.vorontsov@...aro.org> wrote:
> > This includes devices' memory (e.g. framebuffers or memory mapped
> > EEPROMs on a local bus), as well as the normal RAM that we don't use
> > for the main memory.
> >
> > For the normal (but unused) ram we could use kmaps, but this assumes
> > highmem support, so we don't bother and just use the memory via
> > ioremap.
> >
> > As a side effect, the following hack is possible: when used together
> > with pstore_ram (new ramoops) module, we can limit the normal RAM region
> > with mem= and then point ramoops to use the rest of the memory, e.g.
> >
> >        mem=128M ramoops.mem_address=0x8000000
> >
> > Sure, we could just reserve the region with memblock_reserve() early in
> > the arch/ code, and then register a pstore_ram platform device pointing
> > to the reserved region. It's still a viable option if platform wants
> > to do so.
> >
> > Also, we might want to use IO accessors in case of a real device,
> > but for now we don't bother (the old ramoops wasn't using it either, so
> > at least we don't make things worse).
> 
> This is long merged, but I remembered why I moved away from using
> ioremap.  The current code uses atomics to track the ringbuffer
> positions, which results in ldrex and strex instructions on ARM.
> ldrex and strex on memory that is mapped as Device memory (which is
> what ioremap maps as) is implementation defined, and is unpredictable
> at the architecture level.

Makes sense, thanks for sharing! Fortunately, we still map things
w/ vmap if pfn appears to be valid. :-)

Thanks,

-- 
Anton Vorontsov
Email: cbouatmailru@...il.com
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ