# Re: \[PATCH v1 1/1\] treewide: Align match\_string() with sysfs\_match\_string()

- From: Jani Nikula \<jani.nikula@linux.intel.com\>
- Date: 2024-06-04 07:46:33 
- List: linux-fbdev
- Page: https://ratatoskr.run/linux-fbdev/2024/06/2624702
- Thread: https://ratatoskr.run/linuxppc-dev/2024/06/2624286/t.md

```text
On Sun, 02 Jun 2024, Andy Shevchenko [ref] wrote:
> Make two APIs look similar. Hence convert match_string() to be
> a 2-argument macro. In order to avoid unneeded churn, convert
> all users as well. There is no functional change intended.

Why do we think it's a good idea to increase and normalize the use of
double-underscore function names across the kernel, like
__match_string() in this case? It should mean "reserved for the
implementation, not to be called directly".

If it's to be used directly, it should be named accordingly, right?

Being in line with __sysfs_match_string() isn't a great argument alone,
because this adds three times the number of __match_string() calls than
there are __sysfs_match_string() calls. It's not a good model to follow.
Arguably both should be renamed.

BR,
Jani.


-- 
Jani Nikula, Intel
```
