- 28 11月, 2018 1 次提交
-
-
由 Amit Nischal 提交于
Add support for the graphics clock controller found on SDM845 based devices. This would allow graphics drivers to probe and control their clocks. Signed-off-by: NAmit Nischal <anischal@codeaurora.org> Signed-off-by: NTaniya Das <tdas@codeaurora.org> [sboyd@kernel.org: Collapse return in probe into less lines] Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 19 10月, 2018 2 次提交
-
-
由 Evan Green 提交于
This change removes a parent map and parent name array that appear to be completely unreferenced. Signed-off-by: NEvan Green <evgreen@chromium.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Stephen Boyd 提交于
Add a module license to match the license at the top of this file and silence a build warning. Reported-by: NStephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 18 10月, 2018 8 次提交
-
-
由 Sricharan R 提交于
When the Hfplls are reprogrammed during the rate change, the primary muxes which are sourced from the same hfpll for higher frequencies, needs to be switched to the 'safe secondary mux' as the parent for that small window. This is done by registering a clk notifier for the muxes and switching to the safe parent in the PRE_RATE_CHANGE notifier and back to the original parent in the POST_RATE_CHANGE notifier. Signed-off-by: NSricharan R <sricharan@codeaurora.org> Tested-by: NCraig Tatlor <ctatlor97@gmail.com> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Stephen Boyd 提交于
The Krait CPU clocks are made up of a primary mux and secondary mux for each CPU and the L2, controlled via cp15 accessors. For Kraits within KPSSv1 each secondary mux accepts a different aux source, but on KPSSv2 each secondary mux accepts the same aux source. Cc: <devicetree@vger.kernel.org> Signed-off-by: NStephen Boyd <sboyd@codeaurora.org> Signed-off-by: NSricharan R <sricharan@codeaurora.org> Tested-by: NCraig Tatlor <ctatlor97@gmail.com> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Stephen Boyd 提交于
The ACC and GCC regions present in KPSSv1 contain registers to control clocks and power to each Krait CPU and L2. For CPUfreq purposes probe these devices and expose a mux clock that chooses between PXO and PLL8. Cc: <devicetree@vger.kernel.org> Signed-off-by: NStephen Boyd <sboyd@codeaurora.org> Signed-off-by: NSricharan R <sricharan@codeaurora.org> Tested-by: NCraig Tatlor <ctatlor97@gmail.com> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Stephen Boyd 提交于
The Krait clocks are made up of a series of muxes and a divider that choose between a fixed rate clock and dedicated HFPLLs for each CPU. Instead of using mmio accesses to remux parents, the Krait implementation exposes the remux control via cp15 registers. Support these clocks. Signed-off-by: NStephen Boyd <sboyd@codeaurora.org> Signed-off-by: NSricharan R <sricharan@codeaurora.org> Tested-by: NCraig Tatlor <ctatlor97@gmail.com> [sboyd@kernel.org: Move hidden config to top outside of the visible qcom config zone so that menuconfig looks nice] Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Stephen Boyd 提交于
Describe the HFPLLs present on IPQ806X devices. Signed-off-by: NStephen Boyd <sboyd@codeaurora.org> Signed-off-by: NSricharan R <sricharan@codeaurora.org> Tested-by: NCraig Tatlor <ctatlor97@gmail.com> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Stephen Boyd 提交于
Describe the HFPLLs present on MSM8960 and APQ8064 devices. Acked-by: Rob Herring <robh@kernel.org> (bindings) Signed-off-by: NStephen Boyd <sboyd@codeaurora.org> Signed-off-by: NSricharan R <sricharan@codeaurora.org> Tested-by: NCraig Tatlor <ctatlor97@gmail.com> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Stephen Boyd 提交于
On some devices (MSM8974 for example), the HFPLLs are instantiated within the Krait processor subsystem as separate register regions. Add a driver for these PLLs so that we can provide HFPLL clocks for use by the system. Cc: <devicetree@vger.kernel.org> Signed-off-by: NStephen Boyd <sboyd@codeaurora.org> Signed-off-by: NSricharan R <sricharan@codeaurora.org> Tested-by: NCraig Tatlor <ctatlor97@gmail.com> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Stephen Boyd 提交于
HFPLLs are the main frequency source for Krait CPU clocks. Add support for changing the rate of these PLLs. Signed-off-by: NStephen Boyd <sboyd@codeaurora.org> Signed-off-by: NSricharan R <sricharan@codeaurora.org> Tested-by: NCraig Tatlor <ctatlor97@gmail.com> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 17 10月, 2018 3 次提交
-
-
由 Shefali Jain 提交于
Add the clocks supported in global clock controller which clock the peripherals like BLSPs, SDCC, USB, MDSS etc. Register all the clocks to the clock framework for the clients to be able to request for them. Signed-off-by: NShefali Jain <shefjain@codeaurora.org> Signed-off-by: NTaniya Das <tdas@codeaurora.org> Co-developed-by: NTaniya Das <tdas@codeaurora.org> Signed-off-by: NAnu Ramanathan <anur@codeaurora.org> [bamse, vkoul: rebase and tidyup for upstream] Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NVinod Koul <vkoul@kernel.org> Acked-by: NRob Herring <robh@kernel.org> [sboyd@kernel.org: Lowercase hex] Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Bjorn Andersson 提交于
This is used by the QCS404 GCC driver, export it to allow that driver to be compiled as a module.. Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Taniya Das 提交于
Add support for the global clock controller found on SDM660 based devices. This should allow most non-multimedia device drivers to probe and control their clocks. Based on CAF implementation. Signed-off-by: NTaniya Das <tdas@codeaurora.org> [craig: rename parents to fit upstream, and other cleanups] Signed-off-by: NCraig Tatlor <ctatlor97@gmail.com> Acked-by: NRob Herring <robh@kernel.org> [sboyd@kernel.org: Rename gcc_660 to gcc_sdm660 and fix numbering of defines to avoid duplicates] Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 31 8月, 2018 3 次提交
-
-
由 Amit Nischal 提交于
Add support for the camera clock controller found on SDM845 based devices. This would allow camera drivers to probe and control their clocks. Signed-off-by: NAmit Nischal <anischal@codeaurora.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Gustavo A. R. Silva 提交于
Return statements in functions returning bool should use true or false instead of an integer value. This code was detected with the help of Coccinelle. Signed-off-by: NGustavo A. R. Silva <gustavo@embeddedor.com> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Douglas Anderson 提交于
The table allocated in clk_rcg2_dfs_populate_freq_table() is eventually iterated over by qcom_find_freq() which assumes that the table is NULL terminated. Allocate one extra space in the array for the NULL termination. Initting of the NULL termination is implicit due to kcalloc(). Fixes: cc4f6944 ("clk: qcom: Add support for RCG to register for DFS") Signed-off-by: NDouglas Anderson <dianders@chromium.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 29 8月, 2018 2 次提交
-
-
由 Douglas Anderson 提交于
Add both the interface and core clock. Signed-off-by: NDouglas Anderson <dianders@chromium.org> Reviewed-by: NTaniya Das <tdas@codeaurora.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Rajendra Nayak 提交于
Add a few missing gcc clks for msm8996 Signed-off-by: NRajendra Nayak <rnayak@codeaurora.org> [bjorn: omit aggre0_noc_qosgen_extref_clk] Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org> Reviewed-by: NRob Herring <robh@kernel.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 28 8月, 2018 2 次提交
-
-
由 Taniya Das 提交于
QUPv3 clocks support DFS and thus register the RCGs which require support for the same. Signed-off-by: NTaniya Das <tdas@codeaurora.org> [sboyd@kernel.org: Use new macro, split out init structures so they don't have to be copied] Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Taniya Das 提交于
Dynamic Frequency switch is a feature of clock controller by which request from peripherals allows automatic switching frequency of input clock without SW intervention. There are various performance levels associated with a root clock. When the input performance state changes, the source clocks and division ratios of the new performance state are loaded on to RCG via HW and the RCG switches to new clock frequency when the RCG is in DFS HW enabled mode. Register the root clock generators(RCG) to switch to use the dfs clock ops in the cases where DFS is enabled. The clk_round_rate() called by the clock consumer would invoke the dfs determine clock ops and would read the DFS performance level registers to identify all the frequencies supported and update the frequency table. The DFS clock consumers would maintain these frequency mapping and request the desired performance levels. Signed-off-by: NTaniya Das <tdas@codeaurora.org> [sboyd@kernel.org: Rework registration logic to stop copying, change recalc_rate() to index directly into the table if possible and fallback to calculating on the fly with an assumed correct parent] Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 01 8月, 2018 1 次提交
-
-
由 Taniya Das 提交于
Add support for the display clock controller found on SDM845 based devices. This would allow display drivers to probe and control their clocks. Signed-off-by: NTaniya Das <tdas@codeaurora.org> [sboyd@kernel.org: Remove CLK_GET_RATE_NOCACHE everywhere] Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 26 7月, 2018 1 次提交
-
-
由 Taniya Das 提交于
SPDX headers updated for common/branch/pll/regmap files. Signed-off-by: NTaniya Das <tdas@codeaurora.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 17 7月, 2018 1 次提交
-
-
由 Taniya Das 提交于
Add the RPMh clock driver to control the RPMh managed clock resources on some of the Qualcomm Technologies, Inc. SoCs. Signed-off-by: NTaniya Das <tdas@codeaurora.org> [sboyd@kernel.org: Clean up whitespace, indentation, remove cmd_db_ready check] Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 07 7月, 2018 3 次提交
-
-
由 Taniya Das 提交于
Frequency table macro is used by multiple clock drivers, move frequency table macro to common header file. Signed-off-by: NTaniya Das <tdas@codeaurora.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Vivek Gautam 提交于
Patch (7705bb71 clk: qcom: mmcc-msm8996: leave all mmagic gdscs and clocks always enabled") makes all mmgaic gdscs ALWAYS_ON. The mmagic_bimc_gdsc is also needed to be turned on to get display working on 8x96. Signed-off-by: NVivek Gautam <vivek.gautam@codeaurora.org> Cc: Rajendra Nayak <rnayak@codeaurora.org> Cc: Bjorn Andersson <bjorn.andersson@linaro.org> Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Fixes: 7705bb71 ("clk: qcom: mmcc-msm8996: leave all mmagic gdscs and clocks always enabled") Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Vinod Koul 提交于
Commit 12d807cd ("clk: qcom: gcc-msm8996: Disable halt check on UFS clocks") marked BRANCH_HALT_SKIP for ufs rx clocks, but missed ufs tx clocks. The result of that is kernel warnings at reboot: [ 105.624283] gcc_ufs_tx_symbol_0_clk status stuck at 'on' [ 105.624311] WARNING: CPU: 1 PID: 1 at drivers/clk/qcom/clk-branch.c:100 clk_branch_toggle+0x190/0x1b0 [ 105.633235] Modules linked in: [ 105.645118] CPU: 1 PID: 1 Comm: systemd-shutdow Tainted: G W 4.18.0-rc2-00002-g2bfbe52a53a3 #11 [ 105.647988] Hardware name: Qualcomm Technologies, Inc. DB820c (DT) [ 105.657966] pstate: 60000085 (nZCv daIf -PAN -UAO) [ 105.664127] pc : clk_branch_toggle+0x190/0x1b0 [ 105.668900] lr : clk_branch_toggle+0x190/0x1b0 [ 105.673324] sp : ffff00000805bb40 [ 105.677751] x29: ffff00000805bb40 x28: 0000000000000000 [ 105.681140] x27: ffff8000d947cc60 x26: 0000000000000001 [ 105.686520] x25: ffff000008f71900 x24: 0000000000000000 [ 105.691816] x23: ffff00000925e338 x22: ffff00000855f8e0 [ 105.697114] x21: 0000000000000000 x20: 0000000000000000 [ 105.702407] x19: ffff0000091c9000 x18: ffffffffffffffff [ 105.707702] x17: 0000ffffac148c58 x16: ffff000008b82928 [ 105.712998] x15: ffff0000091c96c8 x14: ffff0000893817c7 [ 105.718293] x13: ffff0000093817d5 x12: ffff0000091c9940 [ 105.723587] x11: ffff0000085e3e70 x10: ffff00000805b780 [ 105.728884] x9 : ffff00000805bb40 x8 : 7320737574617473 [ 105.734179] x7 : 206b6c635f305f6c x6 : 00000000000001e5 [ 105.739472] x5 : 0000000000000000 x4 : 0000000000000000 [ 105.744769] x3 : ffffffffffffffff x2 : ffff0000091e2658 [ 105.750063] x1 : a7c4712dd5e09c00 x0 : 0000000000000000 [ 105.755360] Call trace: [ 105.760652] clk_branch_toggle+0x190/0x1b0 [ 105.762824] clk_branch2_disable+0x18/0x20 [ 105.766994] clk_core_disable+0x58/0xa8 [ 105.771069] clk_core_disable_lock+0x20/0x38 [ 105.774803] clk_disable+0x1c/0x28 [ 105.779320] __ufshcd_setup_clocks+0x298/0x308 [ 105.782529] ufshcd_suspend+0x160/0x308 [ 105.786953] ufshcd_shutdown+0x38/0xa0 [ 105.790690] ufshcd_pltfrm_shutdown+0x10/0x18 [ 105.794512] platform_drv_shutdown+0x20/0x30 [ 105.798935] device_shutdown+0x110/0x1e8 [ 105.803278] kernel_restart_prepare+0x34/0x40 [ 105.807181] kernel_restart+0x14/0x78 [ 105.811434] sys_reboot+0x200/0x248 [ 105.815081] el0_svc_naked+0x30/0x34 [ 105.818378] ---[ end trace 8d2322276b27879c ]--- Mark gcc_ufs_tx_symbol_0_clk as BRANCH_HALT_SKIP as well. Fixes: 12d807cd ("clk: qcom: gcc-msm8996: Disable halt check on UFS clocks") Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 04 7月, 2018 1 次提交
-
-
由 Amit Nischal 提交于
There are certain clocks which needs to be always enabled for system operation. Add support for the same by adding 'CLK_IS_CRITICAL' flag for such clocks. Signed-off-by: NAmit Nischal <anischal@codeaurora.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 20 6月, 2018 1 次提交
-
-
由 Jerome Brunet 提交于
the mmci driver (drivers/mmc/host/mmci.c) does the following sequence: * clk_prepare_enable() * clk_set_rate() on SDCx_clk which is a children of SDCx_src. SDCx_src has CLK_SET_RATE_GATE so this sequence should not be allowed but this was not enforced. IOW, the flag is ignored. Dropping the flag won't change anything to the current behaviour of the platform. CLK_SET_RATE_GATE is being fixed and enforced now. If the flag was kept, the mmci driver would receive -EBUSY when calling clk_set_rate() Signed-off-by: NJerome Brunet <jbrunet@baylibre.com> Signed-off-by: NMichael Turquette <mturquette@baylibre.com> Link: lkml.kernel.org/r/20180619134051.16726-2-jbrunet@baylibre.com
-
- 07 6月, 2018 1 次提交
-
-
由 Kees Cook 提交于
Replaces open-coded struct size calculations with struct_size() for devm_*, f2fs_*, and sock_* allocations. Automatically generated (and manually adjusted) from the following Coccinelle script: // Direct reference to struct field. @@ identifier alloc =~ "devm_kmalloc|devm_kzalloc|sock_kmalloc|f2fs_kmalloc|f2fs_kzalloc"; expression HANDLE; expression GFP; identifier VAR, ELEMENT; expression COUNT; @@ - alloc(HANDLE, sizeof(*VAR) + COUNT * sizeof(*VAR->ELEMENT), GFP) + alloc(HANDLE, struct_size(VAR, ELEMENT, COUNT), GFP) // mr = kzalloc(sizeof(*mr) + m * sizeof(mr->map[0]), GFP_KERNEL); @@ identifier alloc =~ "devm_kmalloc|devm_kzalloc|sock_kmalloc|f2fs_kmalloc|f2fs_kzalloc"; expression HANDLE; expression GFP; identifier VAR, ELEMENT; expression COUNT; @@ - alloc(HANDLE, sizeof(*VAR) + COUNT * sizeof(VAR->ELEMENT[0]), GFP) + alloc(HANDLE, struct_size(VAR, ELEMENT, COUNT), GFP) // Same pattern, but can't trivially locate the trailing element name, // or variable name. @@ identifier alloc =~ "devm_kmalloc|devm_kzalloc|sock_kmalloc|f2fs_kmalloc|f2fs_kzalloc"; expression HANDLE; expression GFP; expression SOMETHING, COUNT, ELEMENT; @@ - alloc(HANDLE, sizeof(SOMETHING) + COUNT * sizeof(ELEMENT), GFP) + alloc(HANDLE, CHECKME_struct_size(&SOMETHING, ELEMENT, COUNT), GFP) Signed-off-by: NKees Cook <keescook@chromium.org>
-
- 02 6月, 2018 7 次提交
-
-
由 Stephen Boyd 提交于
This is used by the video clk driver on sdm845 and that's a module. Export it to prevent module build failures. Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Bjorn Andersson 提交于
The halt check of the UFS symbol clocks always fails, as such probing UFS after clk_disable_unused always fails. This makes it impossible to boot a system with the UFS phy or UFS HCD drivers compiled as modules. Follow SDM845 and disable the halt check on these clocks. Signed-off-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Amit Nischal 提交于
Add support for the video clock controller found on SDM845 based devices. This would allow video drivers to probe and control their clocks. Signed-off-by: NAmit Nischal <anischal@codeaurora.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Manu Gautam 提交于
The USB and PCIE pipe clocks are sourced from external clocks inside the QMP USB/PCIE PHYs. Enabling or disabling of PIPE RCG clocks is dependent on PHY initialization sequence hence update halt_check to BRANCH_HALT_SKIP for these clocks so that clock status bit is not polled when enabling or disabling the clocks. It allows to simplify PHY client driver code which is both user and source of the pipe_clk and avoid error logging related status check on clk_disable/enable. Signed-off-by: NManu Gautam <mgautam@codeaurora.org> Reviewed-by: NDouglas Anderson <dianders@chromium.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Rajendra Nayak 提交于
There's no bus infrastructure today to handle all the mmagic bus clocks and GDSCs needed by all the multimedia blocks in msm8996, like mdss, video, camera and gpu. Mark all these clocks with a CLK_IS_CRITICAL and GDSCs with a ALWAYS_ON flag for now so they are left always enabled. This patch should be reverted at some point when we do have a bus driver to manage these clocks and GDSCs. Signed-off-by: NRajendra Nayak <rnayak@codeaurora.org> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Rajendra Nayak 提交于
We have atleast some instances of ALWAYS_ON gdscs, which need to be turned ON *before* some clocks within the gdsc domain marked with a CLK_IS_CRITICAL can be turned ON. To facilitate this sequence, register the GDCSs (and hence handle the ALWAYS_ON gdscs) before we register clocks (and handle the clocks marked as CLK_IS_CRITICAL) Signed-off-by: NRajendra Nayak <rnayak@codeaurora.org> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Tested-by: NSrinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Rajendra Nayak 提交于
Some GDSCs might have software control to turn them off, but we might want to keep them enabled always, in some cases because of lack of support in kernel to handle a graceful turning off/on of such GDSCs. Most common instances would be the GDCSs which power up the noc/bus fabrics, which need bus drivers to handle them and atleast support for which is missing on all qcom SoCs. Signed-off-by: NRajendra Nayak <rnayak@codeaurora.org> Reviewed-by: NBjorn Andersson <bjorn.andersson@linaro.org> Tested-by: NSrinivas Kandagatla <srinivas.kandagatla@linaro.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 11 5月, 2018 1 次提交
-
-
由 Evan Green 提交于
_freq_tbl_determine_rate uses the pre_div found in the clock plan multiplied by the requested rate from the caller to determine the best parent rate to set. If the requested rate is not exactly equal to the rate that was found in the clock plan, then using the requested rate in parent rate calculations is incorrect. For instance, if 150MHz was requested, but 200MHz was the match found, and that plan had a pre_div of 3, then the parent should be set to 600MHz, not 450MHz. Signed-off-by: NEvan Green <evgreen@chromium.org> Fixes: bcd61c0f ("clk: qcom: Add support for root clock generators (RCGs)") Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
- 09 5月, 2018 2 次提交
-
-
由 Taniya Das 提交于
Add support for the global clock controller found on SDM845 based devices. This should allow most non-multimedia device drivers to probe and control their clocks. Signed-off-by: NTaniya Das <tdas@codeaurora.org> Signed-off-by: NAmit Nischal <anischal@codeaurora.org> Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-
由 Amit Nischal 提交于
There could be few clocks where the clock status bit is not required to be polled as the clock on/off would be controlled by enabling/disabling external source. Add support for the same by introducing new flag named as 'BRANCH_HALT_SKIP'. Signed-off-by: NAmit Nischal <anischal@codeaurora.org> [sboyd@kernel.org: Rename flag to BRANCH_HALT_SKIP] Signed-off-by: NStephen Boyd <sboyd@kernel.org>
-