From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 5944F404BF6; Tue, 21 Jul 2026 21:45:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784670342; cv=none; b=MLcdCnRAGOsJ7yNvtI+l6rQtex77ltkrLWtbjxEV3/xdb89HwIFPlvbQbtgABq0yUZrYy9lc0tR8sZGF444C63MTcy/Xen45dsyvRjLqpsdvkHIZDwxtUwIplPktwbNiay1Dxyh6EebwOIfP05ftzVnVyr/JDWTiTOxyA4BhnmI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784670342; c=relaxed/simple; bh=MySz2bVH5l5PbikhecjQbCqAqu2WBtJvcwyDMuuRbPg=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=R3Y2HCUFJOBQztCUmT4JnkSTu2YuOxQvwGowZTa57WRABrUzLa6IBlQVE2hattVc0I3felKvtsk6aiMSPxgX3j12xWV2C6tN8ymdSZ1mypUE/4mwr6kZqE3tTDvo+r3YeicGyL+8CjAd/2U+y3Y+mbxlYph4ZQdxxutOuotjrUw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=rnbYVa1b; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="rnbYVa1b" Received: by smtp.kernel.org (Postfix) with ESMTPSA id B90841F000E9; Tue, 21 Jul 2026 21:45:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1784670341; bh=582ZS1VDw5kYiOejeq6GllPsk/+DDThAYfnJnST4988=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=rnbYVa1btRGwb/qefJA1LXovRd3EZqBDIADEmrpk4Ef6azkxiw2jdoq2TITANb/yj DAeEIezSE8iZbSZZViCQJKbQe356AdYBh1SFEkrvQU7aZKQ4UPLU8UbkflJ9454cjB F02GRK9VlSeB92UZeVICDJXDqTwxOu6NndR5/O28= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Pengpeng Hou , Guenter Roeck Subject: [PATCH 6.1 0897/1067] hwmon: (w83793) remove vrm sysfs file on probe failure Date: Tue, 21 Jul 2026 17:24:58 +0200 Message-ID: <20260721152444.600064790@linuxfoundation.org> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260721152424.521567757@linuxfoundation.org> References: <20260721152424.521567757@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.1-stable review patch. If anyone has any objections, please let me know. ------------------ From: Pengpeng Hou commit 77b983757280c69b0290811669ff1d31022e5f1d upstream. w83793_probe() creates the vrm sysfs file after creating the VID files when VID support is present. The normal remove path deletes vrm, but the probe error path only removes the sensor, SDA, VID, fan, PWM and temperature files. A later probe failure can therefore leave vrm behind after the driver data has been freed. Remove vrm in the probe error path next to the VID files, matching the normal remove path. Signed-off-by: Pengpeng Hou Link: https://lore.kernel.org/r/20260615064806.51139-1-pengpeng@iscas.ac.cn Cc: stable@vger.kernel.org Signed-off-by: Guenter Roeck Signed-off-by: Greg Kroah-Hartman --- drivers/hwmon/w83793.c | 1 + 1 file changed, 1 insertion(+) --- a/drivers/hwmon/w83793.c +++ b/drivers/hwmon/w83793.c @@ -1918,6 +1918,7 @@ exit_remove: for (i = 0; i < ARRAY_SIZE(w83793_vid); i++) device_remove_file(dev, &w83793_vid[i].dev_attr); + device_remove_file(dev, &dev_attr_vrm); for (i = 0; i < ARRAY_SIZE(w83793_left_fan); i++) device_remove_file(dev, &w83793_left_fan[i].dev_attr);