Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1722980pxj; Wed, 19 May 2021 12:20:55 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzzeuLi6zVdd9lIB6Fpwm2CSpgLTdrTmve6cRbH+6SvpraW6JD2D1tOruRBr4DyZ/PiwMLn X-Received: by 2002:a17:906:4a46:: with SMTP id a6mr717869ejv.322.1621452054877; Wed, 19 May 2021 12:20:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621452054; cv=none; d=google.com; s=arc-20160816; b=ylaHPkrV038pinKAECbxnhiQlAg4AywAPu74fGeyU1l4uRyYH4E3W9dBKCpMwukNMk Cz15mktpICZLgrMx6MADEhmvJbZa8SQ6C1XZe1G1tsO6xyZKQlHu+ziSRXa3bXERjgRl 6Vfx7DaijeMCTmFcXuSQM4WfipnQBNPVthDrqLXTq3vNE4QrbGc6fFetGEtXg7hcqzd6 GHJWjqGmdQpgOLIx81lyaPkdSpdrLsBljM8r3dlN4giFIvch76LECrZDbMYELMPX8H4I 9VY7pxzBD5kGnFNz62awcEiLx1S7Kmkv9D6B8VCuTfdM6sG9vKw7r9u/qY1IHkR+zCrW 5Uzg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:organization:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :ironport-sdr:ironport-sdr; bh=8S8JMk2QU0RuLkzzOFIuDd5JjEg7XtNEBpt5ex9BKt8=; b=L1ToQ+N0Gb/TEszb1prLKFiD+ZnUSD6+2K45ws1BH/X5YW9bjd/gDU3c3fJhBLgzyG y0nStzT9kJLhCVlb07iNkR3UaFBkofTvsfrSpy28It6lqgG+94C/XlW/Y64apvE7Sb9O XBBBLCrhljhNhE66MqTWWl7UVKW5WFXJxnba11zhWZjTJXm5cRbiCPal2v11U2KfE4Xg JKeTmIhPQv40zaeBkFidyQgV4FXbmQSFTVH3M8NiTQlja5XQD+87k7mqILvYtGo9bVQj bQXSh/n3udlG7RvneFJ5x/SAoK+XLRlI52fjGaxRrI1zk+s6vnXY9EXuPHFVlH2PQXhz lsEQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id pw23si341756ejb.144.2021.05.19.12.20.28; Wed, 19 May 2021 12:20:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241796AbhESHqm (ORCPT + 99 others); Wed, 19 May 2021 03:46:42 -0400 Received: from mga02.intel.com ([134.134.136.20]:44814 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234879AbhESHql (ORCPT ); Wed, 19 May 2021 03:46:41 -0400 IronPort-SDR: Jj44/z2AEc/GK2ugM9JhrnL0moFJFZZ0V3g1gzGzqkJVQESX3KkbGlgdcJnP3sJCYvJwSswYic F/fQsMEcEIEQ== X-IronPort-AV: E=McAfee;i="6200,9189,9988"; a="188042600" X-IronPort-AV: E=Sophos;i="5.82,312,1613462400"; d="scan'208";a="188042600" Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 May 2021 00:45:22 -0700 IronPort-SDR: RPGXIXXASOkQEW3xJ1raYGkgwDAxWM2cnqOVNkfL8WTYoFlUhFZswFiUg4ZWx+qIg/p3nPfQy9 /qclinwFaDqQ== X-IronPort-AV: E=Sophos;i="5.82,312,1613462400"; d="scan'208";a="411625304" Received: from smile.fi.intel.com (HELO smile) ([10.237.68.40]) by orsmga002-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 May 2021 00:45:20 -0700 Received: from andy by smile with local (Exim 4.94) (envelope-from ) id 1ljGtI-00DARi-6B; Wed, 19 May 2021 10:45:16 +0300 Date: Wed, 19 May 2021 10:45:16 +0300 From: Andy Shevchenko To: Kent Gibson Cc: Bartosz Golaszewski , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Linus Walleij , Suresh Balakrishnan Subject: Re: [PATCH v1 1/2] gpiolib: Never return internal error codes to user space Message-ID: References: <20210518155013.45622-1-andriy.shevchenko@linux.intel.com> <20210518232451.GA7362@sol> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210518232451.GA7362@sol> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, May 19, 2021 at 07:24:51AM +0800, Kent Gibson wrote: > On Tue, May 18, 2021 at 06:50:12PM +0300, Andy Shevchenko wrote: > > Currently it's possible that character device interface may return > > the error codes which are not supposed to be seen by user space. > > In this case it's EPROBE_DEFER. > > > > Wrap it to return -ENODEV instead as sysfs does. > > Fixes: d7c51b47ac11 ("gpio: userspace ABI for reading/writing GPIO lines") > > Fixes: 61f922db7221 ("gpio: userspace ABI for reading GPIO line events") > > Fixes: 3c0d9c635ae2 ("gpiolib: cdev: support GPIO_V2_GET_LINE_IOCTL and GPIO_V2_LINE_GET_VALUES_IOCTL") ... > You immediately revert this patch in patch 2. > My understanding is that is not allowed within a patch set. > Why split the patches instead of going direct to the new helper? It's for backporting to make it easier. (I deliberately left the context above) I can fold them if maintainers think it's okay to do. -- With Best Regards, Andy Shevchenko