Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp542240ybb; Sat, 28 Mar 2020 05:05:33 -0700 (PDT) X-Google-Smtp-Source: ADFU+vsEGVSC9ZAKO2qNKc3gZcfIRM4R9Lvu8C/0e4Ob8yJTKyjV1Ipe2Cq351ZCBdBCmkVHVdmQ X-Received: by 2002:aca:1812:: with SMTP id h18mr2241418oih.107.1585397133419; Sat, 28 Mar 2020 05:05:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585397133; cv=none; d=google.com; s=arc-20160816; b=sJvds81GDALo3M1HLadFuFJeuTxx3tqdo+8vIl+pQxe3t+XQ+nXkgWOhHxCf85Vcez Bl24jEbC4JRT+XVMYJZLsKo/QYncNa5pPJ/Q2TCXfJqXLAXDcEdj4lovQIMhTKGJkY+f reIgAOa7mcoY+Il+8Vgt79SCdgtsAIj5y0iyxYM+8eh47q+Mi9LEXFJdDj3YT0BuHIFi q+AXPLFtQdBmpbHnwTNpcblebJ3rxE2chKJZGNFgU31Zm266ridxAwooyzDZ1Nj0ewei qc21ZsW8Bhotf2uOoOHCR286MlEd9t7oCcawCPSQh8KWDkJl7q4FQgZKFGb/k7IFOqcs NpXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:message-id:references :in-reply-to:subject:cc:to:from:date:content-transfer-encoding :mime-version:dkim-signature; bh=n5jtDDhzPSvYKIS+PmQfH6uIuXE3eV4q3g/zF9Fsvio=; b=I/Mq+XlXwClnNJMqM0r/y1lrQGH3bOh4VNOcO8KHRdJ/c37UqRo5oBGPLfZdTMbg9F Osnu4f9s1ZX52zsKc7TagGNogjByZ6whIZp6Xb25+agcRv7s9c3ftqisCKhPtMsBjeXV bKpXPf9372ekixoXekDJzl5w8mNEvWv0th0MKsIuni3UGX2S4CL3iQVNz8k/y8JeCjkE +BMnK0YmS3iHD66jK1cLLFtxyBBoALn7qORpBOD24m2bU2TnkZO8OVXCu5VkXIDq6dI3 X5pEMOB66reeKx3W5rp7xKs/gkUq1Fj5j9IuRcl8vRl6890oAEQ8qwh5RlrUDmeayEJg ncag== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@walle.cc header.s=mail2016061301 header.b=XLgcUGYR; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p187si3805796oop.28.2020.03.28.05.05.19; Sat, 28 Mar 2020 05:05:33 -0700 (PDT) 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; dkim=pass header.i=@walle.cc header.s=mail2016061301 header.b=XLgcUGYR; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726307AbgC1MEz (ORCPT + 99 others); Sat, 28 Mar 2020 08:04:55 -0400 Received: from ssl.serverraum.org ([176.9.125.105]:34069 "EHLO ssl.serverraum.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726199AbgC1MEz (ORCPT ); Sat, 28 Mar 2020 08:04:55 -0400 Received: from ssl.serverraum.org (web.serverraum.org [172.16.0.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ssl.serverraum.org (Postfix) with ESMTPSA id 06D1423058; Sat, 28 Mar 2020 13:04:50 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=walle.cc; s=mail2016061301; t=1585397092; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=n5jtDDhzPSvYKIS+PmQfH6uIuXE3eV4q3g/zF9Fsvio=; b=XLgcUGYRO9K8MDB5bv0eN6E/rPVGT7+8hpRkYKa0oYK7kqG+J82GWy9Z9UrVXXM2d3TY/l 44dxqw9vOcjFA43tDjkZeTHYvo/ZL/wck9Z06bEN5KblEyL2ihn4+V5olaW8sgt5tfgn5X sAEssrEkn0SCRxZcAsyH0d9PcQckI6U= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Date: Sat, 28 Mar 2020 13:04:50 +0100 From: Michael Walle To: Bartosz Golaszewski Cc: linux-gpio , linux-devicetree , LKML , linux-hwmon@vger.kernel.org, linux-pwm@vger.kernel.org, LINUXWATCHDOG , arm-soc , Linus Walleij , Rob Herring , Jean Delvare , Guenter Roeck , Lee Jones , Thierry Reding , =?UTF-8?Q?Uwe_Kleine-K=C3=B6nig?= , Wim Van Sebroeck , Shawn Guo , Li Yang , Thomas Gleixner , Jason Cooper , Marc Zyngier Subject: Re: [PATCH 12/18] gpio: add support for the sl28cpld GPIO controller In-Reply-To: References: <20200317205017.28280-1-michael@walle.cc> <20200317205017.28280-13-michael@walle.cc> Message-ID: X-Sender: michael@walle.cc User-Agent: Roundcube Webmail/1.3.10 X-Spamd-Bar: + X-Spam-Level: * X-Rspamd-Server: web X-Spam-Status: No, score=1.40 X-Spam-Score: 1.40 X-Rspamd-Queue-Id: 06D1423058 X-Spamd-Result: default: False [1.40 / 15.00]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; FREEMAIL_ENVRCPT(0.00)[gmail.com]; TO_MATCH_ENVRCPT_ALL(0.00)[]; TAGGED_RCPT(0.00)[dt]; MIME_GOOD(-0.10)[text/plain]; DKIM_SIGNED(0.00)[]; RCPT_COUNT_TWELVE(0.00)[21]; NEURAL_HAM(-0.00)[-0.578]; RCVD_COUNT_ZERO(0.00)[0]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; FREEMAIL_CC(0.00)[vger.kernel.org,lists.infradead.org,linaro.org,kernel.org,suse.com,roeck-us.net,gmail.com,pengutronix.de,linux-watchdog.org,nxp.com,linutronix.de,lakedaemon.net]; MID_RHS_MATCH_FROM(0.00)[]; SUSPICIOUS_RECIPS(1.50)[] Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Bartosz, Am 2020-03-18 10:14, schrieb Bartosz Golaszewski: > wt., 17 mar 2020 o 21:50 Michael Walle napisaƂ(a): >> >> This adds support for the GPIO controller of the sl28 board management >> controller. This driver is part of a multi-function device. >> >> Signed-off-by: Michael Walle > > Hi Michael, > > thanks for the driver. Please take a look at some comments below. > >> --- [..] >> +#define GPIO_REG_DIR 0 >> +#define GPIO_REG_OUT 1 >> +#define GPIO_REG_IN 2 >> +#define GPIO_REG_IE 3 >> +#define GPIO_REG_IP 4 > > These values would be more clear if they were defined as hex. > >> + >> +#define GPI_REG_IN 0 >> + >> +#define GPO_REG_OUT 0 > > Please also use a common prefix even for defines. The GPIO_, GPI_ and GPO_ prefixes corresponds to the different flavours. Do they still need a common prefix? Ie. the GPI_REG_IN has nothing to do with GPO_REG_OUT, nor has both something to do with the GPIO_REG_IN and GPIO_REG_OUT. I could prefix them with SL28CPLD_ though. But I don't know if that is what you had in mind because then they would be SL28CPLD_GPIO_REG_IN and SL28CPLD_GPI_REG_IN for example. -michael