Fix regression introduced by torvalds/linux@ed8b0de5a33d ("efi: Make efivarfs entries immutable by default").
chattr fails on pre-4.5 kernels or if the gpu-power-prefs entry is missing (e.g. after booting into OS X). My initial version checked the kernel release and existence of the file but then I settled on this one liner which just calls chattr unconditionally and pipes any error messages to /dev/null.
Fix regression introduced by torvalds/linux@ed8b0de5a33d ("efi: Make efivarfs entries immutable by default").
chattr fails on pre-4.5 kernels or if the gpu-power-prefs entry is missing (e.g. after booting into OS X). My initial version checked the kernel release and existence of the file but then I settled on this one liner which just calls chattr unconditionally and pipes any error messages to /dev/null.