All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tom Li <tomli@tomli.me>
To: linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org,
	linux-kernel@vger.kernel.org
Cc: Yifeng Li <tomli@tomli.me>,
	Sudip Mukherjee <sudipm.mukherjee@gmail.com>,
	Teddy Wang <teddy.wang@siliconmotion.com>,
	Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Subject: Is it possible to reset graphics controller on reboot in a framebuffer driver?
Date: Thu, 7 Mar 2019 13:16:41 +0800	[thread overview]
Message-ID: <20190307051641.GA7012@localhost.localdomain> (raw)

Hi all.

As you may have noticed, recently I've been working on a reworked version
of sm712fb, and planned to convert it to a DRM/KMS driver. Besides using
it on embedded/non-x86 systems, I thought it would be a good idea to support
histrocial x86 laptops with this VGA chipset as well, so I've acquired a
machine for testing.

However, soon I found a nasty problem. The BIOS does not reset the chip
on boot! Like most graphics controller of that era, sm712 chipset has a
VGA compatible mode and a 2D framebuffer mode. The power-on default is
VGA. The BIOS writer just assumed this, and does nothing to reinitialize
it. If one uses the framebuffer driver under Linux, once the machine reboots,
the entire LCD panel becomes a piece of garbage.

AFAIK, the framebuffer driver would be running throughout the kernel's life-
cycle, is it really possible to workaround this issue by restoring on VGA
state upon reboot?

Thanks,
Tom Li

WARNING: multiple messages have this Message-ID (diff)
From: Tom Li <tomli@tomli.me>
To: linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org,
	linux-kernel@vger.kernel.org
Cc: Yifeng Li <tomli@tomli.me>,
	Sudip Mukherjee <sudipm.mukherjee@gmail.com>,
	Teddy Wang <teddy.wang@siliconmotion.com>,
	Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Subject: Is it possible to reset graphics controller on reboot in a framebuffer driver?
Date: Thu, 07 Mar 2019 05:16:41 +0000	[thread overview]
Message-ID: <20190307051641.GA7012@localhost.localdomain> (raw)

Hi all.

As you may have noticed, recently I've been working on a reworked version
of sm712fb, and planned to convert it to a DRM/KMS driver. Besides using
it on embedded/non-x86 systems, I thought it would be a good idea to support
histrocial x86 laptops with this VGA chipset as well, so I've acquired a
machine for testing.

However, soon I found a nasty problem. The BIOS does not reset the chip
on boot! Like most graphics controller of that era, sm712 chipset has a
VGA compatible mode and a 2D framebuffer mode. The power-on default is
VGA. The BIOS writer just assumed this, and does nothing to reinitialize
it. If one uses the framebuffer driver under Linux, once the machine reboots,
the entire LCD panel becomes a piece of garbage.

AFAIK, the framebuffer driver would be running throughout the kernel's life-
cycle, is it really possible to workaround this issue by restoring on VGA
state upon reboot?

Thanks,
Tom Li

             reply	other threads:[~2019-03-07  5:16 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-07  5:16 Tom Li [this message]
2019-03-07  5:16 ` Is it possible to reset graphics controller on reboot in a framebuffer driver? Tom Li
2019-03-07  8:58 ` Jani Nikula
2019-03-07  9:00   ` Jani Nikula
2019-03-07  9:00   ` Jani Nikula
2019-03-07  9:39   ` Geert Uytterhoeven
2019-03-07  9:39     ` Geert Uytterhoeven
2019-03-07  9:39     ` Geert Uytterhoeven
2019-03-07 21:38     ` Tom Li
2019-03-07 21:38       ` Tom Li
2019-03-08  9:13       ` Geert Uytterhoeven
2019-03-08  9:13         ` Geert Uytterhoeven
2019-03-08 10:35         ` Tom Li
2019-03-08 10:35           ` Tom Li
2019-03-12  9:19           ` Tom Li
2019-03-12  9:19             ` Tom Li

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=20190307051641.GA7012@localhost.localdomain \
    --to=tomli@tomli.me \
    --cc=b.zolnierkie@samsung.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-fbdev@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sudipm.mukherjee@gmail.com \
    --cc=teddy.wang@siliconmotion.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.