Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp560525ybl; Wed, 4 Dec 2019 07:17:02 -0800 (PST) X-Google-Smtp-Source: APXvYqzEDF1BHksQlItoKdn23n8z/t9A4r6Cq46tkx7StXq7qnsHO6jMCUurzVHaB3eQWzJD/Yd/ X-Received: by 2002:aca:f20b:: with SMTP id q11mr2824401oih.78.1575472622329; Wed, 04 Dec 2019 07:17:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1575472622; cv=none; d=google.com; s=arc-20160816; b=h9pkvA0uyXjoXMMXHcPeaGQu3pyD3Z4A+24KAVJLqXxAGEI+veZqtqds2weARPXStQ ze+XnnYquOS/HylNP8Hp9Or1W5OfWktKzAxQwn4kk7+vG5GVKeznE05L45187vatUlg0 9F5NZfLFRsF0fn1cGtYRn7pauya0NTzgwyvT2kfFVXAuZOg5jLdvI79A2ZOQeDNqu43Q M3Jw2KzUSYD6vJYrlKdYQRERzepzVU2WWLfYC6yXjoAny8f71tyfVtT/O/c9WmF6hnvl 1HEbIcm8RrD7u1GYSIYaLfAeCcsGRUngdbCPg8dBJ1rK5pEu5hkikJFFDQjKj0xxBWJR XhuQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=o+hFN8IqKVNoUmQrkJu8TMIhc+FtW0Kt3XLH9BBCFME=; b=mU7eovZsStto5mvgdY8EsXBhHuL5cNt1mL5F3I0jmLkLsRKsTDSQDPRJgjxx/iVOwD rOmftkImWSTDWfkp7lMhnwzbI9AmCUF3KsKPcxxqp+UKETzgQ873cUJrE0sGhKwFoYBU BAWkuyS2MaHLMFfjXLcCbwIBbJoVvavCSmKw0aJYFgrqkFu3Kz1kikXiB7598IA/gXK8 0Q4qlvJa0GMyxcdiVxIuBIbfsawefd6HmUCN609vmV6WTGRf/l6z2iQf9p+m5H9tc+Es Il8sopZbajMK+1yB0d6V6lmIcNQDHnNpRZsxToybLcwJgQ1g+Rsr49+5SilF1PVVsEtK hyBA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 77si902807oie.10.2019.12.04.07.16.49; Wed, 04 Dec 2019 07:17:02 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728197AbfLDPO2 (ORCPT + 99 others); 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-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