Message ID | 20230526215621.16075-1-samsagax@gmail.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp2683vqr; Fri, 26 May 2023 15:49:24 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6Bw9ssjyKl1Wa7OfsVUVhDb5kybNWZpf6J9kGrgMCyoI+4E5LSjPHgI3gv8UOz7h41CRFm X-Received: by 2002:a17:902:d483:b0:1b0:12e:3bfd with SMTP id c3-20020a170902d48300b001b0012e3bfdmr5100612plg.7.1685141364350; Fri, 26 May 2023 15:49:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685141364; cv=none; d=google.com; s=arc-20160816; b=NL+kWpm718JQ10FfYEZ4/RkdIhptvdWJa2+oLz2DyZBbCdl9DzUSZVRYJnt/2AVTq/ VjLW46jH23ersxqez+QE3lcRJZBAGG91zZZwrTIpbRvhyTjUm1Ey/OXtd2qO0gKCCutB n4UXKEyddgjMFiWIEqDZq8GTCp4UZSXaCovSAHAuZjxzOOGsAZnas+/Mz2fnO+Fz4b+0 XauMsDvkZdJIEMbRo71PU9b0zVBeTSoUVkMjE9MIvSOhVWXiwEjKFH6VPekjzm5sOaeI p681JZGL+/ZydFJZS1GCScrJM8qXhScDYclr2PBgf4mSLeEx2PJ8HT61jbKv8b0DoTPG PuYQ== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=oobY8Hnr+V4wGPCWsnIMgT9DHlRXZoBkbIC6BEX23SU=; b=cpKj6T+YIR1Dbp8yAkttmQNmbeQ6Km0/QHB6tCbNfT7NPxwcjTjN2JIs+Z+f6oPDpA CSldqEk807KPo2c5omwK6gBDao7FEGtSsQBSeH1QPMCg4mYhZsrh2YJp2b4Vtli+D+8X ZNWd2JueHbKJIJe8hxmfAmoaYyW5IR+ZpMqpa1KDsyvZEe7OmxENjokKEB33X6JMTWoz 9iJyaW23jcZ4yIEqMu3mr7mFnmV0gk7bM/H1lLq14e+MHJ44VUxeJhb/uH6JNxkx0izQ AxlNdunSK5C6jSt6fu/U0npNOETd3EK568Y1X0xaL2svlUZD2XJ6nA3hqZhmbBIXmevj 2eQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=aWxVHnmK; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w18-20020a170902e89200b001ae2aa44a98si5235375plg.265.2023.05.26.15.49.12; Fri, 26 May 2023 15:49:24 -0700 (PDT) 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=@gmail.com header.s=20221208 header.b=aWxVHnmK; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244392AbjEZV6y (ORCPT <rfc822;zhanglyra.2023@gmail.com> + 99 others); Fri, 26 May 2023 17:58:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48450 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244342AbjEZV6j (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 26 May 2023 17:58:39 -0400 Received: from mail-oi1-x229.google.com (mail-oi1-x229.google.com [IPv6:2607:f8b0:4864:20::229]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B966CE57; Fri, 26 May 2023 14:58:12 -0700 (PDT) Received: by mail-oi1-x229.google.com with SMTP id 5614622812f47-39831cb47fbso870176b6e.1; Fri, 26 May 2023 14:58:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1685138198; x=1687730198; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=oobY8Hnr+V4wGPCWsnIMgT9DHlRXZoBkbIC6BEX23SU=; b=aWxVHnmKMVbtSgYUQYksmmw46grMNqXatXG37GenPMK6H2zm72YHpscZDwyPN8T/m1 Tecjxqo/3hceavTncqvVwiooAL9aqvP0Q4boolJrJzMvIMasnWtNDTbHcgVfVcD68LxZ oA3lbIbMtjcQNCA+LK6FbF2oChOcTdMzhedMmlavhDXJ6Fzd/H0BiIs2L9s15HNyrKuw 2LCRpsRUDZjMlVzham69+vGuVb984kaoKlkPdtqfibEn2/zQFiOFGJ2y6oo+brMzSa45 +zOTYntAgaV2e59iBia3KAgwUNlxWlQc8SKKdNCfz5QzrBqpzq7il/w93zw/3lBiWvx4 lsAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685138198; x=1687730198; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=oobY8Hnr+V4wGPCWsnIMgT9DHlRXZoBkbIC6BEX23SU=; b=R/bwr0YRj3E6S9hL9/hf71FgHRt6UUsWzyp7MhtOLDWbfDuO0zrhJAjn7gdG0wMVa5 KIk0jmytE9vz+joxHzrpcLQw1VEBbVcqYoCVNTtFgZhjDDoiJDB7Q5L8DuEIBlZhTWtf Td5DMGBNkkIb+ryhuAMuuU7kMuw40V6kFJpf6X1ILRG0nFA1l0g487VANZy4eomBoGpv D+j5M05NTrwZeekP/JqM5Fg0UIQgf4kWIyY+0GycJ8yz2eDzHMm2SeZndjEhzkZrFiZG FwK2D4VTuxZn3tIVAtI1+g2/KCQ99VyUn/33vj/tHexxQDh3svU5Q5GQWKUUOpQ0WkeI D71w== X-Gm-Message-State: AC+VfDwPMA1EE5AJ5g0aCIiQYKBsUbQfCxwBhGpDBaj89i1gXzKeUvOD DLVAabFZu4z/SV56roTIAJYdGniBwvY= X-Received: by 2002:a05:6808:8ca:b0:398:523a:f1ee with SMTP id k10-20020a05680808ca00b00398523af1eemr1741000oij.21.1685138198134; Fri, 26 May 2023 14:56:38 -0700 (PDT) Received: from smeagol.fibertel.com.ar ([201.235.4.68]) by smtp.gmail.com with ESMTPSA id q6-20020acaf206000000b00399ee6330a9sm756978oih.52.2023.05.26.14.56.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 26 May 2023 14:56:37 -0700 (PDT) From: =?utf-8?q?Joaqu=C3=ADn_Ignacio_Aramend=C3=ADa?= <samsagax@gmail.com> To: linux@roeck-us.net Cc: =?utf-8?q?Joaqu=C3=ADn_Ignacio_Aramend=C3=ADa?= <samsagax@gmail.com>, derekjohn.clark@gmail.com, jdelvare@suse.com, linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] hwmon: (oxp-sensors) Differentiate new BIOS for the Mini Date: Fri, 26 May 2023 18:56:22 -0300 Message-Id: <20230526215621.16075-1-samsagax@gmail.com> X-Mailer: git-send-email 2.40.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1766998791200256709?= X-GMAIL-MSGID: =?utf-8?q?1766998791200256709?= |
Series |
hwmon: (oxp-sensors) Differentiate new BIOS for the Mini
|
|
Commit Message
Joaquín Ignacio Aramendía
May 26, 2023, 9:56 p.m. UTC
Newer BIOS got some other changes aside from string changes. Add a board
enum to differentiate it from the old OneXplayer Mini AMD BIOS.
Signed-off-by: Joaquín Ignacio Aramendía <samsagax@gmail.com>
---
drivers/hwmon/oxp-sensors.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
Comments
On Fri, May 26, 2023 at 06:56:22PM -0300, Joaquín Ignacio Aramendía wrote: > Newer BIOS got some other changes aside from string changes. Add a board > enum to differentiate it from the old OneXplayer Mini AMD BIOS. > I see no functional difference. What is the point of this change ? Thanks, Guenter > Signed-off-by: Joaquín Ignacio Aramendía <samsagax@gmail.com> > --- > drivers/hwmon/oxp-sensors.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/drivers/hwmon/oxp-sensors.c b/drivers/hwmon/oxp-sensors.c > index 0ec7588610ad..423307ed4930 100644 > --- a/drivers/hwmon/oxp-sensors.c > +++ b/drivers/hwmon/oxp-sensors.c > @@ -47,6 +47,7 @@ enum oxp_board { > aya_neo_air_pro, > aya_neo_geek, > oxp_mini_amd, > + oxp_mini_amd_a07, > oxp_mini_amd_pro, > }; > > @@ -104,7 +105,7 @@ static const struct dmi_system_id dmi_table[] = { > DMI_MATCH(DMI_BOARD_VENDOR, "ONE-NETBOOK"), > DMI_EXACT_MATCH(DMI_BOARD_NAME, "ONEXPLAYER mini A07"), > }, > - .driver_data = (void *)oxp_mini_amd, > + .driver_data = (void *)oxp_mini_amd_a07, > }, > { > .matches = { > @@ -206,6 +207,7 @@ static int oxp_platform_read(struct device *dev, enum hwmon_sensor_types type, > case aya_neo_air_pro: > case aya_neo_geek: > case oxp_mini_amd: > + case oxp_mini_amd_a07: > *val = (*val * 255) / 100; > break; > case oxp_mini_amd_pro: > @@ -247,6 +249,7 @@ static int oxp_platform_write(struct device *dev, enum hwmon_sensor_types type, > case aya_neo_air_pro: > case aya_neo_geek: > case oxp_mini_amd: > + case oxp_mini_amd_a07: > val = (val * 100) / 255; > break; > case aok_zoe_a1: > -- > 2.40.1 >
> On Fri, May 26, 2023 at 06:56:22PM -0300, Joaquín Ignacio Aramendía wrote: > > Newer BIOS got some other changes aside from string changes. Add a board > > enum to differentiate it from the old OneXplayer Mini AMD BIOS. > > > > I see no functional difference. What is the point of this change ? > > Thanks, > Guenter It is nothing right now, honestly. But is necessary for a later change i have queued and a bit of OCD on my part. Should I add this to the other change? Joaquín I. Aramendía
On Fri, May 26, 2023 at 08:42:51PM -0300, Joaquin Aramendia wrote: > > On Fri, May 26, 2023 at 06:56:22PM -0300, Joaquín Ignacio Aramendía wrote: > > > Newer BIOS got some other changes aside from string changes. Add a board > > > enum to differentiate it from the old OneXplayer Mini AMD BIOS. > > > > > > > I see no functional difference. What is the point of this change ? > > > > Thanks, > > Guenter > > It is nothing right now, honestly. But is necessary for a later change > i have queued and a bit of OCD on my part. Should I add this to the > other change? > It can stay as separate patch, but please resubmit it together with the patch(es) actually using it. Guenter
I have resubmitted the change that uses this that includes this change. So drip this one and let's continue the review on the other. Thanks! Joaquín I Aramendía
diff --git a/drivers/hwmon/oxp-sensors.c b/drivers/hwmon/oxp-sensors.c index 0ec7588610ad..423307ed4930 100644 --- a/drivers/hwmon/oxp-sensors.c +++ b/drivers/hwmon/oxp-sensors.c @@ -47,6 +47,7 @@ enum oxp_board { aya_neo_air_pro, aya_neo_geek, oxp_mini_amd, + oxp_mini_amd_a07, oxp_mini_amd_pro, }; @@ -104,7 +105,7 @@ static const struct dmi_system_id dmi_table[] = { DMI_MATCH(DMI_BOARD_VENDOR, "ONE-NETBOOK"), DMI_EXACT_MATCH(DMI_BOARD_NAME, "ONEXPLAYER mini A07"), }, - .driver_data = (void *)oxp_mini_amd, + .driver_data = (void *)oxp_mini_amd_a07, }, { .matches = { @@ -206,6 +207,7 @@ static int oxp_platform_read(struct device *dev, enum hwmon_sensor_types type, case aya_neo_air_pro: case aya_neo_geek: case oxp_mini_amd: + case oxp_mini_amd_a07: *val = (*val * 255) / 100; break; case oxp_mini_amd_pro: @@ -247,6 +249,7 @@ static int oxp_platform_write(struct device *dev, enum hwmon_sensor_types type, case aya_neo_air_pro: case aya_neo_geek: case oxp_mini_amd: + case oxp_mini_amd_a07: val = (val * 100) / 255; break; case aok_zoe_a1: