i.MX drivers update for 5.7:
- Update SCU power domain driver to include PD ranges for audio, CM40 I2C and INTMUX, also enlarge PD range for mu_b. - Remove IMX_SC_RPC_SVC_ABORT from SCU API, as it was added by mistake. - Increase build test coverage for i.MX8M SoC and IMX_SCU driver. - Improve i.MX GPC power up sequencing to ensure that the reset is properly propagated through the peripheral devices in the power domain. -----BEGIN PGP SIGNATURE----- iQFIBAABCgAyFiEEFmJXigPl4LoGSz08UFdYWoewfM4FAl5xhKcUHHNoYXduZ3Vv QGtlcm5lbC5vcmcACgkQUFdYWoewfM4/6gf/e9lFuDNG9HiVsDad6YODwzZZxNF6 AxBqD924W4chqLZboAgahFVrWEyINourkzx9PMYK5gE6D6lxEnHhevbfVOYaw3NT Wjv4TSOCMzzlfzJIeFf+m0vzTR3gOtmE6Cto/HMd95IlF+afCzIWrKW+gAGWoRVH c1sCstForQ8SMoFixCJ+YfV8DXje1wGqgLEquMtn5jih2ZEIijo2XZ4nPs6ip4mV Pf+a3WXuN2NB13U2CKbkonk+JY2d8OFqLNQer7WsNp29wCSJqZB2ewnZP/vGSqvO e/i4BxMTtKg/2DPZFmCZNVbM3aEf0tv2E2c28bcb5qDuJfFu2jE4+olwCg== =LVyO -----END PGP SIGNATURE----- Merge tag 'imx-drivers-5.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into arm/drivers i.MX drivers update for 5.7: - Update SCU power domain driver to include PD ranges for audio, CM40 I2C and INTMUX, also enlarge PD range for mu_b. - Remove IMX_SC_RPC_SVC_ABORT from SCU API, as it was added by mistake. - Increase build test coverage for i.MX8M SoC and IMX_SCU driver. - Improve i.MX GPC power up sequencing to ensure that the reset is properly propagated through the peripheral devices in the power domain. * tag 'imx-drivers-5.7' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux: soc: imx: drop COMPILE_TEST for IMX_SCU_SOC firmware: imx: add COMPILE_TEST for IMX_SCU driver soc: imx: gpc: fix power up sequencing soc: imx: increase build coverage for imx8m soc driver firmware: imx: scu-pd: add power domain for I2C and INTMUX in CM40 SS firmware: imx: Remove IMX_SC_RPC_SVC_ABORT firmware: imx: scu-pd: enlarge PD range for mu_b firmware: imx: scu-pd: Add missing audio PD ranges soc: imx: gpcv2: include linux/sizes.h Link: https://lore.kernel.org/r/20200318051918.32579-1-shawnguo@kernel.org Signed-off-by: Arnd Bergmann <arnd@arndb.de>
This commit is contained in:
Коммит
90ae9ee792
|
@ -12,7 +12,7 @@ config IMX_DSP
|
|||
|
||||
config IMX_SCU
|
||||
bool "IMX SCU Protocol driver"
|
||||
depends on IMX_MBOX
|
||||
depends on IMX_MBOX || COMPILE_TEST
|
||||
help
|
||||
The System Controller Firmware (SCFW) is a low-level system function
|
||||
which runs on a dedicated Cortex-M core to provide power, clock, and
|
||||
|
|
|
@ -93,7 +93,7 @@ static const struct imx_sc_pd_range imx8qxp_scu_pd_ranges[] = {
|
|||
{ "kpp", IMX_SC_R_KPP, 1, false, 0 },
|
||||
{ "fspi", IMX_SC_R_FSPI_0, 2, true, 0 },
|
||||
{ "mu_a", IMX_SC_R_MU_0A, 14, true, 0 },
|
||||
{ "mu_b", IMX_SC_R_MU_13B, 1, true, 13 },
|
||||
{ "mu_b", IMX_SC_R_MU_5B, 9, true, 5 },
|
||||
|
||||
/* CONN SS */
|
||||
{ "usb", IMX_SC_R_USB_0, 2, true, 0 },
|
||||
|
@ -109,6 +109,7 @@ static const struct imx_sc_pd_range imx8qxp_scu_pd_ranges[] = {
|
|||
{ "audio-pll0", IMX_SC_R_AUDIO_PLL_0, 1, false, 0 },
|
||||
{ "audio-pll1", IMX_SC_R_AUDIO_PLL_1, 1, false, 0 },
|
||||
{ "audio-clk-0", IMX_SC_R_AUDIO_CLK_0, 1, false, 0 },
|
||||
{ "audio-clk-1", IMX_SC_R_AUDIO_CLK_1, 1, false, 0 },
|
||||
{ "dma0-ch", IMX_SC_R_DMA_0_CH0, 16, true, 0 },
|
||||
{ "dma1-ch", IMX_SC_R_DMA_1_CH0, 16, true, 0 },
|
||||
{ "dma2-ch", IMX_SC_R_DMA_2_CH0, 5, true, 0 },
|
||||
|
@ -116,7 +117,13 @@ static const struct imx_sc_pd_range imx8qxp_scu_pd_ranges[] = {
|
|||
{ "asrc1", IMX_SC_R_ASRC_1, 1, false, 0 },
|
||||
{ "esai0", IMX_SC_R_ESAI_0, 1, false, 0 },
|
||||
{ "spdif0", IMX_SC_R_SPDIF_0, 1, false, 0 },
|
||||
{ "spdif1", IMX_SC_R_SPDIF_1, 1, false, 0 },
|
||||
{ "sai", IMX_SC_R_SAI_0, 3, true, 0 },
|
||||
{ "sai3", IMX_SC_R_SAI_3, 1, false, 0 },
|
||||
{ "sai4", IMX_SC_R_SAI_4, 1, false, 0 },
|
||||
{ "sai5", IMX_SC_R_SAI_5, 1, false, 0 },
|
||||
{ "sai6", IMX_SC_R_SAI_6, 1, false, 0 },
|
||||
{ "sai7", IMX_SC_R_SAI_7, 1, false, 0 },
|
||||
{ "amix", IMX_SC_R_AMIX, 1, false, 0 },
|
||||
{ "mqs0", IMX_SC_R_MQS_0, 1, false, 0 },
|
||||
{ "dsp", IMX_SC_R_DSP, 1, false, 0 },
|
||||
|
@ -158,6 +165,10 @@ static const struct imx_sc_pd_range imx8qxp_scu_pd_ranges[] = {
|
|||
/* DC SS */
|
||||
{ "dc0", IMX_SC_R_DC_0, 1, false, 0 },
|
||||
{ "dc0-pll", IMX_SC_R_DC_0_PLL_0, 2, true, 0 },
|
||||
|
||||
/* CM40 SS */
|
||||
{ "cm40_i2c", IMX_SC_R_M4_0_I2C, 1, 0 },
|
||||
{ "cm40_intmux", IMX_SC_R_M4_0_INTMUX, 1, 0 },
|
||||
};
|
||||
|
||||
static const struct imx_sc_pd_soc imx8qxp_scu_pd = {
|
||||
|
|
|
@ -11,7 +11,7 @@ obj-$(CONFIG_ARCH_DOVE) += dove/
|
|||
obj-$(CONFIG_MACH_DOVE) += dove/
|
||||
obj-y += fsl/
|
||||
obj-$(CONFIG_ARCH_GEMINI) += gemini/
|
||||
obj-$(CONFIG_ARCH_MXC) += imx/
|
||||
obj-y += imx/
|
||||
obj-$(CONFIG_ARCH_IXP4XX) += ixp4xx/
|
||||
obj-$(CONFIG_SOC_XWAY) += lantiq/
|
||||
obj-y += mediatek/
|
||||
|
|
|
@ -10,11 +10,20 @@ config IMX_GPCV2_PM_DOMAINS
|
|||
|
||||
config IMX_SCU_SOC
|
||||
bool "i.MX System Controller Unit SoC info support"
|
||||
depends on IMX_SCU || COMPILE_TEST
|
||||
depends on IMX_SCU
|
||||
select SOC_BUS
|
||||
help
|
||||
If you say yes here you get support for the NXP i.MX System
|
||||
Controller Unit SoC info module, it will provide the SoC info
|
||||
like SoC family, ID and revision etc.
|
||||
|
||||
config SOC_IMX8M
|
||||
bool "i.MX8M SoC family support"
|
||||
depends on ARCH_MXC || COMPILE_TEST
|
||||
default ARCH_MXC && ARM64
|
||||
help
|
||||
If you say yes here you get support for the NXP i.MX8M family
|
||||
support, it will provide the SoC info like SoC family,
|
||||
ID and revision etc.
|
||||
|
||||
endmenu
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
# SPDX-License-Identifier: GPL-2.0-only
|
||||
obj-$(CONFIG_HAVE_IMX_GPC) += gpc.o
|
||||
obj-$(CONFIG_IMX_GPCV2_PM_DOMAINS) += gpcv2.o
|
||||
obj-$(CONFIG_ARCH_MXC) += soc-imx8.o
|
||||
obj-$(CONFIG_SOC_IMX8M) += soc-imx8m.o
|
||||
obj-$(CONFIG_IMX_SCU_SOC) += soc-imx-scu.o
|
||||
|
|
|
@ -87,8 +87,8 @@ static int imx6_pm_domain_power_off(struct generic_pm_domain *genpd)
|
|||
static int imx6_pm_domain_power_on(struct generic_pm_domain *genpd)
|
||||
{
|
||||
struct imx_pm_domain *pd = to_imx_pm_domain(genpd);
|
||||
int i, ret, sw, sw2iso;
|
||||
u32 val;
|
||||
int i, ret;
|
||||
u32 val, req;
|
||||
|
||||
if (pd->supply) {
|
||||
ret = regulator_enable(pd->supply);
|
||||
|
@ -107,17 +107,18 @@ static int imx6_pm_domain_power_on(struct generic_pm_domain *genpd)
|
|||
regmap_update_bits(pd->regmap, pd->reg_offs + GPC_PGC_CTRL_OFFS,
|
||||
0x1, 0x1);
|
||||
|
||||
/* Read ISO and ISO2SW power up delays */
|
||||
regmap_read(pd->regmap, pd->reg_offs + GPC_PGC_PUPSCR_OFFS, &val);
|
||||
sw = val & 0x3f;
|
||||
sw2iso = (val >> 8) & 0x3f;
|
||||
|
||||
/* Request GPC to power up domain */
|
||||
val = BIT(pd->cntr_pdn_bit + 1);
|
||||
regmap_update_bits(pd->regmap, GPC_CNTR, val, val);
|
||||
req = BIT(pd->cntr_pdn_bit + 1);
|
||||
regmap_update_bits(pd->regmap, GPC_CNTR, req, req);
|
||||
|
||||
/* Wait ISO + ISO2SW IPG clock cycles */
|
||||
udelay(DIV_ROUND_UP(sw + sw2iso, pd->ipg_rate_mhz));
|
||||
/* Wait for the PGC to handle the request */
|
||||
ret = regmap_read_poll_timeout(pd->regmap, GPC_CNTR, val, !(val & req),
|
||||
1, 50);
|
||||
if (ret)
|
||||
pr_err("powerup request on domain %s timed out\n", genpd->name);
|
||||
|
||||
/* Wait for reset to propagate through peripherals */
|
||||
usleep_range(5, 10);
|
||||
|
||||
/* Disable reset clocks for all devices in the domain */
|
||||
for (i = 0; i < pd->num_clks; i++)
|
||||
|
@ -343,6 +344,7 @@ static const struct regmap_config imx_gpc_regmap_config = {
|
|||
.rd_table = &access_table,
|
||||
.wr_table = &access_table,
|
||||
.max_register = 0x2ac,
|
||||
.fast_io = true,
|
||||
};
|
||||
|
||||
static struct generic_pm_domain *imx_gpc_onecell_domains[] = {
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
#include <linux/pm_domain.h>
|
||||
#include <linux/regmap.h>
|
||||
#include <linux/regulator/consumer.h>
|
||||
#include <linux/sizes.h>
|
||||
#include <dt-bindings/power/imx7-power.h>
|
||||
#include <dt-bindings/power/imx8mq-power.h>
|
||||
|
||||
|
|
|
@ -25,7 +25,6 @@ enum imx_sc_rpc_svc {
|
|||
IMX_SC_RPC_SVC_PAD = 6,
|
||||
IMX_SC_RPC_SVC_MISC = 7,
|
||||
IMX_SC_RPC_SVC_IRQ = 8,
|
||||
IMX_SC_RPC_SVC_ABORT = 9
|
||||
};
|
||||
|
||||
struct imx_sc_rpc_msg {
|
||||
|
|
Загрузка…
Ссылка в новой задаче