Applied "regmap: Introduce max_raw_read/write for regmap_bulk_read/write" to the regmap tree
Subsystems (2)
Mark Brown
maintainerThe patch
regmap: Introduce max_raw_read/write for regmap_bulk_read/write
has been applied to the regmap tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap.git
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark
Quoted 1 line
From
9e86b69c3021148d1668db582d3cb3c0c398d001Mon Sep 17 00:00:00 2001
From: Markus Pargmann <[email protected]>
Date: Thu, 27 Aug 2015 08:44:29 +0200
Subject: [PATCH] regmap: Introduce max_raw_read/write for
regmap_bulk_read/write
There are some buses which have a limit on the maximum number of bytes that can be send/received. An example for this is I2C_FUNC_SMBUS_I2C_BLOCK which does not support any reads/writes of more than 32 bytes. The regmap_bulk operations should still be able to utilize the full 32 bytes in this case.
--- drivers/base/regmap/internal.h | 4 ++ drivers/base/regmap/regmap.c | 85 ++++++++++++++++++++++++++++++++++-------- include/linux/regmap.h | 4 ++ 3 files changed, 78 insertions(+), 15 deletions(-)
drivers/base/regmap/internal.h +4 -0
@@ -146,6 +146,10 @@ struct regmap {/* if set, the device supports multi write mode */ bool can_multi_write; +/* if set, raw reads/writes are limited to this size */ +size_t max_raw_read; +size_t max_raw_write; +struct rb_root range_tree;void *selector_work_buf;/* Scratch buffer used for selector */ };
drivers/base/regmap/regmap.c +70 -15
118 lines not on this page · raw message
include/linux/regmap.h +4 -0
@@ -311,6 +311,8 @@ typedef void (*regmap_hw_free_context)(void *context);* @val_format_endian_default: Default endianness for formatted register * values. Used when the regmap_config specifies DEFAULT. If this is * DEFAULT, BIG is assumed. +* @max_raw_read: Max raw read size that can be used on the bus. +* @max_raw_write: Max raw write size that can be used on the bus. */ struct regmap_bus {bool fast_io;
@@ -325,6 +327,8 @@ struct regmap_bus {u8 read_flag_mask;enum regmap_endian reg_format_endian_default;enum regmap_endian val_format_endian_default; +size_t max_raw_read; +size_t max_raw_write; }; struct regmap *regmap_init(struct device *dev,
Signature · 1 line
2.5.0