From patchwork Thu May 20 09:23:36 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 443225 Delivered-To: patch@linaro.org Received: by 2002:a02:7a1b:0:0:0:0:0 with SMTP id a27csp2184671jac; Thu, 20 May 2021 04:09:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw369Yw+Ku2SYkPAv3PpvIQqvET1vbWlrLmrxsse7BMvoZ2QtNI2YmgmpVvAA+gkRQpkYUI X-Received: by 2002:a92:cc4c:: with SMTP id t12mr4444788ilq.232.1621508955194; Thu, 20 May 2021 04:09:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621508955; cv=none; d=google.com; s=arc-20160816; b=LXk4ciLEZji/0riUiWzPaRtbI6FYI25MNXPFBxYrZkhVJZHIyeAmDZ+MS6cFvk71Eh w6nbgpc3T6Uv894vjAD4n878Qw0ffSR5ArUDSD+NRAM+A9OEQpYvSWlUc/hPMlanoGLi FGf8L2ly+JkbIeF3kl1y+2J7ykRbUWMK1l1nS+zcFk/kpXR5hM86OspyIkCthcRP0kkt kG7Sqenqm/VTsFCuANzgrR+ZN2cSxUR9BFv3eIALX5lo49ni3VTYRfElPvA+utX6PyDI llUga3YN4Dnt1P5xW+o7Tu/qoWZPKPLpVhEJbfNFCznmGvp3pngqvJkD4aMxfS0zhgmN givA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=MkK1Pwz5if5Lazfa9egXrYtYWfUp6EStyHoYhNzK6Qc=; b=a3gehU0/xPkIwoW8XW/b4j53bL4CdhLX43PPHhYw5TGlFNp2/kUr6/jtCUc67UEfM2 8oLeAK4mEymi+uuzv0RL4e6c1/Y11xvDr9+hx5W4Rlsy2iRlkggTTaRhp89yW5Gxyl0u LV6rT2rH4ejNlPL3G6ySc+bzokJFt9rskdNpMIP8sYu5hQ7gaw0MXh0FgijrN8p+Jdw4 G+G35sixhVOh4x3dsIATZaPu3egPr39DFRJQMTFifGC7PjX42HM6lKPdg/C072ODbrPz yJN12BcdqNd6WM3v07IG8MeR4fbAjgxpBM71J9aPYQs/qQnFYzb+0vcuxAgh+IM8e4hl 6Qsw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=kTKjI11c; spf=pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p14si2671290ils.62.2021.05.20.04.09.15; Thu, 20 May 2021 04:09:15 -0700 (PDT) Received-SPF: pass (google.com: domain of stable-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=@linuxfoundation.org header.s=korg header.b=kTKjI11c; spf=pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238544AbhETLK0 (ORCPT + 12 others); Thu, 20 May 2021 07:10:26 -0400 Received: from mail.kernel.org ([198.145.29.99]:37896 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235618AbhETLHN (ORCPT ); Thu, 20 May 2021 07:07:13 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id F1D9461D26; Thu, 20 May 2021 10:05:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1621505152; bh=DxXPoU4nmCj8bRLhnv8Q1DKdGo+gIGPorYOkRXJSt0M=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kTKjI11cgJfi3l/rn1dHCnZpIW+2RtQ4ySrBULjsD9K7rXKOvpv9Lf/kNGdZZiBGe IjAYEV0gD2lpZniFbB+YMq7pG2gHiEYDYULRHgXuBPDv3w7vyohIR3G1X4qRwKEj2p onX7zGtK3sz/jRz5+1uMru1OKKbLQ/0fS+d45QfU= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Arnd Bergmann , Ingo Molnar Subject: [PATCH 4.9 224/240] x86/msr: Fix wr/rdmsr_safe_regs_on_cpu() prototypes Date: Thu, 20 May 2021 11:23:36 +0200 Message-Id: <20210520092116.235551046@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210520092108.587553970@linuxfoundation.org> References: <20210520092108.587553970@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Arnd Bergmann commit 396a66aa1172ef2b78c21651f59b40b87b2e5e1e upstream. gcc-11 warns about mismatched prototypes here: arch/x86/lib/msr-smp.c:255:51: error: argument 2 of type ‘u32 *’ {aka ‘unsigned int *’} declared as a pointer [-Werror=array-parameter=] 255 | int rdmsr_safe_regs_on_cpu(unsigned int cpu, u32 *regs) | ~~~~~^~~~ arch/x86/include/asm/msr.h:347:50: note: previously declared as an array ‘u32[8]’ {aka ‘unsigned int[8]’} GCC is right here - fix up the types. [ mingo: Twiddled the changelog. ] Signed-off-by: Arnd Bergmann Signed-off-by: Ingo Molnar Link: https://lore.kernel.org/r/20210322164541.912261-1-arnd@kernel.org Signed-off-by: Greg Kroah-Hartman --- arch/x86/lib/msr-smp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/arch/x86/lib/msr-smp.c +++ b/arch/x86/lib/msr-smp.c @@ -239,7 +239,7 @@ static void __wrmsr_safe_regs_on_cpu(voi rv->err = wrmsr_safe_regs(rv->regs); } -int rdmsr_safe_regs_on_cpu(unsigned int cpu, u32 *regs) +int rdmsr_safe_regs_on_cpu(unsigned int cpu, u32 regs[8]) { int err; struct msr_regs_info rv; @@ -252,7 +252,7 @@ int rdmsr_safe_regs_on_cpu(unsigned int } EXPORT_SYMBOL(rdmsr_safe_regs_on_cpu); -int wrmsr_safe_regs_on_cpu(unsigned int cpu, u32 *regs) +int wrmsr_safe_regs_on_cpu(unsigned int cpu, u32 regs[8]) { int err; struct msr_regs_info rv;