Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

tty: serial: max310x: convert to use maple tree register cache

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: wangkaiyuan <wangkaiyuan@inspur.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20240318064036.1656-1-wangkaiyuan@inspur.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

wangkaiyuan and committed by
Greg Kroah-Hartman
c9615d34 0867a980

+2 -2
+2 -2
drivers/tty/serial/max310x.c
··· 1473 1473 .reg_bits = 8, 1474 1474 .val_bits = 8, 1475 1475 .write_flag_mask = MAX310X_WRITE_BIT, 1476 - .cache_type = REGCACHE_RBTREE, 1476 + .cache_type = REGCACHE_MAPLE, 1477 1477 .max_register = MAX310X_REG_1F, 1478 1478 .writeable_reg = max310x_reg_writeable, 1479 1479 .volatile_reg = max310x_reg_volatile, ··· 1577 1577 static struct regmap_config regcfg_i2c = { 1578 1578 .reg_bits = 8, 1579 1579 .val_bits = 8, 1580 - .cache_type = REGCACHE_RBTREE, 1580 + .cache_type = REGCACHE_MAPLE, 1581 1581 .writeable_reg = max310x_reg_writeable, 1582 1582 .volatile_reg = max310x_reg_volatile, 1583 1583 .precious_reg = max310x_reg_precious,