Skip to content

Commit

Permalink
plymouth: ignore serial console hvc0
Browse files Browse the repository at this point in the history
It fixes splash screen issue QubesOS/qubes-issues#3849
  • Loading branch information
fepitre committed Mar 9, 2019
1 parent c8f70c1 commit af67412
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions kernel.spec.in
Expand Up @@ -402,6 +402,12 @@ done
%posttrans
/bin/kernel-install add %{kernelrelease} /boot/vmlinuz-%{kernelrelease} || exit $?

# with kernel-4.14+ plymouth detects hvc0 serial console and forces text boot
# we simply make plymouth ignore it to recover the splash screen
if ! grep -q '^GRUB_CMDLINE_LINUX.*plymouth.ignore-serial-consoles' /etc/default/grub; then
sed -i 's/^GRUB_CMDLINE_LINUX="[^"]*/& plymouth.ignore-serial-consoles/' /etc/default/grub
fi

# grubby (used by new-kernel-pkg) do not understand xen entries in grub2 config
if [ -x /sbin/new-kernel-pkg -a -e /boot/grub2/grub.cfg ]; then
grub2-mkconfig > /boot/grub2/grub.cfg
Expand Down

1 comment on commit af67412

@marmarek
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd prefer it in separate line, like it's done in https://github.com/QubesOS/qubes-vmm-xen/blob/xen-4.8/xen.spec.in#L751-L756. See also the grep is intentionally less accurate there (look only for actual option, not from the start of the line). This way, if someone want to disable it (and not have it added automatically on upgrade), it would be enough to comment it out, or override on the next line.

Please sign in to comment.