Lines Matching full:scm

70  * struct qcom_scm_qseecom_resp - QSEECOM SCM call response.
71 * @result: Result or status of the SCM call. See &enum qcom_scm_qseecom_result.
265 if (of_device_is_compatible(__scm ? __scm->dev->of_node : NULL, "qcom,scm-sc7180")) { in __get_convention()
296 * Sends a command to the SCM and waits for the command to finish processing.
310 pr_err("Unknown current SCM calling convention.\n"); in qcom_scm_call()
321 * Sends a command to the SCM and waits for the command to finish processing.
335 pr_err("Unknown current SCM calling convention.\n"); in qcom_scm_call_atomic()
420 * Set the Linux entry point for the SCM to transfer control to when coming
426 /* Fallback to old SCM call */ in qcom_scm_set_warm_boot_addr()
439 /* Fallback to old SCM call */ in qcom_scm_set_cold_boot_addr()
591 * During the scm call memory protection will be enabled for the meta in qcom_scm_pas_init_image()
1163 * Return: true iff the SCM calls wrapped by qcom_scm_ice_invalidate_key() and
1180 * doesn't work on these SoCs; only this SCM call does.
1182 * It is assumed that the SoC has only one ICE instance being used, as this SCM
1215 * doesn't work on these SoCs; only this SCM call does.
1217 * It is assumed that the SoC has only one ICE instance being used, as this SCM
1282 * @resp: response buffer passed to SCM
1284 * Write HDCP register(s) through SCM.
1526 /* Lock for QSEECOM SCM call executions */
1536 * QSEECOM SCM calls should not be executed concurrently. Therefore, we in __qcom_scm_qseecom_call()
1554 * qcom_scm_qseecom_call() - Perform a QSEECOM SCM call.
1555 * @desc: SCM call descriptor.
1556 * @res: SCM call response (output).
1558 * Performs the QSEECOM SCM call described by @desc, returning the response in
1569 * Note: Multiple QSEECOM SCM calls should not be executed same time, in qcom_scm_qseecom_call()
1583 dev_err(__scm->dev, "qseecom: scm call failed with error %d\n", status); in qcom_scm_qseecom_call()
1605 * Performs the QSEECOM SCM querying the QSEECOM version currently running in
1779 static int qcom_scm_qseecom_init(struct qcom_scm *scm) in qcom_scm_qseecom_init() argument
1800 dev_info(scm->dev, "qseecom: found qseecom with version 0x%x\n", version); in qcom_scm_qseecom_init()
1803 dev_info(scm->dev, "qseecom: untested machine, skipping\n"); in qcom_scm_qseecom_init()
1815 qseecom_dev->dev.parent = scm->dev; in qcom_scm_qseecom_init()
1823 return devm_add_action_or_reset(scm->dev, qcom_scm_qseecom_free, qseecom_dev); in qcom_scm_qseecom_init()
1828 static int qcom_scm_qseecom_init(struct qcom_scm *scm) in qcom_scm_qseecom_init() argument
1836 * qcom_scm_is_available() - Checks if SCM is available
1887 struct qcom_scm *scm = data; in qcom_scm_irq_handler() local
1893 dev_err(scm->dev, "GET_WQ_CTX SMC call failed: %d\n", ret); in qcom_scm_irq_handler()
1898 dev_err(scm->dev, "Invalid flags received for wq_ctx: %u\n", flags); in qcom_scm_irq_handler()
1953 struct qcom_scm *scm; in qcom_scm_probe() local
1956 scm = devm_kzalloc(&pdev->dev, sizeof(*scm), GFP_KERNEL); in qcom_scm_probe()
1957 if (!scm) in qcom_scm_probe()
1960 scm->dev = &pdev->dev; in qcom_scm_probe()
1961 ret = qcom_scm_find_dload_address(&pdev->dev, &scm->dload_mode_addr); in qcom_scm_probe()
1965 init_completion(&scm->waitq_comp); in qcom_scm_probe()
1966 mutex_init(&scm->scm_bw_lock); in qcom_scm_probe()
1968 scm->path = devm_of_icc_get(&pdev->dev, NULL); in qcom_scm_probe()
1969 if (IS_ERR(scm->path)) in qcom_scm_probe()
1970 return dev_err_probe(&pdev->dev, PTR_ERR(scm->path), in qcom_scm_probe()
1973 scm->core_clk = devm_clk_get_optional(&pdev->dev, "core"); in qcom_scm_probe()
1974 if (IS_ERR(scm->core_clk)) in qcom_scm_probe()
1975 return PTR_ERR(scm->core_clk); in qcom_scm_probe()
1977 scm->iface_clk = devm_clk_get_optional(&pdev->dev, "iface"); in qcom_scm_probe()
1978 if (IS_ERR(scm->iface_clk)) in qcom_scm_probe()
1979 return PTR_ERR(scm->iface_clk); in qcom_scm_probe()
1981 scm->bus_clk = devm_clk_get_optional(&pdev->dev, "bus"); in qcom_scm_probe()
1982 if (IS_ERR(scm->bus_clk)) in qcom_scm_probe()
1983 return PTR_ERR(scm->bus_clk); in qcom_scm_probe()
1985 scm->reset.ops = &qcom_scm_pas_reset_ops; in qcom_scm_probe()
1986 scm->reset.nr_resets = 1; in qcom_scm_probe()
1987 scm->reset.of_node = pdev->dev.of_node; in qcom_scm_probe()
1988 ret = devm_reset_controller_register(&pdev->dev, &scm->reset); in qcom_scm_probe()
1993 ret = clk_set_rate(scm->core_clk, INT_MAX); in qcom_scm_probe()
1998 smp_store_release(&__scm, scm); in qcom_scm_probe()
2006 IRQF_ONESHOT, "qcom-scm", __scm); in qcom_scm_probe()
2008 return dev_err_probe(scm->dev, ret, "Failed to request qcom-scm irq\n"); in qcom_scm_probe()
2044 "Failed to create the SCM memory pool\n"); in qcom_scm_probe()
2053 * This means that there is no need to bring down the whole SCM driver. in qcom_scm_probe()
2054 * Just log the error instead and let SCM live. in qcom_scm_probe()
2056 ret = qcom_scm_qseecom_init(scm); in qcom_scm_probe()
2069 { .compatible = "qcom,scm" },
2072 { .compatible = "qcom,scm-apq8064" },
2073 { .compatible = "qcom,scm-apq8084" },
2074 { .compatible = "qcom,scm-ipq4019" },
2075 { .compatible = "qcom,scm-msm8953" },
2076 { .compatible = "qcom,scm-msm8974" },
2077 { .compatible = "qcom,scm-msm8996" },
2098 MODULE_DESCRIPTION("Qualcomm Technologies, Inc. SCM driver");