From owner-freebsd-arm@FreeBSD.ORG Fri Jan 16 17:42:46 2015 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 279AB699 for ; Fri, 16 Jan 2015 17:42:46 +0000 (UTC) Received: from mail-wi0-f181.google.com (mail-wi0-f181.google.com [209.85.212.181]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B4A5E2E4 for ; Fri, 16 Jan 2015 17:42:45 +0000 (UTC) Received: by mail-wi0-f181.google.com with SMTP id hi2so5418686wib.2 for ; Fri, 16 Jan 2015 09:42:38 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :subject:references:in-reply-to:content-type :content-transfer-encoding; bh=c76QnRzNUg/vbrtrv+ESG9coQtxsPjrWz0xFJF0oq6I=; b=BuWQOoUV0CKR8sQEIkeFPfvMlnG/rt2bguvmVF8kFXI6F/Dur7QgV3ldg1ethGjWE4 pPFksk/hLOrdW6C8vuX2n35PSZLFrJXjUCfPRUvzjoTyvBoWEHybZL/KRW7i79CPYn0q Mv0c9+o7i2j8Ne3er+88jxaS8MkZ9PurUkvQyC18opZXlAhogpsCCnnBq7Mu5tHvNrOh DV7vsu8F5uQddvMf9rvFSeD+/MLQBHAH2DEvcmmP8q6NFwTOVt7ESJqAnnZNEhZj4A1Q 00zLD5yi34SFS2DTOuv52StMk9L4Ccg3tdI2de5iLpOKzNQ9OjtxoRLB2C6zJ5WFF6lK 7KOQ== X-Gm-Message-State: ALoCoQnaMbXiPJJy99hB+hkIEhyNySxpRCBHVnSbHrklMCFoL1/54Fhk/d+DCrCn2tbbdsPQPVln X-Received: by 10.194.78.204 with SMTP id d12mr31297325wjx.37.1421430158180; Fri, 16 Jan 2015 09:42:38 -0800 (PST) Received: from [10.80.2.139] ([185.25.64.249]) by mx.google.com with ESMTPSA id n3sm6907786wja.36.2015.01.16.09.42.36 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Jan 2015 09:42:37 -0800 (PST) Message-ID: <54B94D71.90403@linaro.org> Date: Fri, 16 Jan 2015 17:42:09 +0000 From: Julien Grall User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.3.0 MIME-Version: 1.0 To: Svatopluk Kraus , freebsd-arm@freebsd.org, Roger Pau Monne Subject: Re: interrupt framework References: In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Jan 2015 17:42:46 -0000 On 15/01/15 13:51, Svatopluk Kraus wrote: > Hi community, Hello, > I and Michal Meloun have done some work on ARM interrupt framework and > this is the result. > > We've started with intrng project with Ian's WIP changes, have looked > at Andrew's ARM64 git repository, and this is how we think an > interrupt framework should look like. We've implemented it with > removable interrupt controllers in mind (PCI world). It's not finished > from this point of view, however some functions are more complex > because of it. Is there any plan to make this framework generic across all the architectures? Some of our drivers as to create new interrupt controllers to handle event channel, it's an event notifications provided by Xen which is very similar to an interrupt (eoi/mask/unmask...). They are used by virtual devices in order to send/receive interrupts. The current code [1] already supports x86 which has a similar framework [2]. If your framework is used on all the architecture (especially ARM, ARM64 and x86), it would allow us to share the code between the architectures supported by Xen. Regards, [1] sys/x86/xen/xen_intr.c [2] sys/x86/x86/intr_machdep.c -- Julien Grall