From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-43100.protonmail.ch (mail-43100.protonmail.ch [185.70.43.100]) (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 43D723A16BF for ; Mon, 30 Mar 2026 08:52:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.70.43.100 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774860749; cv=none; b=G40E8y7+R07d63gpifgFr4rCP/XNJoYbBPjmw5sYJJAPU7mTe2F64q0HKvzlLZbevcGF1hFoPbYkwYmBe7jRg2tTiNJlCQydSnSATganCvI0JQCPFAvCQDQg/h5GKhzrsSArfY3zFqOUXoKWmw4eXnnN8aXjs8sOxZ5wPXb8rzI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774860749; c=relaxed/simple; bh=b4rARcFPFxPijjBXb23PvbFcLtm9exzTXqkGwXyinuc=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=FBv5LIRoic8oZrohZJDAPMjyVYPz27xD+tJoEucn4vLkLNvhwiZXNybD2JHet74yn+hb1rTxjmci368zGCU45xhuXLV/hbAHLsoRDQxH48JopMn12+dhnCbD59PDRZ8bY8mkvg6F9+udQmc/m71+keQfOqfSo+Nfcfuc+WBXijM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=pm.me; spf=pass smtp.mailfrom=pm.me; dkim=pass (2048-bit key) header.d=pm.me header.i=@pm.me header.b=nl4UIfI9; arc=none smtp.client-ip=185.70.43.100 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=pm.me Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=pm.me Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=pm.me header.i=@pm.me header.b="nl4UIfI9" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pm.me; s=protonmail3; t=1774860746; x=1775119946; bh=b4rARcFPFxPijjBXb23PvbFcLtm9exzTXqkGwXyinuc=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=nl4UIfI9pjKzMAoxIB4d0PHG3Jsuq5jZOpkbva1Cz/4Ak0SEnEi+Z1XAVk7sR7G+d iNAG0pvZ8Y6TzNaQdQppWtUmmr6hVn9RcKLVzTuOcLIcUrurStFdj24zq7VeVWlV0K WDDeUaJGAowT+VOQfxUccte3ofuCndX7Yp082+x2VaDVy/bwqGbng+JHkqpB5P+n8W 8/SUpL7bsD8TPwln1TajvHEJj/94Pk3hDJ7kEwSMHf7ovPA7CZ72lIJMlRhU5Jj3VZ AsKNjBLeL54TiCSyL0E4aSzvYUpWDJWeFHE9rQ99NmIOXi1NhjoVMRShnP9d5/JRtH B8V+CTSHnQCew== Date: Mon, 30 Mar 2026 08:52:21 +0000 To: Andi Kleen From: Maciej Wieczor-Retman Cc: bp@alien8.de, dave.hansen@linux.intel.com, hpa@zytor.com, xin@zytor.com, chang.seok.bae@intel.com, mingo@redhat.com, elena.reshetova@intel.com, maciej.wieczor-retman@intel.com, babu.moger@amd.com, sohil.mehta@intel.com, pawan.kumar.gupta@linux.intel.com, pmladek@suse.com, nik.borisov@suse.com, ptesarik@suse.com, darwi@linutronix.de, tglx@kernel.org, peterz@infradead.org, jpoimboe@kernel.org, linux-kernel@vger.kernel.org, x86@kernel.org Subject: Re: [PATCH v12 0/4] x86: Capability bits fix and required bits sanity check Message-ID: In-Reply-To: References: Feedback-ID: 164464600:user:proton X-Pm-Message-ID: b943458ef06e6f2b2601ba8f078596efb33d8b23 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 2026-03-29 at 23:11:19 -0700, Andi Kleen wrote: > >I'm not sure what the point of this check is. Obviously the kernel cannot >handle it, short of refusing to boot which would be far too drastic. > >And if it's just for having something in the kernel log, who would look >for this? Any possible symptoms from a bogus cpuid will be far >disconnected from that particular log location. > >Further, there's also no evidence that it is a real practical problem. >If anything it could likely only come from rogue VMMs, but these don't=20 >seem to be common. But VMMs normally don't really disable ISA, so even if = the=20 >CPUID is inconsistent things will still likely work because the actual >instructions are fine. > >Assuming it was a real problem, you could just do it in a user program, wh= y >put it into the kernel and waste everyone's memory? (this cannot be >initcode due to hotplug) > >Also it seems to violate Steinbach's system programing maxim >(never check for something you don't know how to handle) > >-Andi According to hpa [1] one could for example boot with PAE disabled and it mi= ght go unnoticed. In that thread it was also mentioned that the BIOS might have something required disabled and even if the system will not get to boot ful= ly a user could get a clue what failed. Also a user could technically disable required features through clearcpuid.= I know it will also taint the kernel but no warning is produced if the cleare= d feature was required. [1] https://lore.kernel.org/all/207ba0a6-5ebc-465a-8d54-6e5a99622a72@zytor.= com/ --=20 Kind regards Maciej Wiecz=C3=B3r-Retman