From patchwork Sat Nov 7 08:34:31 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nick Desaulniers X-Patchwork-Id: 320894 Delivered-To: patch@linaro.org Received: by 2002:a17:906:d156:0:0:0:0 with SMTP id br22csp1110306ejb; Sat, 7 Nov 2020 00:34:50 -0800 (PST) X-Google-Smtp-Source: ABdhPJxp0NLbiakhL5NLFEWMf03Bwwy0PGV44d91+ofZi761yxQAKEAh82ylSlzqzi2k/Lbs7vMB X-Received: by 2002:a17:906:1c0f:: with SMTP id k15mr5731374ejg.343.1604738089963; Sat, 07 Nov 2020 00:34:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604738089; cv=none; d=google.com; s=arc-20160816; b=py320HjBoiKk1uT83Zjb/hMGBwb1Wa7zwKAAKshGSH1Xty3NZ34hsx0oLOL0qWEXu9 Cmat7jgEXbB5V7pamF+S6ICNUF4RVK7i1ZmOWbtIbVe9Pa/y8FaG1PJqufqRN7K4kuND +gAnZeiOQ5ng49K/bAkT8OV4vUhkb8uHJgzsRZZ0UjUKr/mxNZkKJOBJpbycUji0g0aV 4eC8lffNXH6AvIFr/pbsE3M5b47n1vk3Nz37qt0mzqdW5A2ZTu4y9MJ1DY8AXPb0cmgL vVMJhDOhxk7kpiHJISaTnH2Wkoszx0SOIB246aMOqIrr2gasD2rwkZRrPJywLSjjrdxa f2pg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:from:subject:mime-version:message-id:date :sender:dkim-signature; bh=Z1peopUQ0CXJcnmm3Y1iXQw/XLE0Jshqm+lf7SqAfcA=; b=psU7WB2S0keM1qkuCCuIoXHcDDcbshreIBTD+ewhz2Xw43HukcLJLFKKQc6zIj8x8d 39kmFsCzGGLSulW2Apmeu7zhsLQpkp2BKNYKHaJyuBUwDvRKrmGrfj22bDdNXwWzTXW+ TR/qUTqJQ7eQnN1qCJ7EjzrAO7kgT/00tF0Y16AcNFRxg3oT6poXqOlnedOfZFTVGf78 A3Cjy8aljPgMjqRfsP7MeoOnNfpT5SAiWoOn7pJuQAo+fEyPq05xMtXql0x5Q2JabVNh TdBv0iCIfNWzAE57b3lOjY+WVyNylcIajM+OZ+2IKhe0pF4cBH/uHpZiYZtvGN+JA5iy MkhQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=ljoBwQSY; spf=pass (google.com: domain of linux-acpi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-acpi-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w25si2969634edt.600.2020.11.07.00.34.48; Sat, 07 Nov 2020 00:34:49 -0800 (PST) Received-SPF: pass (google.com: domain of linux-acpi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=ljoBwQSY; spf=pass (google.com: domain of linux-acpi-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-acpi-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727901AbgKGIeo (ORCPT + 7 others); Sat, 7 Nov 2020 03:34:44 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43418 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728175AbgKGIeo (ORCPT ); Sat, 7 Nov 2020 03:34:44 -0500 Received: from mail-yb1-xb4a.google.com (mail-yb1-xb4a.google.com [IPv6:2607:f8b0:4864:20::b4a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5691BC0613D2 for ; Sat, 7 Nov 2020 00:34:42 -0800 (PST) Received: by mail-yb1-xb4a.google.com with SMTP id q83so4521014ybq.17 for ; Sat, 07 Nov 2020 00:34:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=sender:date:message-id:mime-version:subject:from:to:cc; bh=Z1peopUQ0CXJcnmm3Y1iXQw/XLE0Jshqm+lf7SqAfcA=; b=ljoBwQSYeuvhSAm05Tb8i9IjvzUi2f9jfINj73VmVc0oHO1K+tLPdjZfs/7fHxJ4Zg M4r7Y7HSH212OENIhVPZXNEZdCOhGxYuNm3F3hktzk1t64hSVnYEq72r1jbUYXQCigQZ FSHlH5bRWBwmHB7mM4WOK4FqSdiPP/l4x2SL+sGyMFNPuIEuuu1KtFpMoelEt96svhee q3OqD9B2RwumGf0HzoIJSID4KWqU8RZxG+Wb2TJ40/vyVlG4G3sNo/7FGU/wMlOWbvcA mQZk/looCHFKwfFM81fXiCVvxXSjBE8Dl82hNtH2o/Pk5QLkmWAmblmJYYM5HJgNJBfg 4faw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:message-id:mime-version:subject:from :to:cc; bh=Z1peopUQ0CXJcnmm3Y1iXQw/XLE0Jshqm+lf7SqAfcA=; b=s/T3kBn2uoGV7CPhEDEdckWVDP5LoEepcT738+w4XXlEGZ7CgRBPvy5237koQYzBpN bJKpBoiK+sGvHyF2GqFgn8ObKS4YOQJWgu5AyPzl6i6hMUMJs9v1M/JQ9dcV68K0wVyz xzKwMo6nhPFKFPAvdNkE++kF0A2oLLXDB8EF6oLmcFt/2rruCwek895pMX550Pq034uR bQgzg2HD09m/Bu3yzHJ3ZYoy6kTLZ21bBq+j+b4i6MKc7Qa3Ubw6tEItvocfC3fzQYCF wMT/I6UjN11Orki23byf1bxfvf6Bm3iUcW1w4Y4U0+j2OkHbL7XJYpeQhXpDGKVMcpwl z8qA== X-Gm-Message-State: AOAM5316KHVBpHUx71LM4ry9glexi1xRRt5Rnxftxk5VgvHDfR3vehJZ GnPX6OC1T9d2Ceb8+EvpGP2VMibbC2gBglun5L8= Sender: "ndesaulniers via sendgmr" X-Received: from ndesaulniers1.mtv.corp.google.com ([2620:15c:211:202:f693:9fff:fef4:4d25]) (user=ndesaulniers job=sendgmr) by 2002:a25:ca8e:: with SMTP id a136mr7465151ybg.101.1604738081544; Sat, 07 Nov 2020 00:34:41 -0800 (PST) Date: Sat, 7 Nov 2020 00:34:31 -0800 Message-Id: <20201107083432.3175710-1-ndesaulniers@google.com> Mime-Version: 1.0 X-Mailer: git-send-email 2.29.2.222.g5d2a92d10f8-goog Subject: [PATCH] ACPI: GED: fix -Wformat From: Nick Desaulniers To: "Rafael J . Wysocki" , Len Brown Cc: Ard Biesheuvel , Nick Desaulniers , Nathan Chancellor , linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, clang-built-linux@googlegroups.com Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org 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: commit ea6f3af4c5e6 ("ACPI: GED: add support for _Exx / _Lxx handler methods") Signed-off-by: Nick Desaulniers --- drivers/acpi/evged.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.29.2.222.g5d2a92d10f8-goog Acked-by: Ard Biesheuvel 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)))