* [PATCH] of/unittest: Swap arguments of of_unittest_apply_overlay()
@ 2017-01-19 10:06 Alexander Sverdlin
[not found] ` <20170119100616.4679-1-alexander.sverdlin-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org>
0 siblings, 1 reply; 2+ messages in thread
From: Alexander Sverdlin @ 2017-01-19 10:06 UTC (permalink / raw)
Cc: Alexander Sverdlin, Rob Herring, Frank Rowand,
devicetree-u79uwXL29TY76Z2rM5mHXA
Function signature
of_unittest_apply_overlay(int unittest_nr, int overlay_nr, ...
and call sites, like in of_unittest_apply_overlay_check():
ret = of_unittest_apply_overlay(overlay_nr, unittest_nr, ...
do not match. Fix this in one place (function signature).
The only affected test case is 15, which supplies non-existing
overlay number 16, but two bugs matched here. Fix the test case.
Signed-off-by: Alexander Sverdlin <alexander.sverdlin-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org>
Cc: Rob Herring <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Cc: Frank Rowand <frowand.list-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
---
drivers/of/unittest.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/of/unittest.c b/drivers/of/unittest.c
index 53c83d66eb7e..66bfa8d674ce 100644
--- a/drivers/of/unittest.c
+++ b/drivers/of/unittest.c
@@ -1181,7 +1181,7 @@ static void of_unittest_destroy_tracked_overlays(void)
} while (defers > 0);
}
-static int of_unittest_apply_overlay(int unittest_nr, int overlay_nr,
+static int of_unittest_apply_overlay(int overlay_nr, int unittest_nr,
int *overlay_id)
{
struct device_node *np = NULL;
@@ -1840,7 +1840,7 @@ static void of_unittest_overlay_i2c_15(void)
int ret;
/* device should enable */
- ret = of_unittest_apply_overlay_check(16, 15, 0, 1, I2C_OVERLAY);
+ ret = of_unittest_apply_overlay_check(15, 15, 0, 1, I2C_OVERLAY);
if (ret != 0)
return;
--
2.11.0
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] of/unittest: Swap arguments of of_unittest_apply_overlay()
[not found] ` <20170119100616.4679-1-alexander.sverdlin-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org>
@ 2017-02-09 15:12 ` Rob Herring
0 siblings, 0 replies; 2+ messages in thread
From: Rob Herring @ 2017-02-09 15:12 UTC (permalink / raw)
To: Alexander Sverdlin
Cc: Frank Rowand, devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
On Thu, Jan 19, 2017 at 4:06 AM, Alexander Sverdlin
<alexander.sverdlin-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org> wrote:
> Function signature
>
> of_unittest_apply_overlay(int unittest_nr, int overlay_nr, ...
>
> and call sites, like in of_unittest_apply_overlay_check():
>
> ret = of_unittest_apply_overlay(overlay_nr, unittest_nr, ...
>
> do not match. Fix this in one place (function signature).
> The only affected test case is 15, which supplies non-existing
> overlay number 16, but two bugs matched here. Fix the test case.
>
> Signed-off-by: Alexander Sverdlin <alexander.sverdlin-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org>
> Cc: Rob Herring <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
> Cc: Frank Rowand <frowand.list-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
> Cc: devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
> ---
> drivers/of/unittest.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
Applied, thanks.
Rob
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-02-09 15:12 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-19 10:06 [PATCH] of/unittest: Swap arguments of of_unittest_apply_overlay() Alexander Sverdlin
[not found] ` <20170119100616.4679-1-alexander.sverdlin-xNZwKgViW5gAvxtiuMwx3w@public.gmane.org>
2017-02-09 15:12 ` Rob Herring
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).