Skip to content
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

reboot.c : changed reboot_default to bool #947

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions kernel/reboot.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,11 @@ EXPORT_SYMBOL(cad_pid);
#endif
enum reboot_mode reboot_mode DEFAULT_REBOOT_MODE;
EXPORT_SYMBOL_GPL(reboot_mode);
#if defined(CONFIG_ARM64)
enum reboot_mode panic_reboot_mode = REBOOT_HARD;
#else
enum reboot_mode panic_reboot_mode = REBOOT_UNDEFINED;
#endif

/*
* This variable is used privately to keep track of whether or not
Expand All @@ -43,7 +47,7 @@ enum reboot_mode panic_reboot_mode = REBOOT_UNDEFINED;
* suppress DMI scanning for reboot quirks. Without it, it's
* impossible to override a faulty reboot quirk without recompiling.
*/
int reboot_default = 1;
bool reboot_default = true;
int reboot_cpu;
enum reboot_type reboot_type = BOOT_ACPI;
int reboot_force;
Expand Down Expand Up @@ -1016,7 +1020,7 @@ static int __init reboot_setup(char *str)

/*
* Having anything passed on the command line via
* reboot= will cause us to disable DMI checking
* reboot= will cause us to skip DMI checking
* below.
*/
reboot_default = 0;

Choose a reason for hiding this comment

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

why not use the bool value here?

Copy link
Author

Choose a reason for hiding this comment

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

I just overlooked, I just changed all the variables to bool. It should solve the issue now.

Expand Down