]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
power: supply: smb347: convert to use maple tree register cache
authorBo Liu <liubo03@inspur.com>
Fri, 28 Feb 2025 08:02:36 +0000 (03:02 -0500)
committerSebastian Reichel <sebastian.reichel@collabora.com>
Sat, 8 Mar 2025 00:30:54 +0000 (01:30 +0100)
The maple tree register cache is based on a much more modern data structure
than the rbtree cache and makes optimisation choices which are probably
more appropriate for modern systems than those made by the rbtree cache.

Signed-off-by: Bo Liu <liubo03@inspur.com>
Link: https://lore.kernel.org/r/20250228080236.2759-10-liubo03@inspur.com
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
drivers/power/supply/smb347-charger.c

index c8392933ee285255438a78f5bbd9429f9f1c6764..75ad3bb16ac8ab2491277267bd233249f220fffd 100644 (file)
@@ -1488,7 +1488,7 @@ static const struct regmap_config smb347_regmap = {
        .max_register   = SMB347_MAX_REGISTER,
        .volatile_reg   = smb347_volatile_reg,
        .readable_reg   = smb347_readable_reg,
-       .cache_type     = REGCACHE_RBTREE,
+       .cache_type     = REGCACHE_MAPLE,
 };
 
 static const struct regulator_ops smb347_usb_vbus_regulator_ops = {