summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorNick Desaulniers <ndesaulniers@google.com>2020-11-07 11:49:39 +0300
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2020-11-09 21:25:20 +0300
commit9debfb81e7654fe7388a49f45bc4d789b94c1103 (patch)
tree99df5484a62a8fb1028ca6049c10ede8bdbc8e41 /drivers
parentc6237b210ddc4f026a368172e957cbd3d5b5c78a (diff)
downloadlinux-9debfb81e7654fe7388a49f45bc4d789b94c1103.tar.xz
ACPI: GED: fix -Wformat
Clang is more aggressive about -Wformat warnings when the format flag specifies a type smaller than the parameter. It turns out that gsi is an int. Fixes: drivers/acpi/evged.c:105:48: warning: format specifies type 'unsigned char' but the argument has type 'unsigned int' [-Wformat] trigger == ACPI_EDGE_SENSITIVE ? 'E' : 'L', gsi); ^~~ Link: https://github.com/ClangBuiltLinux/linux/issues/378 Fixes: ea6f3af4c5e6 ("ACPI: GED: add support for _Exx / _Lxx handler methods") Acked-by: Ard Biesheuvel <ardb@kernel.org> Signed-off-by: Nick Desaulniers <ndesaulniers@google.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/acpi/evged.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/acpi/evged.c b/drivers/acpi/evged.c
index b1a7f8d6965e..fe6b6792c8bb 100644
--- a/drivers/acpi/evged.c
+++ b/drivers/acpi/evged.c
@@ -101,7 +101,7 @@ static acpi_status acpi_ged_request_interrupt(struct acpi_resource *ares,
switch (gsi) {
case 0 ... 255:
- sprintf(ev_name, "_%c%02hhX",
+ sprintf(ev_name, "_%c%02X",
trigger == ACPI_EDGE_SENSITIVE ? 'E' : 'L', gsi);
if (ACPI_SUCCESS(acpi_get_handle(handle, ev_name, &evt_handle)))