Lines Matching refs:ath79_reset

19 struct ath79_reset {  struct
28 struct ath79_reset *ath79_reset = in ath79_reset_update() argument
29 container_of(rcdev, struct ath79_reset, rcdev); in ath79_reset_update()
33 spin_lock_irqsave(&ath79_reset->lock, flags); in ath79_reset_update()
34 val = readl(ath79_reset->base); in ath79_reset_update()
39 writel(val, ath79_reset->base); in ath79_reset_update()
40 spin_unlock_irqrestore(&ath79_reset->lock, flags); in ath79_reset_update()
60 struct ath79_reset *ath79_reset = in ath79_reset_status() local
61 container_of(rcdev, struct ath79_reset, rcdev); in ath79_reset_status()
64 val = readl(ath79_reset->base); in ath79_reset_status()
77 struct ath79_reset *ath79_reset; in ath79_reset_probe() local
80 ath79_reset = devm_kzalloc(&pdev->dev, in ath79_reset_probe()
81 sizeof(*ath79_reset), GFP_KERNEL); in ath79_reset_probe()
82 if (!ath79_reset) in ath79_reset_probe()
85 platform_set_drvdata(pdev, ath79_reset); in ath79_reset_probe()
88 ath79_reset->base = devm_ioremap_resource(&pdev->dev, res); in ath79_reset_probe()
89 if (IS_ERR(ath79_reset->base)) in ath79_reset_probe()
90 return PTR_ERR(ath79_reset->base); in ath79_reset_probe()
92 spin_lock_init(&ath79_reset->lock); in ath79_reset_probe()
93 ath79_reset->rcdev.ops = &ath79_reset_ops; in ath79_reset_probe()
94 ath79_reset->rcdev.owner = THIS_MODULE; in ath79_reset_probe()
95 ath79_reset->rcdev.of_node = pdev->dev.of_node; in ath79_reset_probe()
96 ath79_reset->rcdev.of_reset_n_cells = 1; in ath79_reset_probe()
97 ath79_reset->rcdev.nr_resets = 32; in ath79_reset_probe()
99 return reset_controller_register(&ath79_reset->rcdev); in ath79_reset_probe()
104 struct ath79_reset *ath79_reset = platform_get_drvdata(pdev); in ath79_reset_remove() local
106 reset_controller_unregister(&ath79_reset->rcdev); in ath79_reset_remove()