From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from fhigh1-smtp.messagingengine.com (fhigh1-smtp.messagingengine.com [103.168.172.152]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6172916DEDA; Fri, 21 Jun 2024 09:25:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=103.168.172.152 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718961929; cv=none; b=omHHxkZg1KdYM8RUKoDH++htGt8G7Jj2QKI/IIdpADgm7ynseRp9mGBE3oCHXqizrrryEAMc0z9sY78SNMN4Nu7MIiOib0/3ps+NPK5E702LsSfgnFzXX0ocntXXF6MVFFYmOf4FX2+NpeAbgOu4IZg53wXsUVd70Li351R0Yaw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718961929; c=relaxed/simple; bh=SIATBHynFPT4f+uIOXa3YInhK69wX4k++ZVS8wWjv5w=; h=MIME-Version:Message-Id:In-Reply-To:References:Date:From:To:Cc: Subject:Content-Type; b=e40MiSyvzOUV550BpwAqvrSa1AxMQjauG9sUibUG0KgNdrYhwKfCUQJxndgU1MyQBxkmlWxePnmDxSwummaaHepEcpXY5m9ZJkMwftG76E89H45gZeGUML5VRssje0hvTcM5gDXcfhR6e9tpLYiu9rY+bmyXkZUJ3kEablX7uhE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=ljones.dev; spf=none smtp.mailfrom=ljones.dev; dkim=pass (2048-bit key) header.d=ljones.dev header.i=@ljones.dev header.b=LPT4HTFD; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b=fLokdyMT; arc=none smtp.client-ip=103.168.172.152 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=ljones.dev Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=ljones.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ljones.dev header.i=@ljones.dev header.b="LPT4HTFD"; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="fLokdyMT" Received: from compute2.internal (compute2.nyi.internal [10.202.2.46]) by mailfhigh.nyi.internal (Postfix) with ESMTP id 5D05C1140227; Fri, 21 Jun 2024 05:25:25 -0400 (EDT) Received: from imap41 ([10.202.2.91]) by compute2.internal (MEProxy); Fri, 21 Jun 2024 05:25:25 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ljones.dev; h=cc :cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm3; t=1718961925; x=1719048325; bh=/yr39+Xu06 R6chuqcUrLF7krLetllE+7yriX4oNGtLE=; b=LPT4HTFDM/hI9/ZaAoTIzxwKRe BZ9OBVXZI9UM1+VsXe9NkrCSjZW8XShs5d9s/cMSrZzxye7doyOyU13IjxhBTXwz UeNp7QF/tLzETXxXG0ki1Z7e6qk3irOZQPuUWpYZblME8lFM03XEL9+xG10Y7NvH t+Lv46QtarTCzsKwIzohso1wdo1d6zvk60L8lNgbTj8zrJizW1eEfUfQ+GDRqbYY BJSGH+HjEj1ChfIP3Fztuvui3BSQBgZuD2o4Dk4tF1pfN/EzMOWy6p96j8lY6RwU eqLMQdndw+m8frnELWO4aXlvEVBJV/kpyqUxFeyMmgm7qNoN/izyEQyDX6TA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; t=1718961925; x=1719048325; bh=/yr39+Xu06R6chuqcUrLF7krLetl lE+7yriX4oNGtLE=; b=fLokdyMThmaAdWVgXue8YQXjDhjjoNuzHpgVthyohscc AcTuggRWKhc1tNwo43gcr1IBF8VeYfhzzJNBaVEDY4icLLYUBfn/myxlXssRxxFT HMmA6Hdq4m+qh7sl66yy2G8it6F0VIwKwwup1VHmee/lqitWqXUXwkjL5/KjPuEB n8+AcyLEJkmhda60lpxpF/TxNoylg1IQoXTGmypKDXMdJuv/VSrTMkUBwD10U/d1 1aQXl5i90prbEx/txpHaOhHSwivmvPyfMiwfQJ1mzfxE+1AvEl1UE5/PnY++z5jk WNSEqYkGQAPo+7b/S0QAP5BQb/F7b9KVkxP/k7E1yQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrfeefgedgudeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepofgfggfkjghffffhvfevufgtsehttdertderredtnecuhfhrohhmpedfnfhu khgvucflohhnvghsfdcuoehluhhkvgeslhhjohhnvghsrdguvghvqeenucggtffrrghtth gvrhhnpedutdelgfdvgeekueeuteevffelfedukeeitedugfdvtdeutdetjeduudeuvdeg gfenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehluh hkvgeslhhjohhnvghsrdguvghv X-ME-Proxy: Feedback-ID: i5ec1447f:Fastmail Received: by mailuser.nyi.internal (Postfix, from userid 501) id A549B2340082; Fri, 21 Jun 2024 05:25:24 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.11.0-alpha0-522-ga39cca1d5-fm-20240610.002-ga39cca1d Precedence: bulk X-Mailing-List: linux-api@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: In-Reply-To: References: <20240620082223.20178-1-dev@doubly.so> <20240620082223.20178-2-dev@doubly.so> Date: Fri, 21 Jun 2024 21:25:04 +1200 From: "Luke Jones" To: "Devin Bayer" , corentin.chary@gmail.com Cc: "Hans de Goede" , platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org, linux-api@vger.kernel.org, =?UTF-8?Q?Ilpo_J=C3=A4rvinen?= Subject: Re: [PATCH 1/2] platform/x86: asus-wmi: support camera disable LED Content-Type: text/plain On Fri, 21 Jun 2024, at 7:50 PM, Devin Bayer wrote: > > Thanks for the review, Luke. > > On 20/06/2024 23.40, Luke Jones wrote: > >> > >> + if (asus_wmi_dev_is_present(asus, ASUS_WMI_DEVID_CAMERA_LED)) { > >> + asus->camera_led.name = "platform::camera"; > > > > What do other devices label their camera LED as? The one I could find appears to use `::camera`. So maybe `asus::camera` would be better? This also keeps in line with `asus::kbd_backlight`. > > I reasoned it would be better to keep the name generic is so out of the > box desktops could toggle the camera and the LED when KEY_CAMERA is > pressed, just like with micmute and mute. This might be true if one relies solely on the filesystem path, which in any case is a bad move and likely to cause the moon to drift away from earth eventually. Most Linux software will use the udev libraries available to filter devices according to any amount of criteria (and if they are not they *really should* - udev is pretty powerful and freeing. I've tried finding prior art again and there's just not a lot to go on. ".name = "platform" shows very little except a few micmute labels. "::cam" gets one entry. So my guess is this is still a very new thing or it's not important enough to be used.. In any case looking at the rest of the possible LED entries, mostly those following keyboard, the last part of the name being sensible is what counts the most (e.g "scrolllock", "camera"). This might be setting a precedent, and if so I'd be happy with "::camera" in the LED class conveying expectations well enough.