From: Eric Farman <farman@linux.ibm.com>
To: qemu-devel@nongnu.org
Cc: qemu-s390x@nongnu.org, Matthew Rosato <mjrosato@linux.ibm.com>,
Cornelia Huck <cohuck@redhat.com>,
Collin Walling <walling@linux.ibm.com>,
Hendrik Brueckner <brueckner@linux.ibm.com>,
Eric Farman <farman@linux.ibm.com>
Subject: [PULL 2/6] target/s390x: mark feats dependent on deprecated feats as deprecated
Date: Mon, 26 Oct 2026 10:01:49 -0400 [thread overview]
Message-ID: <20261026140153.2072253-3-farman@linux.ibm.com> (raw)
In-Reply-To: <20261026140153.2072253-1-farman@linux.ibm.com>
From: Collin Walling <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>
Tested-by: Eric Farman <farman@linux.ibm.com>
Reviewed-by: Matthew Rosato <mjrosato@linux.ibm.com>
Reviewed-by: Eric Farman <farman@linux.ibm.com>
Link: https://lore.kernel.org/qemu-devel/20261009185559.144750-3-walling@linux.ibm.com
Signed-off-by: Eric Farman <farman@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 20f9947c7b..babee7f5ba 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.56.0
next prev parent reply other threads:[~2026-10-26 14:08 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-26 14:01 [PULL 0/6] s390x queue for 11.2 Eric Farman
2026-10-26 14:01 ` [PULL 1/6] target/s390x: externalize feat dependency array Eric Farman
2026-10-26 14:01 ` Eric Farman [this message]
2026-10-26 14:01 ` [PULL 3/6] s390x/sclpconsole: implement resizing for vt220 consoles Eric Farman
2026-10-26 14:01 ` [PULL 4/6] s390x/pci: reclaim DMA slots upon IOMMU disable Eric Farman
2026-10-26 14:01 ` [PULL 5/6] MAINTAINERS: Add other s390x tree Eric Farman
2026-10-26 14:01 ` [PULL 6/6] MAINTAINERS: Update s390 boot reviewer Eric Farman
2026-10-27 22:25 ` [PULL 0/6] s390x queue for 11.2 Richard Henderson
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=20261026140153.2072253-3-farman@linux.ibm.com \
--to=farman@linux.ibm.com \
--cc=brueckner@linux.ibm.com \
--cc=cohuck@redhat.com \
--cc=mjrosato@linux.ibm.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-s390x@nongnu.org \
--cc=walling@linux.ibm.com \
/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.