From 1ddc8a8e6870e9d19dda286fff5fde66663dc391 Mon Sep 17 00:00:00 2001 From: Kyle Evans Date: Mon, 30 Jul 2018 18:13:20 +0000 Subject: [PATCH] Follow up to r336919 and r336921: s/efi.rt_disabled/efi.rt.disabled/ The latter matches the rest of the tree better [0]. The UPDATING entry has been updated to reflect this, and the new tunable is now documented in loader(8) [1]. Reported by: imp [0], Shawn Webb [1] --- UPDATING | 2 +- stand/man/loader.8 | 6 +++++- sys/dev/efidev/efirt.c | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/UPDATING b/UPDATING index ebded032e740..44aafb2514ab 100644 --- a/UPDATING +++ b/UPDATING @@ -34,7 +34,7 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 12.x IS SLOW: 20180730: amd64/GENERIC now has EFI runtime services, EFIRT, enabled by default. This should have no effect if the kernel is booted via BIOS/legacy boot. - EFIRT may be disabled via a loader tunable, efi.rt_disabled, if a system + EFIRT may be disabled via a loader tunable, efi.rt.disabled, if a system has a buggy firmware that prevents a successful boot due to use of runtime services. diff --git a/stand/man/loader.8 b/stand/man/loader.8 index 467e5c1ae116..e6c26ad28bb0 100644 --- a/stand/man/loader.8 +++ b/stand/man/loader.8 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 15, 2018 +.Dd July 30, 2018 .Dt LOADER 8 .Os .Sh NAME @@ -588,6 +588,10 @@ explicitly. Other variables are used to override kernel tunable parameters. The following tunables are available: .Bl -tag -width Va +.It Va efi.rt.disabled +Disable UEFI runtime services in the kernel, if applicable. +Runtime services are only available and used if the kernel is booted in a UEFI +environment. .It Va hw.physmem Limit the amount of physical memory the system will use. By default the size is in bytes, but the diff --git a/sys/dev/efidev/efirt.c b/sys/dev/efidev/efirt.c index 377cf230e9f3..9a3b2509c4cf 100644 --- a/sys/dev/efidev/efirt.c +++ b/sys/dev/efidev/efirt.c @@ -136,7 +136,7 @@ efi_init(void) int rt_disabled; rt_disabled = 0; - TUNABLE_INT_FETCH("efi.rt_disabled", &rt_disabled); + TUNABLE_INT_FETCH("efi.rt.disabled", &rt_disabled); if (rt_disabled == 1) return (0); mtx_init(&efi_lock, "efi", NULL, MTX_DEF);