Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp7027541ybi; Mon, 22 Jul 2019 05:58:52 -0700 (PDT) X-Google-Smtp-Source: APXvYqyM2c8pKS3g3NgAADfFxcOqSxJ0xPB72RAzoev+mzLQmH3aV4ZzNYeL0vJd7pjyt1CPJrZO X-Received: by 2002:a17:90a:1b48:: with SMTP id q66mr73779461pjq.83.1563800331983; Mon, 22 Jul 2019 05:58:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1563800331; cv=none; d=google.com; s=arc-20160816; b=bVoZ+rc/BcmPdj7pO8XTe/he3dmJuOojeI4+MT9EC5nwvkiYyB3PL35julZaTP6kKh dU/Geelyk2NM6a5u0m/LfUGdbrdEPXz+FY4lo6CWl7pjf3o00UjSWRyF0t2Ow6XwFRxq +FXlwTtx6D3zfgnJL8dJjofPrSptnlInKNAG3Vrzbc1MHGJlOveNe6YYUNtW7ymnUYr1 a1vwcheJUeJDbU0k3pJUlt9QRCxjfUFoaYrcU3izLDM/Cbi1SYnXXOp7fyRpJW/3TrHn WDpPjzF8vDyNX4amM1irnNUoKVq62h6uYPmG1TYD5PVEgZIJVTYeuyLbWhxhJYlohV4H fkzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:message-id:in-reply-to:subject:cc:to :from:dkim-signature; bh=1YYrtFyJ0Ttd+Xvk2FDy/peCTQJ9kNEyVkmLdHZHaaw=; b=WdiEf93UWbgnAqfd2Cr/o5wqkH/emk2a7e2vBxyIxA8QAztUskgZJyR8g6mFS6HntZ ntYAUzfinf3juiAh0OaFCtuKUolUT3fr05j1iUsRAn4WjG/Tb92mbwZ9nh0CkOedXJkJ eivJcbydIC4JPP6Jj/L/nL8Iqtj0V7l3hYTgQLVlJAGUDxGiTQoMX7dZbIuMYAOWltyM Zql5Enctodq4pGcEq6QFVs+Fu2BH7aftNtT9YeGP3J+elMwtycZJhv7S6rYiRt/Qf1+x Z05ueWp5PkUyg9RQldbe/rH+rir9Ksg2BTy81MIFqgJnjKth88q98sfbEsRH9KU0KHMZ CEpQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=GNzBsxDE; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 85si13846286pgb.583.2019.07.22.05.58.35; Mon, 22 Jul 2019 05:58:51 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=GNzBsxDE; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730403AbfGVMXG (ORCPT + 99 others); Mon, 22 Jul 2019 08:23:06 -0400 Received: from heliosphere.sirena.org.uk ([172.104.155.198]:58692 "EHLO heliosphere.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730262AbfGVMWU (ORCPT ); Mon, 22 Jul 2019 08:22:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sirena.org.uk; s=20170815-heliosphere; h=Date:Message-Id:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References: List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner: List-Archive; bh=1YYrtFyJ0Ttd+Xvk2FDy/peCTQJ9kNEyVkmLdHZHaaw=; b=GNzBsxDEPi6a xf9G6VnPq18D+IFFzeNvK+3XopxYY/oi5xJEomTbe5BEZrOG9l1lQ2nXvivuRnRVkFgLMZ4gFWaFV oZI/RBCQ8QJYngoR6l9HLqJQ8csD+UMJk4Sq1IRiGo0CL79BYlbM1H/DFU8/ypDZx7/QKTyeou7Zl eileM=; Received: from cpc102320-sgyl38-2-0-cust46.18-2.cable.virginm.net ([82.37.168.47] helo=ypsilon.sirena.org.uk) by heliosphere.sirena.org.uk with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1hpXKa-0007fa-Dq; Mon, 22 Jul 2019 12:22:16 +0000 Received: by ypsilon.sirena.org.uk (Postfix, from userid 1000) id D4340274046A; Mon, 22 Jul 2019 13:22:15 +0100 (BST) From: Mark Brown To: Axel Lin Cc: Dan Murphy , Liam Girdwood , linux-kernel@vger.kernel.org, Mark Brown , Milo Kim Subject: Applied "regulator: lm363x: Fix n_voltages setting for lm36274" to the regulator tree In-Reply-To: <20190626132632.32629-2-axel.lin@ingics.com> X-Patchwork-Hint: ignore Message-Id: <20190722122215.D4340274046A@ypsilon.sirena.org.uk> Date: Mon, 22 Jul 2019 13:22:15 +0100 (BST) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The patch regulator: lm363x: Fix n_voltages setting for lm36274 has been applied to the regulator tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-5.4 All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark From 962f170d9344e5d9edb3903971c591f42d55e226 Mon Sep 17 00:00:00 2001 From: Axel Lin Date: Wed, 26 Jun 2019 21:26:32 +0800 Subject: [PATCH] regulator: lm363x: Fix n_voltages setting for lm36274 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit According to the datasheet http://www.ti.com/lit/ds/symlink/lm36274.pdf: Table 23. VPOS Bias Register Field Descriptions VPOS[5:0]: VPOS voltage (50-mV steps): VPOS = 4 V + (Code × 50 mV), 6.5 V max 000000 = 4 V 000001 = 4.05 V : 011110 = 5.5 V (Default) : 110010 = 6.5 V 110011 to 111111 map to 6.5 V So the LM36274_LDO_VSEL_MAX should be 0b110010 (0x32). The valid selectors are 0 ... LM36274_LDO_VSEL_MAX, n_voltages should be LM36274_LDO_VSEL_MAX + 1. Similarly, the n_voltages should be LM36274_BOOST_VSEL_MAX + 1 for LM36274_BOOST. Fixes: bff5e8071533 ("regulator: lm363x: Add support for LM36274") Signed-off-by: Axel Lin Link: https://lore.kernel.org/r/20190626132632.32629-2-axel.lin@ingics.com Signed-off-by: Mark Brown --- drivers/regulator/lm363x-regulator.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/regulator/lm363x-regulator.c b/drivers/regulator/lm363x-regulator.c index e4a27d63bf90..4b9f618b07e9 100644 --- a/drivers/regulator/lm363x-regulator.c +++ b/drivers/regulator/lm363x-regulator.c @@ -36,7 +36,7 @@ /* LM36274 */ #define LM36274_BOOST_VSEL_MAX 0x3f -#define LM36274_LDO_VSEL_MAX 0x34 +#define LM36274_LDO_VSEL_MAX 0x32 #define LM36274_VOLTAGE_MIN 4000000 /* Common */ @@ -226,7 +226,7 @@ static const struct regulator_desc lm363x_regulator_desc[] = { .of_match = "vboost", .id = LM36274_BOOST, .ops = &lm363x_boost_voltage_table_ops, - .n_voltages = LM36274_BOOST_VSEL_MAX, + .n_voltages = LM36274_BOOST_VSEL_MAX + 1, .min_uV = LM36274_VOLTAGE_MIN, .uV_step = LM363X_STEP_50mV, .type = REGULATOR_VOLTAGE, @@ -239,7 +239,7 @@ static const struct regulator_desc lm363x_regulator_desc[] = { .of_match = "vpos", .id = LM36274_LDO_POS, .ops = &lm363x_regulator_voltage_table_ops, - .n_voltages = LM36274_LDO_VSEL_MAX, + .n_voltages = LM36274_LDO_VSEL_MAX + 1, .min_uV = LM36274_VOLTAGE_MIN, .uV_step = LM363X_STEP_50mV, .type = REGULATOR_VOLTAGE, @@ -254,7 +254,7 @@ static const struct regulator_desc lm363x_regulator_desc[] = { .of_match = "vneg", .id = LM36274_LDO_NEG, .ops = &lm363x_regulator_voltage_table_ops, - .n_voltages = LM36274_LDO_VSEL_MAX, + .n_voltages = LM36274_LDO_VSEL_MAX + 1, .min_uV = LM36274_VOLTAGE_MIN, .uV_step = LM363X_STEP_50mV, .type = REGULATOR_VOLTAGE, -- 2.20.1