1. 16 12月, 2014 1 次提交
  2. 12 9月, 2014 1 次提交
  3. 26 8月, 2014 1 次提交
    • L
      regmap: Fix regcache debugfs initialization · 5e0cbe78
      Lars-Peter Clausen 提交于
      Commit 6cfec04b ("regmap: Separate regmap dev initialization") moved the
      regmap debugfs initialization after regcache initialization. This means
      that the regmap debugfs directory is not created yet when the cache
      initialization runs and so any debugfs files registered by the regcache are
      created in the debugfs root directory rather than the debugfs directory of
      the regmap instance. Fix this by adding a separate callback for the
      regcache debugfs initialization which will be called after the parent
      debugfs entry has been created.
      
      Fixes: 6cfec04b (regmap: Separate regmap dev initialization)
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      Cc: stable@vger.kernel.org
      5e0cbe78
  4. 11 3月, 2014 1 次提交
  5. 09 10月, 2013 1 次提交
  6. 08 10月, 2013 1 次提交
  7. 17 9月, 2013 1 次提交
    • K
      regmap: Add regmap_fields APIs · a0102375
      Kuninori Morimoto 提交于
      Current Linux kernel is supporting regmap_field method
      and it is very useful feature.
      It needs one regmap_filed for one register access.
      
      OTOH, there is multi port device which
      has many same registers in the market.
      The difference for each register access is
      only its address offset.
      
      Current API needs many regmap_field for such device,
      but it is not good.
      This patch adds new regmap_fileds API which can care
      about multi port/offset access via regmap.
      Signed-off-by: NKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      a0102375
  8. 29 8月, 2013 1 次提交
    • L
      regmap: rbtree: Make cache_present bitmap per node · 3f4ff561
      Lars-Peter Clausen 提交于
      With devices which have a dense and small register map but placed at a large
      offset the global cache_present bitmap imposes a huge memory overhead. Making
      the cache_present per rbtree node avoids the issue and easily reduces the memory
      footprint by a factor of ten. For devices with a more sparse map or without a
      large base register offset the memory usage might increase slightly by a few
      bytes, but not significantly. E.g. for a device which has ~50 registers at
      offset 0x4000 the memory footprint of the register cache goes down form 2496
      bytes to 175 bytes.
      
      Moving the bitmap to a per node basis means that the handling of the bitmap is
      now cache implementation specific and can no longer be managed by the core. The
      regcache_sync_block() function is extended by a additional parameter so that the
      cache implementation can tell the core which registers in the block are set and
      which are not. The parameter is optional and if NULL the core assumes that all
      registers are set. The rbtree cache also needs to implement its own drop
      callback instead of relying on the core to handle this.
      Signed-off-by: NLars-Peter Clausen <lars@metafoo.de>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      3f4ff561
  9. 09 8月, 2013 1 次提交
  10. 12 6月, 2013 1 次提交
    • S
      regmap: Add regmap_field APIs · 67252287
      Srinivas Kandagatla 提交于
      It is common to access regmap registers at bit level, using
      regmap_update_bits or regmap_read functions, however the end user has to
      take care of a mask or shifting. This becomes overhead when such use
      cases are high. Having a common function to do this is much convenient
      and less error prone.
      
      The idea of regmap_field is simple, regmap_field gives a logical
      structure to bits of the regmap register, and the driver can use this
      logical entity without the knowledge of the bit positions and masks all
      over the code. This way code looks much neat and it need not handle the
      masks, shifts every time it access the those entities.
      
      With this new regmap_field_read/write apis the end user can setup a
      regmap field using regmap_field_init and use the return regmap_field to
      read write the register field without worrying about the masks or
      shifts.
      
      Also this apis will be useful for drivers which are based on regmaps,
      like some clocks or pinctrls which can work on the regmap_fields
      directly without having to worry about bit positions.
      Signed-off-by: NSrinivas Kandagatla <srinivas.kandagatla@st.com>
      Signed-off-by: NMark Brown <broonie@linaro.org>
      67252287
  11. 25 5月, 2013 1 次提交
  12. 12 5月, 2013 1 次提交
  13. 30 3月, 2013 2 次提交
  14. 27 3月, 2013 2 次提交
  15. 04 3月, 2013 3 次提交
  16. 11 2月, 2013 1 次提交
  17. 29 1月, 2013 2 次提交
  18. 14 1月, 2013 2 次提交
  19. 02 1月, 2013 1 次提交
    • M
      regmap: flat: Add flat cache type · 2ac902ce
      Mark Brown 提交于
      While for I2C and SPI devices the overhead of using rbtree for devices with
      only one block of registers is negligible the same isn't always going to
      be true for MMIO devices where the I/O costs are very much lower. Cater
      for these devices by adding a simple flat array type for them where the
      lookups are simple array accesses, taking us right back to the original
      ASoC cache implementation.
      
      Thanks to Magnus Damm for the discussion which prompted this.
      Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
      2ac902ce
  20. 11 12月, 2012 1 次提交
    • M
      regmap: debugfs: Cache offsets of valid regions for dump · 5166b7c0
      Mark Brown 提交于
      Avoid doing a linear scan of the entire register map for each read() of
      the debugfs register dump by recording the offsets where valid registers
      exist when we first read the registers file. This assumes the set of
      valid registers never changes, if this is not the case invalidation of
      the cache will be required.
      
      This could be further improved for large blocks of contiguous registers
      by calculating the register we will read from within the block - currently
      we do a linear scan of the block. An rbtree may also be worthwhile.
      Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
      5166b7c0
  21. 06 12月, 2012 1 次提交
  22. 21 11月, 2012 1 次提交
  23. 17 10月, 2012 1 次提交
  24. 15 10月, 2012 2 次提交
  25. 18 6月, 2012 1 次提交
    • K
      regmap: Add support for register indirect addressing. · 6863ca62
      Krystian Garbaciak 提交于
      Devices with register paging or indirectly accessed registers can configure
      register mapping to map those on virtual address range. During access to
      virtually mapped register range, indirect addressing is processed
      automatically, in following steps:
        1. selector for page or indirect register is updated (when needed);
        2. register in data window is accessed.
      
      Configuration should provide minimum and maximum register for virtual range,
      details of selector field for page selection, minimum and maximum register of
      data window for indirect access.
      
      Virtual range registers are managed by cache as well as direct access
      registers. In order to make indirect access more efficient, selector register
      should be declared as non-volatile, if possible.
      
      struct regmap_config is extended with the following:
      struct regmap_range_cfg	*ranges;
      unsigned int		n_ranges;
      
      [Also reordered debugfs init to later on since the cleanup code was
      conflicting with the new cleanup code for ranges anyway -- broonie]
      Signed-off-by: NKrystian Garbaciak <krystian.garbaciak@diasemi.com>
      Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
      6863ca62
  26. 09 5月, 2012 1 次提交
  27. 01 5月, 2012 1 次提交
  28. 13 4月, 2012 6 次提交