-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
lib/ukboot: Fix configuration of no "no scheduler" #1413
lib/ukboot: Fix configuration of no "no scheduler" #1413
Conversation
This commit introduces the hidden configuration option `CONFIG_LIBUKBOOT_INITSCHED` that indicates that scheduler initialization is configured with `lib/ukboot`. The previous check for `!CONFIG_LIBUKBOOT_NOSCHED` was not sufficient, as the option is not available if `CONFIG_LIBUKBOOT_NOALLOC` is set. The reason is the dependency expressed for the corresponding `choice` in the libraries' `Config.uk`. This would incorrectly mean that a scheduler is being initialized. Signed-off-by: Simon Kuenzer <simon@unikraft.io>
This commit introduces the hidden configuration option `CONFIG_LIBUKBOOT_INITALLOC` that indicates that allocator initialization is configured with `lib/ukboot`. We do this in order to be inline with the scheduler configuration (`Config.uk`) and to have the possibility to add dependencies to the corresponding `choice` of the allocator initialization configuration in the future. Signed-off-by: Simon Kuenzer <simon@unikraft.io>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. In the future we need to be a bit careful not to use LIBUKBOOT_NOALLOC
/LIBUKBOOT_NOSCHED
, also during reviews. I will wait for one more RB before approving for merge.
Reviewed-by: Michalis Pappas michalis@unikraft.io
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works fine, thank you.
Reviewed-by: Stefan Jumarea stefanjumarea02@gmail.com
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved-by: Razvan Deaconescu razvand@unikraft.io
This commit introduces the hidden configuration option `CONFIG_LIBUKBOOT_INITSCHED` that indicates that scheduler initialization is configured with `lib/ukboot`. The previous check for `!CONFIG_LIBUKBOOT_NOSCHED` was not sufficient, as the option is not available if `CONFIG_LIBUKBOOT_NOALLOC` is set. The reason is the dependency expressed for the corresponding `choice` in the libraries' `Config.uk`. This would incorrectly mean that a scheduler is being initialized. Signed-off-by: Simon Kuenzer <simon@unikraft.io> Reviewed-by: Michalis Pappas <michalis@unikraft.io> Reviewed-by: Stefan Jumarea <stefanjumarea02@gmail.com> Approved-by: Razvan Deaconescu <razvand@unikraft.io> GitHub-Closes: #1413
This commit introduces the hidden configuration option `CONFIG_LIBUKBOOT_INITALLOC` that indicates that allocator initialization is configured with `lib/ukboot`. We do this in order to be inline with the scheduler configuration (`Config.uk`) and to have the possibility to add dependencies to the corresponding `choice` of the allocator initialization configuration in the future. Signed-off-by: Simon Kuenzer <simon@unikraft.io> Reviewed-by: Michalis Pappas <michalis@unikraft.io> Reviewed-by: Stefan Jumarea <stefanjumarea02@gmail.com> Approved-by: Razvan Deaconescu <razvand@unikraft.io> GitHub-Closes: #1413
Description of changes
This PR fixes the KConfig configuration of "no scheduler" with
lib/ukboot
. Previously, scheduler initialization code was still compiled in even if no scheduling was selected. This happened if at the same time no allocator was configured as well.Please note that this PR fixes only the configuration handling in
lib/ukboot
. I noticed a crash within one of the registered inittab functions if no scheduler was initialized. There is also an assertion failure iflib/ukboot
is configured without allocator initialization (system does not boot without an allocator assigned to the platform libraries). Both need fixing with corresponding subsystem PRs and taking re-arch into account.