Received: by 2002:a05:7412:f690:b0:e2:908c:2ebd with SMTP id ej16csp491105rdb; Thu, 19 Oct 2023 09:57:53 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGOUAdodDF9zzdImxk/s/A0Rwnu+gscL+PKOsEOzdd9a1OVxMy1q780AF+aw/bx++Tj9LIA X-Received: by 2002:a17:903:2344:b0:1b8:8b72:fa28 with SMTP id c4-20020a170903234400b001b88b72fa28mr3587879plh.58.1697734672957; Thu, 19 Oct 2023 09:57:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697734672; cv=none; d=google.com; s=arc-20160816; b=J9atontZsJD8li8x46Agge+gcdDP0ivxiZ1lOz/941qTJOmvDJHBiTH3+j3jX3f5r8 zN+wks7dUPr+O09BTdAgGwu2yJ8bCcYRzoE8AjhzXsC4kRjYr4Wvf7nxTRR5txSd6P9t HFXWVDylCrSqp5sMk06+K+Kp1yhhfmlEim/vXYx7xS/ZE+V9xupqdSLHa2b+q6V6J8vy KOIyZP/LQwcrierqUUg+xVUQmcbInnDRHUUITk8T4YDoa52cGqzKRpToqZWgHeX95p+c bpbAaaSVyduicWTuxtYNLZtQTdt0PjsUVhcrTFklT+GZhuzOKq3U3gzekqzxRc2uzy5K eQdw== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=kpauOqhIBiI0EJ6iUwx8+m/VZa+TC127yYLjxQtimLs=; fh=d6XH3dt5H0c+4wnwIk/8KA2kgFbVz8WdE7bZpO88hdM=; b=Da7S30bYTT6WiuwkvYWNTagR/62NbAyWjFat6GvKL4WmH8AtyVTuj2LdOjoYQYknK5 q71gzsj5G6XF7amEwQnuN4VXDwiJK+14G4pLAr6cuz4poUQoVAEa3OCRw+r3SUDndYeA WKxhylMpo8ltgZTPrRQDv4qkI3pN0fHA8xb74UHvaOU7qEYVJQbDrwKll6rP3oACMksk BJAnMRyYH58mrea7MzcdOPAnCr8TRm5wpBtDDkr8SKKcgGbmSbVGexiTisxEFFPl6jMQ w+ENZrDvb0MfkIn6cpwyGvGgvtaYhnt/VLlHQgxAadS4C2ebHTB/RohNJMnJtWCMDvYb tX8Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@xff.cz header.s=mail header.b=XrrzEBxq; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=xff.cz Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id a18-20020a170902ecd200b001bf5c12ea06si2644647plh.404.2023.10.19.09.57.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Oct 2023 09:57:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@xff.cz header.s=mail header.b=XrrzEBxq; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=xff.cz Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id AD1E0826C0F0; Thu, 19 Oct 2023 09:57:51 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345324AbjJSQ5q (ORCPT + 99 others); Thu, 19 Oct 2023 12:57:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56936 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235455AbjJSQ5k (ORCPT ); Thu, 19 Oct 2023 12:57:40 -0400 Received: from vps.xff.cz (vps.xff.cz [195.181.215.36]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0940013A; Thu, 19 Oct 2023 09:57:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=xff.cz; s=mail; t=1697734656; bh=07aDVsUy5RsQxnmnnN1afCwYsv5zVhLjMtrYunUCVWI=; h=From:To:Cc:Subject:Date:References:From; b=XrrzEBxqrJI2NUBKVQBiqsjqdRYhqAG5OeZXouIUqBKS+k565hXPquw7WL+pyGsan mMtNeSjULHISu2/snIV97Edi63AdqjD6FDWT4C1/BRGkpUF1QmZdVel5k80kHLvBBh hx6fQWpz9SnzWWn3yq+/Pc2c2BkGPVexbn751Oj8= From: =?UTF-8?q?Ond=C5=99ej=20Jirman?= To: Lee Jones , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Heiko Stuebner Cc: Ondrej Jirman , Sebastian Reichel , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [RESEND PATCH v3 4/4] mfd: rk8xx: Add support for RK806 power off Date: Thu, 19 Oct 2023 18:57:26 +0200 Message-ID: <20231019165732.3818789-5-megi@xff.cz> In-Reply-To: <20231019165732.3818789-1-megi@xff.cz> References: <20231019165732.3818789-1-megi@xff.cz> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net 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 (snail.vger.email [0.0.0.0]); Thu, 19 Oct 2023 09:57:52 -0700 (PDT) From: Ondrej Jirman Use DEV_OFF bit to power off the RK806 PMIC, when system-power-controller is used in DTS. Signed-off-by: Ondrej Jirman Reviewed-by: Sebastian Reichel --- drivers/mfd/rk8xx-core.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/mfd/rk8xx-core.c b/drivers/mfd/rk8xx-core.c index a50a181b18e9..c47164a3ec1d 100644 --- a/drivers/mfd/rk8xx-core.c +++ b/drivers/mfd/rk8xx-core.c @@ -525,6 +525,10 @@ static int rk808_power_off(struct sys_off_data *data) reg = RK805_DEV_CTRL_REG; bit = DEV_OFF; break; + case RK806_ID: + reg = RK806_SYS_CFG3; + bit = DEV_OFF; + break; case RK808_ID: reg = RK808_DEVCTRL_REG, bit = DEV_OFF_RST; -- 2.42.0