Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp979703pxb; Wed, 3 Mar 2021 23:19:44 -0800 (PST) X-Google-Smtp-Source: ABdhPJw7XdDWSl+JEekykjndo9Twlv0OvdBK32eb/EVBPEOc5F4GOoEmQE8yjoXTqSjO2k00QikL X-Received: by 2002:a17:907:a06b:: with SMTP id ia11mr2735990ejc.294.1614842384536; Wed, 03 Mar 2021 23:19:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614842384; cv=none; d=google.com; s=arc-20160816; b=rfj2MGcpSEI6KcGiz/jAz4/2xfbishbbo6AdUpEuDVzidlMeZmMAxv2kBfKi9WjFx/ nPDrabt4mnnDJasNTDnoTCfoQ3HOQQGiJRLVDtt8n7J5wikPdGhCqPmp/FnSc+FNtLyD TJEjRvUBvawjXS7Za3YVmil5YPDOHDBHfgkbXyQB2DvaE4/Q2yZY4BJXj6fNDHtEb7w8 catcL+ToApO2sjf0v4JsTuNpCzsB0THBev3JRkm/YkBl2eFsbEnaSG7XWM2adTm/wWQ7 ZePKJn9qy+qnnNEw5JbiKab1Dv8BueDcDr+zOEKY1kx9t33+W0gPjuR9IRzkRTd7uSaA YmGw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=efUmHjLh3cocnat3E6Lx/gv40iZJlKKaQ1VwAIsnZ0o=; b=Dm+aCUMXtMjJ3g0ykb6GSlqkgRdLtOUX/qSZDgEckWuefnLa7SFr+SMwfqF93vVtLJ p+KrBqxtA3keTS1Wi3TveQxL3QjfbewW0DBcvtdARIaZXFfCFr3zHoTjMKmgZjqhMNDq P7Cw0B+E0IVnlk4RvZEV2eOO6idbbNF4qyO7Y6Ys0JlJIAcRcFu7Guem01622Ekmswc3 zb+1KxLCv1UhghaK1l+DWkZ3br5Xk7t2hqIlvGojpis/bmApdkqvJETLrA1bPAqJniAD laAj18306khwHlpkJIhWRk7OfzquDFNsjnuP41LsjZJpqhlX8RxSYFI5Q9z69XW8Ae6M L2aw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b15si2869634edz.247.2021.03.03.23.19.22; Wed, 03 Mar 2021 23:19:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2360322AbhCBWTO (ORCPT + 99 others); Tue, 2 Mar 2021 17:19:14 -0500 Received: from jabberwock.ucw.cz ([46.255.230.98]:36108 "EHLO jabberwock.ucw.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1381321AbhCBU4Q (ORCPT ); Tue, 2 Mar 2021 15:56:16 -0500 Received: by jabberwock.ucw.cz (Postfix, from userid 1017) id 0F40C1C0B81; Tue, 2 Mar 2021 21:54:53 +0100 (CET) Date: Tue, 2 Mar 2021 21:54:52 +0100 From: Pavel Machek To: Henning Schild Cc: linux-kernel@vger.kernel.org, linux-leds@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-watchdog@vger.kernel.org, Srikanth Krishnakar , Jan Kiszka , Gerd Haeussler , Guenter Roeck , Wim Van Sebroeck , Mark Gross , Hans de Goede Subject: Re: [PATCH 2/4] leds: simatic-ipc-leds: add new driver for Siemens Industial PCs Message-ID: <20210302205452.GA32573@duo.ucw.cz> References: <20210302163309.25528-1-henning.schild@siemens.com> <20210302163309.25528-3-henning.schild@siemens.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="cWoXeonUoKmBZSoM" Content-Disposition: inline In-Reply-To: <20210302163309.25528-3-henning.schild@siemens.com> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --cWoXeonUoKmBZSoM Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi! > This driver adds initial support for several devices from Siemens. It is > based on a platform driver introduced in an earlier commit. Ok. > diff --git a/drivers/leds/Makefile b/drivers/leds/Makefile > index 2a698df9da57..c15e1e3c5958 100644 > --- a/drivers/leds/Makefile > +++ b/drivers/leds/Makefile > @@ -93,6 +93,7 @@ obj-$(CONFIG_LEDS_TURRIS_OMNIA) +=3D leds-turris-omnia= =2Eo > obj-$(CONFIG_LEDS_WM831X_STATUS) +=3D leds-wm831x-status.o > obj-$(CONFIG_LEDS_WM8350) +=3D leds-wm8350.o > obj-$(CONFIG_LEDS_WRAP) +=3D leds-wrap.o > +obj-$(CONFIG_LEDS_SIEMENS_SIMATIC_IPC) +=3D simatic-ipc-leds.o Let's put this into drivers/leds/simple. You'll have to create it. > + * > + * This program is free software; you can redistribute it and/or modify > + * it under the terms of the GNU General Public License version 2 as > + * published by the Free Software Foundation. > + */ Remove? > +static struct simatic_ipc_led simatic_ipc_leds_io[] =3D { > + {1 << 15, "simatic-ipc:green:run-stop"}, > + {1 << 7, "simatic-ipc:yellow:run-stop"}, > + {1 << 14, "simatic-ipc:red:error"}, > + {1 << 6, "simatic-ipc:yellow:error"}, > + {1 << 13, "simatic-ipc:red:maint"}, > + {1 << 5, "simatic-ipc:yellow:maint"}, > + {0, ""}, > +}; Please use names consistent with other systems, this is user visible. If you have two-color power led, it should be :green:power... See include/dt-bindings/leds/common.h . Please avoid // comments in the code. > +module_init(simatic_ipc_led_init_module); > +module_exit(simatic_ipc_led_exit_module); No need for such verbosity for functions that are static. > +MODULE_LICENSE("GPL"); GPL v2? Best regards, Pavel --=20 http://www.livejournal.com/~pavelmachek --cWoXeonUoKmBZSoM Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iF0EABECAB0WIQRPfPO7r0eAhk010v0w5/Bqldv68gUCYD6mHAAKCRAw5/Bqldv6 8jccAKCW5J5k8GW26pDj+wn7z3ClTwgz9gCdG2YoZJI2nYD8w2mz8d3Xbt3YS1w= =iNci -----END PGP SIGNATURE----- --cWoXeonUoKmBZSoM--