Re: [PATCH][V4] lib: fix __sysfs_match_string() helper when n != -1

2019-06-26 Thread Ardelean, Alexandru
On Tue, 2019-06-25 at 12:42 -0700, Andrew Morton wrote: > [External] > > > On Tue, 25 Jun 2019 16:28:12 +0300 Andy Shevchenko > wrote: > > > On Tue, Jun 25, 2019 at 04:01:04PM +0300, Alexandru Ardelean wrote: > > > The documentation the `__sysfs_match_string()` helper mentions that `n` > > >

Re: [PATCH][V4] lib: fix __sysfs_match_string() helper when n != -1

2019-06-25 Thread Andrew Morton
On Tue, 25 Jun 2019 16:28:12 +0300 Andy Shevchenko wrote: > On Tue, Jun 25, 2019 at 04:01:04PM +0300, Alexandru Ardelean wrote: > > The documentation the `__sysfs_match_string()` helper mentions that `n` > > (the size of the given array) should be: > > * @n: number of strings in the array or

[PATCH][V4] lib: fix __sysfs_match_string() helper when n != -1

2019-06-25 Thread Alexandru Ardelean
The documentation the `__sysfs_match_string()` helper mentions that `n` (the size of the given array) should be: * @n: number of strings in the array or -1 for NULL terminated arrays The behavior of the function is different, in the sense that it exits on the first NULL element in the array.

Re: [PATCH][V4] lib: fix __sysfs_match_string() helper when n != -1

2019-06-25 Thread Andy Shevchenko
On Tue, Jun 25, 2019 at 04:01:04PM +0300, Alexandru Ardelean wrote: > The documentation the `__sysfs_match_string()` helper mentions that `n` > (the size of the given array) should be: > * @n: number of strings in the array or -1 for NULL terminated arrays > > The behavior of the function is