Received: by 2002:a4a:3008:0:0:0:0:0 with SMTP id q8-v6csp3409164oof; Mon, 10 Sep 2018 14:21:25 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZasrrfGahd0hLaifTlWOJtIv0eVQFWZtw5LTx1MQfR6zOdmjVrnGJQlnILrJmxF/wgXwrx X-Received: by 2002:a62:1314:: with SMTP id b20-v6mr26283453pfj.230.1536614485304; Mon, 10 Sep 2018 14:21:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536614485; cv=none; d=google.com; s=arc-20160816; b=uVgdeUl/KONGf81p/BzAODeaK4jCJ7BqKTX44gvPreMX4R8GCNTWfO2FvUxuWC9mWo iQxb2zKw53iRml97fRPvbd+6eWaHemi5cOhbfX0VIrjznbdTHCJJP7T00WE+gPr0JCdH US/oVqoMoGRBhDbmUMtI5Y+tkUBL8v6ICgr+R0z7szaqHFPDktWVN915UEZwUQEQUxJc gRNKmkzbhOVxNiq2YPjuo1DqiCC3+9uuoT4jjq9Ub5MXs0iUGcqrS0w0/m34onDYWz1y Fycd71EmjRauAh3B6BFPLqmb0MjTTOJhnEixndlspdgXpO2WWWtBFQQ8kGDu9gJfUHMK TkOw== 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=Kz80MEr/y6tF2euh0vg5BfURZczzp7NsMfkHv5lG/5s=; b=UVS/5IqEA3H8b2hXtgwZTyN+7xSfV+7VPmSmx/f8KV2VTTMuePkbog88L8nEI3cjcl hzBTTfQ07pfisOQr81MyuU2IqqE7indEJ//CDhBNtYuPHt7P6bJ2cZRc8KMpNqMbigKF M3q6sRMgJch3duMqiIiUFaFDqmNu3IhzZHFQwDzlP6rr2DPxzW9lpq8SgrpbUMC+N7eg Ezs5uc9IdsE0BcfOYdSfLBMm5VPiNRg5EJytlXB4WoDEHiX00+gbB+3DrY90O2UgjjQ9 lEgVLeIIcyg+jwGOTZ2vQE/hYvHFC8Y9e48+0nagoQS3Qm0DnetsgRHfQVZLYQUeCmRR JVBg== 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 v2-v6si18676644pfv.57.2018.09.10.14.21.05; Mon, 10 Sep 2018 14:21:25 -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 S1727001AbeIKCQv (ORCPT + 99 others); Mon, 10 Sep 2018 22:16:51 -0400 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]:38827 "EHLO atrey.karlin.mff.cuni.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726217AbeIKCQv (ORCPT ); Mon, 10 Sep 2018 22:16:51 -0400 Received: by atrey.karlin.mff.cuni.cz (Postfix, from userid 512) id 0B0568057C; Mon, 10 Sep 2018 23:20:51 +0200 (CEST) Date: Mon, 10 Sep 2018 23:20:51 +0200 From: Pavel Machek To: Baolin Wang Cc: Jacek Anaszewski , Bjorn Andersson , rteysseyre@gmail.com, Mark Brown , Linus Walleij , Linux LED Subsystem , LKML Subject: Re: [PATCH v8 1/2] leds: core: Introduce LED pattern trigger Message-ID: <20180910212051.GB4697@amd> References: <5a502ec29251c019ddad8f3314ab45fc0f6feaf7.1536027873.git.baolin.wang@linaro.org> <20180908050208.GY2523@minitux> <0190dc10-99a3-abb7-b196-a537c49a2b6e@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="St7VIuEGZ6dlpu13" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --St7VIuEGZ6dlpu13 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi! > >> I'm still convinced that this will confuse our users and to me it would > >> be more logical if this denotes the number of times the pattern should > >> be repeated, with e.g. negative numbers denoting infinite. > > > > Sounds reasonable. Let's change this semantics as you propose. > > > >> In particular I expect to have to explain why my driver expects that y= ou > >> write 0 in the file named "repeat" to make it repeat and 1 to make it > >> not repeat. >=20 > Hm, so there are some cases we need to make clear. > 1) If negative numbers present infinite, so what's the meaning of number = 0? > 2) What we should show for users if repeat number is negative, just > show negative numbers or one string "infinite"? I'd say just -1 is infinite, anything else is error. And yes, reading it should just display -1. Thanks, Pavel --=20 (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blo= g.html --St7VIuEGZ6dlpu13 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAluW4DMACgkQMOfwapXb+vIRYACfUOm5UgiwdZQQCFVSVG9lOeQE kUYAoIB9aeDi3jtaGk/9BaMm/73NNuAT =V+ge -----END PGP SIGNATURE----- --St7VIuEGZ6dlpu13--