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

1 // SPDX-License-Identifier: GPL-2.0
19 #include "ufshcd-pltfrm.h"
27 * cdns_ufs_dme_attr_val - for storing L4 attributes
33 * cdns_ufs_get_l4_attr - get L4 attributes on local side
42 &host->cdns_ufs_dme_attr_val[0]); in cdns_ufs_get_l4_attr()
44 &host->cdns_ufs_dme_attr_val[1]); in cdns_ufs_get_l4_attr()
46 &host->cdns_ufs_dme_attr_val[2]); in cdns_ufs_get_l4_attr()
48 &host->cdns_ufs_dme_attr_val[3]); in cdns_ufs_get_l4_attr()
50 &host->cdns_ufs_dme_attr_val[4]); in cdns_ufs_get_l4_attr()
52 &host->cdns_ufs_dme_attr_val[5]); in cdns_ufs_get_l4_attr()
54 &host->cdns_ufs_dme_attr_val[6]); in cdns_ufs_get_l4_attr()
56 &host->cdns_ufs_dme_attr_val[7]); in cdns_ufs_get_l4_attr()
58 &host->cdns_ufs_dme_attr_val[8]); in cdns_ufs_get_l4_attr()
60 &host->cdns_ufs_dme_attr_val[9]); in cdns_ufs_get_l4_attr()
62 &host->cdns_ufs_dme_attr_val[10]); in cdns_ufs_get_l4_attr()
64 &host->cdns_ufs_dme_attr_val[11]); in cdns_ufs_get_l4_attr()
68 * cdns_ufs_set_l4_attr - set L4 attributes on local side
78 host->cdns_ufs_dme_attr_val[0]); in cdns_ufs_set_l4_attr()
80 host->cdns_ufs_dme_attr_val[1]); in cdns_ufs_set_l4_attr()
82 host->cdns_ufs_dme_attr_val[2]); in cdns_ufs_set_l4_attr()
84 host->cdns_ufs_dme_attr_val[3]); in cdns_ufs_set_l4_attr()
86 host->cdns_ufs_dme_attr_val[4]); in cdns_ufs_set_l4_attr()
88 host->cdns_ufs_dme_attr_val[5]); in cdns_ufs_set_l4_attr()
90 host->cdns_ufs_dme_attr_val[6]); in cdns_ufs_set_l4_attr()
92 host->cdns_ufs_dme_attr_val[7]); in cdns_ufs_set_l4_attr()
94 host->cdns_ufs_dme_attr_val[8]); in cdns_ufs_set_l4_attr()
96 host->cdns_ufs_dme_attr_val[9]); in cdns_ufs_set_l4_attr()
98 host->cdns_ufs_dme_attr_val[10]); in cdns_ufs_set_l4_attr()
100 host->cdns_ufs_dme_attr_val[11]); in cdns_ufs_set_l4_attr()
104 * cdns_ufs_set_hclkdiv() - set HCLKDIV register value based on the core_clk.
107 * Return: zero for success and non-zero for failure.
112 struct list_head *head = &hba->clk_list_head; in cdns_ufs_set_hclkdiv()
120 if (IS_ERR_OR_NULL(clki->clk)) in cdns_ufs_set_hclkdiv()
122 if (!strcmp(clki->name, "core_clk")) in cdns_ufs_set_hclkdiv()
123 core_clk_rate = clk_get_rate(clki->clk); in cdns_ufs_set_hclkdiv()
127 dev_err(hba->dev, "%s: unable to find core_clk rate\n", in cdns_ufs_set_hclkdiv()
129 return -EINVAL; in cdns_ufs_set_hclkdiv()
145 * cdns_ufs_hce_enable_notify() - set HCLKDIV register
149 * Return: zero for success and non-zero for failure.
161 * cdns_ufs_hibern8_notify() - save and restore L4 attributes.
176 * cdns_ufs_link_startup_notify() - handle link startup.
180 * Return: zero for success and non-zero for failure.
201 hba->ahit = 0; in cdns_ufs_link_startup_notify()
207 * cdns_ufs_init - performs additional ufs initialization
216 struct device *dev = hba->dev; in cdns_ufs_init()
221 return -ENOMEM; in cdns_ufs_init()
230 * cdns_ufs_m31_16nm_phy_initialization - performs m31 phy initialization
248 .name = "cdns-ufs-pltfm",
256 .name = "cdns-ufs-pltfm",
270 .compatible = "cdns,ufshc-m31-16nm",
279 * cdns_ufs_pltfrm_probe - probe routine of the driver
282 * Return: zero for success and non-zero for failure.
289 struct device *dev = &pdev->dev; in cdns_ufs_pltfrm_probe()
291 of_id = of_match_node(cdns_ufs_of_match, dev->of_node); in cdns_ufs_pltfrm_probe()
292 vops = (struct ufs_hba_variant_ops *)of_id->data; in cdns_ufs_pltfrm_probe()
303 * cdns_ufs_pltfrm_remove - removes the ufs driver
326 .name = "cdns-ufshcd",