All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Jani Nikula <jani.nikula@intel.com>
Cc: dri-devel@lists.freedesktop.org, Steven Price <steven.price@arm.com>
Subject: Re: [PATCH] drm: use "0" instead of "" for deprecated driver date
Date: Fri, 10 May 2024 20:33:59 +0300	[thread overview]
Message-ID: <Zj5ah06WvSb0XP6l@intel.com> (raw)
In-Reply-To: <20240510090951.3398882-1-jani.nikula@intel.com>

On Fri, May 10, 2024 at 12:09:51PM +0300, Jani Nikula wrote:
> libdrm does not like the empty string for driver date. Use "0" instead,
> which has been used by virtio previously.
> 
> Reported-by: Steven Price <steven.price@arm.com>
> Closes: https://lore.kernel.org/r/9d0cff47-308e-4b11-a9f3-4157dc26b6fa@arm.com
> Fixes: 7fb8af6798e8 ("drm: deprecate driver date")
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
> ---
>  drivers/gpu/drm/drm_ioctl.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/drm_ioctl.c b/drivers/gpu/drm/drm_ioctl.c
> index 89feb7306e47..51f39912866f 100644
> --- a/drivers/gpu/drm/drm_ioctl.c
> +++ b/drivers/gpu/drm/drm_ioctl.c
> @@ -530,9 +530,9 @@ int drm_version(struct drm_device *dev, void *data,
>  	err = drm_copy_field(version->name, &version->name_len,
>  			dev->driver->name);
>  
> -	/* Driver date is deprecated. Return the empty string. */
> +	/* Driver date is deprecated. Userspace expects a non-empty string. */
>  	if (!err)
> -		err = drm_copy_field(version->date, &version->date_len, "");
> +		err = drm_copy_field(version->date, &version->date_len, "0");

Does this also fix igt/core_getversion which is on fire now?

>  	if (!err)
>  		err = drm_copy_field(version->desc, &version->desc_len,
>  				dev->driver->desc);
> -- 
> 2.39.2

-- 
Ville Syrjälä
Intel

  parent reply	other threads:[~2024-05-10 17:34 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-10  9:09 [PATCH] drm: use "0" instead of "" for deprecated driver date Jani Nikula
2024-05-10  9:30 ` Javier Martinez Canillas
2024-05-10  9:36 ` Steven Price
2024-05-10 10:36 ` Simon Ser
2024-05-10 17:33 ` Ville Syrjälä [this message]
2024-05-10 17:59   ` Ville Syrjälä
2024-05-13  7:46     ` Jani Nikula

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=Zj5ah06WvSb0XP6l@intel.com \
    --to=ville.syrjala@linux.intel.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jani.nikula@intel.com \
    --cc=steven.price@arm.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.