This is duplicated in the error handling after we go to out_err. Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx> diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c index f9263b2..8416a59 100644 --- a/drivers/pinctrl/core.c +++ b/drivers/pinctrl/core.c @@ -559,8 +559,6 @@ struct pinctrl_dev *pinctrl_register(struct pinctrl_desc *pctldesc, ret = device_register(&pctldev->dev); if (ret != 0) { pr_err("error in device registration\n"); - put_device(&pctldev->dev); - kfree(pctldev); goto out_err; } dev_set_drvdata(&pctldev->dev, pctldev); -- To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html