Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 598623 - CONFIG_GENTOO_LINUX_INIT_SYSTEMD should select several additional kernel options
Summary: CONFIG_GENTOO_LINUX_INIT_SYSTEMD should select several additional kernel options
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Kernel Bug Wranglers and Kernel Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-10-31 13:40 UTC by C. Wijtmans
Modified: 2017-02-14 22:53 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description C. Wijtmans 2016-10-31 13:40:10 UTC
Saw no gentoo-sources component so i filed it under genkernel.

# grep CONFIG_GENTOO_LINUX_INIT_SYSTEMD .config
CONFIG_GENTOO_LINUX_INIT_SYSTEMD=y

>>> Running pre-merge checks for sys-apps/systemd-226-r2
 * Determining the location of the kernel source code
 * Found kernel source directory:
 *     /usr/src/linux
 * Found kernel object directory:
 *     /lib/modules/4.4.21-gentoo/build
 * Found sources for kernel version:
 *     4.4.21-gentoo
 * Checking for suitable kernel configuration options...
 *   CONFIG_DMIID:       is not set when it should be.
 *   CONFIG_TMPFS_XATTR:         is not set when it should be.
 * Please check to make sure these options are set correctly.
 * Failure to do so may cause unexpected problems.
Comment 1 Mike Gilbert gentoo-dev 2016-10-31 13:59:01 UTC
(In reply to C.J. Wijtmans from comment #0)
> Saw no gentoo-sources component so i filed it under genkernel.

Well, your guess was wrong. Next time, select "Gentoo Linux" when you are unsure.
Comment 2 C. Wijtmans 2016-10-31 14:07:17 UTC
(In reply to Mike Gilbert from comment #1)
> (In reply to C.J. Wijtmans from comment #0)
> > Saw no gentoo-sources component so i filed it under genkernel.
> 
> Well, your guess was wrong. Next time, select "Gentoo Linux" when you are
> unsure.

Gentoo Linux=gentoo-sourceS?
Comment 3 Mike Gilbert gentoo-dev 2016-10-31 14:14:00 UTC
(In reply to C.J. Wijtmans from comment #2)

I'm not sure what you are asking.
Comment 4 C. Wijtmans 2016-10-31 14:20:57 UTC
(In reply to Mike Gilbert from comment #3)
> (In reply to C.J. Wijtmans from comment #2)
> 
> I'm not sure what you are asking.

is gentoo-sources a "gentoo hosted" project or not? Nevermind it.
Comment 5 Mike Gilbert gentoo-dev 2016-10-31 14:58:13 UTC
(In reply to C.J. Wijtmans from comment #4)
> is gentoo-sources a "gentoo hosted" project or not? Nevermind it.

No, gentoo-sources is a Gentoo package, and has no direct relation to genkernel.
Comment 6 C. Wijtmans 2016-10-31 14:59:27 UTC
also

*   CONFIG_TMPFS_POSIX_ACL:     is not set when it should be.

However i am guessing you only need CONFIG_TMPFS_XATTR and CONFIG_TMPFS_POSIX_ACL these if you build with +acl and CONFIG_DMIID for +kmod.
Comment 7 Mike Gilbert gentoo-dev 2016-10-31 15:13:45 UTC
Comparing the systemd ebuild against the latest 4567_distro-Gentoo-Kconfig.patch, here is a complete list of the missing options.

Under GENTOO_LINUX_UDEV:

UNIX

Under GENTOO_LINUX_INIT_SYSTEMD:

DMIID
IPV6
SECCOMP
SECCOMP_FILTER
TMPFS_XATTR
TMPFS_POSIX_ACL
Comment 8 C. Wijtmans 2016-10-31 15:34:58 UTC
The question is though are acl and kmod really neccesary on a server that has all modules built in the kernel and does systemd really use acl automatically for tmpfs. pre-merge checks should not warn about these CONFIGs when acl and kmod are not selected.
Comment 9 Mike Gilbert gentoo-dev 2016-10-31 15:39:39 UTC
If you are customizing your system to the point where you want to disable modules and ACL support, you are probably savvy enough to disable the GENTOO_LINUX_INIT_SYSTEMD option.

It is safer to enable the options for users who don't know any better.
Comment 10 C. Wijtmans 2016-10-31 16:40:10 UTC
(In reply to Mike Gilbert from comment #9)
> If you are customizing your system to the point where you want to disable
> modules and ACL support, you are probably savvy enough to disable the
> GENTOO_LINUX_INIT_SYSTEMD option.
> 
> It is safer to enable the options for users who don't know any better.

Right but in case i decide to do it manually it will still give me these pre-merge warnings even if i deselect kmod or acl.
Comment 11 Mike Gilbert gentoo-dev 2016-10-31 17:05:18 UTC
(In reply to C.J. Wijtmans from comment #10)
> Right but in case i decide to do it manually it will still give me these
> pre-merge warnings even if i deselect kmod or acl.

Create a separate bug for this please.
Comment 12 Mike Pagano gentoo-dev 2016-11-07 00:10:52 UTC
(In reply to Mike Gilbert from comment #7)
> Comparing the systemd ebuild against the latest
> 4567_distro-Gentoo-Kconfig.patch, here is a complete list of the missing
> options.
> 
> Under GENTOO_LINUX_UDEV:
> 
> UNIX
> 
> Under GENTOO_LINUX_INIT_SYSTEMD:
> 
> DMIID
> IPV6
> SECCOMP
> SECCOMP_FILTER
> TMPFS_XATTR
> TMPFS_POSIX_ACL

The trunk was updated with these changes. Right now we maintain 4.8.X, 4.4, 4.1, 3.18, 3.12, 3.10 and 3.4.

Which kernels should this be backported too?
Comment 13 Mike Gilbert gentoo-dev 2016-11-07 15:30:47 UTC
(In reply to Mike Pagano from comment #12)
> The trunk was updated with these changes. Right now we maintain 4.8.X, 4.4,
> 4.1, 3.18, 3.12, 3.10 and 3.4.
> 
> Which kernels should this be backported too?

systemd supports kernels >= 3.12, so a backport to those versions would be great.

Also, I found another recommended option in the systemd README:

  CONFIG_CHECKPOINT_RESTORE (for the kcmp() syscall)

Could you add that to the config as well?
Comment 14 Mike Pagano gentoo-dev 2016-11-16 11:37:25 UTC
(In reply to Mike Gilbert from comment #13)
> (In reply to Mike Pagano from comment #12)
> > The trunk was updated with these changes. Right now we maintain 4.8.X, 4.4,
> > 4.1, 3.18, 3.12, 3.10 and 3.4.
> > 
> > Which kernels should this be backported too?
> 
> systemd supports kernels >= 3.12, so a backport to those versions would be
> great.
> 
> Also, I found another recommended option in the systemd README:
> 
>   CONFIG_CHECKPOINT_RESTORE (for the kcmp() syscall)
> 
> Could you add that to the config as well?


commit 574ae42fb009b569a6054bc3622aad2ffe513195
Author: Mike Pagano <mpagano@gentoo.org>
Date:   Wed Nov 16 06:35:55 2016 -0500

    Update gentoo kconfig patch adding CHECKPOINT_RESTORE for GENTOO_LINUX_INIT_SYSTEMD. See bug #598623

This is only on trunk as of this writing, I'll start moving it to kernels >= 3.12
Comment 15 Lorenzo Porta (Vindex17) 2016-11-22 09:07:13 UTC
Reading systemd's README file, I think these should be added too:

> udev will fail to work with the legacy sysfs layout:
>   CONFIG_SYSFS_DEPRECATED=n
>
> Legacy hotplug slows down the system and confuses udev:
>   CONFIG_UEVENT_HELPER_PATH=""
>
> Userspace firmware loading is not supported and should
> be disabled in the kernel:
>   CONFIG_FW_LOADER_USER_HELPER=n
Comment 16 Mike Pagano gentoo-dev 2016-11-22 11:24:31 UTC
I'm going to hold off until Mike G reviews these config settings and gives me the final list.

Doing this piecemeal is not really efficient.
Comment 17 Mike Gilbert gentoo-dev 2016-11-22 16:15:30 UTC
(In reply to Lorenzo Porta (Vindex17) from comment #15)

I was under the impression that it was not possible to de-select kernel options by toggling CONFIG_GENTOO_LINUX_INIT_SYSTEMD. This is why I intentionally did not include them.
Comment 18 Lorenzo Porta (Vindex17) 2016-11-22 16:33:18 UTC
(In reply to Mike Gilbert from comment #17)
> (In reply to Lorenzo Porta (Vindex17) from comment #15)
> 
> I was under the impression that it was not possible to de-select kernel
> options by toggling CONFIG_GENTOO_LINUX_INIT_SYSTEMD. This is why I
> intentionally did not include them.

Adding "depends on !CONFIG_GENTOO_LINUX_INIT_SYSTEMD" to them can be an option
Comment 19 Mike Gilbert gentoo-dev 2016-11-22 18:07:56 UTC
(In reply to Lorenzo Porta (Vindex17) from comment #18)

That sounds a little fragile, and not worth the effort.
Comment 20 Mike Pagano gentoo-dev 2016-11-26 17:44:26 UTC
This is now either in all kernels >= 3.12 or committed in their respective genpatches branch for their next release.
Comment 21 Mike Pagano gentoo-dev 2017-02-14 22:53:53 UTC
Closing for now.  If there are more/other things in the future that we should add for systemd please open a new bug.