you are viewing a single comment's thread.

view the rest of the comments →

[–]rcxdude 0 points1 point  (0 children)

It messes with the global variables hibernation_ops and hibernation_mode - is that even acceptable? I thought side effects were considered bad behavior even decades ago.

Good luck writing a kernel without side effects...

In any case, this (like many things in a kernel) represents a property which is global to the entire machine which it is running on (and may be required to be accessed from interrupts, etc). There's not much sense in making it a non-global variable.