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] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 9 Oct 2020 13:59:24 +0200
From:   Thomas Zimmermann <tzimmermann@...e.de>
To:     stsp <stsp2@...dex.ru>, linux-fbdev@...r.kernel.org,
        Linux kernel <linux-kernel@...r.kernel.org>
Subject: Re: drmfb console switching problems/questions

Hi

Am 09.10.20 um 12:50 schrieb stsp:
> Hi!
> 
> I am trying to run my sdl1-based app
> under linux kms framebuffer (amdgpudrmfb
> in my case).
> The app itself works perfectly, but
> console switching is not.
> 
> If I switch the console while the app
> is drawing, then it will corrupt the
> VC I switched to. It will just draw on
> top of the VC's content.
> Question: is this expected? Is drm
> framebuffer global, rather than per-vc?
> If so, should I somehow freeze my
> app when it is switched away? And
> why would it be the case, with the
> modern video cards that have multi
> gigas of RAM on board?
> 
> If my app crashes without a clean
> shutdown, then the framebuffer kinda
> hangs. I can switch to other VCs but
> I don't see their content. All I see is
> the last drawing of my app. If I happen
> to have an X server on some other VC,
> then switching to it immediately unhangs
> everything, and I can switch back.
> In fact, even if I hit Ctrl-Alt-Del, then
> fb immediately unhangs (by systemd
> or plymouth or whoever else). But for
> example SAK combo doesn't unhang.
> So it seems to be very simple to hang
> the framebuffer, and is quite difficult
> to recover.
> Question: is this an expected behaviour
> or a drmfb bug?

Fbdev exposes the video ram (or a shadow buffer of it) to all
applications. Only one can draw at the same time. It's a limitation of
the design. To fix this, your application has to stop drawing when you
switch consoles.

Best regards
Thomas

> 
> Thanks!
> 

-- 
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Maxfeldstr. 5, 90409 Nürnberg, Germany
(HRB 36809, AG Nürnberg)
Geschäftsführer: Felix Imendörffer



Download attachment "signature.asc" of type "application/pgp-signature" (517 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ