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] [thread-next>] [day] [month] [year] [list]
Message-ID: <8d6898730707110114p3c02e24as8ca8359731fdc320@mail.gmail.com>
Date:	Wed, 11 Jul 2007 13:44:49 +0530
From:	"Nobin Mathew" <nobin.mathew@...il.com>
To:	"Manu Abraham" <abraham.manu@...il.com>
Cc:	"vraghavan3@...l.gatech.edu" <vraghavan3@...l.gatech.edu>,
	linux-kernel@...r.kernel.org
Subject: Re: Reading a physical memory location

See this in the documentation

The returned virtual address is a current CPU mapping for the memory
address given. It is only valid to use this function on addresses that
have a kernel mapping

This function does not handle bus mappings for DMA transfers. In
almost all conceivable cases a device driver should not be using this
function

Nobin

On 7/11/07, Manu Abraham <abraham.manu@...il.com> wrote:
> On 7/11/07, Nobin Mathew <nobin.mathew@...il.com> wrote:
> > Which is your platform ?
> >
> > Which processor?
> >
> > If you want to use physical address directly, then disable MMU. That
> > is not possible in linux.
>
> ioremap does map io memory using phys_to_virt
> I thought phys_to_virt was enough to remap physical memory to virtual
> http://mirror.linux.org.au/linux.conf.au/2005/cdrom-beta-1/linux-mandocs-2.6.12.6/phys_to_virt.html
>
>
>
> >
> > Nobin
> >
> > On 7/11/07, Manu Abraham <abraham.manu@...il.com> wrote:
> > > On 7/10/07, vraghavan3@...l.gatech.edu <vraghavan3@...l.gatech.edu> wrote:
> > > >
> > > > Thanks for the quick reply. But I was wondering as to why I would have to map
> > > > the physical address to the virtual address when I know that the string is
> > > > permanently in the physical memory because its loaded into flash. Is there a way
> > > > to directly read from the physical memory location? Also, do the functions
> > > > ioremap() and readl(va) work when called from within a kernel module?
> > > >
> > >
> > > Of course, if you look at almost any of the memory mapped device
> > > drivers, you will find that ioremap/readl/writel is the backbone of
> > > your infrastructure.
> > >
> > >
> > > Manu
> > >
> >
>
-
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