Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp8562889ybn; Tue, 1 Oct 2019 09:51:42 -0700 (PDT) X-Google-Smtp-Source: APXvYqyX4BGZjHS+d9v75h3twJuXZ1T3NwGMUnhT1Z7BWjVcvKirySHgsBtQ2bwClWir3um62fRY X-Received: by 2002:a17:906:8054:: with SMTP id x20mr24736197ejw.65.1569948701942; Tue, 01 Oct 2019 09:51:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569948701; cv=none; d=google.com; s=arc-20160816; b=ppr1PCC8h5zmif48ltxnMdqliq7VHMdbtTwn2T6x5fJ38eLgLNxUejXDYDSUr4juFE VFOtlTH1s3B1I/0haLIuATcms9Ycsk0Z94Dh/IEHZHgALDPLsri+WRqWXgq9s1puMej5 FzSE26/vMI8I9yr8hJnRQBG6a1fgoaL4bXMTOKj5ER+nJpGnHuqouuzhUPQNmo/6qBlH GuKp0pBobd58YVF5zE5zoDj7S/Ab9nLDeRffAOvDVeXrVAs6AwzNbOsGGAcd0oveqnn1 X0cTYVF4C/LaqbCmGsgHji1Psg1+gLjnNSNbiyCPfJs7o5qCaziJPUPbasljHm5tIEAH Wjtg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=QrtoZRG+wd/zDHNs89jNL2TbIfxHUCCbPgl+qAt14GM=; b=iCBd3ML/EAT2iGKIWX/4vj8CGqk0+TDIynTSBQ02shf5gaK0a+u2lqQRw/ylLfo/aR owW4CdzzAYWMdYY3EAJ4jImGuRUqVD/It2/wd7MTbU1oTCtuoijJKiFi02BXRzIlPKmC ZKqr6Mfd5b44LQsMIncCb0iblqdPi51lzIpEiDG2lz8QfG9b0oDKJqf90NOGYIMntNrn ZVcOHIB+Um3FkLc1DuTaHb9F98n0thHGmPGTJUaQ6swwCk7HvwdZKYKCU5XIhKYjpBrt 1HEVNVpkOED69f1ihPRmupRk36lr6OBVtEwm3NjE8BYnxVVBNUgnT8jtcJKdXFdLkCK+ O+eQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=aggB0Wjo; 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 j21si5538625ejn.392.2019.10.01.09.51.16; Tue, 01 Oct 2019 09:51:41 -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=@kernel.org header.s=default header.b=aggB0Wjo; 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 S1730135AbfJAQ1O (ORCPT + 99 others); Tue, 1 Oct 2019 12:27:14 -0400 Received: from mail.kernel.org ([198.145.29.99]:46064 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726971AbfJAQ1O (ORCPT ); Tue, 1 Oct 2019 12:27:14 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 023D120679; Tue, 1 Oct 2019 16:27:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1569947233; bh=S16vIqGBsU7UMmMX2dbzcwOC4YMTdDCTctJpEhsGpxo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=aggB0WjoiizzEjPBqSKoPUdTtKPsBilJaY2qDULia5dRlw/JyI+8oeYYB8QY+j1TP Yf5o2nisxp1fcjGslufNvpIfIzPg8zQ/ByAR/VL0FgUHVABC8ehwZ41xcbYAtNza1O Cn52fXqXCeq8Gk9hTZ9rO65lg4fSO9cvZDJrTRJE= Date: Tue, 1 Oct 2019 18:27:10 +0200 From: Greg KH To: Mat King Cc: linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, rafael@kernel.org, Ross Zwisler , Rajat Jain , Lee Jones , Daniel Thompson , Jingoo Han Subject: Re: New sysfs interface for privacy screens Message-ID: <20191001162710.GB3526634@kroah.com> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.12.2 (2019-09-21) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Oct 01, 2019 at 10:09:46AM -0600, Mat King wrote: > Resending in plain text mode > > I have been looking into adding Linux support for electronic privacy > screens which is a feature on some new laptops which is built into the > display and allows users to turn it on instead of needing to use a > physical privacy filter. In discussions with my colleagues the idea of > using either /sys/class/backlight or /sys/class/leds but this new > feature does not seem to quite fit into either of those classes. > > I am proposing adding a class called "privacy_screen" to interface > with these devices. The initial API would be simple just a single > property called "privacy_state" which when set to 1 would mean that > privacy is enabled and 0 when privacy is disabled. > > Current known use cases will use ACPI _DSM in order to interface with > the privacy screens, but this class would allow device driver authors > to use other interfaces as well. > > Example: > > # get privacy screen state > cat /sys/class/privacy_screen/cros_privacy/privacy_state # 1: privacy > enabled 0: privacy disabled > > # set privacy enabled > echo 1 > /sys/class/privacy_screen/cros_privacy/privacy_state What is "cros_privacy" here? > Does this approach seem to be reasonable? Seems sane to me, do you have any code that implements this so we can see it? thanks, greg k-h