Received: by 2002:ab2:3141:0:b0:1ed:23cc:44d1 with SMTP id i1csp1065742lqg; Sat, 2 Mar 2024 14:00:17 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCViqD97g0ZxwDPrKp9fBbhV30qWh/PtoOr+Kd+INkTFpq2AmC6EPJpm4EbkZB/NoK+uynUrNIKour9aiFSnBhSxL/D4/5OynJCo85UgKQ== X-Google-Smtp-Source: AGHT+IF0tpgvwm3EyFk1vWcJ+NK925HxRVFRqzjuLdTzk72q4kEz2hPDsTx74Khcde6SlD8ovXpG X-Received: by 2002:a05:651c:141e:b0:2d2:66bf:2c1d with SMTP id u30-20020a05651c141e00b002d266bf2c1dmr3449798lje.2.1709416817761; Sat, 02 Mar 2024 14:00:17 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709416817; cv=pass; d=google.com; s=arc-20160816; b=v/oHYKX6H+aCvBXjDpm2KQ2twh9g+FlM6KLGdLQzyrwqcaMlE6zcUiZBZCCIzu5ny0 G8laMVOPNACK/o5GNB5RAA8GaBjEfNpO9ks5Y3iJ/RfdfD5dmUC5gzg3ihaZ9ss0eFla aexougE3d4zbB4wihUhEfF/hqv8xsG/bsHStUnF+NK3AaATtAUK8Om5oeOftXuiWUd1q kugoDSW0PbFj051n3C1bxhY9ij0IZHso339Nw5GOM8dS/7FR7czIoSGelPQ3cwsic0J0 yb00NtlkQ1mE6h+rd5SJwWsBXl6X4wxqx1S4QRiKPFyhU2T0OWzsDXD+qmyW5xVUAzgd dLPw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:list-unsubscribe:list-subscribe:list-id:precedence :message-id:date:references:in-reply-to:subject:cc:to:dkim-signature :dkim-signature:from; bh=H0/udQZS8D3srIlBNduJy2BLkagOGri68M14lN+zuX8=; fh=XhilH6Eiu1R+nOUr1eFRZhbjNM86AVosKvqBmkw4S00=; b=iZ23RJVYz/OuGs8IMl8UgSyL/VCMkklEV6RcTR/dzInz3GUd7gWgEJ6vpHPgOd/g9W 8kK+bWvBK8uXN0eVe9Uwk3TLrijn2EzbRWWp1Kk5NqnyqMovcdu3FitEN4dku1D8bOoF BGO17sSTaLLrltWTICNAiMU9eYzvGw2zHa0gpYo0zXBUgudwG8Lpc5L+3LsrNgdc5diJ NZtU8yaRH1reudbHMW04O61encu2+b7qgxaJLwypsE2N+WdgAH19zpIQoPNtthWVH4IB U4DnW1jyTKgF9Ei4DlqxIbEXqLDcbxBBJUDbichCfN9Rn6gglTWGJh5GtvLKkqA2Azaa es1A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=ewgVKbLY; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; arc=pass (i=1 spf=pass spfdomain=linutronix.de dkim=pass dkdomain=linutronix.de dmarc=pass fromdomain=linutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-89608-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-89608-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id z9-20020a50cd09000000b00565fb062591si2771271edi.631.2024.03.02.14.00.17 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 02 Mar 2024 14:00:17 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-89608-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=ewgVKbLY; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; arc=pass (i=1 spf=pass spfdomain=linutronix.de dkim=pass dkdomain=linutronix.de dmarc=pass fromdomain=linutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-89608-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-89608-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 77E961F21D9E for ; Sat, 2 Mar 2024 22:00:17 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5EC1E44C84; Sat, 2 Mar 2024 22:00:09 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="ewgVKbLY"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="YirNMqNi" Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AE80B40C15; Sat, 2 Mar 2024 22:00:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709416808; cv=none; b=rpsmsw9UgnKG2wMUOG5t9uVLqVRpauNDONbxtCbPHpEHOegtkx+8+ErwrW4j2Ata0nRDU9zC1gKyDb2y/ttD3ZsPPX0Paw0k9bdqllch9Ax8huVgrB3l3H0oFbB9Bqi/apSD9TU1Y5L2UN75xLQEgZ2ekQu32Ut/dYGqqSvQV9Q= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709416808; c=relaxed/simple; bh=zWKT+oNajnMzt9Fl6KPPxH36WSUCatc6JE36hWWiOck=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=iLp4kRlvD3DZGG4wV1oKXU1Xu+6atJpiaLS4G72MxXeI7yS2RloJjNhm83UEbCXc7mhHW4aPXSb7OVkKcKYTMacZsySolbwoPkey3dN2HYWQZHxjlVjT1n3e8mEszcev8GYZcyJZ7HpwsX0BiLXQ7mBSRfDaWB3N1aL4iZ9VSIY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=ewgVKbLY; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=YirNMqNi; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de From: Thomas Gleixner DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1709416804; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=H0/udQZS8D3srIlBNduJy2BLkagOGri68M14lN+zuX8=; b=ewgVKbLYVjkNzCylZSIHHDavRx8w3P41dzwEhb5XOLx9mtrAzCOo98bo0EpJ1dyBGjRe42 iYAfqCnOOHxTWcdXiC4Zx/d6bb0NLM2BBvSw6J7bPG76i1HFFV9U37mmN3zikVta3UCr23 xcA0svRMG6aJakndl5GwvkBpJVsnAijEjXCicx94vtIFd6MDbAXH2SeCyyuwHD+W0aiGJ6 N/XG7IEzTvxn8XDGrokM5wZIKigkDtRdCPPn5zLvjGSiyDwlQHLGqe1m3U4qeDs1uDAsl4 mrtwyQU6noY+03mu4VsI25rQ6AV/05SsnYcP4T7iLBnwkFgQw4xzHIbogundyg== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1709416804; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=H0/udQZS8D3srIlBNduJy2BLkagOGri68M14lN+zuX8=; b=YirNMqNin/MrKqMpeXOCvdk2XeOLGXb3z8Ioh8EqZIQWch31R99UJ0cGa/BKgJtAsW+FRq k4ETOoiUkjzOQ2Cg== To: kernel test robot Cc: oe-kbuild-all@lists.linux.dev, linux-kernel@vger.kernel.org, Arjan van de Ven , x86@kernel.org, Luc Van Oostenryck , Sparse Mailing-list Subject: Re: arch/x86/include/asm/processor.h:698:16: sparse: sparse: incorrect type in initializer (different address spaces) In-Reply-To: <87sf18vdsq.ffs@tglx> References: <202403020457.RCJoQ3ts-lkp@intel.com> <87edctwr6y.ffs@tglx> <87a5nhwpus.ffs@tglx> <87y1b0vp8m.ffs@tglx> <87sf18vdsq.ffs@tglx> Date: Sat, 02 Mar 2024 23:00:03 +0100 Message-ID: <87le70uwf0.ffs@tglx> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain On Sat, Mar 02 2024 at 16:44, Thomas Gleixner wrote: > On Sat, Mar 02 2024 at 12:37, Thomas Gleixner wrote: > The below addresses _all_ percpu related sparse warnings except > the ones in arch/x86/cpu/bugs.o but that's a sparse problem: > > The following is handled correctly: > > DECLARE_PER_CPU(u64, foo); > this_cpu_read(foo); > > But this is not: > > DECLARE_PER_CPU(u64, foo); > DEFINE_PER_CPU(u64, foo); > this_cpu_read(foo); > > arch/x86/kernel/cpu/bugs.c:71:9: sparse: warning: incorrect type in initializer (different address spaces) > arch/x86/kernel/cpu/bugs.c:71:9: sparse: expected void const [noderef] __percpu *__vpp_verify > arch/x86/kernel/cpu/bugs.c:71:9: sparse: got unsigned long long * > > Commenting out the DEFINE_PER_CPU(u64, x86_spec_ctrl_current) in that > file makes sparse happy, but that's obviously not a solution :) Correction. I found the real issue: DEFINE_PER_CPU(u64, x86_spec_ctrl_current); EXPORT_SYMBOL_GPL(x86_spec_ctrl_current); I had commented out both. But the real reason is the EXPORT_SYMBOL, which obviously wants to be EXPORT_PER_CPU_SYMBOL_GPL... So sparse was right. Nothing to see here. Thanks, tglx