clki 53 drivers/iio/adc/mcp3911.c struct clk *clki; clki 230 drivers/iio/adc/mcp3911.c if (adc->clki) { clki 272 drivers/iio/adc/mcp3911.c adc->clki = devm_clk_get(&adc->spi->dev, NULL); clki 273 drivers/iio/adc/mcp3911.c if (IS_ERR(adc->clki)) { clki 274 drivers/iio/adc/mcp3911.c if (PTR_ERR(adc->clki) == -ENOENT) { clki 275 drivers/iio/adc/mcp3911.c adc->clki = NULL; clki 279 drivers/iio/adc/mcp3911.c PTR_ERR(adc->clki)); clki 280 drivers/iio/adc/mcp3911.c ret = PTR_ERR(adc->clki); clki 284 drivers/iio/adc/mcp3911.c ret = clk_prepare_enable(adc->clki); clki 315 drivers/iio/adc/mcp3911.c clk_disable_unprepare(adc->clki); clki 330 drivers/iio/adc/mcp3911.c clk_disable_unprepare(adc->clki); clki 31 drivers/scsi/ufs/cdns-pltfrm.c struct ufs_clk_info *clki; clki 39 drivers/scsi/ufs/cdns-pltfrm.c list_for_each_entry(clki, head, list) { clki 40 drivers/scsi/ufs/cdns-pltfrm.c if (IS_ERR_OR_NULL(clki->clk)) clki 42 drivers/scsi/ufs/cdns-pltfrm.c if (!strcmp(clki->name, "core_clk")) clki 43 drivers/scsi/ufs/cdns-pltfrm.c core_clk_rate = clk_get_rate(clki->clk); clki 342 drivers/scsi/ufs/ufs-qcom.c struct ufs_clk_info *clki; clki 382 drivers/scsi/ufs/ufs-qcom.c list_for_each_entry(clki, &hba->clk_list_head, list) { clki 383 drivers/scsi/ufs/ufs-qcom.c if (!strcmp(clki->name, "core_clk")) clki 384 drivers/scsi/ufs/ufs-qcom.c core_clk_rate = clk_get_rate(clki->clk); clki 55 drivers/scsi/ufs/ufshcd-pltfrm.c struct ufs_clk_info *clki; clki 111 drivers/scsi/ufs/ufshcd-pltfrm.c clki = devm_kzalloc(dev, sizeof(*clki), GFP_KERNEL); clki 112 drivers/scsi/ufs/ufshcd-pltfrm.c if (!clki) { clki 117 drivers/scsi/ufs/ufshcd-pltfrm.c clki->min_freq = clkfreq[i]; clki 118 drivers/scsi/ufs/ufshcd-pltfrm.c clki->max_freq = clkfreq[i+1]; clki 119 drivers/scsi/ufs/ufshcd-pltfrm.c clki->name = kstrdup(name, GFP_KERNEL); clki 121 drivers/scsi/ufs/ufshcd-pltfrm.c clki->min_freq, clki->max_freq, clki->name); clki 122 drivers/scsi/ufs/ufshcd-pltfrm.c list_add_tail(&clki->list, &hba->clk_list_head); clki 369 drivers/scsi/ufs/ufshcd.c struct ufs_clk_info *clki; clki 375 drivers/scsi/ufs/ufshcd.c list_for_each_entry(clki, head, list) { clki 376 drivers/scsi/ufs/ufshcd.c if (!IS_ERR_OR_NULL(clki->clk) && clki->min_freq && clki 377 drivers/scsi/ufs/ufshcd.c clki->max_freq) clki 379 drivers/scsi/ufs/ufshcd.c clki->name, clki->curr_freq); clki 906 drivers/scsi/ufs/ufshcd.c struct ufs_clk_info *clki; clki 918 drivers/scsi/ufs/ufshcd.c list_for_each_entry(clki, head, list) { clki 919 drivers/scsi/ufs/ufshcd.c if (!IS_ERR_OR_NULL(clki->clk)) { clki 920 drivers/scsi/ufs/ufshcd.c if (scale_up && clki->max_freq) { clki 921 drivers/scsi/ufs/ufshcd.c if (clki->curr_freq == clki->max_freq) clki 925 drivers/scsi/ufs/ufshcd.c ret = clk_set_rate(clki->clk, clki->max_freq); clki 928 drivers/scsi/ufs/ufshcd.c __func__, clki->name, clki 929 drivers/scsi/ufs/ufshcd.c clki->max_freq, ret); clki 933 drivers/scsi/ufs/ufshcd.c "scaled up", clki->name, clki 934 drivers/scsi/ufs/ufshcd.c clki->curr_freq, clki 935 drivers/scsi/ufs/ufshcd.c clki->max_freq); clki 937 drivers/scsi/ufs/ufshcd.c clki->curr_freq = clki->max_freq; clki 939 drivers/scsi/ufs/ufshcd.c } else if (!scale_up && clki->min_freq) { clki 940 drivers/scsi/ufs/ufshcd.c if (clki->curr_freq == clki->min_freq) clki 944 drivers/scsi/ufs/ufshcd.c ret = clk_set_rate(clki->clk, clki->min_freq); clki 947 drivers/scsi/ufs/ufshcd.c __func__, clki->name, clki 948 drivers/scsi/ufs/ufshcd.c clki->min_freq, ret); clki 952 drivers/scsi/ufs/ufshcd.c "scaled down", clki->name, clki 953 drivers/scsi/ufs/ufshcd.c clki->curr_freq, clki 954 drivers/scsi/ufs/ufshcd.c clki->min_freq); clki 955 drivers/scsi/ufs/ufshcd.c clki->curr_freq = clki->min_freq; clki 959 drivers/scsi/ufs/ufshcd.c clki->name, clk_get_rate(clki->clk)); clki 982 drivers/scsi/ufs/ufshcd.c struct ufs_clk_info *clki; clki 988 drivers/scsi/ufs/ufshcd.c list_for_each_entry(clki, head, list) { clki 989 drivers/scsi/ufs/ufshcd.c if (!IS_ERR_OR_NULL(clki->clk)) { clki 990 drivers/scsi/ufs/ufshcd.c if (scale_up && clki->max_freq) { clki 991 drivers/scsi/ufs/ufshcd.c if (clki->curr_freq == clki->max_freq) clki 994 drivers/scsi/ufs/ufshcd.c } else if (!scale_up && clki->min_freq) { clki 995 drivers/scsi/ufs/ufshcd.c if (clki->curr_freq == clki->min_freq) clki 1229 drivers/scsi/ufs/ufshcd.c struct ufs_clk_info *clki; clki 1249 drivers/scsi/ufs/ufshcd.c clki = list_first_entry(&hba->clk_list_head, struct ufs_clk_info, list); clki 1250 drivers/scsi/ufs/ufshcd.c scale_up = (*freq == clki->max_freq) ? true : false; clki 1321 drivers/scsi/ufs/ufshcd.c struct ufs_clk_info *clki; clki 1329 drivers/scsi/ufs/ufshcd.c clki = list_first_entry(clk_list, struct ufs_clk_info, list); clki 1330 drivers/scsi/ufs/ufshcd.c dev_pm_opp_add(hba->dev, clki->min_freq, 0); clki 1331 drivers/scsi/ufs/ufshcd.c dev_pm_opp_add(hba->dev, clki->max_freq, 0); clki 1341 drivers/scsi/ufs/ufshcd.c dev_pm_opp_remove(hba->dev, clki->min_freq); clki 1342 drivers/scsi/ufs/ufshcd.c dev_pm_opp_remove(hba->dev, clki->max_freq); clki 1354 drivers/scsi/ufs/ufshcd.c struct ufs_clk_info *clki; clki 1362 drivers/scsi/ufs/ufshcd.c clki = list_first_entry(clk_list, struct ufs_clk_info, list); clki 1363 drivers/scsi/ufs/ufshcd.c dev_pm_opp_remove(hba->dev, clki->min_freq); clki 1364 drivers/scsi/ufs/ufshcd.c dev_pm_opp_remove(hba->dev, clki->max_freq); clki 7280 drivers/scsi/ufs/ufshcd.c struct ufs_clk_info *clki; clki 7300 drivers/scsi/ufs/ufshcd.c list_for_each_entry(clki, head, list) { clki 7301 drivers/scsi/ufs/ufshcd.c if (!IS_ERR_OR_NULL(clki->clk)) { clki 7302 drivers/scsi/ufs/ufshcd.c if (skip_ref_clk && !strcmp(clki->name, "ref_clk")) clki 7305 drivers/scsi/ufs/ufshcd.c clk_state_changed = on ^ clki->enabled; clki 7306 drivers/scsi/ufs/ufshcd.c if (on && !clki->enabled) { clki 7307 drivers/scsi/ufs/ufshcd.c ret = clk_prepare_enable(clki->clk); clki 7310 drivers/scsi/ufs/ufshcd.c __func__, clki->name, ret); clki 7313 drivers/scsi/ufs/ufshcd.c } else if (!on && clki->enabled) { clki 7314 drivers/scsi/ufs/ufshcd.c clk_disable_unprepare(clki->clk); clki 7316 drivers/scsi/ufs/ufshcd.c clki->enabled = on; clki 7318 drivers/scsi/ufs/ufshcd.c clki->name, on ? "en" : "dis"); clki 7335 drivers/scsi/ufs/ufshcd.c list_for_each_entry(clki, head, list) { clki 7336 drivers/scsi/ufs/ufshcd.c if (!IS_ERR_OR_NULL(clki->clk) && clki->enabled) clki 7337 drivers/scsi/ufs/ufshcd.c clk_disable_unprepare(clki->clk); clki 7362 drivers/scsi/ufs/ufshcd.c struct ufs_clk_info *clki; clki 7369 drivers/scsi/ufs/ufshcd.c list_for_each_entry(clki, head, list) { clki 7370 drivers/scsi/ufs/ufshcd.c if (!clki->name) clki 7373 drivers/scsi/ufs/ufshcd.c clki->clk = devm_clk_get(dev, clki->name); clki 7374 drivers/scsi/ufs/ufshcd.c if (IS_ERR(clki->clk)) { clki 7375 drivers/scsi/ufs/ufshcd.c ret = PTR_ERR(clki->clk); clki 7377 drivers/scsi/ufs/ufshcd.c __func__, clki->name, ret); clki 7386 drivers/scsi/ufs/ufshcd.c if (!strcmp(clki->name, "ref_clk")) clki 7387 drivers/scsi/ufs/ufshcd.c ufshcd_parse_dev_ref_clk_freq(hba, clki->clk); clki 7389 drivers/scsi/ufs/ufshcd.c if (clki->max_freq) { clki 7390 drivers/scsi/ufs/ufshcd.c ret = clk_set_rate(clki->clk, clki->max_freq); clki 7393 drivers/scsi/ufs/ufshcd.c __func__, clki->name, clki 7394 drivers/scsi/ufs/ufshcd.c clki->max_freq, ret); clki 7397 drivers/scsi/ufs/ufshcd.c clki->curr_freq = clki->max_freq; clki 7400 drivers/scsi/ufs/ufshcd.c clki->name, clk_get_rate(clki->clk));