From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.6 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C0C01C2BC73 for ; Wed, 4 Dec 2019 15:14:29 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 93F892081B for ; Wed, 4 Dec 2019 15:14:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1575472469; bh=1ybAm1ALf3cAvtTcV4k+XXr/muJrjJDFhDi9LQbvSlQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:List-ID:From; b=R//IuP7meLMZKUNddxQ+W7jwzrQqjwB4KbtYE676dzO07gs7xybX+dejq+anD6eJg mx7KO/k8P+p3tmcEbuLV46/jCb8m0/JQgLYPNk2k+xDb+iyWrCLAkO0vF9JurBsyKi 43rVsGFg23ilZhFJb/VR13UkOgtv/0wnKsFtW+bU= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728202AbfLDPO2 (ORCPT ); Wed, 4 Dec 2019 10:14:28 -0500 Received: from mail-ot1-f67.google.com ([209.85.210.67]:44708 "EHLO mail-ot1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727828AbfLDPO1 (ORCPT ); Wed, 4 Dec 2019 10:14:27 -0500 Received: by mail-ot1-f67.google.com with SMTP id x3so6575165oto.11; Wed, 04 Dec 2019 07:14:27 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=o+hFN8IqKVNoUmQrkJu8TMIhc+FtW0Kt3XLH9BBCFME=; b=RC+VQrvdq6Fn2W/J4LSNsOim5dSVmWu9zfGe8uUuYd2PaD279V+zCLMJ1fgohT2726 pk5MdA82NF9Alf5PsgB4kuLt2L6Z4X3o69D+PcBBB2Us+o0ZuDm5d1DfiB8uZzWvIqOU Ry2afhImrVRV7l2K4/mJnDySW9hPoEEdy8iFlRxg/pKICupbRBkvKGgSa7yhgjAM6ZoO Qh4PxZjebk9qKRLuxzCjtk8gmjFm7xQi6Y6Im+G0l1uBpHdan1m8RF1wYLwyXIh9d1PB xpRO6n4Ply4xoLWyhobTsqCvvkZ3/5q30eqcZsTvgg0Cc9nCzFW7udWqLUxVbI/d2eHw rR2Q== X-Gm-Message-State: APjAAAVme4igybeYnlrVcSYCNZHuNTo9L38KxuKULrPwtb1pkfdX0qEL o/2bahStyJ+kyGFSji1oDxekvdE= X-Google-Smtp-Source: APXvYqyDpd68LHA7Vc9YToHmwTS2jPtEct42aCrQlGcX6wCzwAM7xJgp3Zq+bIy220TGHyd0vLRcsg== X-Received: by 2002:a9d:5c88:: with SMTP id a8mr992823oti.348.1575472466619; Wed, 04 Dec 2019 07:14:26 -0800 (PST) Received: from localhost (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.gmail.com with ESMTPSA id r13sm2372907oic.52.2019.12.04.07.14.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Dec 2019 07:14:25 -0800 (PST) Date: Wed, 4 Dec 2019 09:14:24 -0600 From: Rob Herring To: Bartosz Golaszewski Cc: Linus Walleij , Khouloud Touil , Bartosz Golaszewski , Mark Rutland , Srinivas Kandagatla , baylibre-upstreaming@groups.io, "linux-kernel@vger.kernel.org" , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , linux-i2c Subject: Re: [PATCH 1/4] dt-bindings: nvmem: new optional property write-protect-gpios Message-ID: <20191204151424.GA20683@bogus> References: <20191120142038.30746-1-ktouil@baylibre.com> <20191120142038.30746-2-ktouil@baylibre.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 29, 2019 at 09:47:01AM +0100, Bartosz Golaszewski wrote: > czw., 28 lis 2019 o 14:45 Linus Walleij napisaƂ(a): > > > > On Tue, Nov 26, 2019 at 4:18 PM Khouloud Touil wrote: > > > > > [Me] > > >> 4. The code still need to be modified to set the value > > >> to "1" to assert the line since the gpiolib now handles > > >> the inversion semantics. > > > > > By saying "assert the wp" do you mean enable the write operation or > > > block it ? > > > > Yeah one more layer of confusion, sorry :/ > > > > By "asserting WP" I mean driving the line to a state where > > writing to the EEPROM is enabled, i.e. the default state is > > that the EEPROM is write protected and when you "assert" > > WP it becomes writable. > > > > If you feel the inverse semantics are more intuitive (such that > > WP comes up asserted and thus write protected), be my > > guest :D > > > > Ha! I've always assumed that "to assert the write-protect pin" means > to *protect* the EEPROM from writing. That's why it comes up as > asserted (logical '1' in the driver) and we need to deassert it (drive > it low, logical '0' in the driver) to enable writing. This is the > current behavior and I'd say in this case it's just a matter of very > explicit statement that this is how it works in the DT binding? > > Rob: any thoughts on this? I agree with you. If it was called write-enable-gpios, then assert would be to enable writing. Rob