From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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=-16.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,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 8DBE5C433E0 for ; Fri, 26 Feb 2021 08:47:23 +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 0A6CF60231 for ; Fri, 26 Feb 2021 08:47:22 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0A6CF60231 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:50474 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lFYmP-00026S-TX for qemu-devel@archiver.kernel.org; Fri, 26 Feb 2021 03:47:21 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:41946) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lFY8D-0001vk-1A for qemu-devel@nongnu.org; Fri, 26 Feb 2021 03:05:49 -0500 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]:37622) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lFY8B-0004D7-6m for qemu-devel@nongnu.org; Fri, 26 Feb 2021 03:05:48 -0500 Received: by mail-wr1-x429.google.com with SMTP id v15so7679204wrx.4 for ; Fri, 26 Feb 2021 00:05:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=AAtYqOemksZdw5g1rYUo9+pu9VW+WxY7JUlFmC94moo=; b=bkf9dZiwsls4VYuiVjip7YfhL8TV8JmZcZmhwiX/fbspjaoVQx+G9ooTF7zpgf+WvK QLJOZPDpk0EoDUr8PFHvuXhcePJevp4skPD6rpp7269xCT1LSyGVwipYjNrQEADou15F 83nsyJLyrOxafKBCIIdMF/DqwUgccbTZ5QZ/GZS77bdi7QBSyhTxgq8ZF8mHpB8hZBY7 V2yT5khUPZAP+DwQNK6Z9BxgOGQVJSrwWhRjUDeWUN6xNFetHjNHBlsKzW14lMlLhWu9 k7qB2CjJ+g6EmM5kyGlpaa2hl4HqM0THDOc3gycShVQpoR5wwZEUZ2bLMtgSLjgf4855 lHLQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=AAtYqOemksZdw5g1rYUo9+pu9VW+WxY7JUlFmC94moo=; b=Ciz2OFzUPjd1Avcjd1WI+JLmIYhOceae3oRg4qbA7zqePFvVLYbhzhmKMN3oWb32VE xa9qCahHWFU9fgJCU0TE5QFwOUHzaplMWhmphCta6ZYx+7cJofcivHrDRjlDVZ+fRasY 0ELsZa8vUrNpgvePVH2eynKpz7ZtH5I9qfvAyjFlUPj2Q79B9FQYs0dkjmsixxgE+a54 FaDT9W/5RURFmlFURsOyeYxlcYBqjd7btdrg3CKR4P/JSVKKWVzYfJoTS0zxvt4pQmH7 z6eAobrwHQIRg48ZPpAHC2ZgfZfpXPJKvQ9ti9coSXxUBvxkxmDlaQL9pBn9VLjA6Md6 O6GQ== X-Gm-Message-State: AOAM531DUncfwjIOQCC6DaJkDAYu8RPvj3xRBq/1OCIs+vSiAVJeM+1L PAHptWg5YQ7SFVh2qSzVS45eJ40cWTg= X-Google-Smtp-Source: ABdhPJz69KW8Du/Kh4zrcn3oGpUseErXg05YR4NnGQraPq8XtHyL+9TDpGOyx0hdFTlGiNToTR4RDA== X-Received: by 2002:adf:b641:: with SMTP id i1mr1825442wre.295.1614326745285; Fri, 26 Feb 2021 00:05:45 -0800 (PST) Received: from avogadro.lan ([2001:b07:6468:f312:c8dd:75d4:99ab:290a]) by smtp.gmail.com with ESMTPSA id n66sm10700830wmn.25.2021.02.26.00.05.44 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 26 Feb 2021 00:05:44 -0800 (PST) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PULL 27/29] vl: deprecate -writeconfig Date: Fri, 26 Feb 2021 09:05:24 +0100 Message-Id: <20210226080526.651705-28-pbonzini@redhat.com> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20210226080526.651705-1-pbonzini@redhat.com> References: <20210226080526.651705-1-pbonzini@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2a00:1450:4864:20::429; envelope-from=paolo.bonzini@gmail.com; helo=mail-wr1-x429.google.com X-Spam_score_int: -14 X-Spam_score: -1.5 X-Spam_bar: - X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.249, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.249, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" The functionality of -writeconfig is limited and the code does not even try to detect cases where it prints incorrect syntax (for example if values have a quote in them, since qemu_config_parse does not support any kind of escaping) so remove it. Signed-off-by: Paolo Bonzini --- docs/system/deprecated.rst | 7 +++++++ qemu-options.hx | 7 +------ softmmu/vl.c | 1 + 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/docs/system/deprecated.rst b/docs/system/deprecated.rst index 2fcac7861e..561c916da2 100644 --- a/docs/system/deprecated.rst +++ b/docs/system/deprecated.rst @@ -146,6 +146,13 @@ library enabled as a cryptography provider. Neither the ``nettle`` library, or the built-in cryptography provider are supported on FIPS enabled hosts. +``-writeconfig`` (since 6.0) +''''''''''''''''''''''''''''' + +The ``-writeconfig`` option is not able to serialize the entire contents +of the QEMU command line. It is thus considered a failed experiment +and deprecated, with no current replacement. + QEMU Machine Protocol (QMP) commands ------------------------------------ diff --git a/qemu-options.hx b/qemu-options.hx index 34be5a7a2d..252db9357c 100644 --- a/qemu-options.hx +++ b/qemu-options.hx @@ -4335,13 +4335,8 @@ SRST ERST DEF("writeconfig", HAS_ARG, QEMU_OPTION_writeconfig, "-writeconfig \n" - " read/write config file\n", QEMU_ARCH_ALL) + " read/write config file (deprecated)\n", QEMU_ARCH_ALL) SRST -``-writeconfig file`` - Write device configuration to file. The file can be either filename - to save command line and device configuration into file or dash - ``-``) character to print the output to stdout. This can be later - used as input file for ``-readconfig`` option. ERST DEF("no-user-config", 0, QEMU_OPTION_nouserconfig, diff --git a/softmmu/vl.c b/softmmu/vl.c index b219ce1f35..6d8393b6f7 100644 --- a/softmmu/vl.c +++ b/softmmu/vl.c @@ -3356,6 +3356,7 @@ void qemu_init(int argc, char **argv, char **envp) case QEMU_OPTION_writeconfig: { FILE *fp; + warn_report("-writeconfig is deprecated. It will go away in QEMU 6.2 with no replacement"); if (strcmp(optarg, "-") == 0) { fp = stdout; } else { -- 2.29.2