summaryrefslogtreecommitdiffstats
path: root/drivers/clk
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'for-next/rpi4'Sascha Hauer2022-06-291-11/+31
|\
| * clk: rpi: add Raspberry Pi 4 supportAhmad Fatoum2022-06-171-11/+31
| | | | | | | | | | | | | | | | | | | | | | | | Our Raspberry Pi clock driver is a hack, but it works well enough for older Rpis and just needs one more clock to support the SD-Card on the Raspberry Pi 4, so add that. In return, we remove bcm2835-cs, which we won't use on Raspberry Pi 4, because we'll leverage the ARM architected timer instead. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220609055922.667016-16-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | treewide: Remove duplicate incudesAlexander Shiyan2022-06-102-2/+0
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix warning fwterated by checkincludes.pl: ./net/nfs.c: libgen.h is included more than once. ./net/ifup.c: globalvar.h is included more than once. ./crypto/rsa.c: asm/types.h is included more than once. ./lib/decompress_unlz4.c: linux/decompress/mm.h is included more than once. ./scripts/stb_image.h: stdio.h is included more than once. ./scripts/kwbimage.c: unistd.h is included more than once. ./scripts/common.c: sys/types.h is included more than once. ./scripts/bareboximd.c: sys/types.h is included more than once. ./scripts/bareboximd.c: sys/mman.h is included more than once. ./fs/pstore/ram_core.c: linux/rslib.h is included more than once. ./fs/pstore/fs.c: fs.h is included more than once. ./fs/pstore/fs.c: linux/pstore.h is included more than once. ./fs/nfs.c: fs.h is included more than once. ./fs/uimagefs.c: fs.h is included more than once. ./fs/fs.c: command.h is included more than once. ./arch/sandbox/board/hostfile.c: linux/err.h is included more than once. ./arch/sandbox/board/devices.c: mach/linux.h is included more than once. ./arch/sandbox/os/common.c: signal.h is included more than once. ./arch/arm/boards/zii-imx51-rdu1/board.c: envfs.h is included more than once. ./arch/arm/boards/imx233-olinuxino/imx23-olinuxino.c: generated/mach-types.h is ./arch/arm/mach-stm32mp/ddrctrl.c: mach/stm32.h is included more than once. ./arch/arm/mach-imx/cpu_init.c: common.h is included more than once. ./arch/arm/mach-imx/imx8m.c: mach/imx8m-ccm-regs.h is included more than once. ./common/efi/payload/init.c: efi.h is included more than once. ./common/state/backend_format_raw.c: common.h is included more than once. ./common/state/backend_format_raw.c: crc.h is included more than once. ./common/hush.c: libbb.h is included more than once. ./drivers/spi/atmel-quadspi.c: linux/clk.h is included more than once. ./drivers/spi/atmel-quadspi.c: linux/err.h is included more than once. ./drivers/net/virtio.c: net.h is included more than once. ./drivers/net/phy/phy.c: linux/phy.h is included more than once. ./drivers/net/cpsw.c: net.h is included more than once. ./drivers/virtio/virtio_pci_common.h: linux/list.h is included more than once. ./drivers/usb/host/ohci-hcd.c: dma.h is included more than once. ./drivers/usb/gadget/fsl_udc.c: dma.h is included more than once. ./drivers/nvmem/eeprom_93xx46.c: spi/spi.h is included more than once. ./drivers/nvmem/eeprom_93xx46.c: of.h is included more than once. ./drivers/video/imx-ipu-v3/imx-ldb.c: linux/clk.h is included more than once. ./drivers/video/imx-ipu-v3/imx-hdmi.c: linux/clk.h is included more than once. ./drivers/video/omap.c: common.h is included more than once. ./drivers/mtd/nand/nand_s3c24xx.c: asm/sections.h is included more than once. ./drivers/clk/imx/clk-imx6sx.c: linux/clk.h is included more than once. ./drivers/clk/imx/clk-imx6sl.c: linux/clk.h is included more than once. ./commands/bootm.c: of.h is included more than once. Signed-off-by: Alexander Shiyan <eagle.alexander923@gmail.com> Link: https://lore.barebox.org/20220607051957.2497-1-eagle.alexander923@gmail.com Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: handle NULL args in clk_{g,s}et_parent() v2Bastian Krause2022-05-121-4/+2
| | | | | | | | | Accidently applied v1 of this patch. This updates to v2. Signed-off-by: Bastian Krause <bst@pengutronix.de> Reviewed-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220511123139.2767034-1-bst@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: handle NULL args in clk_set_parent()Bastian Krause2022-05-121-1/+6
| | | | | | | | | | | | | | | | | | | | NULL struct clk pointers should be treated just as the Linux kernel clk driver does [1]. The reasoning should also apply to the parent clk argument. A NULL struct clk pointer can happen for example on the Freescale i.MX6 SABRE Smart Device Board if CONFIG_DRIVER_VIDEO_IMX_IPUV3 is disabled, leading to assigned-clocks IMX6QDL_CLK_LDB_DI0_SEL and IMX6QDL_CLK_LDB_DI1_SEL [2] being unavailable. Without this patch, the board hangs while setting those assigned clock configurations since [3]. [1] 89ac8d7ae1cd ("clk: handle NULL struct clk gracefully") [2] dts/src/arm/imx6qdl-sabresd.dtsi [3] f5eb5fddb4 ("clk: fix of clk set defaults when dev is a clk provider") Signed-off-by: Bastian Krause <bst@pengutronix.de> Link: https://lore.barebox.org/20220511100911.2009482-1-bst@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: add BCM2835 auxiliary peripheral clock driverAhmad Fatoum2022-04-253-0/+69
| | | | | | | | | | | | | | | | | | Commit f6ce1103fdc4 ("ARM: rpi: move clk support to a separate driver") replaced board code setting up clocks with clkdev_add_physbase() with a proper cprman driver that registers fixed clocks and can be referenced from device tree. It was not fully equivalent though, because the mini UART's clock was no longer registered as that is provided by a different clock controller. Import the Linux v5.17 bcm2835-aux-clk driver to fix console usage on Raspberry Pi 3b. Fixes: f6ce1103fdc4 ("ARM: rpi: move clk support to a separate driver") Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220425094857.674044-3-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: imx8mp: remove SYS PLL 1/2 clock gatesSascha Hauer2022-04-251-32/+35
| | | | | | | | | | | | | | | | | | | | | | | This adopts kernel commit: | commit d097cc045b64948ca3048ced4a43cc74eaf641a5 | Author: Peng Fan <peng.fan@nxp.com> | Date: Fri Feb 25 16:17:33 2022 +0800 | | clk: imx8mp: remove SYS PLL 1/2 clock gates | | Remove the PLL 1/2 gates as it make AMP clock management harder without | obvious benifit. | | Signed-off-by: Peng Fan <peng.fan@nxp.com> | Reviewed-by: Abel Vesa <abel.vesa@nxp.com> | Link: https://lore.kernel.org/r/20220225081733.2294166-4-peng.fan@oss.nxp.com | Signed-off-by: Abel Vesa <abel.vesa@nxp.com> Unlike the original patch this one also makes sure that the removed gates are enabled as they are needed for their consumers. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* dts: update to v5.18-rc1Sascha Hauer2022-04-142-12/+12
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/stm32'Sascha Hauer2022-03-145-276/+849
|\
| * clk: stm32mp1: sync with Linux v5.17-rc1Ahmad Fatoum2022-03-081-276/+623
| | | | | | | | | | | | | | | | | | | | | | | | Linux has meanwhile extended the RCC driver to support both reset and clocks as well as peaceful co-existence with the SCMI driver. Import these changes into barebox and remove the reset controller handling from the old RCC reset driver. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220220124736.3052502-22-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * clk: implement of_clk_hw_{onecell,simple}_getAhmad Fatoum2022-02-231-0/+22
| | | | | | | | | | | | | | | | These functions are easily implemented and make porting code easier. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220220124736.3052502-19-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * clk: add SCMI clock driverAhmad Fatoum2022-02-233-0/+204
| | | | | | | | | | | | | | | | Import the Linux v5.13 state of the SCMI clock protocol driver. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220220124736.3052502-15-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'for-next/imx'Sascha Hauer2022-03-141-9/+28
|\ \
| * | clk: imx6: do pfd workaround unconditionallySascha Hauer2022-03-081-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The i.MX6D and i.MX6Q SoC variants need a workaround for the PFDs which may not work properly when they are not gated/ungated once during startup. We currently have this workaround twice, once in the clock driver and once in imx6_init_lowlevel(). The latter will be removed, but before doing that the workaround in the clock driver is done unconditionally and not only when the IPU driver is enabled. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | clk: imx6: fix cko1_selsSascha Hauer2022-03-081-2/+2
| | | | | | | | | | | | | | | | | | | | | cko1 outputs pll5_video_div, not pll5_video. Also it outputs pll4_audio_div, not pll4_audio. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | clk: imx6: emi_sel clock muxingSascha Hauer2022-03-081-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adaption of kernel commit: | commit 3b79cd15bfc5f1ddb5e387310fa3dbb09b81b552 | Author: Liu Ying <Ying.Liu@freescale.com> | Date: Wed Jul 3 15:29:06 2013 +0800 | | ARM: i.MX6Q: correct emi_sel clock muxing | | The correct muxing for emi_sel clock should be | 2b'00 - 396M PFD | 2b'01 - PLL3 | 2b'10 - AXI clk root | 2b'11 - 352M PFD | | This patch corrects the muxing in the clock driver. | | Signed-off-by: Liu Ying <Ying.Liu@freescale.com> | Signed-off-by: Shawn Guo <shawn.guo@linaro.org> | Acked-by: Dirk Behme <dirk.behme@de.bosch.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | clk: imx6: Fix periph_clk2_sel and periph2_clk2_sel clocksSascha Hauer2022-03-081-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adaption of kernel commit: | commit 72cd7447e72a13ce72d760b42ec295430f77300a | Author: Philipp Zabel <p.zabel@pengutronix.de> | Date: Wed Apr 17 12:05:58 2013 +0200 | | ARM i.MX6q: Fix periph_clk2_sel and periph2_clk2_sel clocks | | The periph_clk2_sel mux can be set to pll3, osc/pll1_ref_clk, or osc/ | pll2_burn_in_clk. The periph2_clk2_sel mux can be set to pll3 or pll2. | | Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de> | Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | clk: imx6: fix axi_selsSascha Hauer2022-03-081-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adaption of Kernel commit: | commit a08b9bc586a7810cdebbc316d5cbaed56a2a04a9 | Author: Anson Huang <b20788@freescale.com> | Commit: Shawn Guo <shawn.guo@linaro.org> | CommitDate: Mon Jun 3 13:47:12 2013 +0800 | | ARM: imx: clk-imx6q: AXI clock select index is incorrect | | The AXI clock mux should be as below: | | 00: periph; | 01: pll2_pfd2_396m; | 10: periph; | 11: pll3_pfd1_540m; Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * | clk: imx6: Add hdmi_isfr clkSascha Hauer2022-03-081-1/+5
| |/ | | | | | | | | | | | | | | | | | | | | The hdmi_isfr clk is requested and enabled by the hdmi driver, but it is never registered, so effectively a dummy clk is used in the hdmi driver. Add the clk and its parents so that the real clk is used. One of the parents is pll3_pfd1_540m which happens to be enabled in our pfd clock workaround in imx6_init_lowlevel(). This patch is necessary when that workaround is removed later. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* / clk: composite: fix possible NULL pointer dereferenceAhmad Fatoum2022-03-081-3/+7
|/ | | | | | | | | | | A composite clock is at most composed of a mux, a divider and a gate, but it may lack one or two of these components. In that case, a NULL pointer is passed, so we need to deal with this case. Fixes: 8b0ca7a885ea ("clk: composite: add clk_hw registration functions") Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220307170106.3937198-2-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/stm32'Sascha Hauer2022-02-189-12/+2089
|\
| * clk: add clock driver for stm32f4 and stm32f7Ahmad Fatoum2022-02-013-0/+1908
| | | | | | | | | | | | | | | | | | Port over the Linux v5.16 state of the clock driver. Tested on a STM32F429. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220131075725.1873026-13-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * clk: implement of_clk_add_hw_providerAhmad Fatoum2022-02-011-9/+34
| | | | | | | | | | | | | | | | New Linux drivers rather use of_clk_add_hw_provider, so port it over. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220131075725.1873026-10-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * clk: mux: export clk_mux_round_rateAhmad Fatoum2022-02-011-2/+3
| | | | | | | | | | | | | | | | | | Clock drivers may want to implement round rate for their custom clocks in term of clk_mux_round_rate. Export the function to facilitate this. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220131075725.1873026-9-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * clk: mux: add clk_hw registration functionsAhmad Fatoum2022-02-011-1/+81
| | | | | | | | | | | | | | | | | | | | Save users the hassle of opencoding by providing wrappers with the same Linux semantics: names are duplicated, same arguments and struct clk_hw is returned. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220131075725.1873026-8-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * clk: clk-fixed: add clk_hw registration functionsAhmad Fatoum2022-02-011-0/+8
| | | | | | | | | | | | | | | | | | | | Save users the hassle of opencoding by providing wrappers with the same Linux semantics: names are duplicated, same arguments and struct clk_hw is returned. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220131075725.1873026-6-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * clk: fixed-factor: add clk_hw registration functionsAhmad Fatoum2022-02-011-0/+9
| | | | | | | | | | | | | | | | | | | | Save users the hassle of opencoding by providing wrappers with the same Linux semantics: names are duplicated, same arguments and struct clk_hw is returned. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220131075725.1873026-5-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * clk: divider: add clk_hw registration functionsAhmad Fatoum2022-02-011-0/+21
| | | | | | | | | | | | | | | | | | | | Save users the hassle of opencoding by providing wrappers with the same Linux semantics: names are duplicated, same arguments and struct clk_hw is returned. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220131075725.1873026-4-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * clk: composite: add clk_hw registration functionsAhmad Fatoum2022-02-011-0/+25
| | | | | | | | | | | | | | | | | | | | Save users the hassle of opencoding by providing wrappers with the same Linux semantics: names are duplicated, same arguments and struct clk_hw is returned. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220131075725.1873026-3-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'for-next/rpi'Sascha Hauer2022-02-182-0/+86
|\ \
| * | ARM: rpi: move clk support to a separate driverOleksij Rempel2022-02-072-0/+86
| | | | | | | | | | | | | | | | | | | | | | | | | | | To make deep-probe work properly, we need clock support be registered as driver to related device. Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de> Link: https://lore.barebox.org/20220203104552.3158202-4-o.rempel@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | | Merge branch 'for-next/dts'Sascha Hauer2022-02-181-1/+0
|\ \ \ | |/ / |/| |
| * | dts: update to v5.17-rc1Sascha Hauer2022-01-281-1/+0
| |/ | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* / clk: imx6: fix PLL exception for i.MX6DQ revision 1.0Ahmad Fatoum2022-02-031-2/+2
|/ | | | | | | | | | | | | | | | | | | | | cpu_is_mx6* and imx_silicon_revision access static variables only initialized in imx_init(). Use the alternative functions instead, that will always consult the hardware to determine the version. This requires us to know beforehand that we run on an i.MX6, but this is a given when probing the imx6-ccm driver. Other instances of this issue were removed in 37bc313add40 ("clk: imx6: fix use of cpu_is_mx6* before they are initialized"), but this instance was reintroduced as part of b534f79112f0 ("clk: imx6: Fix procedure to switch the parent of LDB_DI_CLK"). This change only affects i.MX6D/Q SoCs with exactly revision 1.0 and aligns their behavior to that of the Linux clock driver. Fixes: b534f79112f0 ("clk: imx6: Fix procedure to switch the parent of LDB_DI_CLK") Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220202195524.30740-1-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/misc'Sascha Hauer2022-01-193-1/+1655
|\
| * clk: rockchip: extend for rk3399 supportAhmad Fatoum2022-01-172-0/+1654
| | | | | | | | | | | | | | | | | | | | | | | | This is a very straight-forward port of Linux' clock driver for the SoC facilitated with the very convenient changes done to synchronize barebox clock framework with Linux'. It adds support for clock tree, restart handler and a reset controller. Signed-off-by: Ahmad Fatoum <ahmad@a3f.at> Link: https://lore.barebox.org/20220114083825.726347-3-ahmad@a3f.at Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
| * clk: change clk_get_num_parents into clk_hw_get_num_parentsAhmad Fatoum2022-01-141-1/+1
| | | | | | | | | | | | | | | | | | | | There is no clk_get_num_parents in Linux, but clk_hw_get_num_parents. Our only users uses it with a clk_hw, so adjust the function accordingly. Signed-off-by: Ahmad Fatoum <ahmad@a3f.at> Link: https://lore.barebox.org/20220114065953.698483-1-ahmad@a3f.at Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Revert "clk: handle CLK_OF_DECLARE in deep probe"Sascha Hauer2022-01-181-7/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This issue is now solved differently in: | commit 2f9aeab92f51d7b224468f6cd62d7cbbb05ceb1e (master) | Author: Lucas Stach <dev@lynxeye.de> | Date: Sun Jan 16 22:32:19 2022 +0100 | | clk: ignore of_device_ensure_probed error in clock lookup This reverts commit bd516e38dd1490cb83b58f8f7914912f3a702978. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | clk: ignore of_device_ensure_probed error in clock lookupLucas Stach2022-01-181-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For CLK_OF_DECLARE clocks there is no driver that is bound to the device, so the lookup fails before even trying to find the provider, breaking the parent_ready() logic used when initializing the declared providers. Ignore the return code from of_device_ensure_probed to allow the lookup to proceed as usual. If of_device_ensure_probed the lookup will also fail, as no provider will be found. Signed-off-by: Lucas Stach <dev@lynxeye.de> Tested-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220116213221.3466936-1-dev@lynxeye.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | clk: fixed: record parent name in clk_register_fixed_rateAhmad Fatoum2022-01-051-0/+4
|/ | | | | | | | parent_names is allocated, but only populated with zeroes. Fix this. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220103115718.1723730-3-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: bulk: improve error message on failure to getAhmad Fatoum2021-12-131-2/+2
| | | | | | | | | | | We didn't have the need to handle %pOF specially yet, but for the error message in clk-bulk, not readily knowing what component couldn't get its clocks is annoying. Print the node name directly and change the error code to the error string if those are compiled in. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20211202074224.193631-1-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* drivers: migrate "GPL-2.0+" license identifiers to SPDX 2.0Roland Hieber2021-11-221-1/+1
| | | | | | | | | "GPL-2.0-or-later" was introduced in SPDX 2.0, and the old identifier "GPL-2.0+" is now deprecated; see <https://spdx.org/licenses>. Signed-off-by: Roland Hieber <rhi@pengutronix.de> Link: https://lore.barebox.org/20211117113851.2022669-3-rhi@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* drivers: migrate "GPL-2.0" license identifiers to SPDX 2.0Roland Hieber2021-11-2240-40/+40
| | | | | | | | | | "GPL-2.0-only" was introduced in SPDX 2.0, and the old identifier "GPL-2.0" is now considered deprecated; see <https://spdx.org/licenses>. Fixes: 28f4a6a4df76f0f1581d (2021-10-30, "drivers: add missing SPDX-License-Identifier") Signed-off-by: Roland Hieber <rhi@pengutronix.de> Link: https://lore.barebox.org/20211117113851.2022669-2-rhi@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/spdx'Sascha Hauer2021-11-151-0/+1
|\
| * drivers: add missing SPDX-License-IdentifierAhmad Fatoum2021-11-011-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds the suitable SPDX-License-Identifier to all files in drivers/ that previously lacked one. To aid manual inspection, following heuristics can be used: * No changes outside of comments/whitespace: git show -U0 HEAD | rg -v '^(@@|diff|index)|[-+]([-+]|//|#|[\s/]\*)' * -or-later come in pairs: git show --inter-hunk-context=19 HEAD | \ perl -0777 -F'/^@/gm' -ne 'for (@F) { @m = /later/g; print if @m & 1 }' Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20211030175632.2276077-4-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | Merge branch 'for-next/rockchip'Sascha Hauer2021-11-151-1/+7
|\ \
| * | clk: handle CLK_OF_DECLARE in deep probeAhmad Fatoum2021-11-101-1/+7
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | An assigned-clock-parents referring to a fixed-clock will result in a warning: WARNING: clk: couldn't get parent clock 0 for /ethernet@fe300000 That's because the device for the fixed clock is created on demand and even after ensuring probe, no driver will have bound against it as CLK_OF_DECLARE operates outside the driver model. Fix this by creating devices and binding the dummy driver while iterating over the CLK_OF_DECLARE list. No functional change for systems not enabling deep-probe. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20211108075209.2366770-7-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* / include: add dedicated header for printf/printkAhmad Fatoum2021-11-013-3/+3
|/ | | | | | | | | | | | Including <stdio.h> for printf is a bit problematic, because it pulls in other headers for <console.h>, which includes quite a few more headers as well. To make it easier to share code between barebox and host tools make <printk.h> the new minimal header for printf and move the extra logging stuff into <linux/printk.h>. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20211030141739.2207431-3-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* clk: imx: add i.MX8MN (Nano) supportAhmad Fatoum2021-10-052-0/+560
| | | | | | | | | | | Import the Linux v5.14-rc2 state of the clock driver. Some abstractions used there were not yet added to barebox, so previous equivalent versions were taken instead. This makes the code more in-line with the i.MX8MM. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20211001100949.6891-3-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/zynqmp'Sascha Hauer2021-07-181-0/+3
|\