Received: by 2002:ac0:aa62:0:0:0:0:0 with SMTP id w31-v6csp2063726ima; Mon, 22 Oct 2018 03:42:32 -0700 (PDT) X-Google-Smtp-Source: ACcGV63fn6+DHzgZd1GCm8eERXxldgLZ49QeoQHGaAhzc8Iq66vZiIfkDnziWfTfgZZrpCxFZCFx X-Received: by 2002:a63:4952:: with SMTP id y18-v6mr42339385pgk.32.1540204952437; Mon, 22 Oct 2018 03:42:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1540204952; cv=none; d=google.com; s=arc-20160816; b=rfSprxmd2n9fPY4t6fl0PkvgAhEyMoQVxFexsgzG8PPa2zhFk8drcDfhOITDGIPs+3 a904NW7NNrUhnn6k0NigbQ6L5eD0xXxKnqlI9Gf/UbrpntajDNLYp6EYZulgmjFYgRQi VJioYYfd4mSu6rb6Nd8KBsN4atCriWDbMTxcA/Qb2DaS6a0zmlxlhHigq7CSXndlECAp /t6+JUhQpD124/iCjD2utEZJ8gU5IxsGs7aWEZnexTpk38oSheEgF1GyBKm1ObYCMjpZ l/fj9xgXb+mdVe+92K9YrGPxQ3qEs1aTXPtZkKxJn/QcsAUmJXk/AqEFMC/VqW3mzaMj NQIQ== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=udwgnpd0WUQTSWNJ0IspA6YTrMWnG0E3j0YfO5oSwL8=; b=GpQJqBPCiHeg4allhH925y/5USRF3gQKWXNrAkzicFnJdauIb2tMaTtx79xRREh6Yf JpCr+WgP7agyOyTf/qtLswyBh4C0JsG0GtZp2U5DjcZIQAtb8Q1wUfq56YRbcv9MNEYn 4RMzU88X5ofmZclacwbt4OSrADXDdMmR92+IVWkWr391FKVIWiHnOgI90U+/hijbK5U6 babRbXGa2j8hzJM0oPMe6rC0HPkuO++RhpI81RByOOC6S6yAJH5uExog4O9RSaiVObnc dYXSsxFZAChzweLr2cbAdqhSHeZRVWqHD/fiyn6wFY90FM6m/OF6rvVf8IhcV37CwXuz ZRMQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=v3DATsAk; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z27-v6si33364307pgk.297.2018.10.22.03.42.16; Mon, 22 Oct 2018 03:42:32 -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=@ti.com header.s=ti-com-17Q1 header.b=v3DATsAk; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728589AbeJVS7t (ORCPT + 99 others); Mon, 22 Oct 2018 14:59:49 -0400 Received: from lelv0143.ext.ti.com ([198.47.23.248]:55234 "EHLO lelv0143.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728306AbeJVS7t (ORCPT ); Mon, 22 Oct 2018 14:59:49 -0400 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by lelv0143.ext.ti.com (8.15.2/8.15.2) with ESMTP id w9MAfDki046051; Mon, 22 Oct 2018 05:41:13 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1540204873; bh=udwgnpd0WUQTSWNJ0IspA6YTrMWnG0E3j0YfO5oSwL8=; h=Subject:To:CC:References:From:Date:In-Reply-To; b=v3DATsAkYVn3gYVZ9bSsg3/VurRyZThSs3+d1OYPrfWnQh+IlGt9cRStedwFJTJdz I1gJh7OtMiVLg8B/DkDoBq/19Fjd9YnblRMpQpY25nUge6LqdoGQ1HtwUhcL+vcMUH 9ZRzvDS7UzccIpuCSZxwup9qku16RriYUQ2+C9d4= Received: from DFLE104.ent.ti.com (dfle104.ent.ti.com [10.64.6.25]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id w9MAfDEG026716; Mon, 22 Oct 2018 05:41:13 -0500 Received: from DFLE102.ent.ti.com (10.64.6.23) by DFLE104.ent.ti.com (10.64.6.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1466.3; Mon, 22 Oct 2018 05:41:10 -0500 Received: from dflp32.itg.ti.com (10.64.6.15) by DFLE102.ent.ti.com (10.64.6.23) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.1466.3 via Frontend Transport; Mon, 22 Oct 2018 05:41:10 -0500 Received: from [192.168.2.6] (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp32.itg.ti.com (8.14.3/8.13.8) with ESMTP id w9MAf7N8000920; Mon, 22 Oct 2018 05:41:08 -0500 Subject: Re: [PATCH v2 09/10] irqchip: ti-sci-inta: Add support for Interrupt Aggregator driver To: Lokesh Vutla , Nishanth Menon , Santosh Shilimkar , Rob Herring , , , CC: Linux ARM Mailing List , , Tero Kristo , Sekhar Nori , Device Tree Mailing List , Grygorii Strashko References: <20181018154017.7112-1-lokeshvutla@ti.com> <20181018154017.7112-10-lokeshvutla@ti.com> From: Peter Ujfalusi Message-ID: <6b112f34-cae3-fcd4-0d36-80b39c575fe4@ti.com> Date: Mon, 22 Oct 2018 13:42:15 +0300 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: <20181018154017.7112-10-lokeshvutla@ti.com> Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 8bit X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Lokesh, On 2018-10-18 18:40, Lokesh Vutla wrote: > Texas Instruments' K3 generation SoCs has an IP Interrupt Aggregator > which is an interrupt controller that does the following: > - Converts events to interrupts that can be understood by > an interrupt router. > - Allows for multiplexing of events to interrupts. > - Allows for grouping of multiple events to a single interrupt. > > Configuration of the interrupt aggregator registers can only be done by > a system co-processor and the driver needs to send a message to this > co processor over TISCI protocol. > > Add support for Interrupt Aggregator driver over TISCI protocol. Have you compiled this? ... > diff --git a/drivers/irqchip/irq-ti-sci-inta.c b/drivers/irqchip/irq-ti-sci-inta.c > new file mode 100644 > index 000000000000..ef0a2e8b782c > --- /dev/null > +++ b/drivers/irqchip/irq-ti-sci-inta.c ... > +/** > + * ti_sci_inta_register_event() - Register a event to an interrupt aggregator > + * @dev: Device pointer to source generating the event > + * @src_id: TISCI device ID of the event source > + * @src_index: Event source index within the device. > + * @virq: Linux Virtual IRQ number > + * @flags: Corresponding IRQ flags > + * @ack_needed: If explicit clearing of event is required. > + * > + * Creates a new irq and attaches to IA domain if virq is not specified > + * else attaches the event to vint corresponding to virq. > + * When using TISCI within the client drivers, source indexes are always > + * generated dynamically and cannot be represented in DT. So client > + * drivers should call this API instead of platform_get_irq(). > + * > + * Return virq if all went well else appropriate error value. > + */ > +int ti_sci_inta_register_event(struct device *dev, u16 src_id, u16 src_index, > + unsigned int virq, u32 flags, bool ack_needed) > +{ ... > diff --git a/include/linux/irqchip/irq-ti-sci-inta.h b/include/linux/irqchip/irq-ti-sci-inta.h > new file mode 100644 > index 000000000000..c078234fda3f > --- /dev/null > +++ b/include/linux/irqchip/irq-ti-sci-inta.h > @@ -0,0 +1,35 @@ > +/* SPDX-License-Identifier: GPL-2.0 */ > +/* > + * Texas Instruments' System Control Interface (TI-SCI) irqchip > + * > + * Copyright (C) 2018 Texas Instruments Incorporated - http://www.ti.com/ > + * Lokesh Vutla > + */ > + > +#ifndef __INCLUDE_LINUX_IRQCHIP_TI_SCI_INTA_H > +#define __INCLUDE_LINUX_IRQCHIP_TI_SCI_INTA_H > + > +#if IS_ENABLED(CONFIG_TI_SCI_INTA_IRQCHIP) > +int ti_sci_inta_register_event(struct device *dev, u16 src_id, u16 src_index, > + unsigned int virq, u32 flags); You are missing the ack_needed > +int ti_sci_inta_unregister_event(struct device *dev, u16 src_id, u16 src_index, > + unsigned int virq); > + > +#else /* CONFIG_TI_SCI_INTA_IRQCHIP */ > + > +static inline int ti_sci_inta_register_event(struct device *dev, u16 src_id, > + u16 src_index, unsigned int virq, > + u32 flags) Here as well. > +{ > + return -EINVAL; > +} > + > +static inline int ti_sci_inta_unregister_event(struct device *dev, u16 src_id, > + u16 src_index, unsigned int virq) > +{ > + return -EINVAL; > +} > + > +#endif /* CONFIG_TI_SCI_INTA_IRQCHIP */ > + > +#endif /* __INCLUDE_LINUX_IRQCHIP_TI_SCI_INTA_H */ > - Péter Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki