From nobody Wed Nov 5 18:43:36 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1535985775978221.37081841516306; Mon, 3 Sep 2018 07:42:55 -0700 (PDT) Received: from localhost ([::1]:45437 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fwq42-0003fj-TV for importer@patchew.org; Mon, 03 Sep 2018 10:42:50 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36698) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fwpwh-0004G3-SJ for qemu-devel@nongnu.org; Mon, 03 Sep 2018 10:35:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fwpwc-0000YE-KJ for qemu-devel@nongnu.org; Mon, 03 Sep 2018 10:35:15 -0400 Received: from fanzine.igalia.com ([91.117.99.155]:38255) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fwpwc-0000OP-0R; Mon, 03 Sep 2018 10:35:10 -0400 Received: from 91-158-71-53.elisa-laajakaista.fi ([91.158.71.53] helo=perseus.local) by fanzine.igalia.com with esmtpsa (Cipher TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim) id 1fwpvz-0007gY-P6; Mon, 03 Sep 2018 16:34:31 +0200 Received: from berto by perseus.local with local (Exim 4.89) (envelope-from ) id 1fwpvk-0002ys-0x; Mon, 03 Sep 2018 17:34:16 +0300 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com; s=20170329; h=References:In-Reply-To:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From; bh=6GpN/s0ohdkVGq/E5I1l+ZHSVi5qaMxp+3dw2CjTzN8=; b=buAhcjwJ3v+M83M/j8emJvGKWhz2ruY+81eKnCkNTU1KXjkISWUDOZfni80n2Nt8oRgMSXmSWdrx4M2w4J0Bw7c0Y0FRDZTKcy+CUlhP+99sx/pRE/kZEFSDCsoaYwCq2E9dpAojxVYJA/GZTMzs+z0r6x64+9qpn/epyrC6vYekZI0LSVI0RQQzMrpNsvwCqzy/DWbsivEFDocppdiFh7Dxjrv6NHAdiUQIc9DAN0uB4cKvOSNF7XlpIsdMTTUxdQ1L37ckbS+z0eNusVCWwrdo0JHwzinNjJKYROSVM/SnjyBJgWknm6Vkr0zmMRraFEDIa3uU0Xs0cK0SUSvtPA==; From: Alberto Garcia To: qemu-devel@nongnu.org Date: Mon, 3 Sep 2018 17:34:00 +0300 Message-Id: <986c6eea52cb87132f7d889856efd7c4c9db78bc.1535983918.git.berto@igalia.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: References: In-Reply-To: References: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no timestamps) [generic] [fuzzy] X-Received-From: 91.117.99.155 Subject: [Qemu-devel] [PATCH v2 02/10] file-posix: x-check-cache-dropped should default to false on reopen X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Kevin Wolf , Alberto Garcia , qemu-block@nongnu.org, Max Reitz Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" The default value of x-check-cache-dropped is false. There's no reason to use the previous value as a default in raw_reopen_prepare() because bdrv_reopen_queue_child() already takes care of putting the old options in the BDRVReopenState.options QDict. If x-check-cache-dropped was previously set but is now missing from the reopen QDict then it should be reset to false. Signed-off-by: Alberto Garcia Reviewed-by: Max Reitz --- block/file-posix.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/file-posix.c b/block/file-posix.c index fe83cbf0eb..ddac0cc3e6 100644 --- a/block/file-posix.c +++ b/block/file-posix.c @@ -851,7 +851,7 @@ static int raw_reopen_prepare(BDRVReopenState *state, } =20 rs->check_cache_dropped =3D qemu_opt_get_bool(opts, "x-check-cache-dro= pped", - s->check_cache_dropped); + false); =20 if (s->type =3D=3D FTYPE_CD) { rs->open_flags |=3D O_NONBLOCK; --=20 2.11.0