Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp1832359pxa; Sun, 2 Aug 2020 23:25:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxUiiNxni57FvcR2hPWLq+tvCZnUHkESS2GezkmMwP91eCzD9vrYOmUQ0yGZV1mG0TC4ujg X-Received: by 2002:a17:907:100f:: with SMTP id ox15mr15856013ejb.125.1596435910954; Sun, 02 Aug 2020 23:25:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596435910; cv=none; d=google.com; s=arc-20160816; b=tKJdmUXYTXkjpcaE0XbF66fN73dKQoC/TArkncPCQ0unqsegDddWFKWlUHkvjql7C6 HPg/7ag4MBs33bseIOCI/Z3afrDNP+VseIyyQwzZJZcCp4bpzSph4Ce1LZIkBigT5Sns vqnVV1dKvfTnXd94yzm5XskbBGSogbBUmX2TReeMMwcli4PCx9HC0WTWnCTB/n0tGyAt Z4ba4uRcIxvrfqW0mQSrqdJioHOGf8Guq3/zmYhrt3cbHBZCcbEP/iLxhbZIskpjvwU7 jkeLgMdYywo8TLNF0JZg9rv0j649ru0O1lQ/S7RsgD5n0aYh9WFyFvLqtqWWKjJobICD e7/g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=fKJAJQVfxmdAr8Fx0IAfMXtGgSuSubjw5SgTjtIYFEc=; b=C30HqYm0wIz1mwwwybfECF0VW1tsi0i3reipC5ZBW7ikgcrAwDsx0nuydwx3uo2KF0 i8Fkdq4c7gUwJ69po9QPRhTejAmGgS3OJnYg0K2X7be2D+ATG8GrMkUITIkeBS0en61Y mtCrmZ+ASgnxYBUzbbnHxidR5pPMakjvqUmRja5ZVjRITwjTabfzfALliNR0HurRHkh0 HU5tlJ612wRzYPTkwJ+cskXrMoDhYTAn7PH2siPBxEnk0NiN4EZhDD81+WcbNR8p8Txs Qq/2/8ECt9UmL4us6zkJPgTMZWE1PwEE3d4xw/L6q1PblCBeKZkNOVCHZmCTQb4UlcsD pS9g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=e1yeVrtc; 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=mediatek.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id pv15si9749112ejb.596.2020.08.02.23.24.49; Sun, 02 Aug 2020 23:25:10 -0700 (PDT) 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=@mediatek.com header.s=dk header.b=e1yeVrtc; 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=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728337AbgHCGRS (ORCPT + 99 others); Mon, 3 Aug 2020 02:17:18 -0400 Received: from mailgw02.mediatek.com ([210.61.82.184]:26863 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1728308AbgHCGRQ (ORCPT ); Mon, 3 Aug 2020 02:17:16 -0400 X-UUID: 94d591465c1c47f08c5a371fb3fdfdc5-20200803 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=fKJAJQVfxmdAr8Fx0IAfMXtGgSuSubjw5SgTjtIYFEc=; b=e1yeVrtcOVvjTgTLTcXp0p0KP6uQqyFoHvMg5beo0YAFijG3dB7JpTgdH0ni0PBPHptE/n3rTvHZnjS70qbcSJaDVeHq6Kr8fDzBJX0LN8W1ZniyIwxvBDzFvpUX9Lz+B9U4ciWWbb3XP5TmtaARFqEnKqDvEBfsZYxVN0x9PnY=; X-UUID: 94d591465c1c47f08c5a371fb3fdfdc5-20200803 Received: from mtkcas11.mediatek.inc [(172.21.101.40)] by mailgw02.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.10 Build 0809 with TLS) with ESMTP id 1591615903; Mon, 03 Aug 2020 14:17:14 +0800 Received: from mtkcas07.mediatek.inc (172.21.101.84) by mtkmbs02n1.mediatek.inc (172.21.101.77) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Mon, 3 Aug 2020 14:17:11 +0800 Received: from localhost.localdomain (10.17.3.153) by mtkcas07.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Mon, 3 Aug 2020 14:17:12 +0800 From: Crystal Guo To: , , CC: , , , , , , , , , Crystal Guo Subject: [v2,5/6] reset-controller: ti: Introduce force-update method Date: Mon, 3 Aug 2020 14:15:10 +0800 Message-ID: <20200803061511.29555-6-crystal.guo@mediatek.com> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20200803061511.29555-1-crystal.guo@mediatek.com> References: <20200803061511.29555-1-crystal.guo@mediatek.com> MIME-Version: 1.0 Content-Type: text/plain X-MTK: N Content-Transfer-Encoding: base64 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org SW50cm9kdWNlIGZvcmNlLXVwZGF0ZSBtZXRob2QgZm9yIGFzc2VydCBhbmQgZGVhc3NlcnQgaW50 ZXJmYWNlLA0Kd2hpY2ggZm9yY2UgdGhlIHdyaXRlIG9wZXJhdGlvbiBpbiBjYXNlIHRoZSByZWFk IGFscmVhZHkgaGFwcGVucw0KdG8gcmV0dXJuIHRoZSBjb3JyZWN0IHZhbHVlLg0KDQ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