Lines Matching +full:ufshcd +full:- +full:pltfrm

1 // SPDX-License-Identifier: GPL-2.0 OR MIT
17 #include <ufs/ufshcd.h>
19 #include "ufshcd-pltfrm.h"
287 WARN_ON(p->index >= MAX_INDEX); in ufs_renesas_reg_control()
289 switch (p->mode) { in ufs_renesas_reg_control()
291 ufshcd_writel(hba, save[p->index], p->reg); in ufs_renesas_reg_control()
294 save[p->index] |= p->u.set; in ufs_renesas_reg_control()
297 save[p->index] = ufshcd_readl(hba, p->reg) & p->mask; in ufs_renesas_reg_control()
300 ret = readl_poll_timeout_atomic(hba->mmio_base + p->reg, in ufs_renesas_reg_control()
302 (val & p->mask) == p->u.expected, in ufs_renesas_reg_control()
305 dev_err(hba->dev, "%s: poll failed %d (%08x, %08x, %08x)\n", in ufs_renesas_reg_control()
306 __func__, ret, val, p->mask, p->u.expected); in ufs_renesas_reg_control()
309 if (p->u.delay_us > 1000) in ufs_renesas_reg_control()
310 mdelay(DIV_ROUND_UP(p->u.delay_us, 1000)); in ufs_renesas_reg_control()
312 udelay(p->u.delay_us); in ufs_renesas_reg_control()
315 ufshcd_writel(hba, p->u.val, p->reg); in ufs_renesas_reg_control()
336 if (priv->initialized) in ufs_renesas_hce_enable_notify()
342 priv->initialized = true; in ufs_renesas_hce_enable_notify()
351 pm_runtime_get_sync(hba->dev); in ufs_renesas_setup_clocks()
353 pm_runtime_put(hba->dev); in ufs_renesas_setup_clocks()
362 priv = devm_kzalloc(hba->dev, sizeof(*priv), GFP_KERNEL); in ufs_renesas_init()
364 return -ENOMEM; in ufs_renesas_init()
367 hba->quirks |= UFSHCD_QUIRK_BROKEN_64BIT_ADDRESS | UFSHCD_QUIRK_HIBERN_FASTAUTO; in ufs_renesas_init()
381 { .compatible = "renesas,r8a779f0-ufs" },
402 .name = "ufshcd-renesas",