Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0b21e914 authored by Vikram Mulukutla's avatar Vikram Mulukutla
Browse files

msm: clock-8226: Allow measurement of clocks in the WCNSS



For debugging reasons, it is required that WLAN drivers
be able to measure clocks in the WCNSS subsystem. It is
assumed that the WCNSS debug mux is already programmed
by the WCNSS firmware.

Change-Id: I3e7411021200a96454f37a1d40a17b109be4fc70
Signed-off-by: default avatarVikram Mulukutla <markivx@codeaurora.org>
parent e241f3c5
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -1555,6 +1555,8 @@ static struct branch_clk gcc_usb_hsic_system_clk = {
	},
};

static DEFINE_CLK_MEASURE(wcnss_m_clk);

#ifdef CONFIG_DEBUG_FS
struct measure_mux_entry {
	struct clk *c;
@@ -1610,6 +1612,7 @@ static struct measure_mux_entry measure_mux_GCC[] = {
	{ &pnoc_clk.c, GCC_BASE, 0x010},
	{ &snoc_clk.c, GCC_BASE, 0x000},
	{ &cnoc_clk.c, GCC_BASE, 0x008},
	{ &wcnss_m_clk, GCC_BASE, 0x0198},
	/*
	 * measure the gcc_bimc_kpss_axi_clk instead to account for the DDR
	 * rate being gcc_bimc_clk/2.
@@ -3072,6 +3075,10 @@ static struct clk_lookup msm_clocks_8226[] = {
	CLK_LOOKUP("apc3_m_clk", apc3_m_clk, ""),
	CLK_LOOKUP("l2_m_clk", l2_m_clk, ""),

	/* Measure clocks for WCNSS */
	CLK_LOOKUP("measure",   measure_clk.c, "fb000000.qcom,wcnss-wlan"),
	CLK_LOOKUP("wcnss_debug", wcnss_m_clk, "fb000000.qcom,wcnss-wlan"),

	/* LPM Resources */
	CLK_LOOKUP("xo",          cxo_lpm_clk.c, "fc4281d0.qcom,mpm"),