Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp1767213pxa; Sun, 2 Aug 2020 20:43:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyAgthjnIKu7Cws55bIHAbXeznICqXslFnCz/AXOlD+j9zgpUQxvQxJklGWxt278AVwpRCa X-Received: by 2002:a50:9fc9:: with SMTP id c67mr14227638edf.69.1596426202616; Sun, 02 Aug 2020 20:43:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596426202; cv=none; d=google.com; s=arc-20160816; b=YzkffJSaNEzlxQtuLnBHmazQvLely3wPnbf6HbqMgd4+4bnLbH2MbAqza2NZwoMVw+ aUFYFBiOiN+l4QW7oTlSMLk812Au2OM0Yb1kYxOGILLya2iarcxoOeq8sp1iYXFTLYOe rlrkECWufsx2Tw6BFLKpnwD0kNGfpkBbUQrTn5WU17VRBr2qKN7KhLMzVAIB4kcN9z9U NqZQnuGMFG0jGNSMTPbNnX6Fzm72kc1cQBRerJt0Dt6JVowfBjxE39aQaNihm7PcGzsR KQrOU5F1XQI/vfcnMmHbGl/uK32z/IQSHT/6EZdSUlGYZeOQgT2z1vQRpPT63uvVAGpN etIw== 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:date:cc:to:from:subject:message-id :dkim-signature; bh=m42oonF9rgHK7bYhLL7BB3uQil5O3aZLfSzxPT96WEM=; b=wwQc8AOBpAxSpgTaV3Bzy0KSVB8f34L8/CCcCGdRR3xJ4dG7xK+iovU5bV7LqxEmva dAkD8lmidaEZTAMt4MIw/OHULgw0V7xX5HJd0jfUsOLBcD23uxuH/1TF+Hi6yjYapqbQ IaqFhar8YmaV8aHykjGBVwTjCO3VKtSX9fPJLV5ZcXiMbBn7/G9BgwPneckpLeoxv8Mo Te/NmLGJ31di/VxJSp4BgjZHXAM20aLtF7uytfKBBh1aO2Soz/bdZIOwSY7pijqs0F21 AxLUJH36NefTxRtKPubINVfMgp4Jyvzs5ZOYnQmIwLQ2b+FyXoVk4IlEodDhHJQa8eCg wJKw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=oiHjCpxj; 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 kq26si9078149ejb.754.2020.08.02.20.43.00; Sun, 02 Aug 2020 20:43:22 -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=oiHjCpxj; 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 S1726916AbgHCDlU (ORCPT + 99 others); Sun, 2 Aug 2020 23:41:20 -0400 Received: from mailgw02.mediatek.com ([210.61.82.184]:31793 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1726772AbgHCDlU (ORCPT ); Sun, 2 Aug 2020 23:41:20 -0400 X-UUID: 0acfa016a5124402bc0b6eaa734a0198-20200803 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:MIME-Version:Content-Type:References:In-Reply-To:Date:CC:To:From:Subject:Message-ID; bh=m42oonF9rgHK7bYhLL7BB3uQil5O3aZLfSzxPT96WEM=; b=oiHjCpxjBd8wBVGpIbex+vdM5MPG1Dk5S2nVcHhzf9q//1exnYqtuMudXhOvzjiLzCzbJMU35+WWvu1yaO7mcgvcC/GhluIeU9F1gVfg88+NfaKcSVQGR/RfDYlQ2I5Q449OX6/WfjiEbCiEbZkH9q4zzeHaoujZN4SE8j/xta4=; X-UUID: 0acfa016a5124402bc0b6eaa734a0198-20200803 Received: from mtkexhb02.mediatek.inc [(172.21.101.103)] by mailgw02.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.10 Build 0809 with TLS) with ESMTP id 331396198; Mon, 03 Aug 2020 11:41:14 +0800 Received: from mtkcas08.mediatek.inc (172.21.101.126) by mtkmbs02n2.mediatek.inc (172.21.101.101) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Mon, 3 Aug 2020 11:41:11 +0800 Received: from [172.21.77.33] (172.21.77.33) by mtkcas08.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Mon, 3 Aug 2020 11:41:11 +0800 Message-ID: <1596426072.22971.14.camel@mtkswgap22> Subject: Re: [PATCH v4 2/2] soc: mediatek: add mtk-devapc driver From: Neal Liu To: Chun-Kuang Hu CC: Neal Liu , Rob Herring , Matthias Brugger , , wsd_upstream , lkml , "moderated list:ARM/Mediatek SoC support" , Linux ARM Date: Mon, 3 Aug 2020 11:41:12 +0800 In-Reply-To: References: <1596010690-13178-1-git-send-email-neal.liu@mediatek.com> <1596010690-13178-3-git-send-email-neal.liu@mediatek.com> <1596163970.3932.24.camel@mtkswgap22> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.2.3-0ubuntu6 MIME-Version: 1.0 X-TM-SNTS-SMTP: FDFDD2EEAC8AC8967E0E57305B8F10599BF0B0EF43AB126F2242C878BE64C3FF2000:8 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 SGkgQ2h1bi1LdWFuZywNCg0KT24gRnJpLCAyMDIwLTA3LTMxIGF0IDIz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