From patchwork Thu May 14 19:09:56 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sam Ravnborg X-Patchwork-Id: 11549551 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D4CDC14B7 for ; Thu, 14 May 2020 19:10:46 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id B2C1F206F1 for ; Thu, 14 May 2020 19:10:46 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="l7NkQzxm" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org B2C1F206F1 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ravnborg.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A751A6EBB7; Thu, 14 May 2020 19:10:45 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lj1-x242.google.com (mail-lj1-x242.google.com [IPv6:2a00:1450:4864:20::242]) by gabe.freedesktop.org (Postfix) with ESMTPS id 986DD6EBB6 for ; Thu, 14 May 2020 19:10:44 +0000 (UTC) Received: by mail-lj1-x242.google.com with SMTP id u15so4787731ljd.3 for ; Thu, 14 May 2020 12:10:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=7NL7oOh2YpmGkieh3R7y/HMeuTthqrGLkMzsF1Tg8k0=; b=l7NkQzxmJKlSolH7PJHAvYG4SzzLtTDVkv7A5b8wb8TSIjPhQGtgXsYBBxnnIAKqbX pJchKTttYj1Gbcaqq2XupUvICzobt2Mdl1t7G2DjVrE3+Gc/y0pP4bJCp89MlCOLUl0w 6YK2XlFOt1c286dSaBmDauQ6RcHYnYLOKfyPPaAsKIYpTc58IFpkPagWZURSJewPXbg5 EPtuXM63ZGxf3p+ucfulm5rjpVbQkDph0XKtaojCjYaAxEudP3XAelw/UxLGxdNb498w eIf4RiMOc8ZesgTFe1ULkkmrT+hrwmmOvibWieZpqaLpBXNGmTQo1k5leY/tBU65PwP7 0OIg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=7NL7oOh2YpmGkieh3R7y/HMeuTthqrGLkMzsF1Tg8k0=; b=aDFFcd65FJWR+zP6yHoWwcPYiN5Mp/blNqLvmZj3njatfY6eLihs0N9i/2mayS+fMz Lz/nrGWAtkFvKLdL7EroYIVxWb+GMaoAA1Ph5E5rpE9Cd6PczwWWeUhdFn4MNpUpnpMj oRsjEpCqUR27kf8qjy+1yOXiUTXL2hO0QXjP7cHvQhzJL77Bl0oCbGHKfh3KDDlMpQG7 kvOEuKn+uQKhS55oMirtfWOa+uEvMqTUEp/2qb+3i5GlJK5REHuVsfAr0zx0ajAO95Yh TyzmKFfoZMFF9AIHVNOdIqPOuXn1ahLptj90ZOBiu1HydmuNvMP605eCDEtz7J7BpyJw 8Kfg== X-Gm-Message-State: AOAM530IiPj11AYOoxSTDxVj3wUjUDfUu+l0RgIqjwmzImbBXSE/gb0B uzTl3jy5sruyb9VEuXiJsjc8EgR4glpn+g== X-Google-Smtp-Source: ABdhPJzKDt4XU/BmWeiLV6W594VhbfU7W8uhu8wo1ZRThIlXSSv8E9xcMBsJko0RoOFHj/dT79mvAQ== X-Received: by 2002:a05:651c:c8:: with SMTP id 8mr3521844ljr.182.1589483442684; Thu, 14 May 2020 12:10:42 -0700 (PDT) Received: from saturn.lan ([2a00:fd00:805f:db00:8d23:71d:e677:1c7c]) by smtp.gmail.com with ESMTPSA id q30sm2362958lfd.32.2020.05.14.12.10.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 14 May 2020 12:10:42 -0700 (PDT) From: Sam Ravnborg To: dri-devel@lists.freedesktop.org, Jingoo Han , Lee Jones , Daniel Thompson Subject: [PATCH v1 13/18] backlight: document enums in backlight.h Date: Thu, 14 May 2020 21:09:56 +0200 Message-Id: <20200514191001.457441-14-sam@ravnborg.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200514191001.457441-1-sam@ravnborg.org> References: <20200514191001.457441-1-sam@ravnborg.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Kate Stewart , Kefeng Wang , David Airlie , Daniel Vetter , Bjorn Andersson , Thierry Reding , Laurent Pinchart , Sam Ravnborg , Jonathan Corbet , Tomi Valkeinen , Russell King , Andy Gross , Uwe Kleine Konig , linux-pwm@vger.kernel.org, Michael Hennerich , Bartlomiej Zolnierkiewicz , Jani Nikula , linux-arm-msm@vger.kernel.org, Jyri Sarha , Thomas Gleixner , Allison Randal , Support Opensource , patches@opensource.cirrus.com, Douglas Anderson , Zheng Bin , Thomas Zimmermann , Enrico Weigelt Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Add kernel-doc documentation for the backlight enums Signed-off-by: Sam Ravnborg Cc: Lee Jones Cc: Daniel Thompson Cc: Jingoo Han --- include/linux/backlight.h | 84 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) diff --git a/include/linux/backlight.h b/include/linux/backlight.h index b8e78549a48c..bedc0c9885b6 100644 --- a/include/linux/backlight.h +++ b/include/linux/backlight.h @@ -14,26 +14,110 @@ #include #include +/** + * enum backlight_update_reason - what method was used to update backlight + * + * A driver indicates the method (reason) used for updating the backlight + * when calling backlight_force_update(). + */ enum backlight_update_reason { + /** + * @BACKLIGHT_UPDATE_HOTKEY: + * + * The backlight was updated using a hot-key. + */ BACKLIGHT_UPDATE_HOTKEY, + + /** + * @BACKLIGHT_UPDATE_SYSFS: + * + * The backlight was updated using sysfs. + */ BACKLIGHT_UPDATE_SYSFS, }; +/** + * enum backlight_type - the type of backlight control + * + * The type of interface used to control the backlight. + */ enum backlight_type { + /** + * @BACKLIGHT_RAW: + * + * The backlight is controlled using hardware registers directly. + */ BACKLIGHT_RAW = 1, + + /** + * @BACKLIGHT_PLATFORM: + * + * The backlight is controller using a platform-specific interface. + */ BACKLIGHT_PLATFORM, + + /** + * @BACKLIGHT_FIRMWARE: + * + * The backlight is controlled using a standard firmware interface. + */ BACKLIGHT_FIRMWARE, + + /** + * @BACKLIGHT_TYPE_MAX: Number of entries. + */ BACKLIGHT_TYPE_MAX, }; +/** + * enum backlight_notification - the type of notification + * + * The notifications that is used for notification sent to the receiver + * that registered notifications using backlight_register_notifier(). + */ enum backlight_notification { + /** + * @BACKLIGHT_REGISTERED: + * + * The backlight device is registered. + */ BACKLIGHT_REGISTERED, + + /** + * @BACKLIGHT_UNREGISTERED: + * + * The backlight revice is unregistered. + */ BACKLIGHT_UNREGISTERED, }; +/** enum backlight_scale - the type of scale used for brightness values + * + * The type of scale used for brightness values. + */ enum backlight_scale { + /** + * @BACKLIGHT_SCALE_UNKNOWN: + * + * The scale is unknown. + */ BACKLIGHT_SCALE_UNKNOWN = 0, + + /** + * @BACKLIGHT_SCALE_LINEAR: + * + * The scale is linear, so the brigness increase is the same + * when increasing with the same steps (more or less). + */ BACKLIGHT_SCALE_LINEAR, + + /** + * @BACKLIGHT_SCALE_NON_LINEAR: + * + * The scale is not linear. This is often used when the brightness + * values tries to adjust to the relative perception of the eye + * demanding a non-linear scale. + */ BACKLIGHT_SCALE_NON_LINEAR, };