You are not logged in.

#1 2013-08-26 17:39:02

Kalrish
Member
Registered: 2013-02-27
Posts: 62

kmscon and TTYs

Hello!

After reading a bit on the topic, I finally decided to switch (or, at least, to give a try) to kmscon. I have installed it, and, well, it works. Colors seem a bit different, it politely cleans the screen after using man... I like it.

However, I'm having a problem with hardware acceleration: it is not available. It causes artifacts when switching between X and kmscon and makes it impossible to launch the X server from a kmscon session. I suspect it comes down to kmscon being given an instance of /dev/pts/X instead of a "physical" terminal (i.e. /dev/ttyX). It is a bit strange:

  • when using agetty:

    $ tty
    /dev/ttyX
  • when using kmscon:

    $ tty
    /dev/pts/X

If I initialize kmscon with --hwaccel, my system hangs (soft-lockup; I'm still able to restart by pressing the power button). It seems a bit strange, since I've never had problems with 3D acceleration.

I haven't been able to find much on the topic. Has anyone had this problem before? Any solutions?

Thanks for your time. Best regards,
Kalrish

Offline

#2 2013-08-26 17:47:37

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: kmscon and TTYs

Have you read https://wiki.archlinux.org/index.php/KM … leshooting ? Is that what you mean by running kmscon with --hwaccel?

Edit: https://wiki.archlinux.org/index.php/KM … ux-console might be the reason for tty / pts difference.

Last edited by karol (2013-08-26 17:50:49)

Offline

#3 2013-08-26 17:51:21

Kalrish
Member
Registered: 2013-02-27
Posts: 62

Re: kmscon and TTYs

Yes, I have. As I've mentioned, executing kmscon with --hwaccel hangs my system.

kmscon --help
...
Video Options:
	    --drm                   [on]    Use DRM if available
	    --hwaccel               [off]   Use 3D hardware-acceleration if
	                                    available

(use of DRM is enabled by default, whereas hardware acceleration isn't)

karol wrote:

Edit: https://wiki.archlinux.org/index.php/KM … ux-console might be the reason for tty / pts difference.

Edit (in response of your last edit): how could that make a difference? Anyway, would there be any workarounds...?

Last edited by Kalrish (2013-08-26 17:53:40)

Offline

#4 2013-08-27 18:12:37

Kalrish
Member
Registered: 2013-02-27
Posts: 62

Re: kmscon and TTYs

I think I'm closer to the problem. It is not about kmscon being given a "wrong" TTY; it's just that it has no hardware acceleration available (for a reason I'm trying to find) nor has an X server started from it. (If I start X in another TTY, it works.) I've just rebuilt Mesa and am checking my system. If I finally get it to work, I'll update the post.

Cheers,
Kalrish

Edit: I think I have it: . I have no idea why the hardware acceleration is not working, but it explains why I can't run the X server from my kmscon session.

Edit: Finally, it works! The solution was to remove --enable-r600-llvm-compiler from the configuration of Mesa. If you are having the same issue and using the official package, however, this won't make much sense for you: it is disabled in the default package. Good luck.

Last edited by Kalrish (2013-08-28 19:25:45)

Offline

#5 2013-11-07 10:52:04

Aditya Raj Bhatt
Member
From: New Delhi, India
Registered: 2013-02-27
Posts: 17

Re: kmscon and TTYs

I am thinking about switching to kmscon and wanted to ask - what do you mean about having to start X from another tty. If I replace the linux console with kmscon (with ln -s) then wouldn't kmscon be started on each login instance? So if I press Alt+F2 - F7 all of them should have kmscon running? How do you switch back to tty once that happens? Or have I got it wrong? I haven't installed it yet so I don't know.

I am talking about the situation after completing these steps - https://wiki.archlinux.org/index.php/KM … ux-console

If this is considered hijacking or necroing, please warn me before deleting and I will move this post to a new thread.

Offline

#6 2013-11-07 16:22:48

Kalrish
Member
Registered: 2013-02-27
Posts: 62

Re: kmscon and TTYs

I'm sorry about the confusion I may have led you to. What I meant is that, as kmscon is using the graphics device, it conflicts with any other program that tries to draw - be it X, another kmscon or whatever you come up with. So, if you want to run X, you have to make it start on another VT.

I use the Xfce4 desktop. As I don't use a login manager, I have to start it from the terminal. I used to do this:

startxfce4

However, that would start it on the same VT, freezing kmscon and X. You have to instead use:

XDG_VTNR=7 startxfce4

(replacing 7 with the VT of your liking)

About the VT switching, it behaves just like the traditional terminal. Note that you'll have to also use Ctrl (as in X), not just Alt+Fn.

Please, excuse me if I have misunderstood your question. I'm not sure if what you've done is considered a 'bad thing', but anyway, if you open a new thread or mail me, I'll try to help you.

Best regards,
Kalrish

Offline

Board footer

Powered by FluxBB