Re: [RFC PATCH 01/14] devres: Add devm_of_iomap()

2018-06-29 Thread Benjamin Herrenschmidt
On Fri, 2018-06-29 at 23:27 +0300, Andy Shevchenko wrote: > On Fri, Jun 29, 2018 at 12:14 PM, Linus Walleij > wrote: > > > I wonder if it is easy to find these cases and replace them with > > this neat function... > > Would be reasonable easy by using coccinelle. For the obvious ones yes. A

Re: [RFC PATCH 01/14] devres: Add devm_of_iomap()

2018-06-29 Thread Benjamin Herrenschmidt
On Fri, 2018-06-29 at 23:27 +0300, Andy Shevchenko wrote: > On Fri, Jun 29, 2018 at 12:14 PM, Linus Walleij > wrote: > > > I wonder if it is easy to find these cases and replace them with > > this neat function... > > Would be reasonable easy by using coccinelle. For the obvious ones yes. A

Re: [RFC PATCH 01/14] devres: Add devm_of_iomap()

2018-06-29 Thread Andy Shevchenko
On Fri, Jun 29, 2018 at 12:14 PM, Linus Walleij wrote: > I wonder if it is easy to find these cases and replace them with > this neat function... Would be reasonable easy by using coccinelle. -- With Best Regards, Andy Shevchenko

Re: [RFC PATCH 01/14] devres: Add devm_of_iomap()

2018-06-29 Thread Andy Shevchenko
On Fri, Jun 29, 2018 at 12:14 PM, Linus Walleij wrote: > I wonder if it is easy to find these cases and replace them with > this neat function... Would be reasonable easy by using coccinelle. -- With Best Regards, Andy Shevchenko

Re: [RFC PATCH 01/14] devres: Add devm_of_iomap()

2018-06-29 Thread Linus Walleij
On Fri, Jun 22, 2018 at 6:31 AM Benjamin Herrenschmidt wrote: > There are still quite a few cases where a device might want > to get to a different node of the device-tree, obtain the > resources and map them. > > We have of_iomap() and of_io_request_and_map() but they both > have shortcomings,

Re: [RFC PATCH 01/14] devres: Add devm_of_iomap()

2018-06-29 Thread Linus Walleij
On Fri, Jun 22, 2018 at 6:31 AM Benjamin Herrenschmidt wrote: > There are still quite a few cases where a device might want > to get to a different node of the device-tree, obtain the > resources and map them. > > We have of_iomap() and of_io_request_and_map() but they both > have shortcomings,

[RFC PATCH 01/14] devres: Add devm_of_iomap()

2018-06-21 Thread Benjamin Herrenschmidt
There are still quite a few cases where a device might want to get to a different node of the device-tree, obtain the resources and map them. We have of_iomap() and of_io_request_and_map() but they both have shortcomings, such as not returning the size of the resource found (which can be useful)

[RFC PATCH 01/14] devres: Add devm_of_iomap()

2018-06-21 Thread Benjamin Herrenschmidt
There are still quite a few cases where a device might want to get to a different node of the device-tree, obtain the resources and map them. We have of_iomap() and of_io_request_and_map() but they both have shortcomings, such as not returning the size of the resource found (which can be useful)