From: Arun Kumar K <arun.kk@samsung.com>
To: Sylwester Nawrocki <sylvester.nawrocki@gmail.com>
Cc: "linux-samsung-soc@vger.kernel.org"
<linux-samsung-soc@vger.kernel.org>,
"devicetree-discuss@lists.ozlabs.org"
<devicetree-discuss@lists.ozlabs.org>,
Kukjin Kim <kgene.kim@samsung.com>,
Kamil Debski <k.debski@samsung.com>,
Jeongtae Park <jtp.park@samsung.com>,
"thomas.abraham@linaro.org" <thomas.abraham@linaro.org>,
Karol Lewandowski <k.lewandowsk@samsung.com>,
NAVEEN KRISHNA CHATRADHI <ch.naveen@samsung.com>,
SUNIL JOSHI <joshi@samsung.com>
Subject: Re: [PATCH v2] ARM: EXYNOS: Add MFC device tree support
Date: Thu, 13 Sep 2012 04:22:09 +0000 (GMT) [thread overview]
Message-ID: <8407236.410361347510128765.JavaMail.weblogic@epml14> (raw)
Hi Sylwester,
Thank you for the comments.
Will make the necessary changes.
Regards
Arun
On Thu, Sep 13, 2012 at 1:54 AM, Sylwester Nawrocki <sylvester.nawrocki@gmail.com> wrote:
> Just a few small comments...
>
>
> On 09/12/2012 03:34 PM, Arun Kumar K wrote:
>>
>> This patch adds device tree entry for MFC v6 in the Exynos5
>> SoC. Makes the required changes in the clock files and adds
>> MFC to the DT device list.
>>
>> Signed-off-by: Naveen Krishna Chatradhi<ch.naveen@samsung.com>
>> Signed-off-by: Arun Kumar K<arun.kk@samsung.com>
>> ---
>
> ...
>>
>> diff --git a/Documentation/devicetree/bindings/media/s5p-mfc.txt
>> b/Documentation/devicetree/bindings/media/s5p-mfc.txt
>>
>> new file mode 100644
>> index 0000000..9a74d09
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/media/s5p-mfc.txt
>> @@ -0,0 +1,27 @@
>> +* Samsung Multi Format Codec (MFC)
>> +
>> +Mult Format Codec (MFC) is the IP present in Samsung SoCs which
>
>
> Mult -> Multi
>
>
>> +supports high resolution decoding and encoding functionalities.
>> +The MFC device driver is a v4l2 driver which can encode/decode
>> +video raw/elementary streams and has support for all popular
>> +video codecs.
>> +
>> +Required properties:
>> + - compatible : value should be either one among the following
>> + (a) "samsung,mfc-v5" for MFC v5 present in Exynos4 SoCs
>> + (b) "samsung,mfc-v6" for MFC v6 present in Exynos5 SoCs
>> +
>> + - reg : Physical base address of the IP registers and length of memory
>> + mapped region.
>> +
>> + - interrupts : MFC interupt number to the CPU.
>
>
> interupt -> interrupt
>
>
>> +
>> + - samsung,mfc-r : Base address of the first memory bank used by MFC
>> + for DMA contiguous memory allocation.
>> +
>> + - samsung,mfc-r-size : Size of the first memory bank.
>> +
>> + - samsung,mfc-l : Base address of the second memory bank used by MFC
>> + for DMA contiguous memory allocation.
>> +
>
> ...
>
>> +struct mfc_dt_meminfo {
>> + unsigned long loff;
>> + unsigned long lsize;
>> + unsigned long roff;
>> + unsigned long rsize;
>> +};
>> +
>> +int fdt_find_mfc_mem(unsigned long node, const char *uname, int depth,
>> + void *data)
>> +{
>> + __be32 *prop;
>> + unsigned long len;
>> + struct mfc_dt_meminfo *mfc_mem = (struct mfc_dt_meminfo *)data;
>
>
> No need for explicit cast from void *.
>
>
>> + if (of_flat_dt_is_compatible(node, "samsung,mfc-v6")) {
>
>
> Might be worth to change it to
>
> if (!of_flat_dt_is_compatible(node, "samsung,mfc-v6"))
> return 0;
>
> and avoid indentation.
>
>> + prop = of_get_flat_dt_prop(node, "samsung,mfc-l",&len);
>> + if (!prop)
>> + return 0;
>> + mfc_mem->loff = of_read_ulong(prop, len/4);
>> +
>> + prop = of_get_flat_dt_prop(node,
>> "samsung,mfc-l-size",&len);
>> + if (!prop)
>> + return 0;
>> + mfc_mem->lsize = of_read_ulong(prop, len/4);
>> +
>> + prop = of_get_flat_dt_prop(node, "samsung,mfc-r",&len);
>> + if (!prop)
>> + return 0;
>> + mfc_mem->roff = of_read_ulong(prop, len/4);
>> +
>> + prop = of_get_flat_dt_prop(node,
>> "samsung,mfc-r-size",&len);
>> + if (!prop)
>> + return 0;
>> + mfc_mem->rsize = of_read_ulong(prop, len/4);
>> +
>> + return 1;
>> + }
>> + return 0;
>> +}
>
>
> --
> Regards,
> Sylwester
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc"
> in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next reply other threads:[~2012-09-13 4:22 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-13 4:22 Arun Kumar K [this message]
-- strict thread matches above, loose matches on Subject: below --
2012-09-12 13:34 [PATCH v2] Add MFC device tree support Arun Kumar K
2012-09-12 13:34 ` [PATCH v2] ARM: EXYNOS: " Arun Kumar K
2012-09-12 20:24 ` Sylwester Nawrocki
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=8407236.410361347510128765.JavaMail.weblogic@epml14 \
--to=arun.kk@samsung.com \
--cc=ch.naveen@samsung.com \
--cc=devicetree-discuss@lists.ozlabs.org \
--cc=joshi@samsung.com \
--cc=jtp.park@samsung.com \
--cc=k.debski@samsung.com \
--cc=k.lewandowsk@samsung.com \
--cc=kgene.kim@samsung.com \
--cc=linux-samsung-soc@vger.kernel.org \
--cc=sylvester.nawrocki@gmail.com \
--cc=thomas.abraham@linaro.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).