From patchwork Tue Aug 7 08:57:31 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: IKEGAMI Tokunori X-Patchwork-Id: 10558401 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 913C413BB for ; Tue, 7 Aug 2018 08:58:45 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7F28829B73 for ; Tue, 7 Aug 2018 08:58:45 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 730BB29B7C; Tue, 7 Aug 2018 08:58:45 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI,URIBL_SBL autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 11DE629B73 for ; Tue, 7 Aug 2018 08:58:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726414AbeHGLMD (ORCPT ); Tue, 7 Aug 2018 07:12:03 -0400 Received: from mail1.bemta24.messagelabs.com ([67.219.250.112]:17971 "EHLO mail1.bemta24.messagelabs.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727669AbeHGLMD (ORCPT ); Tue, 7 Aug 2018 07:12:03 -0400 Received: from [67.219.250.196] (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256 bits)) by server-1.bemta.az-b.us-west-2.aws.symcld.net id E1/61-15908-34F596B5; Tue, 07 Aug 2018 08:58:43 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFupnkeJIrShJLcpLzFFi42KZFv5DRNc5PjP aYMpJdov211sZHRg9Pm+SC2CMYs3MS8qvSGDN2DrhIUtBE1fFlnMnWRsYd3N0MXJxCAnMYZRY Onk3E4Tzk1Hi2fPJbF2MnBxsAqYS018tZASxRQRUJLasW8MMUsQssIpR4vuyA0wgCWEBT4k3b UfZQWwWAVWJvyd7WbsYOTh4BRwlenfVgYQlBOQlDr9pYgWxOQWcJC49bwObKQRU0nFlCQuErS nxvOc7I0irhECwxJdvdhMYeRcwMqxitEgqykzPKMlNzMzRNTQw0DU0NNI1NDbRNTKw0Eus0k3 SKy3WLU8tLtE10kssL9YrrsxNzknRy0st2cQIDBYGINjBePVQyiFGSQ4mJVHeIuXMaCG+pPyU yozE4oz4otKc1OJDjDIcHEoSvHpxQDnBotT01Iq0zBxg2MKkJTh4lER4t8YCpXmLCxJzizPTI VKnGI05/ryfOomZY1/3tEnMQix5+XmpUuK8tSCTBEBKM0rz4AbB4ukSo6yUMC8j0GlCPAWpRb mZJajyrxjFORiVhHmNQabwZOaVwO17BXQKE9Apb7TBTilJREhJNTCuZdW8dC3s5IVNk/IurtI otZXWK/ecf1Wt9UDq8xtnXkiu1v6z6I7v9jw7szcTn8oxLQtbpuD6k+H0NXPVSfqvX6/K2JrX E57w/V7EnxLuScYzzki3zFsnmyXQks9utGOdiKldQquszMOXpZNELXmCXsl9/Tgn+PuMNT6vU 9cmp1f931ah+HCdEktxRqKhFnNRcSIAHmChQaICAAA= X-Env-Sender: ikegami@allied-telesis.co.jp X-Msg-Ref: server-23.tower-344.messagelabs.com!1533632322!2726792!1 X-Originating-IP: [150.87.248.20] X-SYMC-ESS-Client-Auth: outbound-route-from=pass X-StarScan-Received: X-StarScan-Version: 9.9.15; banners=-,-,- X-VirusChecked: Checked Received: (qmail 22247 invoked from network); 7 Aug 2018 08:58:42 -0000 Received: from abricot-inet.allied-telesis.co.jp (HELO TKY-DS01.at.lc) (150.87.248.20) by server-23.tower-344.messagelabs.com with SMTP; 7 Aug 2018 08:58:42 -0000 Received: from swim-manx.rd.allied-telesis.co.jp ([150.87.21.50]) by TKY-DS01.at.lc with Microsoft SMTPSVC(8.0.9200.16384); Tue, 7 Aug 2018 17:58:41 +0900 Received: from ikegami-pc.rd.allied-telesis.co.jp by swim-manx.rd.allied-telesis.co.jp (AlliedTelesis SMTPRS 1.3 pl 1 ++E6B86F8C687C6288D9B5559052954DC9) with ESMTP id ; Tue, 7 Aug 2018 17:58:41 +0900 From: Tokunori Ikegami To: Jean Delvare Cc: Tokunori Ikegami , Guenter Roeck , Chris Packham , linux-hwmon@vger.kernel.org Subject: [PATCH 2/4] hwmon: (adt7475) Change valid parameter to bool type Date: Tue, 7 Aug 2018 17:57:31 +0900 Message-Id: <20180807085733.28756-3-ikegami@allied-telesis.co.jp> X-Mailer: git-send-email 2.16.1 In-Reply-To: <20180807085733.28756-1-ikegami@allied-telesis.co.jp> References: <20180807085733.28756-1-ikegami@allied-telesis.co.jp> X-OriginalArrivalTime: 07 Aug 2018 08:58:41.0919 (UTC) FILETIME=[D6E270F0:01D42E2C] Sender: linux-hwmon-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-hwmon@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Currently the valid paramter is char type but the type is not required. So change the parameter to boot type correctly. Signed-off-by: Tokunori Ikegami Cc: Guenter Roeck Cc: Chris Packham Cc: linux-hwmon@vger.kernel.org --- drivers/hwmon/adt7475.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/hwmon/adt7475.c b/drivers/hwmon/adt7475.c index 270cabb49677..5f03a93632c3 100644 --- a/drivers/hwmon/adt7475.c +++ b/drivers/hwmon/adt7475.c @@ -195,7 +195,7 @@ struct adt7475_data { unsigned long measure_updated; unsigned long limits_updated; - char valid; + bool valid; u8 config4; u8 config5; @@ -1780,6 +1780,7 @@ static struct adt7475_data *adt7475_update_device(struct device *dev) !data->valid) { adt7475_update_measure(dev); data->measure_updated = jiffies; + data->valid = true; } /* Limits and settings, should never change update every 60 seconds */ @@ -1787,7 +1788,7 @@ static struct adt7475_data *adt7475_update_device(struct device *dev) !data->valid) { adt7475_update_limits(dev); data->limits_updated = jiffies; - data->valid = 1; + data->valid = true; } mutex_unlock(&data->lock);