Re: [PATCH 01/99] lib: Add option iterator

2023-03-07 Thread Thomas Zimmermann
Hi Am 06.03.23 um 23:37 schrieb Randy Dunlap: [...] + * + * The call to option_iter_init() initializes the iterator instance + * from the option string. The while loop walks over the individual + * options in the sting and returns each in the second argument. The + * returned memory is owned by

Re: [PATCH 01/99] lib: Add option iterator

2023-03-06 Thread Randy Dunlap
Hi, On 3/6/23 07:58, Thomas Zimmermann wrote: > Add struct option_iter and helpers that walk over individual options > of an option string. Add documentation. > > Kernel parameters often have the format of > > param=opt1,opt2:val,opt3 > > where the option string contains a number of comma-sep

[PATCH 01/99] lib: Add option iterator

2023-03-06 Thread Thomas Zimmermann
Add struct option_iter and helpers that walk over individual options of an option string. Add documentation. Kernel parameters often have the format of param=opt1,opt2:val,opt3 where the option string contains a number of comma-separated options. Drivers usually use strsep() in a loop to extra