From: Nicolas Devos <ndevos-dev@pm.me>
To: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Maxime Ripard <mripard@kernel.org>,
Thomas Zimmermann <tzimmermann@suse.de>,
David Airlie <airlied@gmail.com>, Daniel Vetter <daniel@ffwll.ch>,
dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org
Cc: Nicolas Devos <ndevos-dev@pm.me>
Subject: [PATCH 2/4] gpu/drm: Remove unnecessary braces
Date: Tue, 02 Apr 2024 22:43:38 +0000 [thread overview]
Message-ID: <20240402224320.12146-3-ndevos-dev@pm.me> (raw)
In-Reply-To: <20240402224320.12146-1-ndevos-dev@pm.me>
This commit fixes following checkpatch warnings:
WARNING: braces {} are not necessary for single statement blocks
WARNING: braces {} are not necessary for any arm of this statement
Signed-off-by: Nicolas Devos <ndevos-dev@pm.me>
---
drivers/gpu/drm/drm_connector.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/drm_connector.c b/drivers/gpu/drm/drm_connector.c
index 40350256b1f6..6d8f0fc905f3 100644
--- a/drivers/gpu/drm/drm_connector.c
+++ b/drivers/gpu/drm/drm_connector.c
@@ -314,9 +314,8 @@ static int __drm_connector_init(struct drm_device *dev,
config->tile_property,
0);
- if (drm_core_check_feature(dev, DRIVER_ATOMIC)) {
+ if (drm_core_check_feature(dev, DRIVER_ATOMIC))
drm_object_attach_property(&connector->base, config->prop_crtc_id, 0);
- }
connector->debugfs_entry = NULL;
out_put_type_id:
@@ -2818,9 +2817,9 @@ int drm_connector_set_obj_prop(struct drm_mode_object *obj,
struct drm_connector *connector = obj_to_connector(obj);
/* Do DPMS ourselves */
- if (property == connector->dev->mode_config.dpms_property) {
+ if (property == connector->dev->mode_config.dpms_property)
ret = (*connector->funcs->dpms)(connector, (int)value);
- } else if (connector->funcs->set_property)
+ else if (connector->funcs->set_property)
ret = connector->funcs->set_property(connector, property, value);
if (!ret)
--
2.42.0
next prev parent reply other threads:[~2024-04-02 22:43 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-04-02 22:43 [PATCH 0/4] gpu/drm: Fix checkpatch warnings in drm_connector.c Nicolas Devos
2024-04-02 22:43 ` [PATCH 1/4] gpu/drm: Add SPDX-license-Identifier tag Nicolas Devos
2024-04-02 23:58 ` Joe Perches
2024-04-02 22:43 ` Nicolas Devos [this message]
2024-04-02 22:43 ` [PATCH 3/4] gpu/drm: Prefer `unsigned int` over `unsigned` Nicolas Devos
2024-04-02 22:43 ` [PATCH 4/4] gpu/drm: Replace tabs with spaces in comments Nicolas Devos
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240402224320.12146-3-ndevos-dev@pm.me \
--to=ndevos-dev@pm.me \
--cc=airlied@gmail.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=tzimmermann@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox