lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <0749be61-2f3d-440e-887a-c841007e5b50@redhat.com>
Date: Mon, 10 Nov 2025 15:05:16 +0100
From: Jocelyn Falempe <jfalempe@...hat.com>
To: Thomas Zimmermann <tzimmermann@...e.de>, javierm@...hat.com,
 simona@...ll.ch, airlied@...il.com, mripard@...nel.org,
 maarten.lankhorst@...ux.intel.com, gregkh@...uxfoundation.org,
 jirislaby@...nel.org
Cc: dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org,
 linux-serial@...r.kernel.org
Subject: Re: [PATCH 3/3] drm/client: log: Implement struct
 drm_client_funcs.restore

On 07/11/2025 15:19, Thomas Zimmermann wrote:
> Restore the log client's output when the DRM core invokes the restore
> callback. Follow the existing behavior of fbdev emulation wrt. the
> value of the force parameter.
> 
> If force is false, acquire the DRM master lock and reprogram the
> display. This is the case when the user-space compositor exists and
> the DRM core transfers the display back to the in-kernel client. This
> also enables log output during reboots.
> 
> If force is true, reprogram without considering the master lock. This
> overrides the current compositor and prints the log to the screen. In
> case of system malfunction, users can enter SysRq+v to invoke the
> emergency error reporting. See Documentation/admin-guide/sysrq.rst for
> more information.

Thanks, it looks good to me.

Reviewed-by: Jocelyn Falempe <jfalempe@...hat.com>

> 
> Signed-off-by: Thomas Zimmermann <tzimmermann@...e.de>
> ---
>   drivers/gpu/drm/clients/drm_log.c | 13 +++++++++++++
>   1 file changed, 13 insertions(+)
> 
> diff --git a/drivers/gpu/drm/clients/drm_log.c b/drivers/gpu/drm/clients/drm_log.c
> index 19e55aa0ed74..4d3005273b27 100644
> --- a/drivers/gpu/drm/clients/drm_log.c
> +++ b/drivers/gpu/drm/clients/drm_log.c
> @@ -315,6 +315,18 @@ static void drm_log_client_unregister(struct drm_client_dev *client)
>   	drm_client_release(client);
>   }
>   
> +static int drm_log_client_restore(struct drm_client_dev *client, bool force)
> +{
> +	int ret;
> +
> +	if (force)
> +		ret = drm_client_modeset_commit_locked(client);
> +	else
> +		ret = drm_client_modeset_commit(client);
> +
> +	return ret;
> +}
> +
>   static int drm_log_client_hotplug(struct drm_client_dev *client)
>   {
>   	struct drm_log *dlog = client_to_drm_log(client);
> @@ -348,6 +360,7 @@ static const struct drm_client_funcs drm_log_client_funcs = {
>   	.owner		= THIS_MODULE,
>   	.free		= drm_log_client_free,
>   	.unregister	= drm_log_client_unregister,
> +	.restore	= drm_log_client_restore,
>   	.hotplug	= drm_log_client_hotplug,
>   	.suspend	= drm_log_client_suspend,
>   	.resume		= drm_log_client_resume,


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ