Home
last modified time | relevance | path

Searched refs:rstc (Results 1 – 25 of 89) sorted by relevance

1234

/Linux-v5.10/drivers/reset/
Dcore.c62 struct reset_control *rstc[]; member
194 rstc_to_array(struct reset_control *rstc) { in rstc_to_array() argument
195 return container_of(rstc, struct reset_control_array, base); in rstc_to_array()
203 ret = reset_control_reset(resets->rstc[i]); in reset_control_array_reset()
216 ret = reset_control_assert(resets->rstc[i]); in reset_control_array_assert()
225 reset_control_deassert(resets->rstc[i]); in reset_control_array_assert()
234 ret = reset_control_deassert(resets->rstc[i]); in reset_control_array_deassert()
243 reset_control_assert(resets->rstc[i]); in reset_control_array_deassert()
253 err = reset_control_acquire(resets->rstc[i]); in reset_control_array_acquire()
262 reset_control_release(resets->rstc[i]); in reset_control_array_acquire()
[all …]
Dreset-meson-audio-arb.c15 struct reset_controller_dev rstc; member
64 container_of(rcdev, struct meson_audio_arb_data, rstc); in meson_audio_arb_update()
85 container_of(rcdev, struct meson_audio_arb_data, rstc); in meson_audio_arb_status()
167 arb->rstc.nr_resets = data->reset_num; in meson_audio_arb_probe()
168 arb->rstc.ops = &meson_audio_arb_rstc_ops; in meson_audio_arb_probe()
169 arb->rstc.of_node = dev->of_node; in meson_audio_arb_probe()
170 arb->rstc.owner = THIS_MODULE; in meson_audio_arb_probe()
185 ret = devm_reset_controller_register(dev, &arb->rstc); in meson_audio_arb_probe()
/Linux-v5.10/drivers/clk/hisilicon/
Dreset.c46 struct hisi_reset_controller *rstc = to_hisi_reset_controller(rcdev); in hisi_reset_assert() local
54 spin_lock_irqsave(&rstc->lock, flags); in hisi_reset_assert()
56 reg = readl(rstc->membase + offset); in hisi_reset_assert()
57 writel(reg | BIT(bit), rstc->membase + offset); in hisi_reset_assert()
59 spin_unlock_irqrestore(&rstc->lock, flags); in hisi_reset_assert()
67 struct hisi_reset_controller *rstc = to_hisi_reset_controller(rcdev); in hisi_reset_deassert() local
75 spin_lock_irqsave(&rstc->lock, flags); in hisi_reset_deassert()
77 reg = readl(rstc->membase + offset); in hisi_reset_deassert()
78 writel(reg & ~BIT(bit), rstc->membase + offset); in hisi_reset_deassert()
80 spin_unlock_irqrestore(&rstc->lock, flags); in hisi_reset_deassert()
[all …]
Dclk-hi3519.c31 struct hisi_reset_controller *rstc; member
151 crg->rstc = hisi_reset_init(pdev); in hi3519_clk_probe()
152 if (!crg->rstc) in hi3519_clk_probe()
157 hisi_reset_exit(crg->rstc); in hi3519_clk_probe()
169 hisi_reset_exit(crg->rstc); in hi3519_clk_remove()
Dreset.h14 void hisi_reset_exit(struct hisi_reset_controller *rstc);
21 static inline void hisi_reset_exit(struct hisi_reset_controller *rstc) in hisi_reset_exit() argument
/Linux-v5.10/drivers/reset/tegra/
Dreset-bpmp.c11 static struct tegra_bpmp *to_tegra_bpmp(struct reset_controller_dev *rstc) in to_tegra_bpmp() argument
13 return container_of(rstc, struct tegra_bpmp, rstc); in to_tegra_bpmp()
16 static int tegra_bpmp_reset_common(struct reset_controller_dev *rstc, in tegra_bpmp_reset_common() argument
20 struct tegra_bpmp *bpmp = to_tegra_bpmp(rstc); in tegra_bpmp_reset_common()
36 static int tegra_bpmp_reset_module(struct reset_controller_dev *rstc, in tegra_bpmp_reset_module() argument
39 return tegra_bpmp_reset_common(rstc, CMD_RESET_MODULE, id); in tegra_bpmp_reset_module()
42 static int tegra_bpmp_reset_assert(struct reset_controller_dev *rstc, in tegra_bpmp_reset_assert() argument
45 return tegra_bpmp_reset_common(rstc, CMD_RESET_ASSERT, id); in tegra_bpmp_reset_assert()
48 static int tegra_bpmp_reset_deassert(struct reset_controller_dev *rstc, in tegra_bpmp_reset_deassert() argument
51 return tegra_bpmp_reset_common(rstc, CMD_RESET_DEASSERT, id); in tegra_bpmp_reset_deassert()
[all …]
/Linux-v5.10/drivers/clk/meson/
Dmeson-aoclk.c23 struct meson_aoclk_reset_controller *rstc = in meson_aoclk_do_reset() local
26 return regmap_write(rstc->regmap, rstc->data->reset_reg, in meson_aoclk_do_reset()
27 BIT(rstc->data->reset[id])); in meson_aoclk_do_reset()
36 struct meson_aoclk_reset_controller *rstc; in meson_aoclkc_probe() local
46 rstc = devm_kzalloc(dev, sizeof(*rstc), GFP_KERNEL); in meson_aoclkc_probe()
47 if (!rstc) in meson_aoclkc_probe()
57 rstc->data = data; in meson_aoclkc_probe()
58 rstc->regmap = regmap; in meson_aoclkc_probe()
59 rstc->reset.ops = &meson_aoclk_reset_ops; in meson_aoclkc_probe()
60 rstc->reset.nr_resets = data->num_reset; in meson_aoclkc_probe()
[all …]
/Linux-v5.10/include/linux/
Dreset.h15 int reset_control_reset(struct reset_control *rstc);
16 int reset_control_assert(struct reset_control *rstc);
17 int reset_control_deassert(struct reset_control *rstc);
18 int reset_control_status(struct reset_control *rstc);
19 int reset_control_acquire(struct reset_control *rstc);
20 void reset_control_release(struct reset_control *rstc);
28 void reset_control_put(struct reset_control *rstc);
44 static inline int reset_control_reset(struct reset_control *rstc) in reset_control_reset() argument
49 static inline int reset_control_assert(struct reset_control *rstc) in reset_control_assert() argument
54 static inline int reset_control_deassert(struct reset_control *rstc) in reset_control_deassert() argument
[all …]
/Linux-v5.10/Documentation/devicetree/bindings/reset/
Dsirf,rstc.txt8 - compatible: Should be "sirf,prima2-rstc" or "sirf,marco-rstc"
15 rstc: reset-controller@88010000 {
16 compatible = "sirf,prima2-rstc";
24 The reset controller(rstc) manages various reset sources. This module provides
26 reset line on the rstc in their resets property, containing a phandle to the
27 rstc device node and a RESET_INDEX specifying which module to reset, as described
41 resets = <&rstc 6>;
Dnuvoton,npcm-reset.txt15 rstc: rstc@f0801000 {
28 resets = <&rstc NPCM7XX_RESET_IPSRST2 NPCM7XX_RESET_PSPI1>;
/Linux-v5.10/arch/arm/mach-meson/
Dplatsmp.c156 struct reset_control *rstc; in meson8_smp_boot_secondary() local
159 rstc = meson_smp_get_core_reset(cpu); in meson8_smp_boot_secondary()
160 if (IS_ERR(rstc)) { in meson8_smp_boot_secondary()
162 return PTR_ERR(rstc); in meson8_smp_boot_secondary()
168 ret = reset_control_assert(rstc); in meson8_smp_boot_secondary()
193 ret = reset_control_deassert(rstc); in meson8_smp_boot_secondary()
204 reset_control_put(rstc); in meson8_smp_boot_secondary()
212 struct reset_control *rstc; in meson8b_smp_boot_secondary() local
216 rstc = meson_smp_get_core_reset(cpu); in meson8b_smp_boot_secondary()
217 if (IS_ERR(rstc)) { in meson8b_smp_boot_secondary()
[all …]
/Linux-v5.10/drivers/mmc/host/
Dsdhci-st.c21 struct reset_control *rstc; member
352 struct reset_control *rstc; in sdhci_st_probe() local
365 rstc = devm_reset_control_get_exclusive(&pdev->dev, NULL); in sdhci_st_probe()
366 if (IS_ERR(rstc)) in sdhci_st_probe()
367 rstc = NULL; in sdhci_st_probe()
369 reset_control_deassert(rstc); in sdhci_st_probe()
380 pdata->rstc = rstc; in sdhci_st_probe()
435 if (rstc) in sdhci_st_probe()
436 reset_control_assert(rstc); in sdhci_st_probe()
446 struct reset_control *rstc = pdata->rstc; in sdhci_st_remove() local
[all …]
/Linux-v5.10/drivers/pinctrl/sunxi/
Dpinctrl-sun8i-a23-r.c101 struct reset_control *rstc; in sun8i_a23_r_pinctrl_probe() local
104 rstc = devm_reset_control_get_exclusive(&pdev->dev, NULL); in sun8i_a23_r_pinctrl_probe()
105 if (IS_ERR(rstc)) { in sun8i_a23_r_pinctrl_probe()
106 ret = PTR_ERR(rstc); in sun8i_a23_r_pinctrl_probe()
113 ret = reset_control_deassert(rstc); in sun8i_a23_r_pinctrl_probe()
121 reset_control_assert(rstc); in sun8i_a23_r_pinctrl_probe()
Dpinctrl-sun6i-a31-r.c114 struct reset_control *rstc; in sun6i_a31_r_pinctrl_probe() local
117 rstc = devm_reset_control_get_exclusive(&pdev->dev, NULL); in sun6i_a31_r_pinctrl_probe()
118 if (IS_ERR(rstc)) { in sun6i_a31_r_pinctrl_probe()
120 return PTR_ERR(rstc); in sun6i_a31_r_pinctrl_probe()
123 ret = reset_control_deassert(rstc); in sun6i_a31_r_pinctrl_probe()
131 reset_control_assert(rstc); in sun6i_a31_r_pinctrl_probe()
/Linux-v5.10/drivers/soc/amlogic/
Dmeson-gx-pwrc-vpu.c36 struct reset_control *rstc; member
173 ret = reset_control_assert(pd->rstc); in meson_gx_pwrc_vpu_power_on()
180 ret = reset_control_deassert(pd->rstc); in meson_gx_pwrc_vpu_power_on()
227 ret = reset_control_assert(pd->rstc); in meson_g12a_pwrc_vpu_power_on()
234 ret = reset_control_deassert(pd->rstc); in meson_g12a_pwrc_vpu_power_on()
275 struct reset_control *rstc; in meson_gx_pwrc_vpu_probe() local
306 rstc = devm_reset_control_array_get(&pdev->dev, false, false); in meson_gx_pwrc_vpu_probe()
307 if (IS_ERR(rstc)) { in meson_gx_pwrc_vpu_probe()
308 if (PTR_ERR(rstc) != -EPROBE_DEFER) in meson_gx_pwrc_vpu_probe()
310 return PTR_ERR(rstc); in meson_gx_pwrc_vpu_probe()
[all …]
/Linux-v5.10/arch/arm/mach-rockchip/
Dplatsmp.c67 struct reset_control *rstc = rockchip_get_core_reset(pd); in pmu_set_power_domain() local
70 if (IS_ERR(rstc) && read_cpuid_part() != ARM_CPU_PART_CORTEX_A9) { in pmu_set_power_domain()
73 return PTR_ERR(rstc); in pmu_set_power_domain()
81 if (!IS_ERR(rstc) && !on) in pmu_set_power_domain()
82 reset_control_assert(rstc); in pmu_set_power_domain()
103 if (!IS_ERR(rstc)) { in pmu_set_power_domain()
105 reset_control_deassert(rstc); in pmu_set_power_domain()
106 reset_control_put(rstc); in pmu_set_power_domain()
/Linux-v5.10/drivers/clocksource/
Ddw_apb_timer_of.c22 struct reset_control *rstc; in timer_get_base_and_rate() local
33 rstc = of_reset_control_get(np, NULL); in timer_get_base_and_rate()
34 if (!IS_ERR(rstc)) { in timer_get_base_and_rate()
35 reset_control_assert(rstc); in timer_get_base_and_rate()
36 reset_control_deassert(rstc); in timer_get_base_and_rate()
Dtimer-stm32.c290 struct reset_control *rstc; in stm32_timer_init() local
312 rstc = of_reset_control_get(node, NULL); in stm32_timer_init()
313 if (!IS_ERR(rstc)) { in stm32_timer_init()
314 reset_control_assert(rstc); in stm32_timer_init()
315 reset_control_deassert(rstc); in stm32_timer_init()
/Linux-v5.10/drivers/phy/st/
Dphy-stih407-usb.c36 struct reset_control *rstc; member
44 reset_control_deassert(phy_dev->rstc); in stih407_usb2_pico_ctrl()
104 phy_dev->rstc = devm_reset_control_get_shared(dev, "global"); in stih407_usb2_picophy_probe()
105 if (IS_ERR(phy_dev->rstc)) { in stih407_usb2_picophy_probe()
107 return PTR_ERR(phy_dev->rstc); in stih407_usb2_picophy_probe()
/Linux-v5.10/drivers/pwm/
Dpwm-hibvt.c39 struct reset_control *rstc; member
225 pwm_chip->rstc = devm_reset_control_get_exclusive(&pdev->dev, NULL); in hibvt_pwm_probe()
226 if (IS_ERR(pwm_chip->rstc)) { in hibvt_pwm_probe()
228 return PTR_ERR(pwm_chip->rstc); in hibvt_pwm_probe()
231 reset_control_assert(pwm_chip->rstc); in hibvt_pwm_probe()
233 reset_control_deassert(pwm_chip->rstc); in hibvt_pwm_probe()
257 reset_control_assert(pwm_chip->rstc); in hibvt_pwm_remove()
259 reset_control_deassert(pwm_chip->rstc); in hibvt_pwm_remove()
/Linux-v5.10/drivers/i2c/busses/
Di2c-sun6i-p2wi.c90 struct reset_control *rstc; member
257 p2wi->rstc = devm_reset_control_get_exclusive(dev, NULL); in p2wi_probe()
258 if (IS_ERR(p2wi->rstc)) { in p2wi_probe()
259 ret = PTR_ERR(p2wi->rstc); in p2wi_probe()
264 ret = reset_control_deassert(p2wi->rstc); in p2wi_probe()
308 reset_control_assert(p2wi->rstc); in p2wi_probe()
320 reset_control_assert(p2wi->rstc); in p2wi_remove()
/Linux-v5.10/drivers/watchdog/
Dzx2967_wdt.c200 struct reset_control *rstc; in zx2967_wdt_probe() local
238 rstc = devm_reset_control_get_exclusive(dev, NULL); in zx2967_wdt_probe()
239 if (IS_ERR(rstc)) { in zx2967_wdt_probe()
241 return PTR_ERR(rstc); in zx2967_wdt_probe()
244 reset_control_assert(rstc); in zx2967_wdt_probe()
245 reset_control_deassert(rstc); in zx2967_wdt_probe()
/Linux-v5.10/drivers/spi/
Dspi-dw-mmio.c33 struct reset_control *rstc; member
271 dwsmmio->rstc = devm_reset_control_get_optional_exclusive(&pdev->dev, "spi"); in dw_spi_mmio_probe()
272 if (IS_ERR(dwsmmio->rstc)) { in dw_spi_mmio_probe()
273 ret = PTR_ERR(dwsmmio->rstc); in dw_spi_mmio_probe()
276 reset_control_deassert(dwsmmio->rstc); in dw_spi_mmio_probe()
311 reset_control_assert(dwsmmio->rstc); in dw_spi_mmio_probe()
324 reset_control_assert(dwsmmio->rstc); in dw_spi_mmio_remove()
/Linux-v5.10/drivers/clk/sunxi-ng/
Dccu-sun9i-a80-de.c208 struct reset_control *rstc; in sun9i_a80_de_clk_probe() local
225 rstc = devm_reset_control_get_exclusive(&pdev->dev, NULL); in sun9i_a80_de_clk_probe()
226 if (IS_ERR(rstc)) { in sun9i_a80_de_clk_probe()
227 ret = PTR_ERR(rstc); in sun9i_a80_de_clk_probe()
242 ret = reset_control_deassert(rstc); in sun9i_a80_de_clk_probe()
257 reset_control_assert(rstc); in sun9i_a80_de_clk_probe()
/Linux-v5.10/drivers/gpu/drm/panfrost/
Dpanfrost_device.c23 pfdev->rstc = devm_reset_control_array_get(pfdev->dev, false, true); in panfrost_reset_init()
24 if (IS_ERR(pfdev->rstc)) { in panfrost_reset_init()
25 dev_err(pfdev->dev, "get reset failed %ld\n", PTR_ERR(pfdev->rstc)); in panfrost_reset_init()
26 return PTR_ERR(pfdev->rstc); in panfrost_reset_init()
29 err = reset_control_deassert(pfdev->rstc); in panfrost_reset_init()
38 reset_control_assert(pfdev->rstc); in panfrost_reset_fini()

1234