From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757195AbbCCUpK (ORCPT ); Tue, 3 Mar 2015 15:45:10 -0500 Received: from mx1.redhat.com ([209.132.183.28]:37267 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755412AbbCCUpI (ORCPT ); Tue, 3 Mar 2015 15:45:08 -0500 Date: Tue, 3 Mar 2015 21:44:46 +0100 From: Radim =?utf-8?B?S3LEjW3DocWZ?= To: Joel Schopp Cc: Gleb Natapov , Paolo Bonzini , kvm@vger.kernel.org, David Kaplan , Joerg Roedel , linux-kernel@vger.kernel.org, Borislav Petkov Subject: Re: [PATCH v3] x86: svm: use kvm_fast_pio_in() Message-ID: <20150303204445.GC2494@potion.brq.redhat.com> References: <20150302210202.2951.56810.stgit@joelvmguard2.amd.com> <20150303164431.GD25123@potion.brq.redhat.com> <54F61388.6090002@amd.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <54F61388.6090002@amd.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 2015-03-03 14:03-0600, Joel Schopp: > On 03/03/2015 10:44 AM, Radim Krčmář wrote: > > 2015-03-02 15:02-0600, Joel Schopp: > >> + int ret = emulator_pio_in_emulated(&vcpu->arch.emulate_ctxt, size, > >> + port, &val, 1); > > Btw. does this return 1 in some scenario? > If a function returns a value it is always a good idea to check it and > act appropriately. That said... > emulator_pio_in_emulated will return 1 if emulator_pio_in_out returns 1 Ah, I have completely forgotten, thanks!