Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp2227402rwl; Fri, 6 Jan 2023 03:44:38 -0800 (PST) X-Google-Smtp-Source: AMrXdXsg19NOnWk5hItlk2uuDSI3IrqpsVvQ48v1ePhmV9pLKIIy65To2Dl/rfgrVt40d2gKzi0P X-Received: by 2002:a17:906:b142:b0:7c1:6fd3:1efa with SMTP id bt2-20020a170906b14200b007c16fd31efamr51546754ejb.28.1673005477860; Fri, 06 Jan 2023 03:44:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673005477; cv=none; d=google.com; s=arc-20160816; b=Uf640+XJlVkEpFxijBLzuetKpSlFaakTTfJy75HRDQfj8Cn36x5SmwMGJgZ9sXX4bC wYvoELI9Ds1l2jY30mDTt/LAWrFO01n/eu4lBe/izxZFAeniPHvZo9Nm6sYsOmjfnpe8 ca1kHgEYpNBcTFEHq6dv7Pbgv86miVAjtojYpYWm2iAjdqdJt23bGcUOVVPkqnNwnnZ0 c0500yTkcbOCuaC/W6PlQEzzvMPPMoyJmWjstDwXqEYSXOEQw6kD5lj1qbqpV65EEZ1v y/9o+oypFvX84Yw21rSqKiJOfTxrPAIMWY2lxmUeTVv0VGbSjXiksL8SyUzmHCS+WCkw 8ltg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Zwa1AJdb1Yx9W9VHqmxo19nMGtCwdhn9fNGoNRc3Nhc=; b=WbOAFsMWPDzsSf71q4LISSrZSBVUSFasCRY4j63snHduYHN8L2mAjn36JBdfj/eVa6 VyVMFcr7YQvvK8/QqdrV3HbmoMovRTaNWgcEyABfJB0M8rSM2/bGNxPSw4dSbZI0oVGx TrJeNjfwVUNRWf2KCqMwWZTziXjkFYCL4B9WTeDBOGyBBMkd6rILb/xosRYV1okW7bfF lBvflSOUX7QzCpAklUF7nugDV2zi8qVA4EqW1hWihHHqa+DQiRWfm6Y8j8Mg140eFfb1 Op6/Df+5lRC2ScVpa+KDls5MmbRpB/Pk0BfPfF0RwJrVErUHNquENeKJz+f/ByeY8rG7 f5Lg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=Pb3VcGqB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id xd9-20020a170907078900b0078de51e1c3dsi1030335ejb.840.2023.01.06.03.44.24; Fri, 06 Jan 2023 03:44:37 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=Pb3VcGqB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232810AbjAFLMD (ORCPT + 54 others); Fri, 6 Jan 2023 06:12:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54692 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229580AbjAFLMB (ORCPT ); Fri, 6 Jan 2023 06:12:01 -0500 Received: from mail.skyhub.de (mail.skyhub.de [IPv6:2a01:4f8:190:11c2::b:1457]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 04EB56E0E1; Fri, 6 Jan 2023 03:12:01 -0800 (PST) Received: from zn.tnic (p5de8e9fe.dip0.t-ipconnect.de [93.232.233.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 970B71EC06F0; Fri, 6 Jan 2023 12:11:59 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1673003519; 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: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=Zwa1AJdb1Yx9W9VHqmxo19nMGtCwdhn9fNGoNRc3Nhc=; b=Pb3VcGqBfz/Sy3m2F7IeNoquqxzxNd6SRV3L/jVX4g54WtQqhez88GO5R+myAv9erg9oE8 Uj+QZu2Vo4e76djS5EOlrwsfE4uETg/cJABcWHk2u7WrDJ+h3AvjkTND2Tg0XHdqM79JAs f0lhpYl92UU5GuGsBubOWJ+Mi9+77vM= Date: Fri, 6 Jan 2023 12:11:54 +0100 From: Borislav Petkov To: Ingo Molnar Cc: "Zhang, Rui" , "Hansen, Dave" , "ak@linux.intel.com" , "x86@kernel.org" , "dave.hansen@linux.intel.com" , "peterz@infradead.org" , "linux-perf-users@vger.kernel.org" , "mingo@redhat.com" , "tglx@linutronix.de" , "kan.liang@linux.intel.com" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH 1/2] perf/x86/rapl: Add support for Intel Meteor Lake Message-ID: References: <20230104145831.25498-1-rui.zhang@intel.com> <25d07838-3904-a086-4238-f56c9424b53a@intel.com> <4cc5cd868b20366fc9d4bf157656e0c295074282.camel@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jan 06, 2023 at 11:56:18AM +0100, Ingo Molnar wrote: > It's a trade-off in any case: there's a point where quirk flags or even > feature flags become harder to read and harder to maintain than cleanly > separated per model driver functions. Yeah, no, singular: a synthetic feature *flag*: X86_FEATURE_RAPL. cpu/intel.c can set it and driver can test it. Everything else inside the driver. Until Intel can get their act together and actually do a CPUID bit like AMD. :-P But when you think about it, whether the model matching happens in the driver or in cpu/intel.c doesn't matter a whole lot. All that matters is, they should finally give it a CPUID bit. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette