From mboxrd@z Thu Jan 1 00:00:00 1970 From: Borislav Petkov Subject: Re: [PATCH V15 11/11] arm/arm64: KVM: add guest SEA support Date: Mon, 8 May 2017 22:22:14 +0200 Message-ID: <20170508202214.gmfy27d6ypv6af4n@pd.tnic> References: <1492556723-9189-1-git-send-email-tbaicar@codeaurora.org> <1492556723-9189-12-git-send-email-tbaicar@codeaurora.org> <20170508174058.5hbujeblxq5z6iwa@pd.tnic> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kvmarm-bounces@lists.cs.columbia.edu Sender: kvmarm-bounces@lists.cs.columbia.edu To: "Baicar, Tyler" Cc: linux-efi@vger.kernel.org, kvm@vger.kernel.org, matt@codeblueprint.co.uk, catalin.marinas@arm.com, will.deacon@arm.com, robert.moore@intel.com, paul.gortmaker@windriver.com, lv.zheng@intel.com, kvmarm@lists.cs.columbia.edu, fu.wei@linaro.org, rafael@kernel.org, zjzhang@codeaurora.org, linux@armlinux.org.uk, gengdongjiu@huawei.com, linux-acpi@vger.kernel.org, eun.taik.lee@samsung.com, shijie.huang@arm.com, labbott@redhat.com, lenb@kernel.org, harba@codeaurora.org, john.garry@huawei.com, marc.zyngier@arm.com, punit.agrawal@arm.com, rostedt@goodmis.org, nkaje@codeaurora.org, sandeepa.s.prabhu@gmail.com, linux-arm-kernel@lists.infradead.org, devel@acpica.org, tony.luck@intel.com, rjw@rjwysocki.net, rruigrok@codeaurora.org, linux-kernel@vger.kernel.org, astone@redhat.com, hanjun.guo@linaro.org, joe@perches.com, pbonzini@redhat.com, akpm@linux-foundation.org, bristot@redhat.com List-Id: linux-acpi@vger.kernel.org On Mon, May 08, 2017 at 01:54:44PM -0600, Baicar, Tyler wrote: > This was discussed in the v12 and v13 patch series. There is existing > code in kvm_handle_guest_abort for injecting an abort back into the > guest. We only want to do that if it was an abort that was not handled > by the firmware first handling. So here we verify that at least one of > the SEA error sources successfully reported an error record sent from > the firmware. If there were no errors reported by firmware, then we > want to continue with the current implementation that will inject the > virtual abort. (kvm_inject_vabt) So this needs to be in a comment there. This is generic code in the sense that it is in drivers/acpi/ and it should say why it is doing that special thing. I know, SEA is ARM-only, as far as I'm gathering from reviewing this, but this behavior needs to be documented as it is not obvious. Thanks. -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756817AbdEHUX2 (ORCPT ); Mon, 8 May 2017 16:23:28 -0400 Received: from mail.skyhub.de ([5.9.137.197]:60034 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755806AbdEHUWc (ORCPT ); Mon, 8 May 2017 16:22:32 -0400 Date: Mon, 8 May 2017 22:22:14 +0200 From: Borislav Petkov To: "Baicar, Tyler" Cc: christoffer.dall@linaro.org, marc.zyngier@arm.com, pbonzini@redhat.com, rkrcmar@redhat.com, linux@armlinux.org.uk, catalin.marinas@arm.com, will.deacon@arm.com, rjw@rjwysocki.net, lenb@kernel.org, matt@codeblueprint.co.uk, robert.moore@intel.com, lv.zheng@intel.com, nkaje@codeaurora.org, zjzhang@codeaurora.org, mark.rutland@arm.com, james.morse@arm.com, akpm@linux-foundation.org, eun.taik.lee@samsung.com, sandeepa.s.prabhu@gmail.com, labbott@redhat.com, shijie.huang@arm.com, rruigrok@codeaurora.org, paul.gortmaker@windriver.com, tn@semihalf.com, fu.wei@linaro.org, rostedt@goodmis.org, bristot@redhat.com, linux-arm-kernel@lists.infradead.org, kvmarm@lists.cs.columbia.edu, kvm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org, linux-efi@vger.kernel.org, devel@acpica.org, Suzuki.Poulose@arm.com, punit.agrawal@arm.com, astone@redhat.com, harba@codeaurora.org, hanjun.guo@linaro.org, john.garry@huawei.com, shiju.jose@huawei.com, joe@perches.com, rafael@kernel.org, tony.luck@intel.com, gengdongjiu@huawei.com, xiexiuqi@huawei.com Subject: Re: [PATCH V15 11/11] arm/arm64: KVM: add guest SEA support Message-ID: <20170508202214.gmfy27d6ypv6af4n@pd.tnic> References: <1492556723-9189-1-git-send-email-tbaicar@codeaurora.org> <1492556723-9189-12-git-send-email-tbaicar@codeaurora.org> <20170508174058.5hbujeblxq5z6iwa@pd.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 08, 2017 at 01:54:44PM -0600, Baicar, Tyler wrote: > This was discussed in the v12 and v13 patch series. There is existing > code in kvm_handle_guest_abort for injecting an abort back into the > guest. We only want to do that if it was an abort that was not handled > by the firmware first handling. So here we verify that at least one of > the SEA error sources successfully reported an error record sent from > the firmware. If there were no errors reported by firmware, then we > want to continue with the current implementation that will inject the > virtual abort. (kvm_inject_vabt) So this needs to be in a comment there. This is generic code in the sense that it is in drivers/acpi/ and it should say why it is doing that special thing. I know, SEA is ARM-only, as far as I'm gathering from reviewing this, but this behavior needs to be documented as it is not obvious. Thanks. -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply. From mboxrd@z Thu Jan 1 00:00:00 1970 From: bp@alien8.de (Borislav Petkov) Date: Mon, 8 May 2017 22:22:14 +0200 Subject: [PATCH V15 11/11] arm/arm64: KVM: add guest SEA support In-Reply-To: References: <1492556723-9189-1-git-send-email-tbaicar@codeaurora.org> <1492556723-9189-12-git-send-email-tbaicar@codeaurora.org> <20170508174058.5hbujeblxq5z6iwa@pd.tnic> Message-ID: <20170508202214.gmfy27d6ypv6af4n@pd.tnic> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On Mon, May 08, 2017 at 01:54:44PM -0600, Baicar, Tyler wrote: > This was discussed in the v12 and v13 patch series. There is existing > code in kvm_handle_guest_abort for injecting an abort back into the > guest. We only want to do that if it was an abort that was not handled > by the firmware first handling. So here we verify that at least one of > the SEA error sources successfully reported an error record sent from > the firmware. If there were no errors reported by firmware, then we > want to continue with the current implementation that will inject the > virtual abort. (kvm_inject_vabt) So this needs to be in a comment there. This is generic code in the sense that it is in drivers/acpi/ and it should say why it is doing that special thing. I know, SEA is ARM-only, as far as I'm gathering from reviewing this, but this behavior needs to be documented as it is not obvious. Thanks. -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.