Received: by 2002:a05:7412:40d:b0:e2:908c:2ebd with SMTP id 13csp1007677rdf; Wed, 22 Nov 2023 03:12:08 -0800 (PST) X-Google-Smtp-Source: AGHT+IHRdB2reLONw5eCPHcz0ju7a0fOqRE/0uDZ9Xiy0fVsXoS/IAiD1FI4sjypkqGc0vIZwVpo X-Received: by 2002:a17:903:11ce:b0:1cc:4985:fc04 with SMTP id q14-20020a17090311ce00b001cc4985fc04mr2022378plh.66.1700651528227; Wed, 22 Nov 2023 03:12:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700651528; cv=none; d=google.com; s=arc-20160816; b=GurrH9lX87pXTwPSOi3S5Ghv5rwoaSbWuav9w//wOcd0ESgCCXgZIi2PzO4Xd7CSwD +toBEHaTj2NgJ7QtEFMHjIZUwD9xMOupjt5uduIla2SPI61tw4aa+/Yh/55/CvdsNsYj 2UGgIhGjsgn3Sgeft1xJfjm+BK51KLOOH+9Fuj5tFwywSMbqnvcwWuKuJ3GKJJJqawsr Wwma2HhJKbMQyAGuDv6vgBYI8GgHp9W9X4xGz6NJQzakzJKakwP4PTf71nerTAkzV2CL tL1pEVIYEE80EA1Eu1RNves3UMTkrHR+A6rfsHxF/CFhMZgj6giXrfdFNxfVjVunYuGv +n1A== 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=SF73QAC/bwJ0l7oz/xPOVAHdtHihf2dEhBkiPpby2qc=; fh=OahkkZGRMsx/QsvTzHLvmCoK5Fz3HImW7eii1n0wrVw=; b=SFHYQyD5BcNOMqarluWVUt+6JlvVp1IqJOGGQD+uWqyTqwOymZ7XB8Z5xXeMxj37eq 3rv0QjrRIhzBzfUsiY5rSBjmLhlPvugiL9C+5QcW2SD1el0u7VPXmHPMcCr37SetWvsL TGZ+Q667xRS54FWumf4imXKzsYzrmP5BxhuLiSJ8Xe/X80reW8rPqZKkLk3RiXxwtMn5 0BBod1CX0hRfCRq+aQOD0V25Ctt66KlwXsJGQeU/tmHRvg19Ouqp7ICPoSaXT+67mRK7 pxWMdiUen+xzScXI1uT2H2kECLI2E22lL4TrCmaaxQVZQ/sQGguXsdMgAxWKC6Ip0brf cmCA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@microchip.com header.s=mchp header.b=vwdiwioZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=microchip.com Return-Path: Received: from fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id w15-20020a170902e88f00b001cc5f51b1ecsi12733087plg.347.2023.11.22.03.12.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Nov 2023 03:12:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; dkim=pass header.i=@microchip.com header.s=mchp header.b=vwdiwioZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=microchip.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id EF91D81BFBB8; Wed, 22 Nov 2023 03:12:04 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234138AbjKVLLi (ORCPT + 99 others); Wed, 22 Nov 2023 06:11:38 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35896 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229714AbjKVLLg (ORCPT ); Wed, 22 Nov 2023 06:11:36 -0500 Received: from esa.microchip.iphmx.com (esa.microchip.iphmx.com [68.232.154.123]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4FF8ED8; Wed, 22 Nov 2023 03:11:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1700651493; x=1732187493; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=bqZy+15bGo0cAdv3T10s82WMPZ8WYesT6PFaGMF8gZQ=; b=vwdiwioZydBIWvwyyGiELvkWNuiTRl3OPS/tCKiaN184v4a2H6UHnZxg MIX0mMwJwYUYHy29D0/+ABKMlgigIvMeCy9YYde3bDIXykmn8ZgVa0kPJ kCLXnLhSyPO46FoaRozaH1LPnIommQWOtFDjJs4LtIzCRkVKtHJDt9PzD yHARgDmbntFu2r7FgPcja13euXuo23d+t4S26jawGMeNcxRZ2qj1dpKns F4XRe89hHjMkxWRBXQpcW7TF4ipGNEiuOLDFsUzp5O26+klcWzUGcm+ud LDi0jtSMS3m/G7Y0emfgUE5kvmgG/5ZHqm7Bb6Yu4+zYbQdELhY66WTuG A==; X-CSE-ConnectionGUID: pzcGjbUNQWmjzz0egclpxw== X-CSE-MsgGUID: AdC0IIYsSDao5AmsIV7zzw== X-ThreatScanner-Verdict: Negative X-IronPort-AV: E=Sophos;i="6.04,218,1695711600"; d="scan'208";a="179248509" X-Amp-Result: SKIPPED(no attachment in message) Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa6.microchip.iphmx.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 22 Nov 2023 04:11:32 -0700 Received: from chn-vm-ex03.mchp-main.com (10.10.85.151) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.21; Wed, 22 Nov 2023 04:11:10 -0700 Received: from marius-VM.mshome.net (10.10.85.11) by chn-vm-ex03.mchp-main.com (10.10.85.151) with Microsoft SMTP Server id 15.1.2507.21 via Frontend Transport; Wed, 22 Nov 2023 04:11:08 -0700 From: To: , , , CC: , , Subject: [PATCH v1] iio: adc: MCP3564: fix hardware identification logic Date: Wed, 22 Nov 2023 13:11:06 +0200 Message-ID: <20231122111106.45288-1-marius.cristea@microchip.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Wed, 22 Nov 2023 03:12:05 -0800 (PST) From: Marius Cristea In mcp3564_config() fix the hardware identification logic based on the hardware ID registers. Second part of the code was disabled by an logic error. Fix a typo related to the "MODULE_DESCRIPTION". Signed-off-by: Marius Cristea --- drivers/iio/adc/mcp3564.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/iio/adc/mcp3564.c b/drivers/iio/adc/mcp3564.c index e3f1de5fcc5a..e914a885a868 100644 --- a/drivers/iio/adc/mcp3564.c +++ b/drivers/iio/adc/mcp3564.c @@ -1122,7 +1122,7 @@ static int mcp3564_config(struct iio_dev *indio_dev) enum mcp3564_ids ids; int ret = 0; unsigned int tmp = 0x01; - bool err = true; + bool err = false; /* * The address is set on a per-device basis by fuses in the factory, @@ -1509,5 +1509,5 @@ static struct spi_driver mcp3564_driver = { module_spi_driver(mcp3564_driver); MODULE_AUTHOR("Marius Cristea "); -MODULE_DESCRIPTION("Microchip MCP346x/MCP346xR and MCP356x/MCP346xR ADCs"); +MODULE_DESCRIPTION("Microchip MCP346x/MCP346xR and MCP356x/MCP356xR ADCs"); MODULE_LICENSE("GPL v2"); base-commit: 6543f376ec8aa90a6c1ed44b765f4f0d6c3eb1db -- 2.34.1