Loading drivers/gpu/msm/adreno.c +24 −0 Original line number Diff line number Diff line Loading @@ -993,6 +993,26 @@ static int adreno_of_parse_pwrlevels(struct adreno_device *adreno_dev, return 0; } static void adreno_of_get_bimc_iface_clk(struct adreno_device *adreno_dev, struct device_node *node) { struct kgsl_device *device = KGSL_DEVICE(adreno_dev); struct kgsl_pwrctrl *pwr = &device->pwrctrl; /* Getting gfx-bimc-interface-clk frequency */ if (!of_property_read_u32(node, "qcom,gpu-bimc-interface-clk-freq", &pwr->gpu_bimc_int_clk_freq)) { pwr->gpu_bimc_int_clk = devm_clk_get(&device->pdev->dev, "bimc_gpu_clk"); if (IS_ERR_OR_NULL(pwr->gpu_bimc_int_clk)) { dev_err(&device->pdev->dev, "dt: Couldn't get bimc_gpu_clk (%d)\n", PTR_ERR(pwr->gpu_bimc_int_clk)); pwr->gpu_bimc_int_clk = NULL; } } } static void adreno_of_get_initial_pwrlevel(struct adreno_device *adreno_dev, struct device_node *node) { Loading Loading @@ -1050,6 +1070,8 @@ static int adreno_of_get_legacy_pwrlevels(struct adreno_device *adreno_dev, adreno_of_get_limits(adreno_dev, parent); adreno_of_get_bimc_iface_clk(adreno_dev, parent); return 0; } Loading Loading @@ -1077,6 +1099,8 @@ static int adreno_of_get_pwrlevels(struct adreno_device *adreno_dev, adreno_of_get_initial_pwrlevel(adreno_dev, child); adreno_of_get_bimc_iface_clk(adreno_dev, child); /* * Check for global throttle-pwrlevel first and override * with speedbin specific one if found. Loading drivers/gpu/msm/kgsl_pwrctrl.c +0 −7 Original line number Diff line number Diff line Loading @@ -2266,13 +2266,6 @@ int kgsl_pwrctrl_init(struct kgsl_device *device) if (pwr->grp_clks[0] == NULL) pwr->grp_clks[0] = pwr->grp_clks[1]; /* Getting gfx-bimc-interface-clk frequency */ if (!of_property_read_u32(pdev->dev.of_node, "qcom,gpu-bimc-interface-clk-freq", &pwr->gpu_bimc_int_clk_freq)) pwr->gpu_bimc_int_clk = devm_clk_get(&pdev->dev, "bimc_gpu_clk"); if (of_property_read_bool(pdev->dev.of_node, "qcom,no-nap")) device->pwrctrl.ctrl_flags |= BIT(KGSL_PWRFLAGS_NAP_OFF); Loading Loading
drivers/gpu/msm/adreno.c +24 −0 Original line number Diff line number Diff line Loading @@ -993,6 +993,26 @@ static int adreno_of_parse_pwrlevels(struct adreno_device *adreno_dev, return 0; } static void adreno_of_get_bimc_iface_clk(struct adreno_device *adreno_dev, struct device_node *node) { struct kgsl_device *device = KGSL_DEVICE(adreno_dev); struct kgsl_pwrctrl *pwr = &device->pwrctrl; /* Getting gfx-bimc-interface-clk frequency */ if (!of_property_read_u32(node, "qcom,gpu-bimc-interface-clk-freq", &pwr->gpu_bimc_int_clk_freq)) { pwr->gpu_bimc_int_clk = devm_clk_get(&device->pdev->dev, "bimc_gpu_clk"); if (IS_ERR_OR_NULL(pwr->gpu_bimc_int_clk)) { dev_err(&device->pdev->dev, "dt: Couldn't get bimc_gpu_clk (%d)\n", PTR_ERR(pwr->gpu_bimc_int_clk)); pwr->gpu_bimc_int_clk = NULL; } } } static void adreno_of_get_initial_pwrlevel(struct adreno_device *adreno_dev, struct device_node *node) { Loading Loading @@ -1050,6 +1070,8 @@ static int adreno_of_get_legacy_pwrlevels(struct adreno_device *adreno_dev, adreno_of_get_limits(adreno_dev, parent); adreno_of_get_bimc_iface_clk(adreno_dev, parent); return 0; } Loading Loading @@ -1077,6 +1099,8 @@ static int adreno_of_get_pwrlevels(struct adreno_device *adreno_dev, adreno_of_get_initial_pwrlevel(adreno_dev, child); adreno_of_get_bimc_iface_clk(adreno_dev, child); /* * Check for global throttle-pwrlevel first and override * with speedbin specific one if found. Loading
drivers/gpu/msm/kgsl_pwrctrl.c +0 −7 Original line number Diff line number Diff line Loading @@ -2266,13 +2266,6 @@ int kgsl_pwrctrl_init(struct kgsl_device *device) if (pwr->grp_clks[0] == NULL) pwr->grp_clks[0] = pwr->grp_clks[1]; /* Getting gfx-bimc-interface-clk frequency */ if (!of_property_read_u32(pdev->dev.of_node, "qcom,gpu-bimc-interface-clk-freq", &pwr->gpu_bimc_int_clk_freq)) pwr->gpu_bimc_int_clk = devm_clk_get(&pdev->dev, "bimc_gpu_clk"); if (of_property_read_bool(pdev->dev.of_node, "qcom,no-nap")) device->pwrctrl.ctrl_flags |= BIT(KGSL_PWRFLAGS_NAP_OFF); Loading