Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2613721rwd; Mon, 15 May 2023 14:21:24 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5dxsVU03F9zK9umw9ADuCIcsCDsfwE9YLY82XelEUMTlGObSeApxDiezMipoI/RJRFEjUp X-Received: by 2002:a05:6a20:7d88:b0:106:bb67:d684 with SMTP id v8-20020a056a207d8800b00106bb67d684mr1657598pzj.42.1684185684145; Mon, 15 May 2023 14:21:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684185684; cv=none; d=google.com; s=arc-20160816; b=VR1pXc7wmeFA6aF8HP2a5vqOeojO7xKjkHgVXu71jS7UMJ3tz/hPUktHQjaf4Ua7Em QeIoXlKE5usyvuBz/ld8w37p046Y5aVBayltEBdH4F8UUSRESS9KUrPCbo2+wNfXyLCB l8K9tj48KTTg2Vo9r2yTagjJkjKZ6ejUxlp8u2UHMjdOl4sMHAQADUdxGOUjm58p0SL5 fBqn70oUyjt8WxmQRErCnzPu1Q60zvs4mvF34heb7NYxKYDoVD/veY83lKjKNCWFOwKV 5ipZaKdYgekHdAVPI7slq7F6Me4n0ZJZSKCukOqTr7Lv1Q3MCwY4i2Ru4pyon3KKOj+e G/Tw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=wq0o/8p4FZPAmRFUAQ0rfN/u9SgX8f0uwc+1Yna0210=; b=mOqjx17LMKbJ3EpIJiZZYY3Lqt57l6lPoKoZJJ60j48TQKb1++hTWxiaFdpEWZHH+w 2aZw4EHOQuTMTgWAVNi3gEJB/Hl2jsvA9MuJUwFNBjUHvMY/1rl7E/S7N36YVizTNfEY V6vtx2ccTLwiUYLilpalmKidAcEEEs3x7Qj3wojLBCD00x1u9Ys4fWHajmUZMu6JxOtP g4XCibLurLZvEJnd8UBsvgsF0GPQhc5aEQtlvs8TL6+7TtolcH8lOPO/gVoe6YpwkucH oa3e4teJXtKEhR+1EYNks/9DGcA7G2NbRjfd7xgmP6Qo4cxB8vJaM7/0IGfp7nYM/a5F 07Ug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=G6QsJbf5; 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=pass (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 t69-20020a637848000000b00528513a135bsi16079117pgc.49.2023.05.15.14.21.11; Mon, 15 May 2023 14:21:24 -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; dkim=pass header.i=@gmail.com header.s=20221208 header.b=G6QsJbf5; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S245250AbjEOVJO (ORCPT + 99 others); Mon, 15 May 2023 17:09:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44000 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244799AbjEOVJK (ORCPT ); Mon, 15 May 2023 17:09:10 -0400 Received: from mail-qk1-x732.google.com (mail-qk1-x732.google.com [IPv6:2607:f8b0:4864:20::732]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E2B66E6D; Mon, 15 May 2023 14:09:08 -0700 (PDT) Received: by mail-qk1-x732.google.com with SMTP id af79cd13be357-7576516c81fso1024193785a.1; Mon, 15 May 2023 14:09:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1684184948; x=1686776948; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=wq0o/8p4FZPAmRFUAQ0rfN/u9SgX8f0uwc+1Yna0210=; b=G6QsJbf5NUzZl3Yted2qE5YjizUvlyhoHuoUQSk6rEEmNEX/L8lMT4vgzQEWLSJhYO x3v8Rn+sRS7G+sbpHiPGv7DHoHB0JJ8Hti2V121bSA4b8fp4ibqfq1GUcgMBZ/fT72Wi YdhsxIA/GahYdLusb9vnC2KrJ9Gf1/NvwjwEEgT5KJEjQS9Kp6IovzwaLsNPZ3vOmky9 IN52IQNDIEhcKV8ioGcUbm7uenRsLxe5LOpIAAPgvdpnwnNGWv6fZEuhv1eYIOpM33HE gXeSXbepMIyVvQZDurL5cdG7354t8p4bDZgYw51tvFcn6dX/1GhYbiyBGFb+L9U1yZNL vw7g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684184948; x=1686776948; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=wq0o/8p4FZPAmRFUAQ0rfN/u9SgX8f0uwc+1Yna0210=; b=ehaLOqkyFoNS44VwnL/6IqsaZRL6RYG7He+rEKkqZrNjPLPykwKGbRhmnTisLP3sPt 89sarJZduEc0wPLK9QmAGav77kpPzbGPIrOLS9+iv+PQd3SZwpDdeprSoJqYdcrTupgz 5lUOU8b/IkuGVPqdv6cc4tvhlYNt1uKr8qLyIxBL49Z2TrUguMU6hlSMCGPK1MVAzRDA 7nXT3ZsWnqnDxU8JqccWN/HKXARduO2joiSy455mceV2GFZfKA1pm4Rm4hG2yCRqhM4m GiF9qlQraEnd32wi5mqcWKarqSb9zpxGBTz9Su2dPhfv2GSv75RHVvzQN+EbCu9kK1Yl OsWw== X-Gm-Message-State: AC+VfDwtZum4fkFhfzvqo3HV4lGuj/iJt++9VjY6P3Ireif6j8StJXkg 2KUra2Cz5Iobubx/gKKXnImg2gOvW2xhuU41QFk= X-Received: by 2002:a05:6214:5299:b0:5c1:fa35:fe6 with SMTP id kj25-20020a056214529900b005c1fa350fe6mr51005095qvb.24.1684184947993; Mon, 15 May 2023 14:09:07 -0700 (PDT) MIME-Version: 1.0 References: <20230515174224.494631-1-afd@ti.com> In-Reply-To: <20230515174224.494631-1-afd@ti.com> From: Andy Shevchenko Date: Tue, 16 May 2023 00:08:32 +0300 Message-ID: Subject: Re: [PATCH v3] gpio: sch311x: Use devm_gpiochip_add_data() to simplify remove path To: Andrew Davis Cc: Peter Tyser , Andy Shevchenko , Linus Walleij , Bartosz Golaszewski , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 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 On Mon, May 15, 2023 at 8:42=E2=80=AFPM Andrew Davis wrote: > > Use devm version of gpiochip add function to handle removal for us. ...version of gpiochip_add() function... ... > + err =3D devm_gpiochip_add_data(&pdev->dev, &block->chip, = block); > if (err < 0) { > dev_err(&pdev->dev, > "Could not register gpiochip, %d\n", err)= ; > - goto exit_err; > + return err; With this applied you can consider a followup to have this be converted to = use return dev_err_probe(...); here and in other ->probe() related pieces. > } --=20 With Best Regards, Andy Shevchenko