Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp4192781ybb; Tue, 7 Apr 2020 02:37:27 -0700 (PDT) X-Google-Smtp-Source: APiQypLyfRqiMOx0rjzULJhQFBo2nX85LnXOp+BZ0Giulg1lsEPh6zFnMsA26+4ZDJuNKZTw58Q6 X-Received: by 2002:aca:50d0:: with SMTP id e199mr971576oib.133.1586252247123; Tue, 07 Apr 2020 02:37:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586252247; cv=none; d=google.com; s=arc-20160816; b=SRzmivAqjSE+Yzal8BT3whb8FiCcRXwcKuv26fer7vLtLO1m0TxXZkNc6n4Afyve9W iOcIZk9Xxgw3gG3xwfZA6KxKHfAEA+bFhX+Qeo9/jLTE9R4kG74wzd1FHwTUaU4046MQ xQKnPD2Iy9mvnoWdqcYPksaydktbIZu8/0VRIh8UgyU2e0er2yJptgT7n6VKiky3b963 NoQlo4xQqYgxaXoi5UNobOcEvpQfzPP72noZZHnpcJXYGTYpUxP2uQ/NTAJEXwBOCRRy rz09S0tHlRTO3eG3PL46Tbm1fyx80tGh/2gjAnQpPnd2VOTgZG35mVctNPm09lnoUA19 vIkw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=XthnXRsQCwUcoE6HlQrgupzVDcp2XTrWZo4uY89Jcv4=; b=hnNIDKi+DcLIjOG0gxJXxU4/YKNz6v5+xyCcjKX2U9KedUYrrVywosRua00yVkO1dC N7oW6s1rOCSHAlMtfFsUR/FFe9808+R0dP780cTvGxfgJmRzdrqeN6xcejS18v2GLEJe Hc0tp9/ELgHaYXYl6kkqUYDmT1i0OCN8QeUlexr9Ph7Lv0ZQBn3IZzBbPu/xh2oxfzWy Z2KmpF01ru2eldk5u3/wQz8a1mRkuRmeGtVFZ6LA86EopUsUCXpsNhLhVHI5aQJZbzuW f1tiMrc7hlz+xxoY+V5ElWX+PttvOxFKrM2/zVu5nY5PWWm/cJWU8CiHFgZ+hTgnrSV6 VpSg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r6si1070462otc.12.2020.04.07.02.37.14; Tue, 07 Apr 2020 02:37:27 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726716AbgDGJgf (ORCPT + 99 others); Tue, 7 Apr 2020 05:36:35 -0400 Received: from foss.arm.com ([217.140.110.172]:54096 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725883AbgDGJgf (ORCPT ); Tue, 7 Apr 2020 05:36:35 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 59DC830E; Tue, 7 Apr 2020 02:36:34 -0700 (PDT) Received: from bogus (unknown [10.37.12.63]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 5F98A3F73D; Tue, 7 Apr 2020 02:36:32 -0700 (PDT) Date: Tue, 7 Apr 2020 10:36:29 +0100 From: Sudeep Holla To: Cristian Marussi Cc: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, lukasz.luba@arm.com, james.quinlan@broadcom.com, Jonathan.Cameron@Huawei.com, Sudeep Holla Subject: Re: [PATCH v6 01/13] firmware: arm_scmi: Add receive buffer support for notifications Message-ID: <20200407093629.GB28444@bogus> References: <20200327143438.5382-1-cristian.marussi@arm.com> <20200327143438.5382-2-cristian.marussi@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200327143438.5382-2-cristian.marussi@arm.com> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 27, 2020 at 02:34:26PM +0000, Cristian Marussi wrote: > From: Sudeep Holla > > With all the plumbing in place, let's just add the separate dedicated > receive buffers to handle notifications that can arrive asynchronously > from the platform firmware to OS. > > Also add one check to see if the platform supports any receive channels > before allocating the receive buffers: since those buffers are optionally > supported though, the whole xfer initialization is also postponed to be > able to check for their existence in advance. > > Reviewed-by: Jonathan Cameron > Signed-off-by: Sudeep Holla > [Changed parameters in __scmi_xfer_info_init()] > Signed-off-by: Cristian Marussi [...] > @@ -566,6 +568,16 @@ static int scmi_xfer_info_init(struct scmi_info *sinfo) > return 0; > } > > +static int scmi_xfer_info_init(struct scmi_info *sinfo) > +{ > + int ret = __scmi_xfer_info_init(sinfo, &sinfo->tx_minfo); > + > + if (!ret && idr_find(&sinfo->rx_idr, SCMI_PROTOCOL_BASE)) Theoretically, this could be bit tricky if we need to support platforms without Rx channel for base protocol but may have Rx for some specific protocols. But we have other problems too, so we can address that if required in future. Anyways, the first 4 patches are simple and quite independent from the notification part. I will queue them as is and you can drop if you respin the series. I may need some time to go through the series completely and I am trying to comment as I go through individual patches as I may get answers to my own questions as I review. -- Regards, Sudeep