Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp3160055ybk; Mon, 18 May 2020 20:03:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyQM4Ps/UySffwx7OTSZ8hPhHkUXS+KRuGeStG9lmSVl8NH6qw8csSOfy0Gg0+NCAJzke4x X-Received: by 2002:a17:906:ae88:: with SMTP id md8mr16861532ejb.119.1589857410004; Mon, 18 May 2020 20:03:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1589857409; cv=none; d=google.com; s=arc-20160816; b=lshI8BZyvxfUrPJi/1C+FkcrWWgyEi8+KL2rDJxvdA82DhwBAqkI6xaA2LoJ3f/X3x jFJbBwMI51qfACzO/unSteUqC+/N8zigXVXidon0Wk4wQZG2V9SDHVM2OvfrMrFN5Gzc 2+szmupEKoLjbp5HqxXlY+chyaJq8HfRKR5E7VC4RX+O+zVOBnOVDqfR2XOCqlSQAdui UGd8TRHyWAyryLGdLJ+GVIloZzJLGT99rGiXaG2k/391TYwZT2PxOlTDyLJFKb8yVzO4 vIqj8F9wU5gNelrVC/b7ec3jN1g9AC5DdnSE5KnphNVT1J4Je/ZXu6ckj5Juz60I0gEl /1Xg== 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=M+o0Anz4/UQjLm5nYoVibliTyzmVqym+xJdpP5blyMg=; b=xmOL0qOuo00AFXygMKLuxKXyDtavUo0Iqx82pUjG4GKMHRbkGbhAJYgmY70lUqDoaV QZ7wlBhxMTO27lATATkwZUt81GW+KEuFUWtHy6UHRMljAkYckyfPJY3oLopwYvZvZPG2 d8H1u46YlyRCfFww2vdQnujwhgdmZEEoDFMwULVwyy0LXntEOndIX9TMFkGXmoFfK5HP S59d3oRgPRg9T3CTs168/WUXpf8P89lHs12RibiGno9kWP6F3qJONxGhDsDBfbs+v4Ha XGw8RxVTen3uRB/IriV8cB3WnjojdvcfAuhPgnLhyb/N0c94ILOTfylpeCD6OIbBll8b nO7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b="Hfb1/kAc"; 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 o9si7708919ejj.92.2020.05.18.20.03.07; Mon, 18 May 2020 20:03:29 -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="Hfb1/kAc"; 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 S1727973AbgESC7f (ORCPT + 99 others); Mon, 18 May 2020 22:59:35 -0400 Received: from mailgw02.mediatek.com ([1.203.163.81]:23660 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1726270AbgESC7e (ORCPT ); Mon, 18 May 2020 22:59:34 -0400 X-UUID: 65406e5a649647bcb639b8e9ec35218a-20200519 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=M+o0Anz4/UQjLm5nYoVibliTyzmVqym+xJdpP5blyMg=; b=Hfb1/kAcOMyc62ESYxEaNe9rl85iTGBbye1u2kksbh65RXJ/yGx23mtBAhLKezkSCdBF8Q3sh19OqhMixugH6/LkpgS4Y3+k+Nlp/GnY0FoSR4Y7kqF9mJDxD0EA4nBnOLW8vDTEyeIenlvNDv23Kp2epA7Xr+UARfVcANG+sOM=; X-UUID: 65406e5a649647bcb639b8e9ec35218a-20200519 Received: from mtkcas35.mediatek.inc [(172.27.4.253)] by mailgw02.mediatek.com (envelope-from ) (mailgw01.mediatek.com ESMTP with TLS) with ESMTP id 1280698048; Tue, 19 May 2020 10:59:23 +0800 Received: from MTKCAS36.mediatek.inc (172.27.4.186) by MTKMBS31DR.mediatek.inc (172.27.6.102) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 19 May 2020 10:59:22 +0800 Received: from [10.17.3.153] (10.17.3.153) by MTKCAS36.mediatek.inc (172.27.4.170) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Tue, 19 May 2020 10:59:21 +0800 Message-ID: <1589857073.25512.34.camel@mhfsdcap03> Subject: Re: [PATCH v2 2/2] i2c: mediatek: Add i2c ac-timing adjust support From: Qii Wang To: Joe Perches , Geert Uytterhoeven CC: Wolfram Sang , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , , , "Linux Kernel Mailing List" , , Linux I2C , Linux ARM Date: Tue, 19 May 2020 10:57:53 +0800 In-Reply-To: References: <1589461844-15614-1-git-send-email-qii.wang@mediatek.com> <1589461844-15614-3-git-send-email-qii.wang@mediatek.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.10.4-0ubuntu2 MIME-Version: 1.0 X-TM-SNTS-SMTP: 2E488EF03A7622D1ADEEB7C7CD1CCABA41B9EB17953038A2511499CEDEE1E7E62000: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 T24gTW9uLCAyMDIwLTA1LTE4IGF0IDE3OjQ0ICswMjAwLCBHZWVydCBVeXR0ZXJob2V2ZW4gd3Jv dGU6DQo+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pZ2hfY250ID0gMiAqIHN0ZXBfY250IC0gbG93X2NudDsNCj4gPiArICAgICAgICAgICAg ICAgfSBlbHNlIHsNCj4gPiArICAgICAgICAgICAgICAgICAgICAgICBoaWdoX2NudCA9IHN0ZXBf Y250Ow0KPiA+ICsgICAgICAgICAgICAgICAgICAgICAgIGxvd19jbnQgPSBzdGVwX2NudDsNCj4g PiArICAgICAgICAgICAgICAgfQ0KPiA+ICsgICAgICAgfSBlbHNlIHsNCj4gPiArICAgICAgICAg ICAgICAgcmV0dXJuIC0yOw0KPiA+ICsgICAgICAgfQ0KPiA+ICsNCj4gPiArICAgICAgIHNkYV9t YXggPSBzcGVjLT5tYXhfaGRfZGF0X25zIC8gc2FtcGxlX25zOw0KPiA+ICsgICAgICAgaWYgKHNk YV9tYXggPiBsb3dfY250KQ0KPiA+ICsgICAgICAgICAgICAgICBzZGFfbWF4ID0gMDsNCj4gPiAr DQo+ID4gKyAgICAgICBzZGFfbWluID0gRElWX1JPVU5EX1VQKHNwZWMtPm1pbl9zdV9kYXRfbnMs IHNhbXBsZV9ucyk7DQo+IA0KPiBPbmUgbW9yZS4NCj4gDQo+IEdye29ldGplLGVldGluZ31zLA0K PiANCj4gICAgICAgICAgICAgICAgICAgICAgICAgR2VlcnQNCj4gDQo+IC0tDQo+IEdlZXJ0IFV5 dHRlcmhvZXZlbiAtLSBUaGVyZSdzIGxvdHMgb2YgTGludXggYmV5b25kIGlhMzIgLS0gZ2VlcnRA bGludXgtbTY4ay5vcmcNCj4gDQo+IEluIHBlcnNvbmFsIGNvbnZlcnNhdGlvbnMgd2l0aCB0ZWNo bmljYWwgcGVvcGxlLCBJIGNhbGwgbXlzZWxmIGEgaGFja2VyLiBCdXQNCj4gd2hlbiBJJ20gdGFs a2luZyB0byBqb3VybmFsaXN0cyBJIGp1c3Qgc2F5ICJwcm9ncmFtbWVyIiBvciBzb21ldGhpbmcg bGlrZSB0aGF0Lg0KPiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIC0tIExpbnVzIFRv cnZhbGRzDQoNCg==