Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp3024838ybi; Mon, 10 Jun 2019 03:01:43 -0700 (PDT) X-Google-Smtp-Source: APXvYqzNfHoZfZ9/qQ0SgCjZFfoOrDopxOsqYzFZbZ+JWOswNCZJ8rqbAgvj3ledTNftTbqzI1pd X-Received: by 2002:a62:4c5:: with SMTP id 188mr73274731pfe.19.1560160902961; Mon, 10 Jun 2019 03:01:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560160902; cv=none; d=google.com; s=arc-20160816; b=MG2+z1JfWkp/Jx6no8tybyUnlrTOZbMZWh+ja2jeaC2+immn6pX11CrcA+qGEFLe2r 34WoRLkVovLMvbbrIkIkYC4Kbd7ADg23jkVhybTlBUYLxovJsaaP4r9Olu45iaKm35iT 4cr4PVvU4zvr3ETE6WwBAiTcmVth5kraS09JpYeILCpnffBHlNpndWbm94WHb4MRkoNV MlB0UnCUbmVbeQyNZwEqRkULffBIYizXrXEcWmhpwWuNtfViTg6fHT4O3nZRPO8ejWQa bFKLiepz1vO4QoLhM+8zFf8S4GToyKxtbEP3x6Zko2dDqwHdlNDHd4n4XCtLtfSe1kPu n0fw== 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 :organization:references:in-reply-to:message-id:subject:cc:to:from :date; bh=aHaPyptYo0IdaTglpvh9kuamtpi7oZxMl0g10jka9DA=; b=m69jBVk+AJ+bQj8TPq9ayDpwlCs78z0vWglY/uVgKNUjgviYVHbUBOQVa5y6NWPdhj /j9Qbwb4KkbDFFM3GPbfRsLImH93givLOmP1o+oAQnhTMB77Ujyzs2mltHDdJ5/BLKlJ 4w7DIxDRW1gQ7VYTbWt6lZyxcFC7Eo9pPxf/phXPKCJExldMlkaFT5UoUI5w1cS0yxyC eA2zarNRW6I0OJqHq5Ml0h51hSDEpKETIec6FsYnp8V6XCXAWkDMnZ7J8oRmQTM68vZU KlupFIBtGp+ojrV/Yhasb5jlq/aCIpjPwZzk52EXWIWfIObizIUfsYq19kGYSNZ1bPbj tATw== 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 o3si8986937pll.53.2019.06.10.03.01.27; Mon, 10 Jun 2019 03:01:42 -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 S2389005AbfFJKAi (ORCPT + 99 others); Mon, 10 Jun 2019 06:00:38 -0400 Received: from foss.arm.com ([217.140.110.172]:39332 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388056AbfFJKAi (ORCPT ); Mon, 10 Jun 2019 06:00:38 -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 6F84C344; Mon, 10 Jun 2019 03:00:37 -0700 (PDT) Received: from donnerap.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 7B2E13F246; Mon, 10 Jun 2019 03:02:17 -0700 (PDT) Date: Mon, 10 Jun 2019 11:00:33 +0100 From: Andre Przywara To: Peng Fan Cc: Florian Fainelli , "robh+dt@kernel.org" , "mark.rutland@arm.com" , "jassisinghbrar@gmail.com" , "sudeep.holla@arm.com" , "kernel@pengutronix.de" , dl-linux-imx , "shawnguo@kernel.org" , "festevam@gmail.com" , "devicetree@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "van.freenix@gmail.com" Subject: Re: [PATCH V2 2/2] mailbox: introduce ARM SMC based mailbox Message-ID: <20190610110033.28d21d21@donnerap.cambridge.arm.com> In-Reply-To: References: <20190603083005.4304-1-peng.fan@nxp.com> <20190603083005.4304-3-peng.fan@nxp.com> <866db682-785a-e0a6-b394-bb65c7a694c6@gmail.com> <20190606142056.68272dc0@donnerap.cambridge.arm.com> Organization: ARM X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; aarch64-unknown-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 10 Jun 2019 01:32:49 +0000 Peng Fan wrote: Hi Peng, [ ... ] > > > > + > > > > + irq_count = platform_irq_count(pdev); > > > > + if (irq_count == -EPROBE_DEFER) > > > > + return irq_count; > > > > + > > > > + if (irq_count && irq_count != val) { > > > > + dev_err(dev, "Interrupts not match num-chans\n"); > > > > > > Interrupts property does not match \"arm,num-chans\" would be more > > correct. > > > > Given that interrupts are optional, do we have to rely on this? > > If there is interrupt property, the interrupts should match channel counts. > > Do we actually > > need one interrupt per channel? > > I thought about this, provide one interrupt for all channels. > But there is no good way to let interrupt handlers know which > channel triggers the interrupt. So I use one interrupt per channel. Yeah, I was wondering about this as well. Seems like we need this indeed. Just sounds wasteful, but I guess we don't expect many channels anyway, normally. Cheers, Andre.