Re: [RESEND PATCH 1/1] of: Make return types of to_of_node and of_fwnode_handle macros consistent

2017-11-06 Thread Rob Herring
On Thu, Nov 02, 2017 at 11:59:18AM +0200, Sakari Ailus wrote: > (Fixed Mauro's e-mail.) > > to_of_node() macro checks whether the fwnode_handle passed to it is not an > OF node, and if so, returns NULL in order to be NULL-safe. Otherwise it > returns the pointer to the OF node which the

Re: [RESEND PATCH 1/1] of: Make return types of to_of_node and of_fwnode_handle macros consistent

2017-11-02 Thread Laurent Pinchart
Hi Sakari, Thank you for the patch. On Thursday, 2 November 2017 11:59:18 EET Sakari Ailus wrote: > (Fixed Mauro's e-mail.) > > to_of_node() macro checks whether the fwnode_handle passed to it is not an > OF node, and if so, returns NULL in order to be NULL-safe. Otherwise it > returns the

[RESEND PATCH 1/1] of: Make return types of to_of_node and of_fwnode_handle macros consistent

2017-11-02 Thread Sakari Ailus
(Fixed Mauro's e-mail.) to_of_node() macro checks whether the fwnode_handle passed to it is not an OF node, and if so, returns NULL in order to be NULL-safe. Otherwise it returns the pointer to the OF node which the fwnode_handle contains. The problem with returning NULL is that its type was

[PATCH 1/1] of: Make return types of to_of_node and of_fwnode_handle macros consistent

2017-11-02 Thread Sakari Ailus
to_of_node() macro checks whether the fwnode_handle passed to it is not an OF node, and if so, returns NULL in order to be NULL-safe. Otherwise it returns the pointer to the OF node which the fwnode_handle contains. The problem with returning NULL is that its type was void *, which sometimes