From: Javier Martinez Canillas <javier@dowhile0.org> To: Sylwester Nawrocki <s.nawrocki@samsung.com> Cc: Javier Martinez Canillas <javier@osg.samsung.com>, Linux Kernel <linux-kernel@vger.kernel.org>, Kukjin Kim <kgene@kernel.org>, Mauro Carvalho Chehab <mchehab@osg.samsung.com>, "linux-samsung-soc@vger.kernel.org" <linux-samsung-soc@vger.kernel.org>, Kyungmin Park <kyungmin.park@samsung.com>, Krzysztof Kozlowski <k.kozlowski@samsung.com>, "linux-arm-kernel@lists.infradead.org" <linux-arm-kernel@lists.infradead.org>, Linux Media Mailing List <linux-media@vger.kernel.org> Subject: Re: [PATCH 2/2] [media] exynos4-is: FIMC port parse should fail if there's no endpoint Date: Fri, 11 Mar 2016 11:55:58 -0300 [thread overview] Message-ID: <CABxcv=nteCTgaN9t33vOovXoHarMXf_knxjTUfV+G36iQs8AGQ@mail.gmail.com> (raw) In-Reply-To: <56E2C206.6020103@samsung.com> Hello Sylwester, On Fri, Mar 11, 2016 at 10:03 AM, Sylwester Nawrocki <s.nawrocki@samsung.com> wrote: > On 03/04/2016 09:20 PM, Javier Martinez Canillas wrote: >> The fimc_md_parse_port_node() function return 0 if an endpoint node is >> not found but according to Documentation/devicetree/bindings/graph.txt, >> a port must always have at least one enpoint. >> >> So return an -EINVAL errno code to the caller instead, so it knows that >> the port node parse failed due an invalid Device Tree description. > > I don't think it is forbidden to have a port node in device tree > containing no endpoint nodes. Empty port node means only that, > for example, a subsystem has a port/bus for connecting external > devices but nothing is actually connected to it. > That's not what I understood by reading both Documentation/devicetree/bindings/media/video-interfaces.txt and Documentation/devicetree/bindings/graph.txt but maybe these are not that clear about it or I just failed to parse the english. > In case of Exynos CSIS it might not be so useful to have an empty > port node specified in some top level *.dtsi file and only > the endpoints specified in a board specific dts file. Nevertheless, > I wouldn't be saying in general a port node must always have some > endpoint node defined. > Ok, but if that is valid then I believe that at the very least Documentation/devicetree/bindings/media/samsung-fimc.txt should explicitly mention which (sub)nodes are optional and which are required so the DT parsing logic could follow what's documented there. > I could apply this patch as it doesn't do any harm considering > existing dts files in the kernel tree (arch/arm/boot/dts/ > exynos4412-trats2.dts), but the commit description would need to > be changed. > I don't mind if you want to change the commit message but if those nodes are really optional then a follow-up should be to update the DT binding docs to make that clear IMHO. > -- > Thanks, > Sylwester > -- Best regards, Javier
WARNING: multiple messages have this Message-ID (diff)
From: javier@dowhile0.org (Javier Martinez Canillas) To: linux-arm-kernel@lists.infradead.org Subject: [PATCH 2/2] [media] exynos4-is: FIMC port parse should fail if there's no endpoint Date: Fri, 11 Mar 2016 11:55:58 -0300 [thread overview] Message-ID: <CABxcv=nteCTgaN9t33vOovXoHarMXf_knxjTUfV+G36iQs8AGQ@mail.gmail.com> (raw) In-Reply-To: <56E2C206.6020103@samsung.com> Hello Sylwester, On Fri, Mar 11, 2016 at 10:03 AM, Sylwester Nawrocki <s.nawrocki@samsung.com> wrote: > On 03/04/2016 09:20 PM, Javier Martinez Canillas wrote: >> The fimc_md_parse_port_node() function return 0 if an endpoint node is >> not found but according to Documentation/devicetree/bindings/graph.txt, >> a port must always have at least one enpoint. >> >> So return an -EINVAL errno code to the caller instead, so it knows that >> the port node parse failed due an invalid Device Tree description. > > I don't think it is forbidden to have a port node in device tree > containing no endpoint nodes. Empty port node means only that, > for example, a subsystem has a port/bus for connecting external > devices but nothing is actually connected to it. > That's not what I understood by reading both Documentation/devicetree/bindings/media/video-interfaces.txt and Documentation/devicetree/bindings/graph.txt but maybe these are not that clear about it or I just failed to parse the english. > In case of Exynos CSIS it might not be so useful to have an empty > port node specified in some top level *.dtsi file and only > the endpoints specified in a board specific dts file. Nevertheless, > I wouldn't be saying in general a port node must always have some > endpoint node defined. > Ok, but if that is valid then I believe that at the very least Documentation/devicetree/bindings/media/samsung-fimc.txt should explicitly mention which (sub)nodes are optional and which are required so the DT parsing logic could follow what's documented there. > I could apply this patch as it doesn't do any harm considering > existing dts files in the kernel tree (arch/arm/boot/dts/ > exynos4412-trats2.dts), but the commit description would need to > be changed. > I don't mind if you want to change the commit message but if those nodes are really optional then a follow-up should be to update the DT binding docs to make that clear IMHO. > -- > Thanks, > Sylwester > -- Best regards, Javier
next prev parent reply other threads:[~2016-03-11 14:56 UTC|newest] Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top 2016-03-04 20:20 [PATCH 0/2] [media] exynos4-is: Trivial fixes for DT port/endpoint parse logic Javier Martinez Canillas 2016-03-04 20:20 ` Javier Martinez Canillas 2016-03-04 20:20 ` [PATCH 1/2] [media] exynos4-is: Put node before s5pcsis_parse_dt() return error Javier Martinez Canillas 2016-03-04 20:20 ` Javier Martinez Canillas 2016-03-04 20:20 ` [PATCH 2/2] [media] exynos4-is: FIMC port parse should fail if there's no endpoint Javier Martinez Canillas 2016-03-04 20:20 ` Javier Martinez Canillas 2016-03-11 13:03 ` Sylwester Nawrocki 2016-03-11 13:03 ` Sylwester Nawrocki 2016-03-11 14:55 ` Javier Martinez Canillas [this message] 2016-03-11 14:55 ` Javier Martinez Canillas 2016-03-11 14:55 ` Javier Martinez Canillas 2016-03-22 20:19 ` Javier Martinez Canillas 2016-03-22 20:19 ` Javier Martinez Canillas 2016-03-05 4:35 ` [PATCH 0/2] [media] exynos4-is: Trivial fixes for DT port/endpoint parse logic Krzysztof Kozlowski 2016-03-05 4:35 ` Krzysztof Kozlowski 2016-03-07 9:24 ` Sylwester Nawrocki 2016-03-07 9:24 ` Sylwester Nawrocki 2016-03-07 9:24 ` Sylwester Nawrocki 2016-03-07 14:30 ` Javier Martinez Canillas 2016-03-07 14:30 ` Javier Martinez Canillas 2016-03-11 13:09 ` Sylwester Nawrocki 2016-03-11 13:09 ` Sylwester Nawrocki 2016-03-11 14:39 ` Javier Martinez Canillas 2016-03-11 14:39 ` Javier Martinez Canillas 2016-03-11 14:39 ` Javier Martinez Canillas
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='CABxcv=nteCTgaN9t33vOovXoHarMXf_knxjTUfV+G36iQs8AGQ@mail.gmail.com' \ --to=javier@dowhile0.org \ --cc=javier@osg.samsung.com \ --cc=k.kozlowski@samsung.com \ --cc=kgene@kernel.org \ --cc=kyungmin.park@samsung.com \ --cc=linux-arm-kernel@lists.infradead.org \ --cc=linux-kernel@vger.kernel.org \ --cc=linux-media@vger.kernel.org \ --cc=linux-samsung-soc@vger.kernel.org \ --cc=mchehab@osg.samsung.com \ --cc=s.nawrocki@samsung.com \ /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: linkBe 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.