mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/0] regmap: drop cache if the bus transfer error
@ 2016-08-18  9:01 Elaine Zhang
  2016-08-18  9:01 ` [PATCH 0/1] " Elaine Zhang
  2016-08-18  9:42 ` [PATCH 0/0] " Mark Brown
  0 siblings, 2 replies; 4+ messages in thread
From: Elaine Zhang @ 2016-08-18  9:01 UTC (permalink / raw)
  To: broonie; +Cc: huangtao, zyw, xxx, jay.xu, linux-kernel, Elaine Zhang

regmap_write
    ->_regmap_raw_write
    -->regcache_write first and than use map->bus->write to wirte i2c or spi
    But if the i2c or spi transfer failed, But the cache is updated, So if I use
    regmap_read will get the cache data which is not the real register value.

I think the regmap should handle that gracefully,
and may be my modify is not the best way.
But as I described is how to slove that problem.

Elaine Zhang (1):
  regmap: drop cache if the bus transfer error

 drivers/base/regmap/regmap.c | 2 ++
 1 file changed, 2 insertions(+)

-- 
1.9.1

^ permalink raw reply	[flat|nested] 4+ messages in thread
* [PATCH 0/0] regmap: drop cache if the bus transfer error
@ 2016-08-18  6:43 Elaine Zhang
  2016-08-18  6:43 ` [PATCH 0/1] " Elaine Zhang
  0 siblings, 1 reply; 4+ messages in thread
From: Elaine Zhang @ 2016-08-18  6:43 UTC (permalink / raw)
  To: heiko; +Cc: huangtao, zyw, xxx, jay.xu, linux-kernel, Elaine Zhang

regmap_write
    ->_regmap_raw_write
    -->regcache_write first and than use map->bus->write to wirte i2c or spi
    But if the i2c or spi transfer failed, But the cache is updated, So if I use
    regmap_read will get the cache data which is not the real register value.

I think the regmap should handle that gracefully,
and may be my modify is not the best way.
But as I described is how to slove that problem.

Elaine Zhang (1):
  regmap: drop cache if the bus transfer error

 drivers/base/regmap/regmap.c | 2 ++
 1 file changed, 2 insertions(+)

-- 
1.9.1

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

end of thread, other threads:[~2016-08-18  9:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-18  9:01 [PATCH 0/0] regmap: drop cache if the bus transfer error Elaine Zhang
2016-08-18  9:01 ` [PATCH 0/1] " Elaine Zhang
2016-08-18  9:42 ` [PATCH 0/0] " Mark Brown
  -- strict thread matches above, loose matches on Subject: below --
2016-08-18  6:43 Elaine Zhang
2016-08-18  6:43 ` [PATCH 0/1] " Elaine Zhang

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

all inboxes | Powered by JetHome®