From: =?UTF-8?q?Andreas=20Bie=C3=9Fmann?= Date: Tue, 3 Nov 2015 15:13:38 +0100 Subject: [U-Boot] [U-Boot, v3] arm: at91: clock: Add the generated clock support In-Reply-To: <1446169622-3708-1-git-send-email-wenyou.yang@atmel.com> (from Wenyou Yang on Fri, 30 Oct 2015 09:47:02 +0800) References: <1446169622-3708-1-git-send-email-wenyou.yang@atmel.com> Message-ID: <1446560018-1190-1-git-send-email-andreas.devel@googlemail.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Wenyou Yang, Wenyou Yang writes: >Some peripherals may need a second clock source that may be different >from the system clock. This second clock is the generated clock (GCK) >and is managed by the PMC via PMC_PCR. > >For simplicity, the clock source of the GCK is fixed to PLLA_CLK. > >Signed-off-by: Wenyou Yang >Reviewed-by: Andreas Bie?mann >--- > >Changes in v3: >1./ add arguments for at91_enable_periph_generated_clk(). >2./ add return value for at91_enable_periph_generated_clk(). > >Changes in v2: >1./ add timeout to wait for GCK ready. >2./ add warning for timeout to wait for GCK ready. >3./ add printout when the improper GCK clock source is selected. >4./ rework AT91_PMC_PCR_GCKDIV_(x) macro to make sure x is right. > > arch/arm/mach-at91/armv7/clock.c | 95 ++++++++++++++++++++++++++++ > arch/arm/mach-at91/include/mach/at91_pmc.h | 13 ++++ > arch/arm/mach-at91/include/mach/clk.h | 10 +++ > 3 files changed, 118 insertions(+) applied to u-boot-atmel/master, thanks! Best regards, Andreas Bie?mann