Re: [PATCH V2 1/4] pinctrl: imx: prepare for making "group_names" in "function_desc" const

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2.01.2022 00:55, Marcel Ziswiler wrote:
On Wed, 2021-12-22 at 22:24 +0200, Abel Vesa wrote:
@@ -663,14 +664,16 @@ static int imx_pinctrl_parse_functions(struct device_node *np,
                 dev_err(ipctl->dev, "no groups defined in %pOF\n", np);
                 return -EINVAL;
         }
-       func->group_names = devm_kcalloc(ipctl->dev, func->num_group_names,
-                                        sizeof(char *), GFP_KERNEL);
+
+       group_names = devm_kcalloc(ipctl->dev, func->num_group_names,
+                                  sizeof(char *), GFP_KERNEL);
         if (!func->group_names)
This line needs to be:
         if (!group_names)

Otherwise, the driver never probes successufully.

After my i.MX 8M Mini target running latest -next just hang early boot I bisected it to this commit.

I can confirm that this fixes it. Thanks!

Please note there is one more pending fix. Please apply both:
[PATCH] pinctrl: imx: fix allocation result check
[PATCH] pinctrl: imx: fix assigning groups names



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux