From: Collin Walling <walling@linux.ibm.com>
To: qemu-devel@nongnu.org, qemu-s390x@nongnu.org
Cc: Hendrik Brueckner <brueckner@linux.ibm.com>,
David Hildenbrand <david@kernel.org>,
Richard Henderson <richard.henderson@linaro.org>,
Ilya Leoshkevich <iii@linux.ibm.com>,
Cornelia Huck <cohuck@redhat.com>,
Eric Farman <farman@linux.ibm.com>,
Matthew Rosato <mjrosato@linux.ibm.com>,
qemu-stable@nongnu.org
Subject: [PATCH v2 2/2] target/s390x: mark feats dependent on deprecated feats as deprecated
Date: Fri, 9 Oct 2026 14:55:59 -0400 [thread overview]
Message-ID: <20261009185559.144750-3-walling@linux.ibm.com> (raw)
In-Reply-To: <20261009185559.144750-1-walling@linux.ibm.com>
There are certain CPU model features that depend on other features
that are flagged for deprecation. For example `ineff_nc_tx` depends
on the `te` deprecated feature.
If a user defines a VM with the current list of deprecated features
disabled, the following warning occurs:
warning: 'ineff_nc_tx' requires 'te'
To alleviate this, add these "dependent features" to the deprecated
features list. This allows the user to see *all* features that should
be disabled to ensure a successful migration to a host system that
may not support certain deprecated features.
Fixes: 6e55b32d45 ("target/s390x: flag te and cte as deprecated")
Signed-off-by: Collin Walling <walling@linux.ibm.com>
Reviewed-by: Hendrik Brueckner <brueckner@linux.ibm.com>
---
target/s390x/cpu_features.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/target/s390x/cpu_features.c b/target/s390x/cpu_features.c
index 20f9947c7be..babee7f5bac 100644
--- a/target/s390x/cpu_features.c
+++ b/target/s390x/cpu_features.c
@@ -360,10 +360,23 @@ void s390_get_deprecated_features(S390FeatBitmap features)
S390_FEAT_TRANSACTIONAL_EXE
};
int i;
+ bool restart;
for (i = 0; i < ARRAY_SIZE(feats); i++) {
set_bit(feats[i], features);
}
+
+ /* Mark features that depend on any deprecated feature */
+ do {
+ restart = false;
+ for (i = 0; i < s390_feat_deps_len; i++) {
+ if (test_bit(s390_feat_deps[i][1], features) &&
+ !test_and_set_bit(s390_feat_deps[i][0], features)) {
+ /* Restart in case set features have other dependencies */
+ restart = true;
+ }
+ }
+ } while (restart);
}
#define FEAT_GROUP_INIT(_name, _group, _desc) \
--
2.55.0
next prev parent reply other threads:[~2026-10-09 18:59 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-09 18:55 [PATCH v2 0/2] s390: mark features that depend on deprecated features as deprecated Collin Walling
2026-10-09 18:55 ` [PATCH v2 1/2] target/s390x: externalize feat dependency array Collin Walling
2026-10-09 20:37 ` Matthew Rosato
2026-10-09 18:55 ` Collin Walling [this message]
2026-10-09 20:41 ` [PATCH v2 2/2] target/s390x: mark feats dependent on deprecated feats as deprecated Matthew Rosato
2026-10-09 21:07 ` Eric Farman
2026-10-09 20:37 ` [PATCH v2 0/2] s390: mark features that depend on deprecated features " Matthew Rosato
2026-10-09 21:09 ` Eric Farman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261009185559.144750-3-walling@linux.ibm.com \
--to=walling@linux.ibm.com \
--cc=brueckner@linux.ibm.com \
--cc=cohuck@redhat.com \
--cc=david@kernel.org \
--cc=farman@linux.ibm.com \
--cc=iii@linux.ibm.com \
--cc=mjrosato@linux.ibm.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-s390x@nongnu.org \
--cc=qemu-stable@nongnu.org \
--cc=richard.henderson@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.