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

Commit ac95e480 authored by Patrick Daly's avatar Patrick Daly
Browse files

msm: clock-pll: Modify list_registers op for votable plls



Although votable PLLs may share the same interface, the underlying
PLL type may not be the same. Do not make assumptions about the PLL
register interface when printing out registers for debugging.

Change-Id: Ia033da62d6bc1aa0fd19aa3d51cf92b92ff35df6
Signed-off-by: default avatarPatrick Daly <pdaly@codeaurora.org>
parent 4bb26321
Loading
Loading
Loading
Loading
+5 −21
Original line number Diff line number Diff line
@@ -137,29 +137,13 @@ static void __iomem *pll_vote_clk_list_registers(struct clk *c, int n,
	static struct clk_register_data data1[] = {
		{"APPS_VOTE", 0x0},
	};
	/* Not compatible with 8960 & friends */
	static struct clk_register_data data2[] = {
		{"MODE", 0x0},
		{"L", 0x4},
		{"M", 0x8},
		{"N", 0xC},
		{"USER", 0x10},
		{"CONFIG", 0x14},
		{"STATUS", 0x1C},
	};

	switch (n) {
	case 0:
	if (n)
		return ERR_PTR(-EINVAL);

	*regs = data1;
	*size = ARRAY_SIZE(data1);
	return PLL_EN_REG(pllv);
	case 1:
		*regs = data2;
		*size = ARRAY_SIZE(data2);
		return PLL_STATUS_REG(pllv) - 0x1C;
	default:
		return ERR_PTR(-EINVAL);
	}
}

struct clk_ops clk_ops_pll_vote = {