From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 932C9C77B7E for ; Mon, 24 Apr 2023 10:52:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231430AbjDXKwK (ORCPT ); Mon, 24 Apr 2023 06:52:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38554 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231605AbjDXKv6 (ORCPT ); Mon, 24 Apr 2023 06:51:58 -0400 Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C5A5010D1; Mon, 24 Apr 2023 03:51:53 -0700 (PDT) Received: from [192.168.88.20] (91-154-35-171.elisa-laajakaista.fi [91.154.35.171]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 88A289DE; Mon, 24 Apr 2023 12:51:39 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1682333501; bh=k41FYnFPuVa5kdvlRxv3/uNLC9gxaLBYMO4s1pcl8sc=; h=Date:Subject:To:References:From:In-Reply-To:From; b=SBhIRp0/AaG5awrt23WH7HYVNKSZdeYT+K1bFuzeLC3vEEKeAAwaFsdMQpPv1ijcO Qs9ivefncmwybLmxqurAfGdZM1kvxaTEtd808dny/B+iJDRyzEzlhVA4/EGvje7Z8f QHTXCdmjfMSiRvy5xNAHR1mtLyHdXVoqOHcSyzvw= Message-ID: Date: Mon, 24 Apr 2023 13:51:45 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.10.0 Subject: Re: [PATCH v11 1/7] i2c: add I2C Address Translator (ATR) support To: Wolfram Sang , linux-media@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-i2c@vger.kernel.org, Rob Herring , Krzysztof Kozlowski , Luca Ceresoli , Andy Shevchenko , Matti Vaittinen , Laurent Pinchart , Mauro Carvalho Chehab , Peter Rosin , Liam Girdwood , Mark Brown , Sakari Ailus , Michael Tretter , Hans Verkuil , Mike Pagano , =?UTF-8?Q?Krzysztof_Ha=c5=82asa?= , Marek Vasut , Satish Nagireddy , Luca Ceresoli , Andy Shevchenko References: <20230421101833.345984-1-tomi.valkeinen@ideasonboard.com> <20230421101833.345984-2-tomi.valkeinen@ideasonboard.com> Content-Language: en-US From: Tomi Valkeinen In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 24/04/2023 13:31, Wolfram Sang wrote: > On Fri, Apr 21, 2023 at 01:18:27PM +0300, Tomi Valkeinen wrote: >> From: Luca Ceresoli >> >> An ATR is a device that looks similar to an i2c-mux: it has an I2C >> slave "upstream" port and N master "downstream" ports, and forwards >> transactions from upstream to the appropriate downstream port. But it >> is different in that the forwarded transaction has a different slave >> address. The address used on the upstream bus is called the "alias" >> and is (potentially) different from the physical slave address of the >> downstream chip. >> >> Add a helper file (just like i2c-mux.c for a mux or switch) to allow >> implementing ATR features in a device driver. The helper takes care or >> adapter creation/destruction and translates addresses at each transaction. >> >> Signed-off-by: Luca Ceresoli >> Signed-off-by: Tomi Valkeinen >> Reviewed-by: Andy Shevchenko > > This looks good to me. Dunno if the DT folks want the binding as a > seperate patch, but this is good to go as far as I am concerned. Ah, right. I'll resend with the DT bindings separate. Tomi