Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp126065rwb; Sat, 17 Sep 2022 02:08:11 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7LjbHjYI4M7TRa7c6c9OSxPSwx6JYTGjYz1+UJZ7k26SBnhhea/pEWuwC28J/LlTht9tLs X-Received: by 2002:a05:6a00:1596:b0:540:f547:8509 with SMTP id u22-20020a056a00159600b00540f5478509mr9598174pfk.80.1663405690837; Sat, 17 Sep 2022 02:08:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663405690; cv=none; d=google.com; s=arc-20160816; b=CqTeiq0u8Cp0d2LXxxp7yYDkjfWEZxDSDLAn1W2NuFFXZg/IxccqgvXk5yhlG66N1I rnx4Z1ECpeG+IAlw8MAimoEbSLAsk84VvTenWs5xhGTYwgGRYeXlpb6u83MkrKaOXoBs hv0v5pcYzX2TlMLBYLX3hiW3pNytzzgfWeL+kXqA2P3clAeYtSf7gcRDLGGE5e3Kyaqy Je5giqxlTbAhKgr1T5E1DQ1Zetav5YDk29OpPAQmwt+sdqyuY0qvy0pCELSostB+mCtv jObZFCFDUXG4x/uY4Wxz0F7+KqiRxsYS7+cFJis1Z0uolnJ/F0bw0HlvdSyZMio3IlhG s2mw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:date:from; bh=OiTOtBAL6A0SoTo3azfgaa8Isi8DCvRPjLZE4qwHWSE=; b=pf/ivWlHOef5xVmGfjuoJw9RLmEfJC51j1DeMINnTNjaZgE7JI/EX+oN7jN+pBebmU FHz07qtC+Uf7+T4mj9OWy3W/wNP07xh3E4lVFRYtl5Gs7N25fdnYnqj6iw4C2UMn9qJU z2nJSBTd3P6zyRt/aBsjFFTEuJKSI4nm5X6u1anE2awNyEjJ/YrkaSm5H78i4PPI7sSj eg2wyEDqCbUWos/pbCTpb9I9esJS81/kFq5o/YL/CLDOSyvH/asHv96vvMhLgM00wIcd 8xZHqZNw/Jd0TzaunlpMwhG42Y0vJEbGBlwnr043e5vcJ8ZDW5qfyr8AcsAN3tZk8Oga ds8Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id l2-20020a170903244200b00172bb36712fsi27570849pls.514.2022.09.17.02.07.58; Sat, 17 Sep 2022 02:08:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229747AbiIQJBq (ORCPT + 99 others); Sat, 17 Sep 2022 05:01:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46004 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229657AbiIQJBm (ORCPT ); Sat, 17 Sep 2022 05:01:42 -0400 Received: from tulikuusama2.dnainternet.net (tulikuusama2.dnainternet.net [83.102.40.151]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 461692BB2F; Sat, 17 Sep 2022 02:01:41 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by tulikuusama2.dnainternet.net (Postfix) with ESMTP id ABA4F28904; Sat, 17 Sep 2022 11:54:51 +0300 (EEST) X-Virus-Scanned: DNA Internet at dnainternet.net X-Spam-Score: 2.975 X-Spam-Status: No, score=-0.0 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, FORGED_GMAIL_RCVD,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED,RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,SPF_SOFTFAIL autolearn=no autolearn_force=no version=3.4.6 Received: from tulikuusama2.dnainternet.net ([83.102.40.151]) by localhost (tulikuusama2.dnainternet.net [127.0.0.1]) (DNA Internet, port 10041) with ESMTP id opv80w7qov8h; Sat, 17 Sep 2022 11:54:51 +0300 (EEST) Received: from kirsikkapuu2.dnainternet.net (kirsikkapuu2.dnainternet.net [83.102.40.52]) by tulikuusama2.dnainternet.net (Postfix) with ESMTP id 846D220B65; Sat, 17 Sep 2022 11:54:51 +0300 (EEST) Received: from localhost (87-95-96-237.bb.dnainternet.fi [87.95.96.237]) by kirsikkapuu2.dnainternet.net (Postfix) with ESMTP id 07FC67B; Sat, 17 Sep 2022 11:54:44 +0300 (EEST) From: andy.shevchenko@gmail.com Date: Sat, 17 Sep 2022 11:54:44 +0300 To: Yang Yingliang Cc: linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linus.walleij@linaro.org, p.zabel@pengutronix.de, horatiu.vultur@microchip.com Subject: Re: [PATCH -next v2 1/2] pinctrl: ocelot: add missing destroy_workqueue() in error path in ocelot_pinctrl_probe() Message-ID: References: <20220917024634.1021861-1-yangyingliang@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220917024634.1021861-1-yangyingliang@huawei.com> X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Sat, Sep 17, 2022 at 10:46:33AM +0800, Yang Yingliang kirjoitti: > Add the missing destroy_workqueue() before return from ocelot_pinctrl_probe() > in error path. > > Fixes: c297561bc98a ("pinctrl: ocelot: Fix interrupt controller") > Signed-off-by: Yang Yingliang > --- > v2: > move alloc_ordered_workqueue() after ocelot_pinctrl_register(). Why? What will happen if user space start using pins before workqueue is allocated? If you really want to have it correct, you need either drop all devm_ calls after allocating workqueue, or wrap destroying into devm. -- With Best Regards, Andy Shevchenko