From: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
To: Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>,
Hans de Goede <hdegoede@redhat.com>,
linux-fbdev@vger.kernel.org,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Rob Herring <robh+dt@kernel.org>,
Mark Rutland <mark.rutland@arm.com>,
devicetree <devicetree@vger.kernel.org>
Subject: Re: [PATCH] fbdev: simplefb: add support for 'memory-region' property on DT node
Date: Fri, 02 Feb 2018 14:21:21 +0900 [thread overview]
Message-ID: <20180202142121.CEB8.4A936039@socionext.com> (raw)
In-Reply-To: <CAHp75VfTrEELX9kKjZ7zmM8V=ZxbfAPbEDozG1i0A4P6gUjnEA@mail.gmail.com>
Hi Andy,
On Thu, 1 Feb 2018 21:03:30 +0200 <andy.shevchenko@gmail.com> wrote:
> On Thu, Feb 1, 2018 at 5:56 PM, Bartlomiej Zolnierkiewicz
> <b.zolnierkie@samsung.com> wrote:
> > On Tuesday, January 23, 2018 08:34:56 PM Kunihiko Hayashi wrote:
> >> Enables 'memory-region' property referring to the memory description on
> >> the reserved-memory node in case of devicetree use.
> >> If there is no 'reg' property that specifies the address and size of
> >> the framebuffer, the address and size written in the memory description
> >> on the reserved-memory node can be used for the framebuffer.
> >>
> >> Furthermore, the reserved-memory node needs to have "no-map" attributes
> >> because simplefb driver maps the region by ioremap_wc().
> >>
> >> Signed-off-by: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
>
> >> +- memory-region: phandle to a node describing memory region as framebuffer
> >> + memory instead of reg property. The node should include
> >> + 'no-map'.
>
> >> mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> >> + if (!mem)
> >> + mem = simplefb_parse_dt_reserved_mem(&pdev->dev);
>
> I'm not sure I understood why you need this entire function?
>
> Put your memory resource ('reg' property) as part of reserved memory
> with necessary flags.
Surely we prepare a memory resource as a part of reserved memory,
for example:
reserved-memory {
fb_area: memory@0xa0000000 {
reg = <0xa0000000 0x400000>;
no-map;
};
};
And we need to specify the address and size as a reg property in
the framebuffer node.
framebuffer {
compatible = "simple-framebuffer";
reg = <0xa0000000 0x400000>;
};
This function allows us to specify the area with phandle to
the reserved memory instead of same address and size.
framebuffer {
compatible = "simple-framebuffer";
memory-region = <&fb_area>;
};
If both reg and memory-region properties are specified
in the framebuffer node, the reg propery will be applied.
---
Best Regards,
Kunihiko Hayashi
next prev parent reply other threads:[~2018-02-02 5:21 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20180123113510epcas1p1fc8a6e3ad50127bb84fe350b156a8c07@epcas1p1.samsung.com>
2018-01-23 11:34 ` Kunihiko Hayashi
2018-01-23 14:45 ` Hans de Goede
2018-02-01 15:56 ` Bartlomiej Zolnierkiewicz
2018-02-01 19:03 ` Andy Shevchenko
2018-02-02 5:21 ` Kunihiko Hayashi [this message]
2018-02-02 5:20 ` Kunihiko Hayashi
2018-02-05 6:09 ` Rob Herring
2018-02-05 12:03 ` Kunihiko Hayashi
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=20180202142121.CEB8.4A936039@socionext.com \
--to=hayashi.kunihiko@socionext.com \
--cc=andy.shevchenko@gmail.com \
--cc=b.zolnierkie@samsung.com \
--cc=devicetree@vger.kernel.org \
--cc=hdegoede@redhat.com \
--cc=linux-fbdev@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=robh+dt@kernel.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
all inboxes | Powered by JetHome®