From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id CABC2C433E0 for ; Wed, 10 Jun 2020 12:53:43 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 959FA20734 for ; Wed, 10 Jun 2020 12:53:43 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="zMnTDiyV" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 959FA20734 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1jj0EL-0005hL-UP; Wed, 10 Jun 2020 12:53:21 +0000 Received: from all-amaz-eas1.inumbo.com ([34.197.232.57] helo=us1-amaz-eas2.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1jj0EK-0005hF-B1 for xen-devel@lists.xenproject.org; Wed, 10 Jun 2020 12:53:20 +0000 X-Inumbo-ID: 5b01c907-ab19-11ea-b42d-12813bfff9fa Received: from mail.kernel.org (unknown [198.145.29.99]) by us1-amaz-eas2.inumbo.com (Halon) with ESMTPS id 5b01c907-ab19-11ea-b42d-12813bfff9fa; Wed, 10 Jun 2020 12:53:18 +0000 (UTC) Received: from disco-boy.misterjones.org (disco-boy.misterjones.org [51.254.78.96]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9E4A720734; Wed, 10 Jun 2020 12:53:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1591793597; bh=fhb/IE+L+6oFamjPqDHVhaK35ERv6i0wGNU4Jy9uwFk=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=zMnTDiyVaZJX4RuGFKnokSZmemtzflLkxH8CTOZN2A19y+hR4IpivNMIh5mqm0Opl DtjyhkFiASBibYqh4Pp7oky8yxjcJWQWxmFlmBMvinCkxVBLktcsoYN75eFAeqn9zk aSKe+D96bmnfldl06TgmpvMjA6gDfusNOktXwSwQ= Received: from disco-boy.misterjones.org ([51.254.78.96] helo=www.loen.fr) by disco-boy.misterjones.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1jj0EF-001n7x-Rw; Wed, 10 Jun 2020 13:53:15 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Wed, 10 Jun 2020 13:53:15 +0100 From: Marc Zyngier To: CodeWiz2280 Subject: Re: Keystone Issue In-Reply-To: References: <8C6A23AE-6C2B-411F-ACAD-F5574211E8ED@arm.com> <14244e49-e1ac-a29d-bbd9-bd4c202bf186@xen.org> <77006AAF-BC3B-4C6E-BDFC-577CF87DE64E@arm.com> <99E77330-049F-4471-ABF9-13F9AB4E95B5@arm.com> <363A05E0-61C6-4AE4-9C84-EEAC466989D8@arm.com> <03607739-A4FF-486A-899A-F5F36870225A@arm.com> <2ec6255c-9d28-92e7-bd0a-59edb9fc078a@xen.org> <6033f9cecbf10f50f4a713ce52105426@kernel.org> <32FA85C2-7685-49D2-875B-9FA1C138C92A@arm.com> <5C2DB5F7-832E-4B02-A99A-8B5C7CEC7645@arm.com> User-Agent: Roundcube Webmail/1.4.4 Message-ID: X-Sender: maz@kernel.org X-SA-Exim-Connect-IP: 51.254.78.96 X-SA-Exim-Rcpt-To: codewiz2280@gmail.com, Bertrand.Marquis@arm.com, julien@xen.org, sstabellini@kernel.org, xen-devel@lists.xenproject.org, nd@arm.com X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: xen-devel , nd , Stefano Stabellini , Julien Grall , Bertrand Marquis Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" On 2020-06-10 13:39, CodeWiz2280 wrote: [...] > The problem is that a hack may be my only solution to getting this > working on this platform. If TI says that they don't support it then > i'm stuck. Just to summarize the problem, we believe that the GIC is > seeing secure accesses from dom0 when they should be non-secure. This Not necessarily just dom0. The hypothesis is that accesses to the GICV and/or GICD regions from a non-secure guest are treated as secure. My hunch is that it is only GICV that gets messed with, as you seem to solve it by writing to GICC. > is causing the VGIC ack to be non-functional from dom0. We would > need a firmware that supports both secure and non-secure accesses. Not exactly. You'd need the bridge between the CPU and the GIC to honor NS bit passed on the bus (AXI or otherwise). That is assuming that: - the NS attribute is actually present on the interconnect - the HW is configurable - our "finger in the air" analysis is actually correct As for the last point, only someone with access to the RTL could tell you... > The Xen code gets to "gicv2_guest_irq_end()" where it executes > "gicv2_eoi_irq()", but then we had to add the deactivate > "gicv2_dir_irq" to clear the virtual interrupt manually to get things > going again. Also known as "priority drop" and "deactivation". You may want to use architectural terms when explaining this to HW people. M. -- Jazz is not dead. It just smells funny...