Home
last modified time | relevance | path

Searched full:regmap (Results 1 – 25 of 2743) sorted by relevance

12345678910>>...110

/OK3568_Linux_fs/kernel/drivers/clk/at91/
H A Dclk-main.c11 #include <linux/regmap.h>
30 struct regmap *regmap; member
37 struct regmap *regmap; member
46 struct regmap *regmap; member
53 struct regmap *regmap; member
59 static inline bool clk_main_osc_ready(struct regmap *regmap) in clk_main_osc_ready() argument
63 regmap_read(regmap, AT91_PMC_SR, &status); in clk_main_osc_ready()
71 struct regmap *regmap = osc->regmap; in clk_main_osc_prepare() local
74 regmap_read(regmap, AT91_CKGR_MOR, &tmp); in clk_main_osc_prepare()
82 regmap_write(regmap, AT91_CKGR_MOR, tmp); in clk_main_osc_prepare()
[all …]
H A Dpmc.h13 #include <linux/regmap.h>
116 at91_clk_register_audio_pll_frac(struct regmap *regmap, const char *name,
120 at91_clk_register_audio_pll_pad(struct regmap *regmap, const char *name,
124 at91_clk_register_audio_pll_pmc(struct regmap *regmap, const char *name,
128 at91_clk_register_generated(struct regmap *regmap, spinlock_t *lock,
135 at91_clk_register_h32mx(struct regmap *regmap, const char *name,
139 at91_clk_i2s_mux_register(struct regmap *regmap, const char *name,
144 at91_clk_register_main_rc_osc(struct regmap *regmap, const char *name,
147 at91_clk_register_main_osc(struct regmap *regmap, const char *name,
150 at91_clk_register_rm9200_main(struct regmap *regmap,
[all …]
H A Ddt-compat.c6 #include <linux/regmap.h>
33 struct regmap *regmap; in of_sama5d2_clk_audio_pll_frac_setup() local
35 regmap = syscon_node_to_regmap(of_get_parent(np)); in of_sama5d2_clk_audio_pll_frac_setup()
36 if (IS_ERR(regmap)) in of_sama5d2_clk_audio_pll_frac_setup()
41 hw = at91_clk_register_audio_pll_frac(regmap, name, parent_name); in of_sama5d2_clk_audio_pll_frac_setup()
56 struct regmap *regmap; in of_sama5d2_clk_audio_pll_pad_setup() local
58 regmap = syscon_node_to_regmap(of_get_parent(np)); in of_sama5d2_clk_audio_pll_pad_setup()
59 if (IS_ERR(regmap)) in of_sama5d2_clk_audio_pll_pad_setup()
64 hw = at91_clk_register_audio_pll_pad(regmap, name, parent_name); in of_sama5d2_clk_audio_pll_pad_setup()
79 struct regmap *regmap; in of_sama5d2_clk_audio_pll_pmc_setup() local
[all …]
H A Dclk-sam9x60-pll.c13 #include <linux/regmap.h>
31 struct regmap *regmap; member
54 static inline bool sam9x60_pll_ready(struct regmap *regmap, int id) in sam9x60_pll_ready() argument
58 regmap_read(regmap, AT91_PMC_PLL_ISR0, &status); in sam9x60_pll_ready()
63 static bool sam9x60_frac_pll_ready(struct regmap *regmap, u8 id) in sam9x60_frac_pll_ready() argument
65 return sam9x60_pll_ready(regmap, id); in sam9x60_frac_pll_ready()
82 struct regmap *regmap = core->regmap; in sam9x60_frac_pll_prepare() local
88 regmap_update_bits(regmap, AT91_PMC_PLL_UPDT, in sam9x60_frac_pll_prepare()
90 regmap_read(regmap, AT91_PMC_PLL_CTRL1, &val); in sam9x60_frac_pll_prepare()
94 if (sam9x60_frac_pll_ready(regmap, core->id) && in sam9x60_frac_pll_prepare()
[all …]
/OK3568_Linux_fs/kernel/sound/soc/codecs/
H A Dmt6358.c83 struct regmap *regmap; member
115 regmap_update_bits(priv->regmap, MT6358_GPIO_MODE2_CLR, in playback_gpio_set()
117 regmap_update_bits(priv->regmap, MT6358_GPIO_MODE2_SET, in playback_gpio_set()
119 regmap_update_bits(priv->regmap, MT6358_GPIO_MODE2, in playback_gpio_set()
130 regmap_update_bits(priv->regmap, MT6358_GPIO_MODE2_CLR, in playback_gpio_reset()
132 regmap_update_bits(priv->regmap, MT6358_GPIO_MODE2, in playback_gpio_reset()
134 regmap_update_bits(priv->regmap, MT6358_GPIO_DIR0, in playback_gpio_reset()
141 regmap_update_bits(priv->regmap, MT6358_GPIO_MODE3_CLR, in capture_gpio_set()
143 regmap_update_bits(priv->regmap, MT6358_GPIO_MODE3_SET, in capture_gpio_set()
145 regmap_update_bits(priv->regmap, MT6358_GPIO_MODE3, in capture_gpio_set()
[all …]
H A Drk3528_codec.c16 #include <linux/regmap.h>
29 struct regmap *regmap; member
58 regmap_update_bits(rk3528->regmap, ACODEC_DIG00, in rk3528_codec_reset()
63 regmap_update_bits(rk3528->regmap, ACODEC_DIG02, in rk3528_codec_reset()
67 regmap_update_bits(rk3528->regmap, ACODEC_DIG00, in rk3528_codec_reset()
72 regmap_update_bits(rk3528->regmap, ACODEC_DIG02, in rk3528_codec_reset()
83 regmap_update_bits(rk3528->regmap, ACODEC_ANA08, in rk3528_codec_power_on()
86 regmap_update_bits(rk3528->regmap, ACODEC_ANA0C, in rk3528_codec_power_on()
90 regmap_update_bits(rk3528->regmap, ACODEC_ANA01, in rk3528_codec_power_on()
94 regmap_update_bits(rk3528->regmap, ACODEC_ANA00, in rk3528_codec_power_on()
[all …]
H A Drt711.c17 #include <linux/regmap.h>
31 static int rt711_index_write(struct regmap *regmap, in rt711_index_write() argument
37 ret = regmap_write(regmap, addr, value); in rt711_index_write()
45 static int rt711_index_read(struct regmap *regmap, in rt711_index_read() argument
52 ret = regmap_read(regmap, addr, value); in rt711_index_read()
60 static int rt711_index_update_bits(struct regmap *regmap, unsigned int nid, in rt711_index_update_bits() argument
66 ret = rt711_index_read(regmap, nid, reg, &orig); in rt711_index_update_bits()
73 return rt711_index_write(regmap, nid, reg, tmp); in rt711_index_update_bits()
76 static void rt711_reset(struct regmap *regmap) in rt711_reset() argument
78 regmap_write(regmap, RT711_FUNC_RESET, 0); in rt711_reset()
[all …]
H A Dnau8825.c15 #include <linux/regmap.h>
335 regmap_update_bits(nau8825->regmap, NAU8825_REG_HSVOL_CTRL, in nau8825_hpvol_ramp()
344 regmap_update_bits(nau8825->regmap, NAU8825_REG_HSVOL_CTRL, in nau8825_hpvol_ramp()
461 regmap_read(nau8825->regmap, nau8825_xtalk_baktab[i].reg, in nau8825_xtalk_backup()
488 regmap_write(nau8825->regmap, nau8825_xtalk_baktab[i].reg, in nau8825_xtalk_restore()
498 regmap_update_bits(nau8825->regmap, NAU8825_REG_ENA_CTRL, in nau8825_xtalk_prepare_dac()
507 regmap_update_bits(nau8825->regmap, NAU8825_REG_CHARGE_PUMP, in nau8825_xtalk_prepare_dac()
511 regmap_update_bits(nau8825->regmap, NAU8825_REG_RDAC, in nau8825_xtalk_prepare_dac()
516 regmap_update_bits(nau8825->regmap, NAU8825_REG_POWER_UP_CONTROL, in nau8825_xtalk_prepare_dac()
521 regmap_update_bits(nau8825->regmap, NAU8825_REG_POWER_UP_CONTROL, in nau8825_xtalk_prepare_dac()
[all …]
H A Dmt6359.c24 regmap_write(priv->regmap, MT6359_GPIO_MODE2_CLR, 0x0ffe); in mt6359_set_playback_gpio()
25 regmap_write(priv->regmap, MT6359_GPIO_MODE2_SET, 0x0249); in mt6359_set_playback_gpio()
28 regmap_write(priv->regmap, MT6359_GPIO_MODE3_CLR, 0x6); in mt6359_set_playback_gpio()
29 regmap_write(priv->regmap, MT6359_GPIO_MODE3_SET, 0x1); in mt6359_set_playback_gpio()
39 regmap_write(priv->regmap, MT6359_GPIO_MODE2_CLR, 0x0ff8); in mt6359_reset_playback_gpio()
40 regmap_update_bits(priv->regmap, MT6359_GPIO_DIR0, 0x7 << 9, 0x0); in mt6359_reset_playback_gpio()
46 regmap_write(priv->regmap, MT6359_GPIO_MODE3_CLR, 0x0e00); in mt6359_set_capture_gpio()
47 regmap_write(priv->regmap, MT6359_GPIO_MODE3_SET, 0x0200); in mt6359_set_capture_gpio()
49 regmap_write(priv->regmap, MT6359_GPIO_MODE4_CLR, 0x003f); in mt6359_set_capture_gpio()
50 regmap_write(priv->regmap, MT6359_GPIO_MODE4_SET, 0x0009); in mt6359_set_capture_gpio()
[all …]
/OK3568_Linux_fs/kernel/include/linux/
H A Dregmap.h34 struct regmap;
88 * @map: Regmap to read from
115 * @map: Regmap to read from
130 * Note: In general regmap cannot be used in atomic context. If you want to use
131 * this macro then first setup your regmap for atomic use (flat or no cache
132 * and MMIO regmap).
160 * @field: Regmap field to read from
210 * @yes_ranges : pointer to an array of regmap ranges used as "yes ranges"
212 * @no_ranges: pointer to an array of regmap ranges used as "no ranges"
233 * @name: Optional name of the regmap. Useful when a device has multiple
[all …]
/OK3568_Linux_fs/kernel/drivers/reset/hisilicon/
H A Dhi6220_reset.c17 #include <linux/regmap.h>
41 struct regmap *regmap; member
48 struct regmap *regmap = data->regmap; in hi6220_peripheral_assert() local
53 return regmap_write(regmap, reg, BIT(offset)); in hi6220_peripheral_assert()
60 struct regmap *regmap = data->regmap; in hi6220_peripheral_deassert() local
65 return regmap_write(regmap, reg, BIT(offset)); in hi6220_peripheral_deassert()
77 struct regmap *regmap = data->regmap; in hi6220_media_assert() local
79 return regmap_write(regmap, SC_MEDIA_RSTEN, BIT(idx)); in hi6220_media_assert()
86 struct regmap *regmap = data->regmap; in hi6220_media_deassert() local
88 return regmap_write(regmap, SC_MEDIA_RSTDIS, BIT(idx)); in hi6220_media_deassert()
[all …]
/OK3568_Linux_fs/kernel/drivers/phy/mscc/
H A Dphy-ocelot-serdes.c17 #include <linux/regmap.h>
22 struct regmap *regs;
36 static int __serdes_write_mcb_s6g(struct regmap *regmap, u8 macro, u32 op) in __serdes_write_mcb_s6g() argument
40 regmap_write(regmap, HSIO_MCB_S6G_ADDR_CFG, op | in __serdes_write_mcb_s6g()
43 return regmap_read_poll_timeout(regmap, HSIO_MCB_S6G_ADDR_CFG, regval, in __serdes_write_mcb_s6g()
48 static int serdes_commit_mcb_s6g(struct regmap *regmap, u8 macro) in serdes_commit_mcb_s6g() argument
50 return __serdes_write_mcb_s6g(regmap, macro, in serdes_commit_mcb_s6g()
54 static int serdes_update_mcb_s6g(struct regmap *regmap, u8 macro) in serdes_update_mcb_s6g() argument
56 return __serdes_write_mcb_s6g(regmap, macro, in serdes_update_mcb_s6g()
60 static int serdes_init_s6g(struct regmap *regmap, u8 serdes, int mode) in serdes_init_s6g() argument
[all …]
/OK3568_Linux_fs/kernel/drivers/clk/davinci/
H A Dda8xx-cfgchip.c18 #include <linux/regmap.h>
34 struct regmap *regmap; member
46 return regmap_write_bits(clk->regmap, clk->reg, clk->mask, clk->mask); in da8xx_cfgchip_gate_clk_enable()
53 regmap_write_bits(clk->regmap, clk->reg, clk->mask, 0); in da8xx_cfgchip_gate_clk_disable()
61 regmap_read(clk->regmap, clk->reg, &val); in da8xx_cfgchip_gate_clk_is_enabled()
89 struct regmap *regmap) in da8xx_cfgchip_gate_clk_register() argument
117 gate->regmap = regmap; in da8xx_cfgchip_gate_clk_register()
135 struct regmap *regmap) in da8xx_cfgchip_register_tbclk() argument
140 regmap); in da8xx_cfgchip_register_tbclk()
158 struct regmap *regmap) in da8xx_cfgchip_register_div4p5() argument
[all …]
/OK3568_Linux_fs/kernel/drivers/clk/qcom/
H A Dclk-hfpll.c6 #include <linux/regmap.h>
12 #include "clk-regmap.h"
24 struct regmap *regmap = h->clkr.regmap; in __clk_hfpll_init_once() local
31 regmap_write(regmap, hd->config_reg, hd->config_val); in __clk_hfpll_init_once()
32 regmap_write(regmap, hd->m_reg, 0); in __clk_hfpll_init_once()
33 regmap_write(regmap, hd->n_reg, 1); in __clk_hfpll_init_once()
44 regmap_write(regmap, hd->user_reg, regval); in __clk_hfpll_init_once()
48 regmap_write(regmap, hd->droop_reg, hd->droop_val); in __clk_hfpll_init_once()
57 struct regmap *regmap = h->clkr.regmap; in __clk_hfpll_enable() local
63 regmap_update_bits(regmap, hd->mode_reg, PLL_BYPASSNL, PLL_BYPASSNL); in __clk_hfpll_enable()
[all …]
H A Dclk-alpha-pll.c9 #include <linux/regmap.h>
169 ret = regmap_read(pll->clkr.regmap, PLL_MODE(pll), &val); in wait_for_pll()
174 ret = regmap_read(pll->clkr.regmap, PLL_MODE(pll), &val); in wait_for_pll()
210 void clk_alpha_pll_configure(struct clk_alpha_pll *pll, struct regmap *regmap, in clk_alpha_pll_configure() argument
215 regmap_write(regmap, PLL_L_VAL(pll), config->l); in clk_alpha_pll_configure()
216 regmap_write(regmap, PLL_ALPHA_VAL(pll), config->alpha); in clk_alpha_pll_configure()
217 regmap_write(regmap, PLL_CONFIG_CTL(pll), config->config_ctl_val); in clk_alpha_pll_configure()
220 regmap_write(regmap, PLL_CONFIG_CTL_U(pll), in clk_alpha_pll_configure()
224 regmap_write(regmap, PLL_ALPHA_VAL_U(pll), config->alpha_hi); in clk_alpha_pll_configure()
244 regmap_update_bits(regmap, PLL_USER_CTL(pll), mask, val); in clk_alpha_pll_configure()
[all …]
/OK3568_Linux_fs/kernel/drivers/hwmon/
H A Dw83773g.c16 #include <linux/regmap.h>
61 static int get_local_temp(struct regmap *regmap, long *val) in get_local_temp() argument
66 ret = regmap_read(regmap, W83773_LOCAL_TEMP, &regval); in get_local_temp()
74 static int get_remote_temp(struct regmap *regmap, int index, long *val) in get_remote_temp() argument
80 ret = regmap_read(regmap, W83773_TEMP_MSB[index], &regval_high); in get_remote_temp()
84 ret = regmap_read(regmap, W83773_TEMP_LSB[index], &regval_low); in get_remote_temp()
92 static int get_fault(struct regmap *regmap, int index, long *val) in get_fault() argument
97 ret = regmap_read(regmap, W83773_STATUS[index], &regval); in get_fault()
105 static int get_offset(struct regmap *regmap, int index, long *val) in get_offset() argument
111 ret = regmap_read(regmap, W83773_OFFSET_MSB[index], &regval_high); in get_offset()
[all …]
/OK3568_Linux_fs/kernel/drivers/phy/cadence/
H A Dphy-cadence-torrent.c23 #include <linux/regmap.h>
270 struct regmap *regmap; member
271 struct regmap *regmap_common_cdb;
272 struct regmap *regmap_phy_pcs_common_cdb;
273 struct regmap *regmap_phy_pma_common_cdb;
274 struct regmap *regmap_tx_lane_cdb[MAX_NUM_LANES];
275 struct regmap *regmap_rx_lane_cdb[MAX_NUM_LANES];
276 struct regmap *regmap_dptx_phy_reg;
468 static void cdns_torrent_phy_write(struct regmap *regmap, u32 offset, u32 val) in cdns_torrent_phy_write() argument
470 regmap_write(regmap, offset, val); in cdns_torrent_phy_write()
[all …]
/OK3568_Linux_fs/kernel/drivers/base/regmap/
H A Dinternal.h14 #include <linux/regmap.h>
19 struct regmap;
35 void (*format_write)(struct regmap *map,
45 struct regmap *map;
49 struct regmap { struct
165 /* if set, the regmap core can sleep */ argument
172 int (*init)(struct regmap *map); argument
173 int (*exit)(struct regmap *map);
175 void (*debugfs_init)(struct regmap *map);
177 int (*read)(struct regmap *map, unsigned int reg, unsigned int *value);
[all …]
/OK3568_Linux_fs/kernel/drivers/gpu/drm/bridge/
H A Dchrontel-ch7033.c10 #include <linux/regmap.h>
200 struct regmap *regmap; member
336 regmap_write(priv->regmap, 0x03, 0x04); in ch7033_bridge_disable()
337 regmap_update_bits(priv->regmap, 0x52, RESETDB, 0x00); in ch7033_bridge_disable()
344 regmap_write(priv->regmap, 0x03, 0x04); in ch7033_bridge_enable()
345 regmap_update_bits(priv->regmap, 0x52, RESETDB, RESETDB); in ch7033_bridge_enable()
361 regmap_write(priv->regmap, 0x03, 0x04); in ch7033_bridge_mode_set()
364 regmap_write(priv->regmap, 0x52, 0x00); in ch7033_bridge_mode_set()
366 regmap_write(priv->regmap, 0x52, RESETIB); in ch7033_bridge_mode_set()
371 regmap_write(priv->regmap, 0x03, 0x00); in ch7033_bridge_mode_set()
[all …]
/OK3568_Linux_fs/u-boot/drivers/pinctrl/rockchip/
H A Dpinctrl-rv1106.c9 #include <regmap.h>
18 struct regmap *regmap; in rv1106_set_mux() local
26 regmap = priv->regmap_pmu; in rv1106_set_mux()
28 regmap = priv->regmap_base; in rv1106_set_mux()
41 ret = regmap_write(regmap, reg, data); in rv1106_set_mux()
55 int pin_num, struct regmap **regmap, in rv1106_calc_drv_reg_and_bit() argument
63 *regmap = priv->regmap_pmu; in rv1106_calc_drv_reg_and_bit()
68 *regmap = priv->regmap_base; in rv1106_calc_drv_reg_and_bit()
73 *regmap = priv->regmap_base; in rv1106_calc_drv_reg_and_bit()
78 *regmap = priv->regmap_base; in rv1106_calc_drv_reg_and_bit()
[all …]
/OK3568_Linux_fs/kernel/drivers/media/tuners/
H A Dm88rs6000t.c9 #include <linux/regmap.h>
14 struct regmap *regmap; member
36 ret = regmap_read(dev->regmap, 0x15, &utmp); in m88rs6000t_set_demod_mclk()
98 ret = regmap_read(dev->regmap, 0x1D, &utmp); in m88rs6000t_set_demod_mclk()
108 ret = regmap_write(dev->regmap, 0x05, 0x40); in m88rs6000t_set_demod_mclk()
111 ret = regmap_write(dev->regmap, 0x11, 0x08); in m88rs6000t_set_demod_mclk()
114 ret = regmap_write(dev->regmap, 0x15, reg15); in m88rs6000t_set_demod_mclk()
117 ret = regmap_write(dev->regmap, 0x16, reg16); in m88rs6000t_set_demod_mclk()
120 ret = regmap_write(dev->regmap, 0x1D, reg1D); in m88rs6000t_set_demod_mclk()
123 ret = regmap_write(dev->regmap, 0x1E, reg1E); in m88rs6000t_set_demod_mclk()
[all …]
/OK3568_Linux_fs/kernel/drivers/nvmem/
H A Drk628-efuse.c22 #include <linux/regmap.h>
82 struct regmap *regmap; member
86 static int rk628_read(struct regmap *regmap, u32 reg) in rk628_read() argument
90 struct rk628_efuse_chip *efuse = container_of(regmap, struct rk628_efuse_chip, regmap); in rk628_read()
92 ret = regmap_read(regmap, reg, &val); in rk628_read()
101 static int rk628_write(struct regmap *regmap, u32 val, u32 reg) in rk628_write() argument
104 struct rk628_efuse_chip *efuse = container_of(regmap, struct rk628_efuse_chip, regmap); in rk628_write()
106 ret = regmap_write(regmap, reg, val); in rk628_write()
117 rk628_write(efuse->regmap, in rk628_efuse_timing_init()
118 rk628_read(efuse->regmap, base + RK628_MOD) & (~RK628_USER_MODE), in rk628_efuse_timing_init()
[all …]
/OK3568_Linux_fs/u-boot/drivers/phy/
H A Dphy-rockchip-samsung-hdptx.c12 #include <regmap.h>
326 struct regmap *regmap; member
327 struct regmap *grf;
475 static inline void rockchip_grf_write(struct regmap *grf, uint reg, uint mask, in rockchip_grf_write()
534 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c44), in rockchip_hdptx_phy_set_voltage()
540 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c44), in rockchip_hdptx_phy_set_voltage()
547 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c44), in rockchip_hdptx_phy_set_voltage()
553 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c0c), in rockchip_hdptx_phy_set_voltage()
558 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c10), in rockchip_hdptx_phy_set_voltage()
564 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c18), in rockchip_hdptx_phy_set_voltage()
[all …]
/OK3568_Linux_fs/kernel/drivers/phy/rockchip/
H A Dphy-rockchip-samsung-hdptx.c16 #include <linux/regmap.h>
332 struct regmap *regmap; member
333 struct regmap *grf;
474 static int rockchip_grf_write(struct regmap *grf, unsigned int reg, in rockchip_grf_write()
534 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c44), in rockchip_hdptx_phy_set_voltage()
540 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c44), in rockchip_hdptx_phy_set_voltage()
547 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c44), in rockchip_hdptx_phy_set_voltage()
553 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c0c), in rockchip_hdptx_phy_set_voltage()
559 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c10), in rockchip_hdptx_phy_set_voltage()
566 regmap_update_bits(hdptx->regmap, LANE_REG(lane, 0x0c18), in rockchip_hdptx_phy_set_voltage()
[all …]
/OK3568_Linux_fs/kernel/drivers/mfd/
H A Dsyscon.c22 #include <linux/regmap.h>
33 struct regmap *regmap; member
47 struct regmap *regmap; in of_syscon_register() local
110 regmap = regmap_init_mmio(NULL, base, &syscon_config); in of_syscon_register()
112 if (IS_ERR(regmap)) { in of_syscon_register()
113 pr_err("regmap init failed\n"); in of_syscon_register()
114 ret = PTR_ERR(regmap); in of_syscon_register()
126 ret = regmap_mmio_attach_clk(regmap, clk); in of_syscon_register()
132 syscon->regmap = regmap; in of_syscon_register()
145 regmap_exit(regmap); in of_syscon_register()
[all …]

12345678910>>...110