Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp1083237ybh; Wed, 22 Jul 2020 23:12:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJytZZoUShX9qcmWp/G5O9JeQM7YBlAQfcRGNXqNpEQHAcA8VDklSOAo8YSnJPvY5FsX8aej X-Received: by 2002:a17:906:69d3:: with SMTP id g19mr3027156ejs.402.1595484773058; Wed, 22 Jul 2020 23:12:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595484773; cv=none; d=google.com; s=arc-20160816; b=sMgpASymZWFJ6U4vVp7DuMc8K9nQcsm3YFxBJ9A60HDDK4wFk/t5n9cTTq9X360kCD y9pOvVroBqkyLZaoOcwF5thKWyIAZ5lgAVhw0HEoKC2aMO0Aox6X3/OzSQ73p+kJefXK KSBl6Qm+qw2QffSUxkMP8nX+Yt4dlWVgc7zjRIbI4hQznakF7D9HQiMEsUnPmM2BVD59 A+2sdUq6zOP+W+DPD+Jk7UbUBQ5mqHiOx1pfTbTgWJVTcOKjhw+UPTF7EtAdoE4mNH7T m1NQGUwWwOZmWsfZbf24XBM+B0ij5QccComfs9PEjw5MZ+SH0szYZSbC0qtFilG6vQS8 OkMQ== 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=bQtcOMa0mF3Q2c0oK8WxVLTlI5mEhwcVJUkkQzY9QLE=; b=gL6Nzvh3w9UbKVA69IzUklbUG6gub47QQgM1OBFANLBiRgrLYIeZQSs4/DCRqRjlXL Pfx3VqCCdJtH5g+Hapv03J/7NXD92SePoJWRBZTUhTANnH6sGkx0JGitazvAslQbTnSz YUrkdu3r+wFfTbR9Yx7pIm6X6FkDHUMh8OHch87hQDOWrBHxyZexehFBnFTWc4fe8AsO DCYZw/f5NNM0jKs8jPb6MQJ4EvhRzs/TA7hAQN0X1twSPr5Xzdf679oRRjed68OCJQP/ Crv+oBsGwSU9FtJqno9LfSouPlpPu85dQpJo9a9ZW95pBaviX87VteB93lc9y0fdon02 6/rg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=XD6SGrXH; 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 a19si1357741eje.150.2020.07.22.23.12.30; Wed, 22 Jul 2020 23:12:53 -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=XD6SGrXH; 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 S1727852AbgGWGMB (ORCPT + 99 others); Thu, 23 Jul 2020 02:12:01 -0400 Received: from mailgw01.mediatek.com ([210.61.82.183]:55951 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1728182AbgGWGMA (ORCPT ); Thu, 23 Jul 2020 02:12:00 -0400 X-UUID: ac9bb204490f43f38217e2922f505554-20200723 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=bQtcOMa0mF3Q2c0oK8WxVLTlI5mEhwcVJUkkQzY9QLE=; b=XD6SGrXH/ltk+Eq+U7Ya86FtKwPaij6AF5PwOtSgMtRyYOfjqB8bff1OjFrzdhezCMFXq0kV80kASYMM9h1orw412+6BhWqTBZAIZdnp4uZVU9MOiLCZ9VMEhwgYDrKtd02smhPiYC84f/gMMlmlvHLdn4R8csZInlORaQKCFGY=; X-UUID: ac9bb204490f43f38217e2922f505554-20200723 Received: from mtkcas06.mediatek.inc [(172.21.101.30)] by mailgw01.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.10 Build 0809 with TLS) with ESMTP id 1847186785; Thu, 23 Jul 2020 14:11:49 +0800 Received: from mtkcas07.mediatek.inc (172.21.101.84) by mtkmbs02n2.mediatek.inc (172.21.101.101) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Thu, 23 Jul 2020 14:11:47 +0800 Received: from [172.21.77.33] (172.21.77.33) by mtkcas07.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Thu, 23 Jul 2020 14:11:44 +0800 Message-ID: <1595484707.26237.12.camel@mtkswgap22> Subject: Re: [PATCH v3 2/2] soc: mediatek: add mtk-devapc driver From: Neal Liu To: Chun-Kuang Hu CC: Neal Liu , Rob Herring , Matthias Brugger , "devicetree@vger.kernel.org" , wsd_upstream , lkml , "moderated list:ARM/Mediatek SoC support" , Linux ARM Date: Thu, 23 Jul 2020 14:11:47 +0800 In-Reply-To: References: <1595303971-8793-1-git-send-email-neal.liu@mediatek.com> <1595303971-8793-3-git-send-email-neal.liu@mediatek.com> <1595389756.20193.12.camel@mtkswgap22> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.2.3-0ubuntu6 MIME-Version: 1.0 X-TM-SNTS-SMTP: 3709D4D3ED79821D948DF8D1C26D38B0512BE44D2FF5BC86F07753523357A6A42000: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 SGkgQ2h1bi1LdWFuZywNCg0KT24gV2VkLCAyMDIwLTA3LTIyI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R4ID0gMDsgdmlvX2lkeCA8IGN0eC0+dmlvX2lkeF9udW07IHZpb19pZHgrKykgew0K PiA+ID4gPiArICAgICAgICAgICAgICAgaWYgKCFtdGtfZGV2YXBjX2R1bXBfdmlvX2RiZyhjdHgs IHZpb19pZHgpKQ0KPiA+ID4gPiArICAgICAgICAgICAgICAgICAgICAgICBjb250aW51ZTsNCj4g PiA+ID4gKw0KPiA+ID4gPiArICAgICAgICAgICAgICAgLyogRW5zdXJlIHRoYXQgdmlvbGF0aW9u IGluZm8gYXJlIHdyaXR0ZW4gYmVmb3JlDQo+ID4gPiA+ICsgICAgICAgICAgICAgICAgKiBmdXJ0 aGVyIG9wZXJhdGlvbnMNCj4gPiA+ID4gKyAgICAgICAgICAgICAgICAqLw0KPiA+ID4gPiArICAg ICAgICAgICAgICAgc21wX21iKCk7DQo+ID4gPiA+ICsNCj4gPiA+ID4gKyAgICAgICAgICAgICAg IC8qDQo+ID4gPiA+ICsgICAgICAgICAgICAgICAgKiBNYXNrIHNsYXZlJ3MgaXJxIGJlZm9yZSBj bGVhcmluZyB2aW8gc3RhdHVzLg0KPiA+ID4gPiArICAgICAgICAgICAgICAgICogTXVzdCBkbyBp dCB0byBhdm9pZCBuZXN0ZWQgaW50ZXJydXB0IGFuZCBwcmV2ZW50DQo+ID4gPiA+ICsgICAgICAg ICAgICAgICAgKiB1bmV4cGVjdGVkIGJlaGF2aW9yLg0KPiA+ID4gPiArICAgICAgICAgICAgICAg ICovDQo+ID4gPiA+ICsgICAgICAgICAgICAgICBtYXNrX21vZHVsZV9pcnEoY3R4LCB2aW9faWR4 LCB0cnVlKTsNCj4gPiA+ID4gKw0KPiA+ID4gPiArICAgICAgICAgICAgICAgY2xlYXJfdmlvX3N0 YXR1cyhjdHgsIHZpb19pZHgpOw0KPiA+ID4gPiArDQo+ID4gPiA+ICsgICAgICAgICAgICAgICBt YXNrX21vZHVsZV9pcnEoY3R4LCB2aW9faWR4LCBmYWxzZSk7DQo+ID4gPiA+ICs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