Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp2935702imm; Mon, 10 Sep 2018 08:31:40 -0700 (PDT) X-Google-Smtp-Source: ANB0VdaJRilpbwW3J0lGn/iUsnH3XoaoR/6IIsCl1AOdWFJ7TFLe3BCHLwE3Za24DfUrferVjJmn X-Received: by 2002:a63:3741:: with SMTP id g1-v6mr23515346pgn.59.1536593500185; Mon, 10 Sep 2018 08:31:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536593500; cv=none; d=google.com; s=arc-20160816; b=cOw9qKOGWlQdNthN+nqw7xff4f84C6T9h4/j5cyH56XMNK4xcGhwUoMubzsvo1dzhV CjWBqRGT0qm8G28OJFbGPTA39RtiSEqCGR7M9DklufeEP+TjKlLI84xepWSs9117DE5z zJkf7onZMEm1egomouKZLGdFHSnWx6NMoXh53ycZ0khudqE4NEvaPCqq7nuLkQ8/L2Dq oLHvD+c2atsqwDmfIQnOwVSWNTwhb7vCzWGLtCMbAWuDWOWCZBc93V4dkwldss8ddXml oY2ega35ixDWLyirC6pAVocgGGLZM3TNILC4UYRcb9K9E8wCw0BUJCerLjK9zQ4UlNl7 GbKw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=tEPdszxPXWbNgLdLMDMVxDSC1PkpW9oQ4oEAOSABt1s=; b=jMJM3eWTpAEpy4UBT4OulUQVxO4vO2Ahe+q0YAGEBXgIYyHTMR6gjvZt6II3K3ibyc lxPjYFL1CvbgPXrJ2ffwnBEJSZkrcea6Ho5bP5jR968yx9+Vio5ZcfGYeHAIz52EKcvo 1YQiFyh5eMPp0H665qfxRn/wZz/I8SBMDJ/sN0A5NCOVGzgJWNh1y4xDw5KV6WGjTJ1Q u/wP9pGsg/S4f6FP44mXThgeqDjavhX5dWdR0ziSFztn6uJFc6eX9bCJ6Oo7VW/af8gC cTAX4ydA4cSxTsyLxmSXstuxF/lGBdW1cK944IQiUsArZUPhUoJ8WYsOhhvZ+qk88Z5V 5Aig== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=fjPAdC7W; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g11-v6si18209326pgo.525.2018.09.10.08.31.25; Mon, 10 Sep 2018 08:31:40 -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=pass header.i=@linaro.org header.s=google header.b=fjPAdC7W; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728719AbeIJUXq (ORCPT + 99 others); Mon, 10 Sep 2018 16:23:46 -0400 Received: from mail-wm0-f65.google.com ([74.125.82.65]:51037 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727856AbeIJUXq (ORCPT ); Mon, 10 Sep 2018 16:23:46 -0400 Received: by mail-wm0-f65.google.com with SMTP id s12-v6so22027728wmc.0 for ; Mon, 10 Sep 2018 08:29:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=tEPdszxPXWbNgLdLMDMVxDSC1PkpW9oQ4oEAOSABt1s=; b=fjPAdC7WdU0eror5Pp9akLXaW4haJYwX7VrNr719OGKvPCyIweQLb8nHN5Kc6JeQDs ZPc9BzqOR1Eyt9X/Y6ba4bGO83ygktuFklJgP0c5HG1tWwoPZY0COtms4SpGORNNCBb6 wtVimiox252aycMGtmbCb4rUHveOxV4waJKMY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=tEPdszxPXWbNgLdLMDMVxDSC1PkpW9oQ4oEAOSABt1s=; b=Pwv8aYaO5TTTNyyNkBeEn5xDZrydwkkzvqs3zrM5S0finy+jVkacHXEhCZfdap9M/j oPkPsndApvEFx2+qxauV1E3R+Z2Ft59WRFgPDACNYkDPC3V29cc862aLcYlJkoIAJjVi qM2ejAdGEYLwvzj8tGwhHUvquJxZ0Zoz8xZWwtYEcPYYduo3P02gaJUsF5GNw8+b0Qay 2+FXI2P87HGJmA0fSuP+Z0GBY1ohIn0ywcw1CYfJ+r7xyD/ApGdvZng2APkGnVFTlfG8 JOEVT7OLEjdd3Hvq0fIT/d49CPLnIMkkvpwDo2yPESFlaEPzDWzYdu23TuhapKrcyMg9 clNQ== X-Gm-Message-State: APzg51AYY4UC00PLfLd+JRcP9m30vxQoQr/fF/hx1XlaeJjtyrTpUbtQ eXLXzpk1lgcyW4ha01LQJaHF8A== X-Received: by 2002:a1c:cc1a:: with SMTP id h26-v6mr1114871wmb.112.1536593347630; Mon, 10 Sep 2018 08:29:07 -0700 (PDT) Received: from dell ([2.27.167.7]) by smtp.gmail.com with ESMTPSA id t9-v6sm38922978wra.91.2018.09.10.08.29.06 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 10 Sep 2018 08:29:06 -0700 (PDT) Date: Mon, 10 Sep 2018 16:29:05 +0100 From: Lee Jones To: Fabio Estevam Cc: linux-kernel@vger.kernel.org, u.kleine-koenig@pengutronix.de, andrey.gusakov@cogentembedded.com, cphealy@gmail.com, Fabio Estevam Subject: Re: [PATCH] mfd: mc13xxx-core: Fix PMIC shutdown when reading ADC values Message-ID: <20180910152905.GB28860@dell> References: <1535486560-16267-1-git-send-email-festevam@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <1535486560-16267-1-git-send-email-festevam@gmail.com> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 28 Aug 2018, Fabio Estevam wrote: > From: Fabio Estevam > > When trying to read any MC13892 ADC channel on a imx51-babbage board: > > # cat /sys/class/hwmon/hwmon0/device/in7_input > > The MC13892 PMIC shutdowns completely. > > After debugging this issue and comparing the MC13892 and MC13783 > initializations done in the vendor kernel, it was noticed that the > CHRGRAWDIV bit of the ADC0 register was not being set. > > This bit is set by default after power on, but the driver was > clearing it. > > After setting this bit it is possible to read the ADC values correctly. > > Signed-off-by: Fabio Estevam > --- > drivers/mfd/mc13xxx-core.c | 3 ++- > include/linux/mfd/mc13xxx.h | 1 + > 2 files changed, 3 insertions(+), 1 deletion(-) Applied, thanks. -- Lee Jones [李琼斯] Linaro Services Technical Lead Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog