]> git.baikalelectronics.ru Git - kernel.git/commit
clk: at91: fix at91sam9x5 peripheral clock number
authorAlexandre Belloni <alexandre.belloni@bootlin.com>
Tue, 19 Feb 2019 16:51:14 +0000 (17:51 +0100)
committerStephen Boyd <sboyd@kernel.org>
Wed, 20 Feb 2019 19:34:24 +0000 (11:34 -0800)
commit14a9d3ef40955ec2568b8d78982ab5ffff87a56b
tree2cc85a0f9758fa9e181a871f4d818189ee8ff223
parent490c7cf9134b5f784360766f25887d846b586fd0
clk: at91: fix at91sam9x5 peripheral clock number

nck() looks at the last id in an array and unfortunately,
at91sam9x35_periphck has a sentinel, hence the id is 0 and the calculated
number of peripheral clocks is 1 instead of a maximum of 31.

Fixes: 1063a4ec4ff9 ("clk: at91: add at91sam9x5 PMCs driver")
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Acked-by: Nicolas Ferre <nicolas.ferre@microchip.com>
Cc: <stable@vger.kernel.org> # v4.20+
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
drivers/clk/at91/at91sam9x5.c