From patchwork Wed Nov 6 08:51:47 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Vaittinen, Matti" X-Patchwork-Id: 11229679 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8A6381575 for ; Wed, 6 Nov 2019 08:56:03 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1A50B21882 for ; Wed, 6 Nov 2019 08:56:03 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=alsa-project.org header.i=@alsa-project.org header.b="q/TDc4b6" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1A50B21882 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=fi.rohmeurope.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 3C96616A4; Wed, 6 Nov 2019 09:55:11 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 3C96616A4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1573030561; bh=nEulrmz8c9rbyyowYzpbjnZeNw2yLk3Dzh8jyNU8cTQ=; h=Date:From:To:References:In-Reply-To:Cc:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=q/TDc4b6a6xTmDBVcOPyeknwwcdNDiJ8IOKZVkqQei3lAVOvM20KbsDR3lxjoTVtq 0LQJ+hRMusqDt/oCgpESdqoNX93hBnFErTrRaJnoKNwBdYocpKBuK54vxsJ14UrJmd RCke6yAXHwow4IgqgA0gg9+k7g+j6F/61ScmZaZk= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 97394F80610; Wed, 6 Nov 2019 09:52:43 +0100 (CET) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa1.perex.cz (Postfix, from userid 50401) id 24CE6F803D0; Wed, 6 Nov 2019 09:51:59 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on alsa1.perex.cz X-Spam-Level: X-Spam-Status: No, score=0.3 required=5.0 tests=FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from mail-lf1-f68.google.com (mail-lf1-f68.google.com [209.85.167.68]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 975D6F8015B for ; Wed, 6 Nov 2019 09:51:56 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 975D6F8015B Received: by mail-lf1-f68.google.com with SMTP id q28so17429179lfa.5 for ; Wed, 06 Nov 2019 00:51:56 -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:in-reply-to:user-agent; bh=S0olsl6U+J7JDQ22nIhebd59focLW5rDuobD1hUdq5I=; b=QU6OAyXJo/Tslt66nev/FfkZb2FSTDKl54i3pnsNBvjMQeaFNgCL414VNGw63m3Igu Uat3f2mmOZh80bPLr4eSAJKfgTDMvCOPgiLiueb/ZOTyjhJ2l7uY7txz+K8oZzkeQESB lFjHpv8jHEtsdjU44/imj0oUyEGALdqDWaTAbDgPFqMRJ+5m6DqdB+F9Z1GtOfJZduxv WlWW6GVswmTGCpc/dgYNU6f2hhIreDZHrG9PKLUn5Dstz9KWB4AfsWzdLA6PfAIrpJ2h /SwEMXMamGIvujCWix572ecCt+yu5N+tRrLL1rrtGk3ju0avuHuIeTpiRKu2osN0n6uw lGUQ== X-Gm-Message-State: APjAAAXioKaXaflGRH84pG1lS8jlre1SiQxZpGs1Li68kv0Qi4V0/NL7 qVJfv2m+XHNMXtAgC9Q3fAk= X-Google-Smtp-Source: APXvYqzDio4qZlOISjr6MeUpYA9Mauudh6cLHNIHVHIEV0v296IjktNY6fM6+w+eUpFaURqfUCi8NA== X-Received: by 2002:a19:c790:: with SMTP id x138mr23827081lff.61.1573030315542; Wed, 06 Nov 2019 00:51:55 -0800 (PST) Received: from localhost.localdomain ([213.255.186.46]) by smtp.gmail.com with ESMTPSA id v203sm10763661lfa.25.2019.11.06.00.51.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Nov 2019 00:51:55 -0800 (PST) Date: Wed, 6 Nov 2019 10:51:47 +0200 From: Matti Vaittinen To: matti.vaittinen@fi.rohmeurope.com, mazziesaccount@gmail.com Message-ID: References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.12.1 (2019-06-15) X-Mailman-Approved-At: Wed, 06 Nov 2019 09:52:36 +0100 Cc: Kuppuswamy Sathyanarayanan , linux-aspeed@lists.ozlabs.org, David Daney , Linus Walleij , alsa-devel@alsa-project.org, Peter Tyser , Thierry Reding , Jonathan Hunter , Fabio Estevam , linux-stm32@st-md-mailman.stormreply.com, Marek Vasut , Florian Fainelli , Kevin Hilman , Michal Simek , Marek Behun , Bartosz Golaszewski , Ludovic Desroches , bcm-kernel-feedback-list@broadcom.com, Joel Stanley , Uwe =?iso-8859-1?q?Kleine-K=F6nig?= , Bamvor Jian Zhang , NXP Linux Team , linux-pwm@vger.kernel.org, Grygorii Strashko , Charles Keepax , Maxime Coquelin , linux-omap@vger.kernel.org, Alexandre Torgue , Ray Jui , Sascha Hauer , William Breathitt Gray , linux-gpio@vger.kernel.org, Richard Fitzgerald , Santosh Shilimkar , linux-tegra@vger.kernel.org, Andy Shevchenko , linux-arm-kernel@lists.infradead.org, Scott Branden , Masahiro Yamada , Andrew Jeffery , "Enrico Weigelt, metux IT consult" , linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, Thorsten Scherer , Pengutronix Kernel Team , patches@opensource.cirrus.com, Shawn Guo Subject: [alsa-devel] [PATCH v2 1/2] gpio: Add definition for GPIO direction X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" At least for me it is difficult to remember the meaning of GPIO direction values. Define GPIO_LINE_DIRECTION_IN and GPIO_LINE_DIRECTION_OUT so that occasional GPIO contributors would not need to always check the meaning of hard coded values 1 and 0. Signed-off-by: Matti Vaittinen --- Changes from v1: No changes. include/linux/gpio/driver.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/linux/gpio/driver.h b/include/linux/gpio/driver.h index 5dd9c982e2cb..cc9ade4552d9 100644 --- a/include/linux/gpio/driver.h +++ b/include/linux/gpio/driver.h @@ -22,6 +22,9 @@ enum gpio_lookup_flags; struct gpio_chip; +#define GPIO_LINE_DIRECTION_IN 1 +#define GPIO_LINE_DIRECTION_OUT 0 + /** * struct gpio_irq_chip - GPIO interrupt controller */