From: Olof Johansson <olof@lixom.net>
To: Rohit Vaswani <rvaswani@codeaurora.org>
Cc: davidb@codeaurora.org, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org
Subject: Re: [PATCH RESEND 2/2] msm: io: Change the default static iomappings to be shared
Date: Tue, 28 Aug 2012 13:41:53 -0700 [thread overview]
Message-ID: <CAOesGMgC2OxEs-wGRQku-GeoiaO2Wa_dZ2AuwnKd3Nze4gknqQ@mail.gmail.com> (raw)
In-Reply-To: <1344633496-1873-1-git-send-email-rvaswani@codeaurora.org>
Hi,
On Fri, Aug 10, 2012 at 2:18 PM, Rohit Vaswani <rvaswani@codeaurora.org> wrote:
> With 3.4 kernel the static iomappings can be shared with the ioremap
> mappings. If ioremap is called with an address for which a static
> mapping already exists, then that mapping should be used instead
> of creating a new one.
> However, the MT_DEVICE_NONSHARED flag prevents this. Hence, get rid
> of this flag. Some targets (7X00) that require the static iomappings
> to be NONSHARED use the MSM_DEVICE_TYPE and MSM_CHIP_DEVICE_TYPE macros.
>
> Signed-off-by: Rohit Vaswani <rvaswani@codeaurora.org>
> ---
> arch/arm/mach-msm/io.c | 25 +++++++++++++++++--------
> 1 files changed, 17 insertions(+), 8 deletions(-)
>
> diff --git a/arch/arm/mach-msm/io.c b/arch/arm/mach-msm/io.c
> index 2409c0b..5fc2e48 100644
> --- a/arch/arm/mach-msm/io.c
> +++ b/arch/arm/mach-msm/io.c
> @@ -33,23 +33,32 @@
> .virtual = (unsigned long) MSM_##name##_BASE, \
> .pfn = __phys_to_pfn(chip##_##name##_PHYS), \
> .length = chip##_##name##_SIZE, \
> - .type = MT_DEVICE_NONSHARED, \
> + .type = MT_DEVICE, \
> + }
> +
> +#define MSM_CHIP_DEVICE_TYPE(name, chip, mem_type) { \
> + .virtual = (unsigned long) MSM_##name##_BASE, \
> + .pfn = __phys_to_pfn(chip##_##name##_PHYS), \
> + .length = chip##_##name##_SIZE, \
> + .type = mem_type, \
> }
The above is partially hidden by lack of context in the diff, but now
you have two defines that do nearly the same thing. It's better to
move to a
#define MSM_CHIP_DEVICE(name, chip) MSM_CHIP_DEVICE_TYPE(name, chip, MT_DEVICE)
for the exising one, instead of duplicating the open coded macros.
-Olof
next prev parent reply other threads:[~2012-08-28 20:41 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-10 21:18 [PATCH RESEND 2/2] msm: io: Change the default static iomappings to be shared Rohit Vaswani
2012-08-28 20:41 ` Olof Johansson [this message]
2012-09-06 17:16 ` [PATCHv2 " Rohit Vaswani
2012-09-07 3:17 ` Stephen Boyd
2012-09-07 20:05 ` [PATCHv3 " Rohit Vaswani
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=CAOesGMgC2OxEs-wGRQku-GeoiaO2Wa_dZ2AuwnKd3Nze4gknqQ@mail.gmail.com \
--to=olof@lixom.net \
--cc=davidb@codeaurora.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rvaswani@codeaurora.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).