public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mfd: bd96801: Use maple tree register cache
@ 2024-09-24 16:22 Mark Brown
  2024-09-25  4:57 ` Matti Vaittinen
  2024-10-09 10:23 ` (subset) " Lee Jones
  0 siblings, 2 replies; 4+ messages in thread
From: Mark Brown @ 2024-09-24 16:22 UTC (permalink / raw)
  To: Matti Vaittinen, Lee Jones; +Cc: linux-kernel, Mark Brown

The maple tree register cache uses a more modern data structure than the
rbtree cache and makes implementation decisions more suited to modern
hardware, switch the bd96801 driver to it to take advantage of this newer
code. No functional changes.

Signed-off-by: Mark Brown <broonie@kernel.org>
---
 drivers/mfd/rohm-bd96801.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mfd/rohm-bd96801.c b/drivers/mfd/rohm-bd96801.c
index 714f08ed544b..f118e63d9b7d 100644
--- a/drivers/mfd/rohm-bd96801.c
+++ b/drivers/mfd/rohm-bd96801.c
@@ -194,7 +194,7 @@ static const struct regmap_config bd96801_regmap_config = {
 	.reg_bits = 8,
 	.val_bits = 8,
 	.volatile_table = &volatile_regs,
-	.cache_type = REGCACHE_RBTREE,
+	.cache_type = REGCACHE_MAPLE,
 };
 
 static int bd96801_i2c_probe(struct i2c_client *i2c)

---
base-commit: 98f7e32f20d28ec452afb208f9cffc08448a2652
change-id: 20240924-mfd-bd96801-maple-cc2e58f891b5

Best regards,
-- 
Mark Brown <broonie@kernel.org>


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] mfd: bd96801: Use maple tree register cache
  2024-09-24 16:22 [PATCH] mfd: bd96801: Use maple tree register cache Mark Brown
@ 2024-09-25  4:57 ` Matti Vaittinen
  2024-09-25  8:07   ` Mark Brown
  2024-10-09 10:23 ` (subset) " Lee Jones
  1 sibling, 1 reply; 4+ messages in thread
From: Matti Vaittinen @ 2024-09-25  4:57 UTC (permalink / raw)
  To: Mark Brown, Lee Jones; +Cc: linux-kernel

Hi Mark,

On 9/24/24 19:22, Mark Brown wrote:
> The maple tree register cache uses a more modern data structure than the
> rbtree cache and makes implementation decisions more suited to modern
> hardware, switch the bd96801 driver to it to take advantage of this newer
> code. No functional changes.
> 
> Signed-off-by: Mark Brown <broonie@kernel.org>

Reviewed-by: Matti Vaittinen <mazziesaccount@gmail.com>

Thanks! So, I should have used maple tree with regmap instead of the 
rbtree when sending this... Do you know, is there any occasion where the 
rbtree would be better?

As a unrelated thing - seems like you've made it safely back from the 
LPC. It was nice finally meeting you :)

Yours,
	-- Matti

-- 
Matti Vaittinen
Linux kernel developer at ROHM Semiconductors
Oulu Finland

~~ When things go utterly wrong vim users can always type :help! ~~


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] mfd: bd96801: Use maple tree register cache
  2024-09-25  4:57 ` Matti Vaittinen
@ 2024-09-25  8:07   ` Mark Brown
  0 siblings, 0 replies; 4+ messages in thread
From: Mark Brown @ 2024-09-25  8:07 UTC (permalink / raw)
  To: Matti Vaittinen; +Cc: Lee Jones, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 660 bytes --]

On Wed, Sep 25, 2024 at 07:57:46AM +0300, Matti Vaittinen wrote:

> Thanks! So, I should have used maple tree with regmap instead of the rbtree
> when sending this... Do you know, is there any occasion where the rbtree
> would be better?

rbtree stores in device native format so large syncs might be more
efficient, we can just send directly from the buffer.  This could be a
good tradeoff for larger syncs running on slower CPUs but it's probably
pretty marginal.

> As a unrelated thing - seems like you've made it safely back from the LPC.
> It was nice finally meeting you :)

Actually in Paris for Kernel Recipies so not quite but yes, good to meet
you!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: (subset) [PATCH] mfd: bd96801: Use maple tree register cache
  2024-09-24 16:22 [PATCH] mfd: bd96801: Use maple tree register cache Mark Brown
  2024-09-25  4:57 ` Matti Vaittinen
@ 2024-10-09 10:23 ` Lee Jones
  1 sibling, 0 replies; 4+ messages in thread
From: Lee Jones @ 2024-10-09 10:23 UTC (permalink / raw)
  To: Matti Vaittinen, Lee Jones, Mark Brown; +Cc: linux-kernel

On Tue, 24 Sep 2024 18:22:04 +0200, Mark Brown wrote:
> The maple tree register cache uses a more modern data structure than the
> rbtree cache and makes implementation decisions more suited to modern
> hardware, switch the bd96801 driver to it to take advantage of this newer
> code. No functional changes.
> 
> 

Applied, thanks!

[1/1] mfd: bd96801: Use maple tree register cache
      commit: f8e7a05154d0fe3e977e1cbfdc43657cebd560ef

--
Lee Jones [李琼斯]


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-10-09 10:23 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-24 16:22 [PATCH] mfd: bd96801: Use maple tree register cache Mark Brown
2024-09-25  4:57 ` Matti Vaittinen
2024-09-25  8:07   ` Mark Brown
2024-10-09 10:23 ` (subset) " Lee Jones

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox