• Home
  • Raw
  • Download

Lines Matching refs:rcdev

35 static int mpfs_assert(struct reset_controller_dev *rcdev, unsigned long id)  in mpfs_assert()  argument
42 reg = mpfs_reset_read(rcdev->dev); in mpfs_assert()
44 mpfs_reset_write(rcdev->dev, reg); in mpfs_assert()
51 static int mpfs_deassert(struct reset_controller_dev *rcdev, unsigned long id) in mpfs_deassert() argument
58 reg = mpfs_reset_read(rcdev->dev); in mpfs_deassert()
60 mpfs_reset_write(rcdev->dev, reg); in mpfs_deassert()
67 static int mpfs_status(struct reset_controller_dev *rcdev, unsigned long id) in mpfs_status() argument
69 u32 reg = mpfs_reset_read(rcdev->dev); in mpfs_status()
78 static int mpfs_reset(struct reset_controller_dev *rcdev, unsigned long id) in mpfs_reset() argument
80 mpfs_assert(rcdev, id); in mpfs_reset()
84 mpfs_deassert(rcdev, id); in mpfs_reset()
96 static int mpfs_reset_xlate(struct reset_controller_dev *rcdev, in mpfs_reset_xlate() argument
107 dev_err(rcdev->dev, "Resetting the fabric is not supported\n"); in mpfs_reset_xlate()
111 if (index < MPFS_PERIPH_OFFSET || index >= (MPFS_PERIPH_OFFSET + rcdev->nr_resets)) { in mpfs_reset_xlate()
112 dev_err(rcdev->dev, "Invalid reset index %u\n", index); in mpfs_reset_xlate()
123 struct reset_controller_dev *rcdev; in mpfs_reset_probe() local
125 rcdev = devm_kzalloc(dev, sizeof(*rcdev), GFP_KERNEL); in mpfs_reset_probe()
126 if (!rcdev) in mpfs_reset_probe()
129 rcdev->dev = dev; in mpfs_reset_probe()
130 rcdev->dev->parent = dev->parent; in mpfs_reset_probe()
131 rcdev->ops = &mpfs_reset_ops; in mpfs_reset_probe()
132 rcdev->of_node = dev->parent->of_node; in mpfs_reset_probe()
133 rcdev->of_reset_n_cells = 1; in mpfs_reset_probe()
134 rcdev->of_xlate = mpfs_reset_xlate; in mpfs_reset_probe()
135 rcdev->nr_resets = MPFS_NUM_RESETS; in mpfs_reset_probe()
137 return devm_reset_controller_register(dev, rcdev); in mpfs_reset_probe()