From: Arnd Bergmann <arnd@arndb.de>
To: linuxppc-dev@ozlabs.org
Subject: Re: of_iomap and request_mem_region
Date: Sun, 10 Feb 2008 03:45:54 +0100 [thread overview]
Message-ID: <200802100345.54580.arnd@arndb.de> (raw)
In-Reply-To: <9e4733910802091838x3e596debj113089faef08c1c8@mail.gmail.com>
On Sunday 10 February 2008, Jon Smirl wrote:
> of_iomap doesn't implicitly do a request_mem_region(). =A0How should
> request_mem_region() be handled? When using of_iomap you don't get the
> length of the region back so it isn't easy to call request_mem_region.
>=20
> What about adding a third param to of_iomap for the driver name? If it
> is non-null also do the request region. If it is null check to make
> sure the region has already be requested.
I'd prefer changing of_iomap so that it gets the of_device instead of
the device_node. That would help us do two changes at once:
1. call request_mem_region using dev->driver->name, as you mentioned.
2. use managed registrations, as lib/devres.c does e.g. in pcim_iomap,
so that we can kill all the calls to iounmap in the cleanup path
of OF drivers.
maybe we can do a new ofm_iomap interface first, and then move
drivers over to use that one.
Arnd <><
next prev parent reply other threads:[~2008-02-10 2:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-10 2:38 of_iomap and request_mem_region Jon Smirl
2008-02-10 2:45 ` Arnd Bergmann [this message]
2008-02-10 2:59 ` Jon Smirl
2008-02-10 3:14 ` Arnd Bergmann
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=200802100345.54580.arnd@arndb.de \
--to=arnd@arndb.de \
--cc=linuxppc-dev@ozlabs.org \
/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.