From 622f56d917ddd3a695254a3929c84dd4d6e79378 Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Tue, 5 Dec 2023 12:10:44 +0800 Subject: util-linux: Add asciidoctor and po4a as dependencies Asciidoctor is needed for regenerating man pages, and po4a is needed for generating translated man pages in addition to asciidoctor. --- appendices/dependencies.xml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/appendices/dependencies.xml b/appendices/dependencies.xml index ed44374ea..30f2b05a6 100644 --- a/appendices/dependencies.xml +++ b/appendices/dependencies.xml @@ -3192,6 +3192,7 @@ &external; + Asciidoctor, Libcap-NG, libeconf, @@ -3200,7 +3201,8 @@ Linux-PAM, smartmontools, and + url="&blfs-book;postlfs/smartmontools.html">smartmontools, + po4a, and slang -- cgit v1.2.3-54-g00ecf From 34774f4986378ae0483a65233f453f5c2227ae47 Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Tue, 5 Dec 2023 14:34:30 +0800 Subject: kernel-config: Regenerate with Linux 6.6.3 Only a trivial change (renaming CONFIG_FB). --- chapter10/kernel/kernel.version | 2 +- chapter10/kernel/systemd.xml | 2 +- chapter10/kernel/sysv.xml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/chapter10/kernel/kernel.version b/chapter10/kernel/kernel.version index 4b20d9700..e411592c2 100644 --- a/chapter10/kernel/kernel.version +++ b/chapter10/kernel/kernel.version @@ -1 +1 @@ -6.4.8 +6.6.3 diff --git a/chapter10/kernel/systemd.xml b/chapter10/kernel/systemd.xml index 6705fdd35..bfe3df275 100644 --- a/chapter10/kernel/systemd.xml +++ b/chapter10/kernel/systemd.xml @@ -42,7 +42,7 @@ [*] Export DMI identification via sysfs to userspace [DMIID] Graphics support ---> Frame buffer Devices ---> - <*> Support for frame buffer devices ---> [FB] + <*> Support for frame buffer device drivers ---> [FB] Console display driver support ---> [*] Framebuffer Console support [FRAMEBUFFER_CONSOLE] diff --git a/chapter10/kernel/sysv.xml b/chapter10/kernel/sysv.xml index 7e62725e6..405dfad0e 100644 --- a/chapter10/kernel/sysv.xml +++ b/chapter10/kernel/sysv.xml @@ -30,6 +30,6 @@ ... [DEVTMPFS_MOUNT] Graphics support ---> Frame buffer Devices ---> - <*> Support for frame buffer devices ---> [FB] + <*> Support for frame buffer device drivers ---> [FB] Console display driver support ---> [*] Framebuffer Console support [FRAMEBUFFER_CONSOLE] -- cgit v1.2.3-54-g00ecf From 981b9fa6a1a47b5ea93d899dc467be3649b0c253 Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Tue, 5 Dec 2023 14:55:45 +0800 Subject: kernel-config: Drop FB In Linux 6.6 DRM_FBDEV_EMULATION no longer depends on FB, so we no longer need to select FB (tested in a QEMU VM). But if DRM is selected, we must select both DRM_FBDEV_EMULATION and FRAMEBUFFER_CONSOLE or we'll see only blank screen. And now FRAMEBUFFER_CONSOLE is not selected by default, be warned!! --- chapter10/kernel.xml | 20 +++++++++++--------- chapter10/kernel/systemd.toml | 12 +++++++++--- chapter10/kernel/systemd.xml | 10 +++++++--- chapter10/kernel/sysv.toml | 11 +++++++++-- chapter10/kernel/sysv.xml | 10 +++++++--- 5 files changed, 43 insertions(+), 20 deletions(-) diff --git a/chapter10/kernel.xml b/chapter10/kernel.xml index 5c7a9d703..5bbfff11a 100644 --- a/chapter10/kernel.xml +++ b/chapter10/kernel.xml @@ -273,16 +273,18 @@ - Framebuffer Console support + + + Enable legacy fbdev support for your modesetting driver + and + Framebuffer Console support + - This is needed to display the Linux console on a frame - buffer device. To allow the kernel to print debug messages at an - early boot stage, it shouldn't be built as a kernel module - unless an initramfs will be used. And, if - (Direct Rendering Manager) is enabled, - it's likely (Enable - legacy fbdev support for your modesetting driver) should be - enabled as well. + These are needed to display the Linux console on a + GPU driven by a DRI (Direct Rendering Infrastructure) driver. + If (Direct Rendering Manager) is + enabled, you should enable these two options as well or you'll see + a blank screen once the DRI driver is loaded. diff --git a/chapter10/kernel/systemd.toml b/chapter10/kernel/systemd.toml index 26ac61c46..dae4a4049 100644 --- a/chapter10/kernel/systemd.toml +++ b/chapter10/kernel/systemd.toml @@ -13,9 +13,7 @@ STACKPROTECTOR_STRONG='*' UEVENT_HELPER=' ' DEVTMPFS='*' DEVTMPFS_MOUNT='*' -FB='*' -FRAMEBUFFER_CONSOLE='*' - +DRM=' *M' AUDIT=' ' NET='*' INET='*' @@ -28,3 +26,11 @@ TMPFS='*' TMPFS_POSIX_ACL='*' revision='systemd' + +[DRM_FBDEV_EMULATION] +value = ' *' +comment = 'If [DRM] is selected as * or M, this must be selected' + +[FRAMEBUFFER_CONSOLE] +value = ' *' +comment = 'If [DRM] is selected as * or M, this must be selected' diff --git a/chapter10/kernel/systemd.xml b/chapter10/kernel/systemd.xml index bfe3df275..c41b26673 100644 --- a/chapter10/kernel/systemd.xml +++ b/chapter10/kernel/systemd.xml @@ -41,10 +41,14 @@ Firmware Drivers ---> [*] Export DMI identification via sysfs to userspace [DMIID] Graphics support ---> - Frame buffer Devices ---> - <*> Support for frame buffer device drivers ---> [FB] + < /*/M> Direct Rendering Manager (XFree86 4.1.0 and higher DRI support) ---> + ... [DRM] + # If [DRM] is selected as * or M, this must be selected: + [ /*] Enable legacy fbdev support for your modesetting driver + ... [DRM_FBDEV_EMULATION] Console display driver support ---> - [*] Framebuffer Console support [FRAMEBUFFER_CONSOLE] + # If [DRM] is selected as * or M, this must be selected: + [ /*] Framebuffer Console support [FRAMEBUFFER_CONSOLE] File systems ---> [*] Inotify support for userspace [INOTIFY_USER] diff --git a/chapter10/kernel/sysv.toml b/chapter10/kernel/sysv.toml index 5c8b2df6e..3f8d2e93c 100644 --- a/chapter10/kernel/sysv.toml +++ b/chapter10/kernel/sysv.toml @@ -12,7 +12,14 @@ STACKPROTECTOR_STRONG='*' UEVENT_HELPER=' ' DEVTMPFS='*' DEVTMPFS_MOUNT='*' -FB='*' -FRAMEBUFFER_CONSOLE='*' +DRM=' *M' revision='sysv' + +[DRM_FBDEV_EMULATION] +value = ' *' +comment = 'If [DRM] is selected as * or M, this must be selected' + +[FRAMEBUFFER_CONSOLE] +value = ' *' +comment = 'If [DRM] is selected as * or M, this must be selected' diff --git a/chapter10/kernel/sysv.xml b/chapter10/kernel/sysv.xml index 405dfad0e..c61208c67 100644 --- a/chapter10/kernel/sysv.xml +++ b/chapter10/kernel/sysv.xml @@ -29,7 +29,11 @@ [*] Automount devtmpfs at /dev, after the kernel mounted the rootfs ... [DEVTMPFS_MOUNT] Graphics support ---> - Frame buffer Devices ---> - <*> Support for frame buffer device drivers ---> [FB] + < /*/M> Direct Rendering Manager (XFree86 4.1.0 and higher DRI support) ---> + ... [DRM] + # If [DRM] is selected as * or M, this must be selected: + [ /*] Enable legacy fbdev support for your modesetting driver + ... [DRM_FBDEV_EMULATION] Console display driver support ---> - [*] Framebuffer Console support [FRAMEBUFFER_CONSOLE] + # If [DRM] is selected as * or M, this must be selected: + [ /*] Framebuffer Console support [FRAMEBUFFER_CONSOLE] -- cgit v1.2.3-54-g00ecf From 31a9142d108a0fd32660068adc1c223a7e60e8b7 Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Wed, 6 Dec 2023 01:32:48 +0800 Subject: kernel-config: Sync fixes from BLFS --- chapter10/kernel/Makefile | 5 ++++- chapter10/kernel/highmem.xml | 2 +- chapter10/kernel/kernel-config.py | 6 +++++- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/chapter10/kernel/Makefile b/chapter10/kernel/Makefile index e04d2d6b1..03de71ed9 100644 --- a/chapter10/kernel/Makefile +++ b/chapter10/kernel/Makefile @@ -19,5 +19,8 @@ s-kernel-version: fi touch s-kernel-version -%.xml: %.toml kernel-config.py kernel_version.py kernel.version +%.xml.tmp: %.toml kernel-config.py kernel_version.py kernel.version ./kernel-config.py $(KERNEL_TREE) $< > $@ + +%.xml: %.xml.tmp + mv $< $@ diff --git a/chapter10/kernel/highmem.xml b/chapter10/kernel/highmem.xml index 4f0938142..efedef46c 100644 --- a/chapter10/kernel/highmem.xml +++ b/chapter10/kernel/highmem.xml @@ -5,4 +5,4 @@ DO NOT EDIT! --> Processor type and features ---> High Memory Support ---> - (X) 64GB [HIGHMEM64G] + (X) 64GB [HIGHMEM64G] diff --git a/chapter10/kernel/kernel-config.py b/chapter10/kernel/kernel-config.py index a36113175..03e6ebb22 100755 --- a/chapter10/kernel/kernel-config.py +++ b/chapter10/kernel/kernel-config.py @@ -185,6 +185,10 @@ def load_kconfig(file): if_stack += [top] elif line.startswith('endif'): if_stack = if_stack[:-1] + + if config_buf: + r += [parse_config(config_buf)] + return r known_config = {} @@ -259,7 +263,7 @@ for i0, val, i1, title, arrow, key, menu, comment in r: if len(title) > rem: title = title[:rem - 3] + '...' - b = title.lstrip('YyMmNnHh') + b = title.lstrip('YyMmNnHh.' + "".join(map(str, range(10)))) a = title[:len(title) - len(b)] b0 = "" + escape(b[0]) + "" line += escape(a) + b0 + escape(b[1:]) + escape(arrow) -- cgit v1.2.3-54-g00ecf From 7cce808a46c5a1df0de2c52827b89b63834436fe Mon Sep 17 00:00:00 2001 From: Xi Ruoyao Date: Wed, 6 Dec 2023 17:26:10 +0800 Subject: kernel-config: The hot key for choices is just the first character Stupid inconsistency... --- chapter10/kernel/highmem.xml | 2 +- chapter10/kernel/kernel-config.py | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/chapter10/kernel/highmem.xml b/chapter10/kernel/highmem.xml index efedef46c..4f0938142 100644 --- a/chapter10/kernel/highmem.xml +++ b/chapter10/kernel/highmem.xml @@ -5,4 +5,4 @@ DO NOT EDIT! --> Processor type and features ---> High Memory Support ---> - (X) 64GB [HIGHMEM64G] + (X) 64GB [HIGHMEM64G] diff --git a/chapter10/kernel/kernel-config.py b/chapter10/kernel/kernel-config.py index 03e6ebb22..eac2b6c4d 100755 --- a/chapter10/kernel/kernel-config.py +++ b/chapter10/kernel/kernel-config.py @@ -251,6 +251,7 @@ sep = known_config.get('separate_toplevel_menu') for i0, val, i1, title, arrow, key, menu, comment in r: rem = max_line + is_choice = (val == '(X)') if val: val += (max_val_len[menu] - len(val)) * ' ' @@ -263,7 +264,9 @@ for i0, val, i1, title, arrow, key, menu, comment in r: if len(title) > rem: title = title[:rem - 3] + '...' - b = title.lstrip('YyMmNnHh.' + "".join(map(str, range(10)))) + b = title + if not is_choice: + b = b.lstrip('YyMmNnHh.' + "".join(map(str, range(10)))) a = title[:len(title) - len(b)] b0 = "" + escape(b[0]) + "" line += escape(a) + b0 + escape(b[1:]) + escape(arrow) -- cgit v1.2.3-54-g00ecf