From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755632AbcETDT5 (ORCPT ); Thu, 19 May 2016 23:19:57 -0400 Received: from ozlabs.org ([103.22.144.67]:55225 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751821AbcETDT4 (ORCPT ); Thu, 19 May 2016 23:19:56 -0400 Date: Fri, 20 May 2016 11:45:45 +1000 From: Paul Mackerras To: "Shreyas B. Prabhu" Cc: mpe@ellerman.id.au, linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org, mikey@neuling.org Subject: Re: [PATCH v2 2/9] powerpc/kvm: make hypervisor state restore a function Message-ID: <20160520014545.GA27460@oak.ozlabs.ibm.com> References: <1462263878-25237-1-git-send-email-shreyas@linux.vnet.ibm.com> <1462263878-25237-3-git-send-email-shreyas@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1462263878-25237-3-git-send-email-shreyas@linux.vnet.ibm.com> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, May 03, 2016 at 01:54:31PM +0530, Shreyas B. Prabhu wrote: > In the current code, when the thread wakes up in reset vector, some > of the state restore code and check for whether a thread needs to > branch to kvm is duplicated. Reorder the code such that this > duplication is avoided. This is a nice cleanup. The one minor comment I have is that since power7_restore_hyp_resource has some unusual entry requirements (such as requiring cr3 to be set a certain way), those requirements should be documented in the comment just about the function entry point. I didn't see any unusual exit conditions, but if there are any they should be documented too. Reviewed-by: Paul Mackerras