From patchwork Mon Jul 16 08:34:24 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 944224 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=linux-gpio-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=bgdev.pl Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=bgdev-pl.20150623.gappssmtp.com header.i=@bgdev-pl.20150623.gappssmtp.com header.b="PDUiOt95"; dkim-atps=neutral Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 41TcCv0Bt7z9s29 for ; Mon, 16 Jul 2018 18:34:51 +1000 (AEST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730304AbeGPJBE (ORCPT ); Mon, 16 Jul 2018 05:01:04 -0400 Received: from mail-wm0-f67.google.com ([74.125.82.67]:35613 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727654AbeGPJBD (ORCPT ); Mon, 16 Jul 2018 05:01:03 -0400 Received: by mail-wm0-f67.google.com with SMTP id y22-v6so407322wma.0 for ; Mon, 16 Jul 2018 01:34:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=puWJdGpBMsO19IRLChl84gsQ52QaGi0Ol+HJelqloys=; b=PDUiOt95HXM8yczayVbNPgJiE7eahygG+HIKJor5th+cuPY4LJNEHkNZqgpqGWJSkM FOunpH8XMyxTUAdN0iepaXqp/4l+DvTHsILx8XHQBpxBSuffoTvHex0Q9h4z8gTklsXQ //1itSOzrIPgR1F3jMc5mI8n1CqOB2MjqZ4EAcNKUdKfi0tpiCfFymg/gmf1CIawL9v0 ZaOLQV1RPo1GBYUYkYrh1JxwinHh6RlCa0OG9hr1DNM2byOcmFVjbHpvNGokaoMhpcUE t/MKoiSOsCJEQ0nLQo86+EeNWg4QANmAgNWM9IOT4gJuy9xXMkAxbPkcz9iFoeMYQaFJ nXWA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=puWJdGpBMsO19IRLChl84gsQ52QaGi0Ol+HJelqloys=; b=jIT/Uq1lK0r18i8EmKU1VnWRDjM9HJFGeTXvXQBKIqIxO1tV7AtS9KSGNm6ybTui1Z Ky3HaWOHYQid2ZVMRvPgfN0No992weTb8msDLUT95+qI1p4bDxL9A7SOWpI+DIFps/vQ R7/NBTn5VKpVYboQG45Cy/qWQAfShYx4GbX+QLDhUgWjP76gwb0t3mCcEFYuQcRw7i+t NF7T2gX/rtJPGEMTipAh7o+kwSL4zhlUShu9CRUTCJ9wUfxIZhmjbJPS0VCJX6ips0GU lJqPb1FCMhcs7KZBKeJem55HlFUJnhbHI5n83cAhCWxGFKLUAhpEImTlOJaZgH6P8eJp vaNQ== X-Gm-Message-State: AOUpUlF88yHXbW+8z7eyAHSXWOBQQErV6UCMhan2xnA3Az7FIbKiIAmv 0f6EY+NOG+p637K5N/BIFRnhFg== X-Google-Smtp-Source: AAOMgpcEfrh2t7Xu2Cj3UxcqGCqyNL3H6KDUca5FJs+GoRGKWM72mJYiU6vQ06XWTrztpxNxN2rPig== X-Received: by 2002:a1c:f902:: with SMTP id x2-v6mr8708220wmh.116.1531730085296; Mon, 16 Jul 2018 01:34:45 -0700 (PDT) Received: from brgl-bgdev.home ([2a01:cb1d:af:5b00:e837:b8d5:48c1:571b]) by smtp.gmail.com with ESMTPSA id z3-v6sm29483104wru.27.2018.07.16.01.34.44 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 16 Jul 2018 01:34:44 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij Cc: linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH 2/2] gpiolib: remove an unnecessary TODO Date: Mon, 16 Jul 2018 10:34:24 +0200 Message-Id: <20180716083424.11157-3-brgl@bgdev.pl> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180716083424.11157-1-brgl@bgdev.pl> References: <20180716083424.11157-1-brgl@bgdev.pl> Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org It's actually fine to read values of output lines. This was also allowed by the legacy sysfs interface. Signed-off-by: Bartosz Golaszewski --- drivers/gpio/gpiolib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index 57973524360d..19d36698574b 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c @@ -431,7 +431,7 @@ static long linehandle_ioctl(struct file *filep, unsigned int cmd, int i; if (cmd == GPIOHANDLE_GET_LINE_VALUES_IOCTL) { - /* TODO: check if descriptors are really input */ + /* NOTE: It's ok to read values of output lines. */ int ret = gpiod_get_array_value_complex(false, true, lh->numdescs,