Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp1097108ybt; Sat, 20 Jun 2020 00:33:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxC9HM/eD5/K7CBhm8Yc7/YjXYGqT/CimmDt72E4Wdj1H/xDinGY/P9R7L/3tUXU+xQk7gr X-Received: by 2002:a50:a694:: with SMTP id e20mr6839301edc.144.1592638393274; Sat, 20 Jun 2020 00:33:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592638393; cv=none; d=google.com; s=arc-20160816; b=XTOuHIp+3bhdqLHDF6wvSo/D5Nl01eo5+XPFQlkOhWnY5Gk/cBO+ZAfdBODYr/3oHL OAlVhl/rg78PHSJ6Bmq17wCNGfCDRmQ+C2o7T4qIaddwHFmGjkLKBxlFbcB12Vc/bVzV HqgnBtBXSA3HDMhKJQUsOnhEljf7Rus9gaLOlfwbB9PMwzIat7haw5yLobEEHuMZMmMM LIMrDWitqbT57ur+UfdfPixCY7vjMysQ9TsQbHm+cWA+vhdDIrTr3CHP2sQrDjk2fHPW qUVHy/zMLXtp9ylNVw1oq9qYvEbX639b6zD5muBIjbu261X52abPctOfUpKV8sGSuQnp IK+w== 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=zBsN1Wyck+84Mbm+gBiGCKGBcPWj9Ghj2Dt/tXk8j/4=; b=aqJSkjUvHCtmoqEevL24iQk1ME4j8U8QbBEa9IIdFREzJ8lRe0+K4ggHfN48d3XKlJ K/mhREDonOYrCPomeTYNcxw+g+W6c5wzY6Bl33tZZp+mUdv9bvjtrTQbbJyl+gyztWzg i5gxlHP1UNVzah6Wg5dNQ+UeMaXAtyxoDV4s1UCkrmh0LjRLHxjJa2NuAsMmVn4A4DF1 rKQdeNBWKzz8uQIWqX39Yg73cEQwpPgJ1NgBuuGFWzBBn+AN+pdE3I4P8g4UcSBN8aRo zWX8DN7DL21ZRjSkJVs36NtSKOM14xnyJOn1DaTGa+gh7GfAQ7/JzA2/2vJnFZo4Dkcc Cq5g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=k27ycLrK; 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 v27si5108731eja.107.2020.06.20.00.32.50; Sat, 20 Jun 2020 00:33:13 -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=k27ycLrK; 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 S1727095AbgFTHaW (ORCPT + 99 others); Sat, 20 Jun 2020 03:30:22 -0400 Received: from mailgw02.mediatek.com ([210.61.82.184]:20656 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1727022AbgFTHaU (ORCPT ); Sat, 20 Jun 2020 03:30:20 -0400 X-UUID: 6003e717073947b0b410684c6cac9b01-20200620 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=zBsN1Wyck+84Mbm+gBiGCKGBcPWj9Ghj2Dt/tXk8j/4=; b=k27ycLrKmA9/8vzoQYhodSiDjJAffxgXh0GQ5WNkFRb3h4L9PkUqWL6mKG5JopoJH2arXhNkU8bCO7s9Xx+Ai/FoJvKHL17ySJf7CFHvMcB5w/M9gG1YAnTQUhm7U1DJ2CBNEqMyPtjQ2xrssZ6p60wMHJrC5ITRxOGs6rRo5zw=; X-UUID: 6003e717073947b0b410684c6cac9b01-20200620 Received: from mtkcas06.mediatek.inc [(172.21.101.30)] by mailgw02.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.10 Build 0809 with TLS) with ESMTP id 1660958606; Sat, 20 Jun 2020 15:30:13 +0800 Received: from mtkcas07.mediatek.inc (172.21.101.84) by mtkmbs07n1.mediatek.inc (172.21.101.16) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Sat, 20 Jun 2020 15:30:11 +0800 Received: from [172.21.77.4] (172.21.77.4) by mtkcas07.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Sat, 20 Jun 2020 15:30:11 +0800 Message-ID: <1592638212.4087.5.camel@mtksdaap41> Subject: Re: [PATCH] i2c: mediatek: Add to support continuous mode From: Yingjoe Chen To: Qiangming Xia CC: , Wolfram Sang , , Qii Wang , , , , , Date: Sat, 20 Jun 2020 15:30:12 +0800 In-Reply-To: <20200619080643.25269-1-qiangming.xia@mediatek.com> References: <20200619080643.25269-1-qiangming.xia@mediatek.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.10.4-0ubuntu2 MIME-Version: 1.0 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 DQpPbiBGcmksIDIwMjAtMDYtMTkgYXQgMTY6MDYgKzA4MDAsIFFpYW5nbWluZyBYaWEgd3JvdGU6 DQo+IEZyb206ICJxaWFuZ21pbmcueGlhIiA8cWlhbmdtaW5nLnhpYUBtZWRpYXRlay5jb20+DQoN ClBsZWFzZSBtYWtlICdGcm9tOicgdGhlIH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