Received: by 2002:a25:f815:0:0:0:0:0 with SMTP id u21csp906729ybd; Wed, 26 Jun 2019 07:57:53 -0700 (PDT) X-Google-Smtp-Source: APXvYqxVHN9zU36zsk9NcXfKnuzU6WhUpgzG5ytVJFJ7NEL/G9qui14vwp/GdQp6vwoeft2mIaeW X-Received: by 2002:a17:90a:1ae2:: with SMTP id p89mr5026635pjp.26.1561561072876; Wed, 26 Jun 2019 07:57:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561561072; cv=none; d=google.com; s=arc-20160816; b=xXGsKim0kl7JeqVGpjOZpTlZ39+gARZspShK4bHyjYzxj6tZRre3TFCziIa2ZglvH2 UKzV/HW2MuICvcl9ne7VigOFQ1Y2zOv3mThSfETX/I4H9IVK9If34PEOce+nYTA8KxGa /g3guKVKznALR0od91NxtNah+zuJMkaivakjT/Q6XKin6Jjv0iV35LEJu1nlv6h9GFht pptc0QBrelMGvvEH5sib9oCGpbpJ/QC0WnfWFW0pqq5jhO0z/WQnkDXokBHN55V3hsFT rXAs5slrIKUOZq78A1O4QV0iZVrX3IOffutBRjaTvQs0PXG/oAZFKZLfnEbMAqnyo80c PUrg== 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; bh=i4+1A70cPnGQFFIZCQmKysYHYTP6etLkzPuuAtC01I0=; b=g5iIMY/W9zvtN8F6kUIHCy1rwKpJKatXdNxiUbzn+HTv+zKwTscuBYlf22IQHHciIj jh6AfZhobKr6kiq5sSnAXjeAg03l63qNXETgmCXh0+Bkq5ZTGfaiYiXitI+1pTWWMMbn vJw15szgDMBeFsUJQ8TdIl5sIMw6id+JkTWnHsPGZiZp1sW6hj0NhSLZwdBgEtH6ZFex P1wyel3pcfTviUBRQn/ddWEimzOKYIvk2mINE5RT1M5mHw2fOhYgJkk/jVIHUvfElKN5 WjZ2OOQyG5MXpHXg4YLYqidrNQ1E3OTi+zzxTja3DgKEsYdcBK5ohVt0/rCZDl1eL5Aj mKjQ== 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 f20si18506832pfn.166.2019.06.26.07.57.36; Wed, 26 Jun 2019 07:57:52 -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; 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 S1728190AbfFZO4V (ORCPT + 99 others); Wed, 26 Jun 2019 10:56:21 -0400 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]:42482 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726029AbfFZO4U (ORCPT ); Wed, 26 Jun 2019 10:56:20 -0400 Received: by atrey.karlin.mff.cuni.cz (Postfix, from userid 512) id 5369E807BA; Wed, 26 Jun 2019 16:56:07 +0200 (CEST) Date: Wed, 26 Jun 2019 16:56:11 +0200 From: Pavel Machek To: Matthias Kaehlcke Cc: Thierry Reding , Lee Jones , Daniel Thompson , Jingoo Han , Bartlomiej Zolnierkiewicz , linux-pwm@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org, Enric Balletbo i Serra , Douglas Anderson , Brian Norris , Jacek Anaszewski Subject: Re: [PATCH v2 2/4] backlight: Expose brightness curve type through sysfs Message-ID: <20190626145611.GA22348@xo-6d-61-c0.localdomain> References: <20190624203114.93277-1-mka@chromium.org> <20190624203114.93277-3-mka@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190624203114.93277-3-mka@chromium.org> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi! > Export the type of the brightness curve via the new sysfs attribute > 'scale'. The value of the attribute may be a simple string like > 'linear' or 'non-linear', or a composite string similar to > 'compatible' strings of the device tree. A composite string consists > of different elements separated by commas, starting with the > most-detailed description and ending with the least-detailed one. An > example for a composite string is "cie-1931,perceptual,non-linear" > This brightness curve was generated with the CIE 1931 algorithm, it > is perceptually linear, but not actually linear in terms of the > emitted light. If userspace doesn't know about 'cie-1931' or > 'perceptual' it should at least be able to interpret the 'non-linear' > part. I'm not sure the comma-separated thing is a good idea. If it is, it should go to the Documentation, not to changelog. > +What: /sys/class/backlight//scale > +Date: June 2019 > +KernelVersion: 5.4 > +Contact: Daniel Thompson > +Description: > + Description of the scale of the brightness curve. The > + description consists of one or more elements separated by > + commas, from the most detailed to the least detailed > + description. > + > + Possible values are: > + > + unknown > + The scale of the brightness curve is unknown. > + > + linear > + The brightness changes linearly in terms of the emitted > + light, changes are perceived as non-linear by the human eye. > + > + non-linear > + The brightness changes non-linearly in terms of the emitted > + light, changes might be perceived as linear by the human eye. non-linear is not too useful as described. > + perceptual,non-linear > + The brightness changes non-linearly in terms of the emitted > + light, changes should be perceived as linear by the human eye. > + > + cie-1931,perceptual,non-linear > + The brightness curve was calculated with the CIE 1931 > + algorithm. Brightness changes non-linearly in terms of the > + emitted light, changes should be perceived as linear by the > + human eye. Is it useful to know difference between perceptual, and cie-1931? Would it be useful to export absolute values in some well-known units? If I'm in dark room, I may want 100mW/m^2 of backlight... And it would be nice if I could set same backlight intensity on all my devices easily. Pavel