[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201020092031.GD4077@smile.fi.intel.com>
Date: Tue, 20 Oct 2020 12:20:31 +0300
From: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To: Daniel Scally <djrscally@...il.com>
Cc: linux-kernel@...r.kernel.org, linux-media@...r.kernel.org,
linux.walleij@...aro.org, prabhakar.mahadev-lad.rj@...renesas.com,
heikki.krogerus@...ux.intel.com, dmitry.torokhov@...il.com,
laurent.pinchart+renesas@...asonboard.com,
kieran.bingham+renesas@...asonboard.com, jacopo+renesas@...ndi.org,
robh@...nel.org, davem@...emloft.net, linux@...musvillemoes.dk,
sergey.senozhatsky@...il.com, rostedt@...dmis.org,
pmladek@...e.com, mchehab@...nel.org, tian.shu.qiu@...el.com,
bingbu.cao@...el.com, sakari.ailus@...ux.intel.com,
yong.zhi@...el.com, rafael@...nel.org, gregkh@...uxfoundation.org,
kitakar@...il.com, dan.carpenter@...cle.org
Subject: Re: [RFC PATCH v3 2/9] lib/test_printf.c: Use helper function to
unwind array of software_nodes
On Mon, Oct 19, 2020 at 11:58:56PM +0100, Daniel Scally wrote:
> Use the new software_node_unregister_nodes_reverse() function to
> unwind this array in a cleaner way.
Reviewed-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
> Suggested-by: Andriy Shevchenko <andriy.shevchenko@...ux.intel.com>
> Signed-off-by: Daniel Scally <djrscally@...il.com>
> ---
> Changes in v3:
> - patch introduced.
>
> lib/test_printf.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/lib/test_printf.c b/lib/test_printf.c
> index 7ac87f18a..c63365570 100644
> --- a/lib/test_printf.c
> +++ b/lib/test_printf.c
> @@ -644,9 +644,7 @@ static void __init fwnode_pointer(void)
> test(second_name, "%pfwP", software_node_fwnode(&softnodes[1]));
> test(third_name, "%pfwP", software_node_fwnode(&softnodes[2]));
>
> - software_node_unregister(&softnodes[2]);
> - software_node_unregister(&softnodes[1]);
> - software_node_unregister(&softnodes[0]);
> + software_node_unregister_nodes_reverse(softnodes);
> }
>
> static void __init
> --
> 2.17.1
>
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists