Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp612200rdb; Tue, 5 Dec 2023 14:51:56 -0800 (PST) X-Google-Smtp-Source: AGHT+IFzom/sdumugUDtDACN3Ak48LejPwqDRmcWh224i8NFUO/dApcYtGHjy2EqZXepV9irkMtg X-Received: by 2002:a17:903:25cb:b0:1d0:6eae:8e78 with SMTP id jc11-20020a17090325cb00b001d06eae8e78mr3272205plb.18.1701816716633; Tue, 05 Dec 2023 14:51:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701816716; cv=none; d=google.com; s=arc-20160816; b=hQXGDVwfcGEMX1xA4LBPouncF+YD2t7r+BHMfJNQn/93l08V313akIKzuZjVeoqSG/ tdq5/pIznoradtPmbq2vk1JebxPu/hsuKPeP8nWWeAnRck8XM83RWh1PTCUGj/KbPdGQ 9UG6FE+uHfOqy4sF2QHvJQFGvGgbdBdVv9kFAyKXtntOBSBWYhuBNtamT5bi+vbJZKgw OQMLAqu1REUwjQz2oJokzw45k5LqPglEL17bNXv3mhpgo/ABOHDXc+3f/454Z7BJRVnD g3Cua1Z4dKKdmGaGhMMNC60xQuqP+C5ACUQsaENNhkhCEnnyC73YYzqJnB25RPvXNXTa x1lA== 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=JrFaCxut1vMUHEQKCkObXuZTRmt2Q25+qM/Ls973otI=; fh=ZCbnr9gO+hyRsVYSYNC1zobm4/NcYBDlrs9F3jIrpX0=; b=b1/AKEu3NjWP8tqq+qqFuhvzdCKpPeTyGaWfKN/UaHXMz7/RQ6XTxDO4Bs3A95GWhA tnKfuw88tCGWUu0uRnjDYbwHReSkRk5KxXnLVpNY4dBCnw6RPJMd42KlPuBZFKN5A4Jj oISv7GCLVODduKmkMR4yyIkTndf6yhhH+kHfy7Te0MRaLDn8qgrLv2Me1McR8iYtJ/RA 6BdCI/J2r9GP28a5hLSsVUnMUIL0JS+weLuFDdgdhvE2sYVFHCdCN1IYtNN6RHWIEv0O Nd+wwc+oOX7qhHudEvIlQdgKM6vpspvoTb2yy87PWMx9lZ1dcfBFztu/NNOO4tMuwVG/ iHzw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dQZ3IFub; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id p24-20020a1709028a9800b001d0afa2f5ddsi3523306plo.621.2023.12.05.14.51.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Dec 2023 14:51:56 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dQZ3IFub; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 4E2A282A39B0; Tue, 5 Dec 2023 14:51:54 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346523AbjLEWtq (ORCPT + 99 others); Tue, 5 Dec 2023 17:49:46 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34426 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346511AbjLEWtp (ORCPT ); Tue, 5 Dec 2023 17:49:45 -0500 Received: from mail-yw1-x112b.google.com (mail-yw1-x112b.google.com [IPv6:2607:f8b0:4864:20::112b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7CFA4196 for ; Tue, 5 Dec 2023 14:49:51 -0800 (PST) Received: by mail-yw1-x112b.google.com with SMTP id 00721157ae682-5c85e8fdd2dso69545957b3.2 for ; Tue, 05 Dec 2023 14:49:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1701816590; x=1702421390; darn=vger.kernel.org; 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=JrFaCxut1vMUHEQKCkObXuZTRmt2Q25+qM/Ls973otI=; b=dQZ3IFubH9gI2jg/gp8HqU98fc7aBOrxFTcjz4dnBQUqkese2qhIhh7Y3OrkDHYWue D92MYGMHfDqX+lEqf4cEBeqDBJ7iqjOBjzZ84vgwfJP3dFkZvXUpf4wu3M0gmy9Gd3H+ OcQW4yE3CS8Am4IXUG+ZbcjTVZyGY4GDwiUG02FQu8uS5ry+DX6yR1GNwdl1DQWKmquF yhaeHQMZKOe1O+Os6kaR06a7jNXRehDVOPic99k3JNPdlY91NP6IZrV5gOV+INj4lRqR ilMKgqjSySnvotwzQm8zWpjHXpez+ZG3wQQJoVh8otuvIjDDJd+wNx0Z5GmkMf9EFG76 1gJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701816590; x=1702421390; 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=JrFaCxut1vMUHEQKCkObXuZTRmt2Q25+qM/Ls973otI=; b=sfTjeEbVOep/8lxfJO4oQUa8t9u5cSoWSZPDsUOn5+1MRdNDBZa4nBY1nukQmKWo76 m25WcCogDKBU7H5sOgn7I078wKHjmqnycYzjrFUMvxFb6Mrfz7JyosKPtq/KQAeSXCKC 0NWtdZPEBa/5F0mMxPce0bl50rBGilcNqABYVynTzyBEZfoDAZP+hqg6ecdueuJ5hyio XS+FmaU4r10E5tHTJZrKH86UzRCn8zTldCF8GSp+EwmOgozCMjJ1/KaUDHWasq2J7UbT a1qKh2j6N7VuBrWtjGyvxmlQ2SGJN7TorOVt4zy8KTW1HJvYEX8MdHDcVh+joaX7ItSh Zdow== X-Gm-Message-State: AOJu0YzKTvjq8WysLq0P50TcgqG0gkCa+ibSzNKF3bovY5jkmnq4ShPZ oXfl9ylWgCqpRFQiKz+aZkBbwy/XiRwouxs02ietTCZgVDWs3zhF X-Received: by 2002:a81:b622:0:b0:5d7:1940:dd63 with SMTP id u34-20020a81b622000000b005d71940dd63mr5381287ywh.57.1701816590707; Tue, 05 Dec 2023 14:49:50 -0800 (PST) MIME-Version: 1.0 References: <20231204093509.19225-1-brgl@bgdev.pl> In-Reply-To: <20231204093509.19225-1-brgl@bgdev.pl> From: Linus Walleij Date: Tue, 5 Dec 2023 23:49:38 +0100 Message-ID: Subject: Re: [PATCH v3 00/10] gpio/pinctrl: replace gpiochip_is_requested() with a safer interface To: Bartosz Golaszewski Cc: Andy Shevchenko , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Bartosz Golaszewski Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on howler.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Tue, 05 Dec 2023 14:51:54 -0800 (PST) On Mon, Dec 4, 2023 at 10:35=E2=80=AFAM Bartosz Golaszewski = wrote: > From: Bartosz Golaszewski > > While reworking the locking in GPIOLIB I realized that locking the > descriptor with users still calling gpiochip_is_requested() will still > be buggy as it returns a pointer to a string that can be freed whenever > the descriptor is released. Let's provide a safer alternative in the > form of a function that returns a copy of the label. > > Use it in all drivers and remove gpiochip_is_requested(). The series: Acked-by: Linus Walleij > I plan to provide this series in an immutable branch for the pinctrl and > baytrail trees to pull. Nice! I'll pull it. Yours, Linus Walleij