The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Lyude Paul <lyude@redhat.com>
To: Maxime Ripard <mripard@kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>
Subject: [PATCH 2/2] drm/mode_config: Make drm_mode_config.(max|min)_(width|height) signed
Date: Tue, 25 Mar 2025 17:27:05 -0400	[thread overview]
Message-ID: <20250325212823.669459-3-lyude@redhat.com> (raw)
In-Reply-To: <20250325212823.669459-1-lyude@redhat.com>

Similarly, it doesn't really make much sense for us to allow devices to
specify their minimum/maximum resolution as signed. So, let's fix that as
well while we're at it.

Signed-off-by: Lyude Paul <lyude@redhat.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Maxime Ripard <mripard@kernel.org>
---
 include/drm/drm_mode_config.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/drm/drm_mode_config.h b/include/drm/drm_mode_config.h
index 271765e2e9f2d..4b8f0370b79bf 100644
--- a/include/drm/drm_mode_config.h
+++ b/include/drm/drm_mode_config.h
@@ -532,8 +532,8 @@ struct drm_mode_config {
 	 */
 	struct list_head privobj_list;
 
-	int min_width, min_height;
-	int max_width, max_height;
+	unsigned int min_width, min_height;
+	unsigned int max_width, max_height;
 	const struct drm_mode_config_funcs *funcs;
 
 	/* output poll support */
-- 
2.48.1


  parent reply	other threads:[~2025-03-25 21:28 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-25 21:27 [PATCH 0/2] drm: Make some resolution info unsigned Lyude Paul
2025-03-25 21:27 ` [PATCH 1/2] drm/edid: Use unsigned int in drm_add_modes_noedid() Lyude Paul
2025-03-26  9:29   ` Thomas Zimmermann
2025-03-26 10:39   ` Jani Nikula
2025-03-26 11:06     ` Miguel Ojeda
2025-03-28 22:27     ` Lyude Paul
2025-03-29 12:04       ` Miguel Ojeda
2025-03-25 21:27 ` Lyude Paul [this message]
2025-03-26  9:32   ` [PATCH 2/2] drm/mode_config: Make drm_mode_config.(max|min)_(width|height) signed Thomas Zimmermann
2025-03-26  9:07 ` [PATCH 0/2] drm: Make some resolution info unsigned Maxime Ripard

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=20250325212823.669459-3-lyude@redhat.com \
    --to=lyude@redhat.com \
    --cc=airlied@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=simona@ffwll.ch \
    --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