Message ID | 20210921102017.273679-12-vsementsov@virtuozzo.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <SRS0=mKbh=OL=nongnu.org=qemu-devel-bounces+qemu-devel=archiver.kernel.org@kernel.org> 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=-18.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham 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 B0905C433EF for <qemu-devel@archiver.kernel.org>; Tue, 21 Sep 2021 10:33:46 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (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 1859761038 for <qemu-devel@archiver.kernel.org>; Tue, 21 Sep 2021 10:33:46 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 1859761038 Authentication-Results: mail.kernel.org; dmarc=fail (p=quarantine dis=none) header.from=virtuozzo.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=nongnu.org Received: from localhost ([::1]:58856 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from <qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org>) id 1mSd5t-0008AM-3O for qemu-devel@archiver.kernel.org; Tue, 21 Sep 2021 06:33:45 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:32990) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <vsementsov@virtuozzo.com>) id 1mSctm-0001lW-DA; Tue, 21 Sep 2021 06:21:14 -0400 Received: from mail-eopbgr140125.outbound.protection.outlook.com ([40.107.14.125]:6053 helo=EUR01-VE1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <vsementsov@virtuozzo.com>) id 1mSctk-0002LA-Sp; Tue, 21 Sep 2021 06:21:14 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Ae61FhVJYwzt1OLaaK+f0r7bSD7y97ny+2wzTzI0Pi7VpPzzwn7dhxGahRwdvhEXkZ2TLuWwVY+BjZmyWTd4BOa7c4zXWf+d9HskEwFLXEk+5oa39OqZkLDGNximnnjBY4ylbee4nCZ3zdRn+XBtafhSr0lI7SgpIHr5OpAym5ozFIOtWCwZ0pOgXHsKBw2PWHqfMXrT2vQDbAmI2XS2iEQWHRjHgWzgolJz44hzutMPBjsZY+FFXTO/HhnF2UPVJQ7cq06E8j615I2vEqLJrYXXcUHEP3nbZkM44lDqq35XQv6DyfUhF1d0/ZvWfR7l15LQH4/zOtl78PTvYx6C4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=2xvaZssygm8Bh7rOi1eUrBCnt039W0hM5xTn0rgu0DI=; b=Cl6wr0eHtzGW5egPgPqXoU/EFpNl4CcPPpHkvoRubSKigl0JvWCL/kwzuKnoTiUI44ehaeU9Jfg5/o7O8UyEXhgQ4qnhRdccA7Uxx48o/o2kvdFhu021//J3YFn5N0IlJ4eTVlceRHTiB0hWyNoUhM2TeoqYB9QqN4ho4MrffJnhajRrrFN2d81e0lWI663KrQ2j2DqysjVT4TqWi9pxWNzVvE0xhoN8kq/L7UY6hjFb9hUWcVsPNF6ZTUOmAFNF4MiUu28WwpLqJiXygI05r7UX9E30QN8EHw3glOby/g1hjxVLyAARlictJXnXNhAg1FGm957pHfhm3X0LDZZA3g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2xvaZssygm8Bh7rOi1eUrBCnt039W0hM5xTn0rgu0DI=; b=PYA/Do3xR/zVL8MA4voUO0iZoRqNokVjNAshaAHZg4tTMO+3Iwe3gAeHX0kw5dqTuVBq4k8TXqv9lj4g30oiPtVswOMlwrfQo/IDKnyf6YXRuSdmSl7ststStpz4f0DZnngVch7fRhFLybLAa0RPS4rgeJd79PE6q3+coS9Z/hs= Authentication-Results: nongnu.org; dkim=none (message not signed) header.d=none;nongnu.org; dmarc=none action=none header.from=virtuozzo.com; Received: from AM7PR08MB5494.eurprd08.prod.outlook.com (2603:10a6:20b:dc::15) by AS8PR08MB6631.eurprd08.prod.outlook.com (2603:10a6:20b:339::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4523.16; Tue, 21 Sep 2021 10:20:46 +0000 Received: from AM7PR08MB5494.eurprd08.prod.outlook.com ([fe80::2817:53b3:f8b4:fe22]) by AM7PR08MB5494.eurprd08.prod.outlook.com ([fe80::2817:53b3:f8b4:fe22%9]) with mapi id 15.20.4544.013; Tue, 21 Sep 2021 10:20:46 +0000 From: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> To: qemu-block@nongnu.org Cc: qemu-devel@nongnu.org, peter.maydell@linaro.org, kwolf@redhat.com, hreitz@redhat.com, vsementsov@virtuozzo.com, jsnow@redhat.com, Eric Blake <eblake@redhat.com> Subject: [PULL 11/12] mirror: Do not clear .cancelled Date: Tue, 21 Sep 2021 13:20:16 +0300 Message-Id: <20210921102017.273679-12-vsementsov@virtuozzo.com> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20210921102017.273679-1-vsementsov@virtuozzo.com> References: <20210921102017.273679-1-vsementsov@virtuozzo.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: HE1PR06CA0127.eurprd06.prod.outlook.com (2603:10a6:7:16::14) To AM7PR08MB5494.eurprd08.prod.outlook.com (2603:10a6:20b:dc::15) MIME-Version: 1.0 Received: from localhost.localdomain (185.215.60.205) by HE1PR06CA0127.eurprd06.prod.outlook.com (2603:10a6:7:16::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4523.16 via Frontend Transport; Tue, 21 Sep 2021 10:20:45 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: e855656d-4212-49d3-91f1-08d97ce97a01 X-MS-TrafficTypeDiagnostic: AS8PR08MB6631: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: <AS8PR08MB6631535869F3836CF5FD4140C1A19@AS8PR08MB6631.eurprd08.prod.outlook.com> X-MS-Oob-TLC-OOBClassifiers: OLM:4714; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: CPZa5l9sUxkdWc1fzF1oyvqnnUiZ4mTDBN/I/k7Ue1yw1pYB6zCZd/Mvpwp/ykYVPfhLPoZ70xNTNGKFpH6f8t5c74g/dhdn+krBI7fIaK7fy9JphEKaUlc9G3Nme1gKzkMo0JuUAQGX5d1hQ+qMB97EB4TzgdvH5WfQyhNPDwEemHrQwYbqsK10YyoysYkxaJSNzUSW+SjhZl8JS3pUepuVGAtL6PniOX4v7zWgOJn7b8ZF++fstx0VuarOE3RzRCOCLzggXxLjFA/xK0/rVbYInerC0Zr8qKFuGrwV98NtMA3Sfe4lF6Smetk9q6PZ0YsV8+T+GWKzsImrraHbGVR44r1hy5ytS6GZcCnBF+cmn0kAlbFlpCWmGd9yfkSD01Tcr/dI//c23mnVYgoNpR8Y71n71uGfODjIAxaW3aahmgH/ogNVeeAaVcXHSS94f8MJ/uYelRxfAqUQurEiT0Bu+KJnH+51iT//O8PIP6LNQYQ8vXqJOFTJOHoqsoMVR4bSxjmPKXJJIIga+09tvQUWiUNaFnFnlANbLcL1oksRlhCgrN/zP0mrC0Ql2CG3XOmUvVqMXhAUo0fZYI+Pq7dWl4IhdmBk+DcI8R9T82x60hFo8UmJLJqwRe+565F2hgeL3IvRs6DaENT6Mqk4TNfqLSfHWAyJbw/kFyq/kV4xx9ENWS/4x4eFaH8E6u1Nc3mYVgEHTXsTB+s0AhjRgE++WC5UlL6WJcenFHSl1NA= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM7PR08MB5494.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(1076003)(38350700002)(38100700002)(186003)(86362001)(8676002)(316002)(4326008)(6916009)(8936002)(6512007)(6666004)(2906002)(26005)(52116002)(5660300002)(6506007)(83380400001)(6486002)(956004)(2616005)(66476007)(36756003)(66556008)(508600001)(66946007)(142923001); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: HQ+OYrpHCp4zugiglH/1uCDVZKW7RQHM2c07PnX1flxpeUhYqt/lIHWanSd3XHWpmbS7pQATvoGeacvM2uRbeMSpWwVdC4Kl+JfU6y3T1KJw/rTpHnSXMZ35RuxDiofwlyoXn04Vd63fDbgsyTHDr2pTOrBs4uNs47dEhyefHP8NI/3lFvKBZVWteZ7ap8RG24N5p8bk00V+XcAuRb+8XCIEpXK/E14mPXzLAyggsXUdKIAxsltllM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07Cm+iDE+zO6ZBpPt X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: e855656d-4212-49d3-91f1-08d97ce97a01 X-MS-Exchange-CrossTenant-AuthSource: AM7PR08MB5494.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Sep 2021 10:20:46.7177 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: WUVuEJQcr9lh0awEkWej/LoWfUISdF3MLcIiyxmEK4JLW4IjGeo3n6dgSDYjmoKsXC+GDzVtCPfQNarbKDmmezqO7GZEToOQPt96E9O9tms= X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR08MB6631 Received-SPF: pass client-ip=40.107.14.125; envelope-from=vsementsov@virtuozzo.com; helo=EUR01-VE1-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MSGID_FROM_MTA_HEADER=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: <qemu-devel.nongnu.org> List-Unsubscribe: <https://lists.nongnu.org/mailman/options/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe> List-Archive: <https://lists.nongnu.org/archive/html/qemu-devel> List-Post: <mailto:qemu-devel@nongnu.org> List-Help: <mailto:qemu-devel-request@nongnu.org?subject=help> List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" <qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org> |
Series |
[PULL,01/12] job: Context changes in job_completed_txn_abort()
|
expand
|
diff --git a/block/mirror.c b/block/mirror.c index bbf5815fd7..bb837db46e 100644 --- a/block/mirror.c +++ b/block/mirror.c @@ -946,7 +946,6 @@ static int coroutine_fn mirror_run(Job *job, Error **errp) while (!job_cancel_requested(&s->common.job) && !s->should_complete) { job_yield(&s->common.job); } - s->common.job.cancelled = false; goto immediate_exit; } @@ -1085,7 +1084,6 @@ static int coroutine_fn mirror_run(Job *job, Error **errp) * completion. */ assert(QLIST_EMPTY(&bs->tracked_requests)); - s->common.job.cancelled = false; need_drain = false; break; } diff --git a/job.c b/job.c index be878ca5fc..85c0216734 100644 --- a/job.c +++ b/job.c @@ -217,7 +217,9 @@ const char *job_type_str(const Job *job) bool job_is_cancelled(Job *job) { - return job->cancelled && job->force_cancel; + /* force_cancel may be true only if cancelled is true, too */ + assert(job->cancelled || !job->force_cancel); + return job->force_cancel; } bool job_cancel_requested(Job *job)