diff options
| author | Tom Rini <[email protected]> | 2025-04-28 10:19:29 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2025-04-28 12:45:45 -0600 |
| commit | 962d9635d4d6a9ac54a7e0feb6b83761f8d4ac8b (patch) | |
| tree | bb910ae1fe04d0ff10a7144feb7dd085aa574f42 /include | |
| parent | b2b2a21b8708bddea3f27e6dab59eadcd04c6fab (diff) | |
| parent | ef41a9f01d20e9209942db4a679ab89b80bb876c (diff) | |
Merge tag 'u-boot-imx-master-20250428' of https://gitlab.denx.de/u-boot/custodians/u-boot-imx
CI: https://source.denx.de/u-boot/custodians/u-boot-imx/-/pipelines/25974
- Fix power-domain ref counting regression.
- Fix i.MX8MP USB clock regression.
- Fix i.MX8MM osc_32k regression in SPL.
- Finish converting clock-osc-24 back to osc_24 on i.MX.
- Several imx8mp capricorn updates.
- Update Stefano Babic's email address.
- Fix fsl_qspi bug by moving AHB read buffer config after LUT.
- Fix verdin imx95 sku 0089 pid4.
Diffstat (limited to 'include')
| -rw-r--r-- | include/configs/capricorn-common.h | 52 | ||||
| -rw-r--r-- | include/configs/giedi.h | 16 | ||||
| -rw-r--r-- | include/linux/clk-provider.h | 2 | ||||
| -rw-r--r-- | include/power-domain.h | 69 |
4 files changed, 64 insertions, 75 deletions
diff --git a/include/configs/capricorn-common.h b/include/configs/capricorn-common.h index 4d95f3fd79b..7120a44d186 100644 --- a/include/configs/capricorn-common.h +++ b/include/configs/capricorn-common.h @@ -10,8 +10,6 @@ #include <linux/sizes.h> #include <asm/arch/imx-regs.h> -#include "siemens-env-common.h" - /* SPL config */ #ifdef CONFIG_XPL_BUILD #define CFG_MALLOC_F_ADDR 0x00120000 @@ -36,57 +34,9 @@ #define AHAB_ENV "sec_boot=no\0" #endif -#define MFG_ENV_SETTINGS_DEFAULT \ - "mfgtool_args=setenv bootargs console=${console},${baudrate} " \ - "rdinit=/linuxrc " \ - "clk_ignore_unused "\ - "\0" \ - "kboot=booti\0"\ - "bootcmd_mfg=run mfgtool_args;" \ - "if iminfo ${initrd_addr}; then " \ - "if test ${tee} = yes; then " \ - "bootm ${tee_addr} ${initrd_addr} ${fdt_addr}; " \ - "else " \ - "booti ${loadaddr} ${initrd_addr} ${fdt_addr}; " \ - "fi; " \ - "else " \ - "echo \"Run fastboot ...\"; fastboot 0; " \ - "fi;\0" - -/* Boot M4 */ -#define M4_BOOT_ENV \ - "m4_0_image=m4_0.bin\0" \ - "loadm4image_0=fatload mmc ${mmcdev}:${mmcpart} " \ - "${loadaddr} ${m4_0_image}\0" \ - "m4boot_0=run loadm4image_0; dcache flush; bootaux ${loadaddr} 0\0" \ - -#define CFG_MFG_ENV_SETTINGS \ - MFG_ENV_SETTINGS_DEFAULT \ - "initrd_addr=0x83100000\0" \ - "initrd_high=0xffffffffffffffff\0" \ - "emmc_dev=0\0" - /* Initial environment variables */ #define CFG_EXTRA_ENV_SETTINGS \ - CFG_MFG_ENV_SETTINGS \ - M4_BOOT_ENV \ - AHAB_ENV \ - ENV_COMMON \ - "script=boot.scr\0" \ - "image=Image\0" \ - "panel=NULL\0" \ - "console=ttyLP2\0" \ - "fdt_addr=0x83000000\0" \ - "fdt_high=0xffffffffffffffff\0" \ - "cntr_addr=0x88000000\0" \ - "cntr_file=os_cntr_signed.bin\0" \ - "initrd_addr=0x83800000\0" \ - "initrd_high=0xffffffffffffffff\0" \ - "netdev=eth0\0" \ - "nfsopts=vers=3,udp,rsize=4096,wsize=4096,nolock rw\0" \ - "hostname=capricorn\0" \ - ENV_EMMC \ - ENV_NET + AHAB_ENV /* Default location for tftp and bootm */ diff --git a/include/configs/giedi.h b/include/configs/giedi.h deleted file mode 100644 index 19a795bcf86..00000000000 --- a/include/configs/giedi.h +++ /dev/null @@ -1,16 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0+ */ -/* - * Copyright 2019 Siemens AG - * - */ - -#ifndef __GIEDI_H -#define __GIEDI_H - -#include "capricorn-common.h" - -/* DDR3 board total DDR is 1 GB */ -#undef PHYS_SDRAM_1_SIZE -#define PHYS_SDRAM_1_SIZE 0x40000000 /* 1 GB */ - -#endif /* __GIEDI_H */ diff --git a/include/linux/clk-provider.h b/include/linux/clk-provider.h index 5ea2171492e..267757939e0 100644 --- a/include/linux/clk-provider.h +++ b/include/linux/clk-provider.h @@ -219,6 +219,8 @@ struct clk_composite { const struct clk_ops *mux_ops; const struct clk_ops *rate_ops; const struct clk_ops *gate_ops; + + struct udevice *dev; }; #define to_clk_composite(_clk) container_of(_clk, struct clk_composite, clk) diff --git a/include/power-domain.h b/include/power-domain.h index 18525073e5e..7fd2c5e365b 100644 --- a/include/power-domain.h +++ b/include/power-domain.h @@ -66,6 +66,15 @@ struct power_domain { }; /** + * struct power_domain_plat - Per device accessible structure + * @subdomains: Number of subdomains covered by this device, required + * for refcounting + */ +struct power_domain_plat { + int subdomains; +}; + +/** * power_domain_get - Get/request the power domain for a device. * * This looks up and requests a power domain. Each device is assumed to have @@ -147,38 +156,82 @@ static inline int power_domain_free(struct power_domain *power_domain) #endif /** - * power_domain_on - Enable power to a power domain. + * power_domain_on_lowlevel - Enable power to a power domain (with refcounting) * * @power_domain: A power domain struct that was previously successfully * requested by power_domain_get(). - * Return: 0 if OK, or a negative error code. + * Return: 0 if the transition has been performed correctly, + * -EALREADY if the domain is already on, + * a negative error code otherwise. */ #if CONFIG_IS_ENABLED(POWER_DOMAIN) -int power_domain_on(struct power_domain *power_domain); +int power_domain_on_lowlevel(struct power_domain *power_domain); #else -static inline int power_domain_on(struct power_domain *power_domain) +static inline int power_domain_on_lowlevel(struct power_domain *power_domain) { return -ENOSYS; } #endif /** - * power_domain_off - Disable power to a power domain. + * power_domain_on - Enable power to a power domain (ignores the actual state + * of the power domain) * * @power_domain: A power domain struct that was previously successfully * requested by power_domain_get(). - * Return: 0 if OK, or a negative error code. + * Return: a negative error code upon error during the transition, 0 otherwise. + */ +static inline int power_domain_on(struct power_domain *power_domain) +{ + int ret; + + ret = power_domain_on_lowlevel(power_domain); + if (ret == -EALREADY) + ret = 0; + + return ret; +} + +/** + * power_domain_off_lowlevel - Disable power to a power domain (with refcounting) + * + * @power_domain: A power domain struct that was previously successfully + * requested by power_domain_get(). + * Return: 0 if the transition has been performed correctly, + * -EALREADY if the domain is already off, + * -EBUSY if another device is keeping the domain on (but the refcounter + * is decremented), + * a negative error code otherwise. */ #if CONFIG_IS_ENABLED(POWER_DOMAIN) -int power_domain_off(struct power_domain *power_domain); +int power_domain_off_lowlevel(struct power_domain *power_domain); #else -static inline int power_domain_off(struct power_domain *power_domain) +static inline int power_domain_off_lowlevel(struct power_domain *power_domain) { return -ENOSYS; } #endif /** + * power_domain_off - Disable power to a power domain (ignores the actual state + * of the power domain) + * + * @power_domain: A power domain struct that was previously successfully + * requested by power_domain_get(). + * Return: a negative error code upon error during the transition, 0 otherwise. + */ +static inline int power_domain_off(struct power_domain *power_domain) +{ + int ret; + + ret = power_domain_off_lowlevel(power_domain); + if (ret == -EALREADY || ret == -EBUSY) + ret = 0; + + return ret; +} + +/** * dev_power_domain_on - Enable power domains for a device . * * @dev: The client device. |
