Re: [PATCH] regmap: make range check functions static
From: Mark Brown
Date: Tue Apr 12 2022 - 08:56:47 EST
On Mon, Apr 11, 2022 at 05:59:33PM +0300, Andy Shevchenko wrote:
> On Wed, Mar 30, 2022 at 11:17 PM Mark Brown <broonie@xxxxxxxxxx> wrote:
> > On Tue, Mar 29, 2022 at 12:56:28AM +0200, Rasmus Villemoes wrote:
> > > regmap_reg_in_ranges() and regmap_check_range_table() have no callers
> > > outside regmap.c, so they have no reason to be exported nor have
> > > external linkage.
> > These are intentional API in case someone needs them, no need to
> > encourage open coding.
> But currently it's not used and simply consumes namespace resources.
> Isn't it our practice not to add dead code / etc?
> In practice I assume that one will grep before implementing, or at
> least at review stage it may be pointed out for a helper, that might
> be exported when needed, no?
Or they'll just look at it and think there must be some good reason
they're missing, or that having to deal with cross tree issues is too
much pain and just open code stuff. It's not insurmountable but there
is a clarity and usability benefit here.
Attachment:
signature.asc
Description: PGP signature