Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp829156pxu; Mon, 23 Nov 2020 05:22:22 -0800 (PST) X-Google-Smtp-Source: ABdhPJzV1UuM8seOgASoHLGEStyPIyjZZaBnZh4hfEWj97aPq+DodW4lVBbKE+AOeYxD38Jk/Gxi X-Received: by 2002:a05:6402:54d:: with SMTP id i13mr49358603edx.3.1606137741913; Mon, 23 Nov 2020 05:22:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606137741; cv=none; d=google.com; s=arc-20160816; b=uG6v3IjNIHV1PcvraBQogY5FD+b+TBrn9Wx7l+pUWpuR1xrzoEhI/40HBOt468Wfyk 1ZVxLDDpjdSEZcQFhiKLtWtJ8L2ovGiYzZv2PPJksPKo/6Mpp5Mlp7c4WdgURKNCGHQV DWFFtJgJX56RLkbJHRsieDJ8chsRDffymhP6+MRxJkbgytQYZteSqIl75/UM3en98gk8 +OuXlYIWhxd7zukIIlhjzgOhs5VBP2kh1iLvrryM+OhEw07EuSZJrgySs6S7kcIXhPsR Oai5jjAGyiBe73gfcKOh61CARgVHPhaYarrjk+2WjTwWw4O6IqKFj4s0SauVYk2r8Wki HupA== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=QiDERs2t7hsLTpf1kpkw+k2vZkIJPdMR5n/Q3bLlweI=; b=lGql+et9zhgf0OuF1823dWHw6D2/YgXsTlS1yu+T88Y67IhoFFhnDFP5iTk3gwLWjG nyNVFyA8DHLDLwe1Q83f5vEKfGEiD63cGmTzUpAaQxBRlIkYQjZXWi30+Pg2sMv4yi4D 9oGDxYxC9PSgTecQ/MnKCZHz7tQt2ywQ04aStzdyQBGZMoBv22uOZ9hi5O8Z3f2hupUE gy0W+D6tUeIsangMdsn4tHvR0dDEL6mbXHYtdkCEu9BA5EvbQmFsioUuCM+E+3EBcCv4 te9G0uQwPm8zEqzSt/6Kc0NzAv2xRSyUORiCZnSRKexNnfUfY+Ttoa/EZ1hLXrWyFllM fdVQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=OuUmrSrb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g5si6951626ejb.287.2020.11.23.05.21.58; Mon, 23 Nov 2020 05:22:21 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=OuUmrSrb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732369AbgKWMjy (ORCPT + 99 others); Mon, 23 Nov 2020 07:39:54 -0500 Received: from mail.kernel.org ([198.145.29.99]:52622 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732338AbgKWMjt (ORCPT ); Mon, 23 Nov 2020 07:39:49 -0500 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 1A836208DB; Mon, 23 Nov 2020 12:39:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1606135188; bh=H9uK/2MhtcSMf/LlP7tZgmppFmP/4GMIrxIkEpiOGQg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=OuUmrSrb199uxElUZzNJX2uICymqVdUas2uh0eykYh2SfU7QUG5rRh4d2mKuEKXrM eaHu0BsXwxSNuUUh3UvYiGnqMuFbBh5lwMR1arCsvDXrD3pd+TFLQSxq48oOGAYuDm ZM2E6CJvT07gbgeW2VNrrhjfKlpzxVE0m5/n85S8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Sean Nyekjaer , Mark Brown Subject: [PATCH 5.4 137/158] regulator: pfuze100: limit pfuze-support-disable-sw to pfuze{100,200} Date: Mon, 23 Nov 2020 13:22:45 +0100 Message-Id: <20201123121826.538738599@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201123121819.943135899@linuxfoundation.org> References: <20201123121819.943135899@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Sean Nyekjaer commit 365ec8b61689bd64d6a61e129e0319bf71336407 upstream. Limit the fsl,pfuze-support-disable-sw to the pfuze100 and pfuze200 variants. When enabling fsl,pfuze-support-disable-sw and using a pfuze3000 or pfuze3001, the driver would choose pfuze100_sw_disable_regulator_ops instead of the newly introduced and correct pfuze3000_sw_regulator_ops. Signed-off-by: Sean Nyekjaer Fixes: 6f1cf5257acc ("regualtor: pfuze100: correct sw1a/sw2 on pfuze3000") Cc: stable@vger.kernel.org Link: https://lore.kernel.org/r/20201110174113.2066534-1-sean@geanix.com Signed-off-by: Mark Brown Signed-off-by: Greg Kroah-Hartman --- drivers/regulator/pfuze100-regulator.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) --- a/drivers/regulator/pfuze100-regulator.c +++ b/drivers/regulator/pfuze100-regulator.c @@ -833,11 +833,14 @@ static int pfuze100_regulator_probe(stru * the switched regulator till yet. */ if (pfuze_chip->flags & PFUZE_FLAG_DISABLE_SW) { - if (pfuze_chip->regulator_descs[i].sw_reg) { - desc->ops = &pfuze100_sw_disable_regulator_ops; - desc->enable_val = 0x8; - desc->disable_val = 0x0; - desc->enable_time = 500; + if (pfuze_chip->chip_id == PFUZE100 || + pfuze_chip->chip_id == PFUZE200) { + if (pfuze_chip->regulator_descs[i].sw_reg) { + desc->ops = &pfuze100_sw_disable_regulator_ops; + desc->enable_val = 0x8; + desc->disable_val = 0x0; + desc->enable_time = 500; + } } }