Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp6995140imm; Tue, 28 Aug 2018 04:52:00 -0700 (PDT) X-Google-Smtp-Source: ANB0VdaDBpu5K4row0BSNlm60zAVDav+wBsJ+paqjRgcZgKPIDBZX0SM+ToxM1LgzulLSdhppwRG X-Received: by 2002:a62:ad9:: with SMTP id 86-v6mr1217870pfk.57.1535457120883; Tue, 28 Aug 2018 04:52:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535457120; cv=none; d=google.com; s=arc-20160816; b=sqB0WB4QgeoYtNX9vZBrepULufHEitxRVdkbsXA+iqU/qz3nHDyYSnrY0Hv29NNYyz kcK2aeTRTlGPtKen8KI6MDjFdySk+e8cQAk+kVtctsFIlaR5MXprmsiAByhS2cH012JK vlmJa9s9IGFoD8lxazasEbLblzIyP+XPh6UVppTjQRtD/+k03T+p0COxpnI3VeHNAaE2 wPXb+4d/Pn140S42WySiTdePM98210LtM8Z174xPm29f7xb9h+fNQxZMejZVcqSJbhGG 2E4TjEotgbZrYsNTi0q1FazBpQ4axoTCPCzLOmpBXDV/SmFtW8XLY2EXNaDwhEoKC8+f MT+A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:references:cc:to:subject:from:dkim-signature :arc-authentication-results; bh=3sinyK9rxo0a5Ka8LExSwk8KfQhf/mA5Q696AoMCEew=; b=Th4/G8g1Gvt1TWPGPNxeqbmL+lbZkXozzVXinQS2dOXuIEzZeWMyVXszDI7mWRjAwP O26gOQy+yEALjmDD7HKSMeqXcN8gSho/C3ve7F1CYzc431F9SJzdi4gn6x7aNr0eUzCU OsDJIF5kkd1l5kQAyuafO/ZMqYspdLCwF34z9m5N+beyIdRUeXvYVgRqGlR8RUJWbOm/ Ua30agvtYEzPegWmY8qjNhdkNFNE+4fsVO/0AOx8405i17pKsNmLw7gVMYzrxikL9Dw9 j6kvyw3BXzbgeklbCRJhOMYCeqitjiBPfNFT8+7+Z3p+rnAOEGZkm3VKOurvCLQ1PZGN PICQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@synopsys.com header.s=mail header.b=crcgB4Pa; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=synopsys.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j11-v6si783268plk.513.2018.08.28.04.51.45; Tue, 28 Aug 2018 04:52:00 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@synopsys.com header.s=mail header.b=crcgB4Pa; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=synopsys.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727798AbeH1Pl4 (ORCPT + 99 others); Tue, 28 Aug 2018 11:41:56 -0400 Received: from us01smtprelay-2.synopsys.com ([198.182.47.9]:33834 "EHLO smtprelay.synopsys.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727085AbeH1Pl4 (ORCPT ); Tue, 28 Aug 2018 11:41:56 -0400 Received: from mailhost.synopsys.com (mailhost2.synopsys.com [10.13.184.66]) by smtprelay.synopsys.com (Postfix) with ESMTP id AD6D024E259D; Tue, 28 Aug 2018 04:50:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=synopsys.com; s=mail; t=1535457038; bh=ppWQ7/tx1Oix8rSrxt7dXwK0rd5LXdWTK0w45RVjSvs=; h=From:Subject:To:CC:References:Date:In-Reply-To:From; b=crcgB4PaXlofsTfDHv5m9kbe1FGZ7jXvRPD5M61agF9g2GoEpkqoZswOBUjoAvQ7W FOTd5IAqLLNf07FI4O49F976jjIfpjI/HLX8dy2lXDOY9oDjFvMK1jY5FcVVIM3nut r8Fpivbo5Li/DsxHY3uwBkAnDhgF9HrQ0jkGwpjVl2OjvUxDgPO3FKei4JLULfKYXv QmPwM6BIrtufhw32gYYXlotOUsDw0ob1mNCIbmgLGnMBfA8+f/xXl4kdfdlhAIpAiP 0aQGfTtG4WuzSIAB5qEjSmhbzonpUo0/J5R5Onx2EOqv6+eepiunZaYsoZF8bAKMsA 3rh9eB64gbtoA== Received: from US01WXQAHTC1.internal.synopsys.com (us01wxqahtc1.internal.synopsys.com [10.12.238.230]) by mailhost.synopsys.com (Postfix) with ESMTP id 0210D38A6; Tue, 28 Aug 2018 04:50:34 -0700 (PDT) Received: from DE02WEHTCB.internal.synopsys.com (10.225.19.94) by US01WXQAHTC1.internal.synopsys.com (10.12.238.230) with Microsoft SMTP Server (TLS) id 14.3.361.1; Tue, 28 Aug 2018 04:50:34 -0700 Received: from DE02WEHTCA.internal.synopsys.com (10.225.19.92) by DE02WEHTCB.internal.synopsys.com (10.225.19.94) with Microsoft SMTP Server (TLS) id 14.3.361.1; Tue, 28 Aug 2018 13:50:32 +0200 Received: from [10.0.2.15] (10.107.25.43) by DE02WEHTCA.internal.synopsys.com (10.225.19.80) with Microsoft SMTP Server (TLS) id 14.3.361.1; Tue, 28 Aug 2018 13:50:32 +0200 From: vitor Subject: Re: [PATCH v6 01/10] i3c: Add core I3C infrastructure To: Boris Brezillon , vitor CC: , Sekhar Nori , Wolfram Sang , , Jonathan Corbet , , Greg Kroah-Hartman , Arnd Bergmann , Przemyslaw Sroka , Arkadiusz Golec , Alan Douglas , Bartosz Folta , Damian Kos , Alicja Jurasik-Urbaniak , "Cyprian Wronka" , Suresh Punnoose , "Rafal Ciepiela" , Thomas Petazzoni , Nishanth Menon , Rob Herring , Pawel Moll , Mark Rutland , Ian Campbell , "Kumar Gala" , , , Geert Uytterhoeven , Linus Walleij , Xiang Lin , Przemyslaw Gaj , Peter Rosin References: <20180719152930.3715-1-boris.brezillon@bootlin.com> <20180719152930.3715-2-boris.brezillon@bootlin.com> <20180824143934.6d6b6487@bbrezillon> <20180824201600.7d80bca9@bbrezillon> Message-ID: Date: Tue, 28 Aug 2018 12:50:12 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20180824201600.7d80bca9@bbrezillon> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US X-Originating-IP: [10.107.25.43] Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Boris, The DT Bindings say "The node describing an I3C bus should be named i3c-master.". Do you have a field for secondary master? On 24-08-2018 19:16, Boris Brezillon wrote: > Well, before even considering supporting secondary master registration, > we need to handle mastership handover. As for the DAA operation, it's > likely to be host specific, so we'll have to add a new hook to the > i3c_master_controller_ops struct. Do you mean when master try to delegate the bus ownership through GETACCMST? or to get the bus ownership with IBI-MR? I think that could be useful to pass the ibi type on request_ibi(), there is some case where the master doesn't support IBI-MR. > Once you've done that, we'll have trigger a mastership handover > everytime an I3C driver tries to send a frame on the bus, and the > master this frame should do through is not in control of the bus. That > should be pretty easy for the nominal case, but error cases are likely > to be hard to deal with. > Note that I have a ->cur_master field in the i3c_bus object which > stores allows us to track whose the currently active master. If > master->this != master->bus->cur_master that means you need to start a > mastership handover procedure. > > That's all I thought about for now, and we'll probably face other > problems when implementing it. Let me know if you have other questions, > and don't hesitate to share your code early during the development > phase. > > Also note that the bus representation is likely to change based on > Arnd's feedback, so you might have to rework your implementation a bit > at some point. > > Regards, > > Boris Best regards, Vitor Soares