From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_2 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 87E3BC433DB for ; Tue, 23 Mar 2021 17:46:23 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 3CCBD619B8 for ; Tue, 23 Mar 2021 17:46:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230280AbhCWRpv (ORCPT ); Tue, 23 Mar 2021 13:45:51 -0400 Received: from lizzard.sbs.de ([194.138.37.39]:43918 "EHLO lizzard.sbs.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230510AbhCWRpi (ORCPT ); Tue, 23 Mar 2021 13:45:38 -0400 Received: from mail1.sbs.de (mail1.sbs.de [192.129.41.35]) by lizzard.sbs.de (8.15.2/8.15.2) with ESMTPS id 12NHj4K6020428 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 23 Mar 2021 18:45:04 +0100 Received: from md1za8fc.ad001.siemens.net ([167.87.18.164]) by mail1.sbs.de (8.15.2/8.15.2) with ESMTP id 12NHj2Dc032073; Tue, 23 Mar 2021 18:45:03 +0100 Date: Tue, 23 Mar 2021 18:45:01 +0100 From: Henning Schild To: Alexander Dahl Cc: "Enrico Weigelt, metux IT consult" , Andy Shevchenko , Linux Kernel Mailing List , "Linux LED Subsystem" , Platform Driver , , Srikanth Krishnakar , Jan Kiszka , Gerd Haeussler , Guenter Roeck , Wim Van Sebroeck , Mark Gross , Hans de Goede , Pavel Machek Subject: Re: [PATCH v2 2/4] leds: simatic-ipc-leds: add new driver for Siemens Industial PCs Message-ID: <20210323184501.39c81a97@md1za8fc.ad001.siemens.net> In-Reply-To: <1819093001.11427.1616071258857@seven.thorsis.com> References: <20210315095710.7140-1-henning.schild@siemens.com> <20210315095710.7140-3-henning.schild@siemens.com> <1819093001.11427.1616071258857@seven.thorsis.com> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-watchdog@vger.kernel.org Am Thu, 18 Mar 2021 13:40:58 +0100 schrieb Alexander Dahl : > Hei hei, > > > Enrico Weigelt, metux IT consult hat am 18.03.2021 > > 11:27 geschrieben: > > > > > > On 15.03.21 11:48, Andy Shevchenko wrote: > > > > Hi, > > > > > I have a question, why we can't provide a GPIO driver which is > > > already in the kernel and, with use of the patch series I sent, > > > to convert this all magic to GPIO LEDs as it's done for all > > > normal cases? > > > > Do we alread have a generic led driver that for cases that just > > set/clear bits in some mem/io location ? If not, that would be > > really great to have. > > Yes, there is. Look out for compatible "register-bit-led" in device > tree. That's from driver in drivers/leds/leds-syscon.c and you can > use it inside a syscon node in dts. > > It assumes one bit per LED. Sorry guys, i am lost here. Is there a driver i can base mine on, if so which one? Maybe you can point me to a good example that is conceptually similar. As i already wrote in the reviews of v1, the ACPI tables will not change on the machines in question. So there is a need for a driver. Either one like i did propose or maybe something that patches ACPI or loads device-tree snippets, again please point me to good examples. We are talking about x86-only here. Henning > Greets > Alex