Lines Matching refs:rst
30 struct axs10x_rst *rst = to_axs10x_rst(rcdev); in axs10x_reset_reset() local
33 spin_lock_irqsave(&rst->lock, flags); in axs10x_reset_reset()
34 writel(BIT(id), rst->regs_rst); in axs10x_reset_reset()
35 spin_unlock_irqrestore(&rst->lock, flags); in axs10x_reset_reset()
46 struct axs10x_rst *rst; in axs10x_reset_probe() local
48 rst = devm_kzalloc(&pdev->dev, sizeof(*rst), GFP_KERNEL); in axs10x_reset_probe()
49 if (!rst) in axs10x_reset_probe()
52 rst->regs_rst = devm_platform_ioremap_resource(pdev, 0); in axs10x_reset_probe()
53 if (IS_ERR(rst->regs_rst)) in axs10x_reset_probe()
54 return PTR_ERR(rst->regs_rst); in axs10x_reset_probe()
56 spin_lock_init(&rst->lock); in axs10x_reset_probe()
58 rst->rcdev.owner = THIS_MODULE; in axs10x_reset_probe()
59 rst->rcdev.ops = &axs10x_reset_ops; in axs10x_reset_probe()
60 rst->rcdev.of_node = pdev->dev.of_node; in axs10x_reset_probe()
61 rst->rcdev.nr_resets = AXS10X_MAX_RESETS; in axs10x_reset_probe()
63 return devm_reset_controller_register(&pdev->dev, &rst->rcdev); in axs10x_reset_probe()