From patchwork Sun Feb 25 20:28:41 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 206117 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:a81b:b0:108:e6aa:91d0 with SMTP id bq27csp1732645dyb; Sun, 25 Feb 2024 12:29:13 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXJQisIetiT0MSd6NXic3cHgFiNOeZ3yEkx9IypZNvbKmz2sVrzGN6W5iwCt4ryyJkbgbmTyMlQeRriivGJQBnvLXjx8g== X-Google-Smtp-Source: AGHT+IEQhkWkNwMSUj5vvSjI+nK5SFOSHw2nvvXtPjGzmloOP/o7NZvhPq3m/DR4vCo30Zn311ok X-Received: by 2002:a05:6a21:3512:b0:1a0:a091:ee97 with SMTP id zc18-20020a056a21351200b001a0a091ee97mr8241439pzb.19.1708892952853; Sun, 25 Feb 2024 12:29:12 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708892952; cv=pass; d=google.com; s=arc-20160816; b=uFyYYkYYBZAj2hY4TTZUK/PfksS1gltcf0HrdPpkKlJmaBiMaHRwz7a8Op5jWcgd1h H7TIJTDC3TtNEPNgzGdoEw5j694qGDBrFbhL4WsG/Xw54We2fttjbNst+53lJ+CWTRc/ tqyZq8esYE1QyfBCp2fams5VQs9NuPPvtSQPKsQgphoLAOdnXcQ3KqLdWqhATCcKhvcT whltuhSPhiofoWCCzW/ANTyZlQxORHh54vg1dYlEE7wDatTQvfWHcGzl7FqKx+ZlzlBd 25b88ubVAQ2cu5oWQuifaZaz6L1u6UyA+PUQBUDlTQhl0RWvNdErGbPgQ0csn5tO1chj Yecw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=LQhObH8iYYJ3IoKtoS8QTP3j/Cwz0hevmJwDdAJZbC4=; fh=Y+Xo4PtevfucNuWkE5LPSSiLt5S4/UzIsXgNDdd9jCQ=; b=dNeZNA1K/qcWTQKR3d1LAV7mlggUFdaxSKSN1DvqOOQCOENy/YF823NGH0FoOHkln+ 2xhoW7GwVYE2ybKTFHA4VVc+63NJKXxSOLKgJ9KuxgJv7sFRZZjpgrfMQvT0DDAuFCmU W2KkWRYG6+K2LF+VxLRs7JqRR3f7dDda+OmDS7osy9YVEneiFpoz9DSTHFzwsCFV2I+G Fx1KEBE7MDfRxsu+yReGRE7XNrlhINfVbYAd/d1eQo9dF76VYRqbV3QZ5srxpAv5kMgL ECsXtXbyElKSFYFXYzEhypuEjo6Ox2UcOhCgaMC+TkwjEobObLaKeANOx6UrjtQMFgG8 yrLQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=VpAw5+cT; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-80280-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-80280-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id du9-20020a056a002b4900b006e2ddb4f8fbsi2602931pfb.65.2024.02.25.12.29.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 25 Feb 2024 12:29:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-80280-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=VpAw5+cT; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-80280-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-80280-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id A84B92832BA for ; Sun, 25 Feb 2024 20:29:12 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 10AC21BC3E; Sun, 25 Feb 2024 20:28:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="VpAw5+cT" Received: from mail-ej1-f48.google.com (mail-ej1-f48.google.com [209.85.218.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0281419BA5 for ; Sun, 25 Feb 2024 20:28:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.48 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708892926; cv=none; b=cZ3KJ8sn29Zmq12LmFFUyyXzyXhcYotRFp6rrZdROZ/CYeJczT30AQ6Q8SEvNKn1i1a/+DHrf0/X9N3Fn1dL5Xu+KwQTZ/DgWegrougCtKy2zO93XzzWlnP/aPe91n+tjys/hJtxUZYPQ+lwdaK85gqHLdWSv96NO3jSvfmIqFE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708892926; c=relaxed/simple; bh=bz7La++wemDtpv2Tj4GKgbBdph0RhPEew+v3vWe9MLs=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=cyTijYX41PbNn8NVaTsk6fM0GDq5OErBswg5Cs4y/wsaPp+E/PczlrYMkPPskLhB4OQGAPfSxdApnU4UjK+ZWgomkEmycJ9lQANhMLggzbWw2V0l50wLpBRXTM7IeHq7FO6gSnQvd5dflRdl0gBnWK5fYvpFp063zWD0E0iNaXc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=VpAw5+cT; arc=none smtp.client-ip=209.85.218.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-ej1-f48.google.com with SMTP id a640c23a62f3a-a3f5808b0dfso330705766b.1 for ; Sun, 25 Feb 2024 12:28:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1708892923; x=1709497723; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=LQhObH8iYYJ3IoKtoS8QTP3j/Cwz0hevmJwDdAJZbC4=; b=VpAw5+cT6zgNRbIxZL+/jHBPm/KZ5do9ByQuKy4u0AusFzhqE+N9tjfA6AJznwX1Qe DS1tKlDJJtakxQOEj/zVp9OZTEihJtyguZ6lJ6RS/dNG0GhCdVulzBGomGfjgrVXP0AR AODYT/yM+w+V9A2ZetFT0l0EOUDdaQoK+H291B4H4DlkgO1w46z4rlC8TkFirFcB3EVe eZsZDfrv19q5sbNChXer3lXakMWLLD2EIOwirDHPOUP53Xl37v2fEQzSZgx6ghnDDkAT AlwigDFoaIAemXLd1BA1zeCu7LqQsAu/JzyujCPjdAa18spQIhDmE2BWWStPTN5eK4Eq Hx3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708892923; x=1709497723; 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=LQhObH8iYYJ3IoKtoS8QTP3j/Cwz0hevmJwDdAJZbC4=; b=Huy3hqKMzZYQ/K/VqDz1k3YYpvxlXyEIZdOCIzToUY4RPwpxwG8uNkTjmvlt/8VuUY EL07q5R65/9cErnOhiwlkQwLbt59kk4loYHjS8EFLw8SvZOZUZdmqcmUD8pDALB2cmFn YdX3AAxu962tZW4Pt+00voRG13hWv8OjMPluU38bohVCQgUhqHQE3zep8N07VZ/4VQym vagzgSJpLVdENeJAo6oVU4DsOjOBxc4B3jxE8csfcXVoU+4Vmo6G9NeDe7ptvb3UcfA+ Hzt1OjMwQWGampGCYMIAA3yY2pf8+khck0UXMDueXb5NlHZZkQ0Qjm8XkO0zXCb7rpAI 8qMQ== X-Forwarded-Encrypted: i=1; AJvYcCUreN9yxs9haESRSopf1geZAGHocJfLfYDMeiDmQuJL4LCqhL4tPGgPmkMfRBaTwVZOxvAZ99cMkeMuip5J3Qvm73auK/uMt/Eq0mq9 X-Gm-Message-State: AOJu0Yznwj9k5K4EjGs3gBndQyWFtQ9o64xdVgQkWfE9EKAYUH8BRiM7 CXCj1wk3SXrqrSfgpQqfnPbUAL934+XssjvL3JvJQjysL7Vksc6g7AIKCSKqI0tTgh9JW1AX7g+ u X-Received: by 2002:a17:906:34cd:b0:a3f:870:535c with SMTP id h13-20020a17090634cd00b00a3f0870535cmr3158316ejb.44.1708892923547; Sun, 25 Feb 2024 12:28:43 -0800 (PST) Received: from krzk-bin.. ([178.197.222.116]) by smtp.gmail.com with ESMTPSA id wb5-20020a170907d50500b00a3e48782f08sm1762249ejc.27.2024.02.25.12.28.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 25 Feb 2024 12:28:43 -0800 (PST) From: Krzysztof Kozlowski To: Jean Delvare , Guenter Roeck , linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Krzysztof Kozlowski Subject: [PATCH] hwmon: sis5595: drop unused DIV_TO_REG function Date: Sun, 25 Feb 2024 21:28:41 +0100 Message-Id: <20240225202841.60740-1-krzysztof.kozlowski@linaro.org> X-Mailer: git-send-email 2.34.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1791904136839058376 X-GMAIL-MSGID: 1791904136839058376 'DIV_TO_REG' function is not used: sis5595.c:159:18: error: unused function 'DIV_TO_REG' [-Werror,-Wunused-function] Signed-off-by: Krzysztof Kozlowski --- drivers/hwmon/sis5595.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/drivers/hwmon/sis5595.c b/drivers/hwmon/sis5595.c index 641be1f7f9cd..e73b1522f3ce 100644 --- a/drivers/hwmon/sis5595.c +++ b/drivers/hwmon/sis5595.c @@ -153,13 +153,9 @@ static inline s8 TEMP_TO_REG(long val) } /* - * FAN DIV: 1, 2, 4, or 8 (defaults to 2) - * REG: 0, 1, 2, or 3 (respectively) (defaults to 1) + * FAN DIV: 1, 2, 4, or 8 + * REG: 0, 1, 2, or 3 (respectively) */ -static inline u8 DIV_TO_REG(int val) -{ - return val == 8 ? 3 : val == 4 ? 2 : val == 1 ? 0 : 1; -} #define DIV_FROM_REG(val) (1 << (val)) /*