From nobody Mon Nov 28 17:27:04 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4NLXTN3J2jz4jR4J; Mon, 28 Nov 2022 17:27:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4NLXTN1wklz43mF; Mon, 28 Nov 2022 17:27:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1669656424; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4XyHvuW8s2axMQP2YAPaoDPRmsXYvISM1/U/5uqWc9g=; b=jcDx2dVjDI/guvrflXpk5GVkVF2DZcvXBxUQ7Z6fri+KwJh9Ct3DX248tx7qd2UlHWlI28 i5BxTUgXVMkg4+Nq1hlUkCXX9vi3BnPNbKEkz9QUQ+oNfQ2jDWCGbRJVtVkRvX2bjpV8eF FkFZUHv1C169U3HOEubj0FjdEcHEGu8AtFuykd3tQWOKR7Dxk9NpY5AJR/bd6Z6ibPBkJP Vbb90oxwsyC4Mol/8f5ljYkwRNhhCiK3AC3d5L2GCjcYbCiTbUWDBap5SaLY9WoYiotiAe S7XUycUe26R3hix+fDkjbG6dv+RS4ex7t97G/e1S3hPyfNgY1M67PP7/d7v7xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1669656424; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=4XyHvuW8s2axMQP2YAPaoDPRmsXYvISM1/U/5uqWc9g=; b=QzfSd0YDaly//TOX+UL8HMo7xIOR4yEciydpQ7mJkMTjerBdpiVjWcBFgx0drFzwZLSoOl P8YC4z4I5fsXEecXSyxY7TDgQgThi0lGBa8w9g/1VjDchSQofIHp6L3upHigYpZEzncC8Y 80t80MMwCkMt+lGatSdoa5MTkb1dn2Ym6Lgl7443TMw1qMC2cWmjFU2guashJU+XqunP53 slx0XmKdF+Qa9PzHx7WD++hA8iiX78f9/jlFxq9BZgtzb2DWLfLaBnVEm+jbKNIOuyxxRD DUhCxZEUokm3SxTpA/UlM5kcrCziOI+NOaV4zba3nqjNSgkZQlV5T3KjiuWcbQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1669656424; a=rsa-sha256; cv=none; b=keRkmu3TI4zFTwzd7iDMPz+Oos+4jEj1AFLhAcLijmBLCF06sbNEqEiYoQxcclF/K0gLiC YFTFR3yZw595Z6HlNN7FCtAXTvJ82yv+EJsenyjIrdwwobhUFDIGCoWcpftJueAEDR/ZTG RewlcOfbPDBSrk6FOIifTuomYyHPhmkoKZSuffDEgAoWx3ivaU4CY3siDzH+2lnpAmx7fD WL6/jaxJ12RXR5Z6aCxc8zcUgTV4i+LKMPpqwLvvtiNDBK1sIEK/kF46zRM52SafBLegIh /0u0v3yxRbCmku75gW8M5VIRztTrmSPNB3KB4fiWRBRl2/imUWtpw3gi/EVIeQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4NLXTN0RRZzm0j; Mon, 28 Nov 2022 17:27:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 2ASHR42C081228; Mon, 28 Nov 2022 17:27:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2ASHR3EP081227; Mon, 28 Nov 2022 17:27:04 GMT (envelope-from git) Date: Mon, 28 Nov 2022 17:27:04 GMT Message-Id: <202211281727.2ASHR3EP081227@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: db047ca73f0f - stable/13 - LinuxKPI: add linux/leds.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bz X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: db047ca73f0f057e913744d65ac723d9fc91b3f6 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=db047ca73f0f057e913744d65ac723d9fc91b3f6 commit db047ca73f0f057e913744d65ac723d9fc91b3f6 Author: Bjoern A. Zeeb AuthorDate: 2022-10-30 17:05:52 +0000 Commit: Bjoern A. Zeeb CommitDate: 2022-11-28 16:31:03 +0000 LinuxKPI: add linux/leds.h This is just a dummy enum and struct in order to make drivers compile more happily as some parts are simply not hidden behind #ifdefs and this avoids a longer-term maintenance problem. Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D37215 (cherry picked from commit a62d5ff5b04cb8657028c090764c3044178c4ccd) --- sys/compat/linuxkpi/common/include/linux/leds.h | 40 +++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/leds.h b/sys/compat/linuxkpi/common/include/linux/leds.h new file mode 100644 index 000000000000..f7ee7a68dcf5 --- /dev/null +++ b/sys/compat/linuxkpi/common/include/linux/leds.h @@ -0,0 +1,40 @@ +/*- + * Copyright (c) 2022 Bjoern A. Zeeb + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#ifndef _LINUXKPI_LINUX_LEDS_H +#define _LINUXKPI_LINUX_LEDS_H + +enum led_brightness { + __DUMMY, +}; + +struct led_classdev { + const char *name; + const char *default_trigger; + int (*blink_set)(struct led_classdev *, unsigned long *, unsigned long *); + void (*brightness_set)(struct led_classdev *, enum led_brightness); +}; + +#endif /* _LINUXKPI_LINUX_LEDS_H */