Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp1322146rwd; Tue, 16 May 2023 15:35:51 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ79JefQyDuaKamXuW6uRBtLT6Uwng6LNniLeYAkyJ/H4OJGcSvqOnTJKabKMt0pI3Z3xLQZ X-Received: by 2002:a17:903:27c3:b0:1ad:c629:2b73 with SMTP id km3-20020a17090327c300b001adc6292b73mr17198625plb.42.1684276551524; Tue, 16 May 2023 15:35:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684276551; cv=none; d=google.com; s=arc-20160816; b=O5NMPwTtCcgCwH/7EQDdSvHQcNmvArZgv1x9eFz88W9Ey4yidPl1ln7B9AobtklbpN d7nsrj+tHDVy9xlVoUWVZ9iq90h/gQy4Ydqke0Zw51lGZ0HgxpiSQLEzTnysr5Lu3GCD KMGOoHy0bpqTQtqEvqBnXJeQbkDjWl/K0jFM6ADhQFbbifIHgTWg2KZc6jA3wT+K+aTa bux7tryF5JJRScMtOBMKrYxs9ueYl1lffSNs/e3QG6pUZDAWdUh0e5ViF//76BcgNR1B a5ZOlobBpG242xorr68obUOjj34pONyUVxvODzdGQdqhXX8qS01f37e1q9ldDgWGbMXo UeNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :content-id:content-language:accept-language:in-reply-to:references :message-id:date:thread-index:thread-topic:subject:cc:to:from :dkim-signature; bh=arElUNBLxYP/oS8PzLnuVnQ8MmR2mLGZDAgu2O2gSP0=; b=eo+ML+7Mcl3FJi4/L86VkGzeGK4prNNvP4Wk4/8VPNo3rdSbg+lBC9bU+hvEOiAeAI e1MoRhkkfGhHXEdhkxilUSSEGIT1HO8JDikF++Z+UL635l/OOKtiTKVvx/QKP2ij+wqa yYs9egltyX1cEfgpMlJlY/BdDH6/F5VM1MUghDJ01ZWR0pqLikYxiIMa8mOyU09ZKndv X5YWwdpcpMpjOrx7UZw2UkuyNLkU9AzlEkn+5wr2cQ6h3WWwX9O7wgERlgqDoESW9eHV In63d4KEOt2OqkNWdGWJb49/HwoLFt8bUBfvftNuwJwIRdhX/EgyZYbNKo5bBlJj5QOE cWpA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alliedtelesis.co.nz header.s=mail181024 header.b=HPFIGvXn; 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=QUARANTINE sp=REJECT dis=NONE) header.from=alliedtelesis.co.nz Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u15-20020a170902e5cf00b001a9b9c32ab7si21289005plf.624.2023.05.16.15.35.39; Tue, 16 May 2023 15:35:51 -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=@alliedtelesis.co.nz header.s=mail181024 header.b=HPFIGvXn; 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=QUARANTINE sp=REJECT dis=NONE) header.from=alliedtelesis.co.nz Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229821AbjEPWT1 (ORCPT + 99 others); Tue, 16 May 2023 18:19:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49654 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229475AbjEPWT0 (ORCPT ); Tue, 16 May 2023 18:19:26 -0400 Received: from gate2.alliedtelesis.co.nz (gate2.alliedtelesis.co.nz [202.36.163.20]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4D15759D2 for ; Tue, 16 May 2023 15:19:24 -0700 (PDT) Received: from svr-chch-seg1.atlnz.lc (mmarshal3.atlnz.lc [10.32.18.43]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by gate2.alliedtelesis.co.nz (Postfix) with ESMTPS id 047C02C04E1; Wed, 17 May 2023 10:19:15 +1200 (NZST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alliedtelesis.co.nz; s=mail181024; t=1684275555; bh=arElUNBLxYP/oS8PzLnuVnQ8MmR2mLGZDAgu2O2gSP0=; h=From:To:CC:Subject:Date:References:In-Reply-To:From; b=HPFIGvXnhVHJyEKGFnxyaxSijIvhEllmsTmbBGp+8Qqb35g1/YKCDZq1dzTp/zGdp MXO8b3wk0ogBOt3D7T01o0EGsIT6bnIyt4Jw66MetNrL71J1GWgdz2qk+gVyCaBrnP lur/J26PiuQlUlw/DoQV7mxuscX3d5cBg5wO6kh0InNO8zat9PEJ/AwkJlnxA2/SHb g/R8eaZOyN1+rp9+Jkf419hgcKUkcYwN8dVrvFumOgt1dQH7eB64AoEzBFsXlqvhlF sxl5asI2MU3uLmd5ubSc9/+TTCWzas5K8fMRuZcG+0An4HO2E64k59/eqrFmcasVt8 eoMAfK1L2DdJw== Received: from svr-chch-ex2.atlnz.lc (Not Verified[2001:df5:b000:bc8::76]) by svr-chch-seg1.atlnz.lc with Trustwave SEG (v8,2,6,11305) id ; Wed, 17 May 2023 10:19:14 +1200 Received: from svr-chch-ex2.atlnz.lc (2001:df5:b000:bc8:f753:6de:11c0:a008) by svr-chch-ex2.atlnz.lc (2001:df5:b000:bc8:f753:6de:11c0:a008) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.26; Wed, 17 May 2023 10:19:14 +1200 Received: from svr-chch-ex2.atlnz.lc ([fe80::a9eb:c9b7:8b52:9567]) by svr-chch-ex2.atlnz.lc ([fe80::a9eb:c9b7:8b52:9567%15]) with mapi id 15.02.1118.026; Wed, 17 May 2023 10:19:14 +1200 From: Chris Packham To: Linus Walleij CC: "brgl@bgdev.pl" , "johan@kernel.org" , "andy.shevchenko@gmail.com" , "maz@kernel.org" , Ben Brown , "linux-gpio@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH] gpiolib: Avoid side effects in gpio_is_visible() Thread-Topic: [PATCH] gpiolib: Avoid side effects in gpio_is_visible() Thread-Index: AQHZhIoofApft8Zm8kuYZtpxH+f53K9VfDeAgAQYHQCAApZDgIAAjA4A Date: Tue, 16 May 2023 22:19:14 +0000 Message-ID: <31a23398-9b0e-4a19-3576-84fcfd3ce4b5@alliedtelesis.co.nz> References: <20230512042806.3438373-1-chris.packham@alliedtelesis.co.nz> In-Reply-To: Accept-Language: en-NZ, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.33.22.30] Content-Type: text/plain; charset="utf-8" Content-ID: <0E08B0DD9C4BAB49AB098DDA8173E7C0@atlnz.lc> Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-SEG-SpamProfiler-Analysis: v=2.3 cv=cLieTWWN c=1 sm=1 tr=0 a=Xf/6aR1Nyvzi7BryhOrcLQ==:117 a=xqWC_Br6kY4A:10 a=75chYTbOgJ0A:10 a=IkcTkHD0fZMA:10 a=P0xRbXHiH_UA:10 a=3N-_S7HmHMGHqhwlQE4A:9 a=QEXdDO2ut3YA:10 X-SEG-SpamProfiler-Score: 0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED 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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