From patchwork Fri Sep 28 15:22:46 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Paolo Bonzini X-Patchwork-Id: 187803 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id BEA852C00C6 for ; Sat, 29 Sep 2012 01:24:09 +1000 (EST) Received: from localhost ([::1]:40541 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1THcQB-0005gu-PA for incoming@patchwork.ozlabs.org; Fri, 28 Sep 2012 11:24:07 -0400 Received: from eggs.gnu.org ([208.118.235.92]:33646) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1THcPk-0005HL-PB for qemu-devel@nongnu.org; Fri, 28 Sep 2012 11:23:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1THcPe-00019H-U8 for qemu-devel@nongnu.org; Fri, 28 Sep 2012 11:23:40 -0400 Received: from mail-pb0-f45.google.com ([209.85.160.45]:40969) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1THcPe-00017A-Nm for qemu-devel@nongnu.org; Fri, 28 Sep 2012 11:23:34 -0400 Received: by mail-pb0-f45.google.com with SMTP id rp2so5308240pbb.4 for ; Fri, 28 Sep 2012 08:23:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references; bh=QCtqimIdueFyoE3e1TcmA+BApFe5K703XWUUoAPF3Nc=; b=JwJeSTZDpHY4qm9RNLvJV2fIo7Kw28kpAg8cbtTAv9Tze6uiR1AemJxMJIkmurHx1T 7urMpmqnHtfIrhDLGkvhOpur0W2zN8/4dpBN3MYkCI7I3ZcdhkYVFIkH+W0X8RK7K+Mn LifT5mkv6zeYnYOM02qNV2uRKlpmhrXtQFpzTI0y9QqjOGiOkwQxIKZaoQazUJOmvWC6 Z5j6wTCvcMWOS77Q5phtWiyn5HOpRt6dou8EkDifwNQ8zsK6zBoeIU5QrMiB+MxDb4ed 9s9VkuQjL1vHYbP4uilg9mcRLT1U2NciiXJzRbDMtKbDUwG7VadsO+jz9KHQqhdMSlC4 /ddA== Received: by 10.68.189.161 with SMTP id gj1mr21109637pbc.21.1348845814440; Fri, 28 Sep 2012 08:23:34 -0700 (PDT) Received: from yakj.usersys.redhat.com (93-34-169-1.ip50.fastwebnet.it. [93.34.169.1]) by mx.google.com with ESMTPS id e9sm5648599pay.34.2012.09.28.08.23.31 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 28 Sep 2012 08:23:33 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Date: Fri, 28 Sep 2012 17:22:46 +0200 Message-Id: <1348845782-15073-4-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.7.12 In-Reply-To: <1348845782-15073-1-git-send-email-pbonzini@redhat.com> References: <1348845782-15073-1-git-send-email-pbonzini@redhat.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.85.160.45 Cc: kwolf@redhat.com Subject: [Qemu-devel] [PATCH 03/19] block: fix documentation of block_job_cancel_sync X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Do this in a separate commit before we move the functions to blockjob.h. Signed-off-by: Paolo Bonzini --- block_int.h | 12 +++++------- 1 file modificato, 5 inserzioni(+), 7 rimozioni(-) diff --git a/block_int.h b/block_int.h index ac4245c..b025fa0 100644 --- a/block_int.h +++ b/block_int.h @@ -425,15 +425,13 @@ void block_job_cancel(BlockJob *job); bool block_job_is_cancelled(BlockJob *job); /** - * block_job_cancel: + * block_job_cancel_sync: * @job: The job to be canceled. * - * Asynchronously cancel the job and wait for it to reach a quiescent - * state. Note that the completion callback will still be called - * asynchronously, hence it is *not* valid to call #bdrv_delete - * immediately after #block_job_cancel_sync. Users of block jobs - * will usually protect the BlockDriverState objects with a reference - * count, should this be a concern. + * Synchronously cancel the job. The completion callback is called + * before the function returns. The job may actually complete + * instead of canceling itself; the circumstances under which this + * happens depend on the kind of job that is active. * * Returns the return value from the job if the job actually completed * during the call, or -ECANCELED if it was canceled.