]> Git Repo - linux.git/commitdiff
interconnect: qcom: use icc_sync state for sm8[12]50
authorDmitry Baryshkov <[email protected]>
Tue, 27 Oct 2020 13:34:18 +0000 (16:34 +0300)
committerGeorgi Djakov <[email protected]>
Tue, 27 Oct 2020 14:01:22 +0000 (16:01 +0200)
In addition to the rest of Qcom interconnect drivers use icc_sync_state
for SM8150/SM8250 interconnect drivers to notify the interconnect
framework when all consumers are probed and there is no need to keep the
bandwidth set to maximum anymore.

Also move the BCM initialization before creating the nodes to set the
max bandwidth in hardware for the initialization/probing stage.

Signed-off-by: Dmitry Baryshkov <[email protected]>
Fixes: 7d3b0b0d8184 ("interconnect: qcom: Use icc_sync_state")
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Georgi Djakov <[email protected]>
drivers/interconnect/qcom/sm8150.c
drivers/interconnect/qcom/sm8250.c

index 9218efed04a072235e992ec572e2f884980d6bce..c76b2c7f9b106dad1a2807bacbbbf939531de873 100644 (file)
@@ -551,6 +551,9 @@ static int qnoc_probe(struct platform_device *pdev)
                return ret;
        }
 
+       for (i = 0; i < qp->num_bcms; i++)
+               qcom_icc_bcm_init(qp->bcms[i], &pdev->dev);
+
        for (i = 0; i < num_nodes; i++) {
                size_t j;
 
@@ -574,9 +577,6 @@ static int qnoc_probe(struct platform_device *pdev)
        }
        data->num_nodes = num_nodes;
 
-       for (i = 0; i < qp->num_bcms; i++)
-               qcom_icc_bcm_init(qp->bcms[i], &pdev->dev);
-
        platform_set_drvdata(pdev, qp);
 
        return 0;
@@ -627,6 +627,7 @@ static struct platform_driver qnoc_driver = {
        .driver = {
                .name = "qnoc-sm8150",
                .of_match_table = qnoc_of_match,
+               .sync_state = icc_sync_state,
        },
 };
 module_platform_driver(qnoc_driver);
index 9b58946f789837b654f7cad7ad747afc7493d3b6..cc558fec74e38780de5d42b75ca412cee7a9bb7b 100644 (file)
@@ -567,6 +567,9 @@ static int qnoc_probe(struct platform_device *pdev)
                return ret;
        }
 
+       for (i = 0; i < qp->num_bcms; i++)
+               qcom_icc_bcm_init(qp->bcms[i], &pdev->dev);
+
        for (i = 0; i < num_nodes; i++) {
                size_t j;
 
@@ -590,9 +593,6 @@ static int qnoc_probe(struct platform_device *pdev)
        }
        data->num_nodes = num_nodes;
 
-       for (i = 0; i < qp->num_bcms; i++)
-               qcom_icc_bcm_init(qp->bcms[i], &pdev->dev);
-
        platform_set_drvdata(pdev, qp);
 
        return 0;
@@ -643,6 +643,7 @@ static struct platform_driver qnoc_driver = {
        .driver = {
                .name = "qnoc-sm8250",
                .of_match_table = qnoc_of_match,
+               .sync_state = icc_sync_state,
        },
 };
 module_platform_driver(qnoc_driver);
This page took 0.062352 seconds and 4 git commands to generate.