Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp6059672ybv; Tue, 18 Feb 2020 09:06:20 -0800 (PST) X-Google-Smtp-Source: APXvYqxvfqdtgFj5fQlwLIcC9BpVll/y1NFREB578tdLuvPLtBythpzXaqmchYW3nSWY+N2c2rmb X-Received: by 2002:a9d:6647:: with SMTP id q7mr17166581otm.35.1582045580216; Tue, 18 Feb 2020 09:06:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582045580; cv=none; d=google.com; s=arc-20160816; b=A/OpkKTsjPyfuIiRscihBNSqLXfxU055UyFwapSJ1sx2apS0nWWQBW2AlWfFhOZZ0n hCvK/QTzeQUQKNxIQOjCRF7MReJpluHFz5pq6x9De/nNBFKQJdoq8j7oJaeEvftgKPNb HbRu50WC+yADeq+jB/aXb73JEt0Unp2udOhB1ygVTuiwkBzs3QiE55fy0NtEG+PzoNC3 f8608BeqH4yPV6B+TlMRKpfJPdqCkvZizEV6f38PBbqHX6sDMqeBrrRqB2QS5J6SZxfu DduqpNzTXzRlmQzZc9YClJdJJR/QwhdadH+uSKI70ssdb9+3ODeBbx1rv97hTlOJBO+V seoQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=qoAhGqwldv53AV58mftg6yYD/COdSN5kbrzybvrOkYw=; b=o4dBw+/iW3rBJmK9I77KteT+FwlYsrcGTeg4mFHER0kNQs3GD5n06QsYuOJhh5tSXm M8mu4GcGKq7sa5chnxkT7826bdxPaUs2iXql/lAujgpTZUJH6nQPeaYEJm/DyrOtt+2v Uq8hObYwkhnq22Of5ShPRbrB8rj1joKPiIysAtCFTXau2M/ATaL1rkTzs3NRKNmySNXB HWp5/RM6U9SGaYyDNDEG6RI0vIPuDtOUg5pUG8IJAsw8+jOLrCwf54PVZl3IFguIWVBR rI9ELiLtsnsYfdzmcNHhN3faXf0jnixy/fJ5Fs8pk+GhZqHgHe0lVG9fZT1EQtTaj1WW pfww== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x198si7728964oif.108.2020.02.18.09.06.06; Tue, 18 Feb 2020 09:06:20 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726486AbgBRREk (ORCPT + 99 others); Tue, 18 Feb 2020 12:04:40 -0500 Received: from smtp1.de.adit-jv.com ([93.241.18.167]:35877 "EHLO smtp1.de.adit-jv.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726399AbgBRREk (ORCPT ); Tue, 18 Feb 2020 12:04:40 -0500 Received: from localhost (smtp1.de.adit-jv.com [127.0.0.1]) by smtp1.de.adit-jv.com (Postfix) with ESMTP id 2C33D3C057C; Tue, 18 Feb 2020 18:04:37 +0100 (CET) Received: from smtp1.de.adit-jv.com ([127.0.0.1]) by localhost (smtp1.de.adit-jv.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id OHopyV6qEM96; Tue, 18 Feb 2020 18:04:31 +0100 (CET) Received: from HI2EXCH01.adit-jv.com (hi2exch01.adit-jv.com [10.72.92.24]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by smtp1.de.adit-jv.com (Postfix) with ESMTPS id 5F1653C00C5; Tue, 18 Feb 2020 18:04:31 +0100 (CET) Received: from lxhi-065.adit-jv.com (10.72.93.66) by HI2EXCH01.adit-jv.com (10.72.92.24) with Microsoft SMTP Server (TLS) id 14.3.468.0; Tue, 18 Feb 2020 18:04:30 +0100 Date: Tue, 18 Feb 2020 18:04:27 +0100 From: Eugeniu Rosca To: Geert Uytterhoeven CC: Linus Walleij , Bartosz Golaszewski , Jonathan Corbet , Harish Jenny K N , Alexander Graf , Peter Maydell , Paolo Bonzini , Phil Reid , Marc Zyngier , Christoffer Dall , Magnus Damm , Rob Herring , Mark Rutland , , , , , , Eugeniu Rosca , Eugeniu Rosca Subject: Re: [PATCH v5 0/5] gpio: Add GPIO Aggregator Message-ID: <20200218170427.GA7423@lxhi-065.adit-jv.com> References: <20200218151812.7816-1-geert+renesas@glider.be> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20200218151812.7816-1-geert+renesas@glider.be> X-Originating-IP: [10.72.93.66] Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Geert, On Tue, Feb 18, 2020 at 04:18:07PM +0100, Geert Uytterhoeven wrote: > Hi all, > > GPIO controllers are exported to userspace using /dev/gpiochip* > character devices. Access control to these devices is provided by > standard UNIX file system permissions, on an all-or-nothing basis: > either a GPIO controller is accessible for a user, or it is not. > Currently no mechanism exists to control access to individual GPIOs. > > Hence this adds a GPIO driver to aggregate existing GPIOs, and expose > them as a new gpiochip. This is useful for implementing access control, > and assigning a set of GPIOs to a specific user. Furthermore, this > simplifies and hardens exporting GPIOs to a virtual machine, as the VM > can just grab the full GPIO controller, and no longer needs to care > about which GPIOs to grab and which not, reducing the attack surface. > > Recently, other use cases have been discovered[1]: > - Describing simple GPIO-operated devices in DT, and using the GPIO > Aggregator as a generic GPIO driver for userspace, which is useful > for industrial control. > > Changes compared to v4[2]: > - Add Reviewed-by, Tested-by, > - Fix inconsistent indentation in documentation. I confirm that the diff between v4 and v5 comprises whitespace only. Thanks for your time to develop this useful functionality! -- Best Regards Eugeniu Rosca