_TO_CURR > results in an incorrect calculation. > > Read data->curr_sense into a local variable to ensure consistency. Note > that data->curr_gain is constant and safe to access directly. > > This aligns max16065_current_show with max16065_input_show, which > already uses a local variable for the same reason. > > Link: https://lore.kernel.org/all/CALbr=LYJ_ehtp53HXEVkSpYoub+XYSTU8Rg=o1xxMJ8=5z8B-g@mail.gmail.com/ > Fixes: f5bae2642e3d ("hwmon: Driver for MAX16065 System Manager and compatibles") > Cc: stable@vger.kernel.org > Signed-off-by: Gui-Dong Han Applied. Thanks, Guenter From - Fri Nov 28 17:06:09 2025 X-Mozilla-Status: 0001 X-Mozilla-Status2: 00000000 Return-Path: Delivered-To: hi@josie.lol Received: from witcher.mxrouting.net by witcher.mxrouting.net with LMTP id IAIAEH3WKWmQXAoAYBR5ng (envelope-from ) for ; Fri, 28 Nov 2025 17:06:05 +0000 Return-path: Envelope-to: hi@josie.lol Delivery-date: Fri, 28 Nov 2025 17:06:05 +0000 Received: from ams.mirrors.kernel.org ([213.196.21.55]) by witcher.mxrouting.net with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.98) (envelope-from ) id 1vP1v0-000000030W0-1uAh for hi@josie.lol; Fri, 28 Nov 2025 17:06:05 +0000 Received: from smtp.subspace.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.mirrors.kernel.org (Postfix) with ESMTPS id 13B94341BBC for ; Fri, 28 Nov 2025 17:03:48 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E75612BDC3D; Fri, 28 Nov 2025 17:03:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="uIvh06r3" X-Original-To: stable@vger.kernel.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 47CA229E11B; Fri, 28 Nov 2025 17:03:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764349423; cv=none; b=ctf2YznEfus1n0cu1FGEk5YfCPrzXdYdnITleQbnziy7AzO1p7aSHwVGeML+crqKtRI88CzEGCtJ6brntqNOQ9eU35rsie2yPcheCnZT7+vtwy6/jgQLMlu4tmZ1hWLb7p26qnPF9wSmSAS0UTSQVnU4NmsCt3wTuche35+C9Jk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764349423; c=relaxed/simple; bh=Ab9/QvgY2oGmHJbmytHgV/rvTKv/Atdsju9GWpu/now=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=URO7pGPG/cy2HpD0qqEUOLvBaGowFtPLSkqfCJHL8xqR4q8e6X8g9TF2QHUkouo667PTD0hxRx5jxeLhhHkTuCL4VVInUcQuLZ1n1QSvPPG0D8l1T5OMBYzagbJ0YpG+DiVKyI35ZNWMGh7QY8+QgVy97+OJAxbtgptwa6czcgI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=uIvh06r3; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 35BF6C4CEF1; Fri, 28 Nov 2025 17:03:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1764349422; bh=Ab9/QvgY2oGmHJbmytHgV/rvTKv/Atdsju9GWpu/now=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=uIvh06r3wOYQaDLbkwyb10fGHZciV6zWpju0H3tMGUIPq5BVWVINxbizVMd8fx5w3 7wTpULtp18SjIvlybcJBZouKFR2pAljnHwQxzougN0XLv0AO5HRtopHOsnSFsVFq8D bLyZFm+EqoGktzT9QHKdWgPddkOJNQ3IS+iFTgoI4G9D9Glwe1LSnMFCBmCCNT0Flp llb94uT5cNphoF4LNZaReHL/0DLqhVZQDCB9kp1wNDMHD9c+6KUYpoZtgWQv5BEnGp BtmiP5XA4q/mpinTavPoruoqHaE7DJYNu1s/byiMpHc7wO2eDEyNoRUXE