Hi guys,
I'm trying to enable migration from MtCollins(Ampere Altra, ARMv8.2+) to
AmpereOne(AmpereOne, ARMv8.6+), the migration always fails when migration from
MtCollins to AmpereOne due to some register fields differing between the
two machines.
In this patch series, we try to make more register fields writable like
ID_AA64PFR1_EL1.BT. This is first step towards making the migration possible.
Some other hurdles need to be overcome. This is not sufficient to make the
migration successful from MtCollins to AmpereOne.
Shaoqin Huang (2):
KVM: arm64: Allow BT field in ID_AA64PFR1_EL1 writable
KVM: selftests: aarch64: Add writable test for ID_AA64PFR1_EL1
arch/arm64/kvm/sys_regs.c | 2 +-
tools/testing/selftests/kvm/aarch64/set_id_regs.c | 6 ++++++
2 files changed, 7 insertions(+), 1 deletion(-)
--
2.40.1
From: Geliang Tang <tanggeliang(a)kylinos.cn>
v3:
- rename start_client to client_socket
- Use connect_to_addr in connect_to_fd_opt
v2:
- update patch 2, extract a new helper start_client.
- drop patch 3, keep must_fail in network_helper_opts.
Drop type and noconnect from network_helper_opts. And use start_server_str
in mptcp and test_tcp_check_syncookie_user.
Patches 1-4 address Martin's comments in the previous series.
Geliang Tang (6):
selftests/bpf: Drop type from network_helper_opts
selftests/bpf: Use connect_to_addr in connect_to_fd_opt
selftests/bpf: Add client_socket helper
selftests/bpf: Drop noconnect from network_helper_opts
selftests/bpf: Use start_server_str in mptcp
selftests/bpf: Use start_server_str in test_tcp_check_syncookie_user
tools/testing/selftests/bpf/network_helpers.c | 100 ++++++++----------
tools/testing/selftests/bpf/network_helpers.h | 6 +-
.../selftests/bpf/prog_tests/bpf_tcp_ca.c | 2 +-
.../selftests/bpf/prog_tests/cgroup_v1v2.c | 4 +-
.../bpf/prog_tests/ip_check_defrag.c | 10 +-
.../testing/selftests/bpf/prog_tests/mptcp.c | 7 +-
.../bpf/test_tcp_check_syncookie_user.c | 29 +----
7 files changed, 56 insertions(+), 102 deletions(-)
--
2.43.0
Hi,
this is a v3 patch set as a follow up of the thread about the errors
reported by kselftest mixer-test. It changes HD-audio and vmaster
control behavior to return -EINVAL for invalid input values.
There is a change in kselftest itself to skip the verification after
write tests for volatile controls, too. It's for the channel map
controls that can't hold the stable values.
v2->v3:
* Replace with Mark's patch for kselftest
* Apply the validation for user controls in put callback instead
v1->v2:
* Skip only verification after write in kselftest
* Add sanity check to HDMI chmap write, too
v2: https://lore.kernel.org/r/20240614153717.30143-1-tiwai@suse.de
v1: https://lore.kernel.org/r/20240614124728.27901-1-tiwai@suse.de
Takashi
===
Mark Brown (1):
kselftest/alsa: Fix validation of writes to volatile controls
Takashi Iwai (5):
ALSA: vmaster: Return error for invalid input values
ALSA: hda: Return -EINVAL for invalid volume/switch inputs
ALSA: control: Apply sanity check of input values for user elements
ALSA: chmap: Mark Channel Map controls as volatile
ALSA: hda: Add input value sanity checks to HDMI channel map controls
sound/core/control.c | 6 ++-
sound/core/pcm_lib.c | 1 +
sound/core/vmaster.c | 8 ++++
sound/hda/hdmi_chmap.c | 18 +++++++++
sound/pci/hda/hda_codec.c | 23 +++++++++---
tools/testing/selftests/alsa/mixer-test.c | 45 +++++++++++++++--------
6 files changed, 79 insertions(+), 22 deletions(-)
--
2.43.0
When validating writes to controls we check that whatever value we wrote
actually appears in the control. For volatile controls we cannot assume
that this will be the case, the value may be changed at any time
including between our write and read. Handle this by moving the check
for volatile controls that we currently do for events to a separate
block and just verifying that whatever value we read is valid for the
control.
Signed-off-by: Mark Brown <broonie(a)kernel.org>
---
tools/testing/selftests/alsa/mixer-test.c | 45 ++++++++++++++++++++-----------
1 file changed, 29 insertions(+), 16 deletions(-)
diff --git a/tools/testing/selftests/alsa/mixer-test.c b/tools/testing/selftests/alsa/mixer-test.c
index 1c04e5f638a0..dd74f8cc7ece 100644
--- a/tools/testing/selftests/alsa/mixer-test.c
+++ b/tools/testing/selftests/alsa/mixer-test.c
@@ -625,6 +625,21 @@ static int write_and_verify(struct ctl_data *ctl,
return err;
}
+ /*
+ * We can't verify any specific value for volatile controls
+ * but we should still check that whatever we read is a valid
+ * vale for the control.
+ */
+ if (snd_ctl_elem_info_is_volatile(ctl->info)) {
+ if (!ctl_value_valid(ctl, read_val)) {
+ ksft_print_msg("Volatile control %s has invalid value\n",
+ ctl->name);
+ return -EINVAL;
+ }
+
+ return 0;
+ }
+
/*
* Check for an event if the value changed, or confirm that
* there was none if it didn't. We rely on the kernel
@@ -632,22 +647,20 @@ static int write_and_verify(struct ctl_data *ctl,
* write, this is currently true, should that ever change this
* will most likely break and need updating.
*/
- if (!snd_ctl_elem_info_is_volatile(ctl->info)) {
- err = wait_for_event(ctl, 0);
- if (snd_ctl_elem_value_compare(initial_val, read_val)) {
- if (err < 1) {
- ksft_print_msg("No event generated for %s\n",
- ctl->name);
- show_values(ctl, initial_val, read_val);
- ctl->event_missing++;
- }
- } else {
- if (err != 0) {
- ksft_print_msg("Spurious event generated for %s\n",
- ctl->name);
- show_values(ctl, initial_val, read_val);
- ctl->event_spurious++;
- }
+ err = wait_for_event(ctl, 0);
+ if (snd_ctl_elem_value_compare(initial_val, read_val)) {
+ if (err < 1) {
+ ksft_print_msg("No event generated for %s\n",
+ ctl->name);
+ show_values(ctl, initial_val, read_val);
+ ctl->event_missing++;
+ }
+ } else {
+ if (err != 0) {
+ ksft_print_msg("Spurious event generated for %s\n",
+ ctl->name);
+ show_values(ctl, initial_val, read_val);
+ ctl->event_spurious++;
}
}
---
base-commit: 83a7eefedc9b56fe7bfeff13b6c7356688ffa670
change-id: 20240614-alsa-selftest-volatile-d6f3e8e28c08
Best regards,
--
Mark Brown <broonie(a)kernel.org>
Hi,
this is a revised patch set as a follow up of the thread about the
errors reported by kselftest mixer-test. It changes HD-audio and
vmaster control behavior to return -EINVAL for invalid input values.
There is a change in kselftest itself to skip the verification after
write tests for volatile controls, too. It's for the channel map
controls that can't hold the stable values.
v1->v2:
* Skip only verification after write in kselftest
* Add sanity check to HDMI chmap write, too
Takashi
===
Takashi Iwai (6):
ALSA: vmaster: Return error for invalid input values
ALSA: hda: Return -EINVAL for invalid volume/switch inputs
ALSA: control: Apply sanity check of input values for user elements
kselftest/alsa: mixer-test: Skip write verification for volatile
controls
ALSA: chmap: Mark Channel Map controls as volatile
ALSA: hda: Add input value sanity checks to HDMI channel map controls
sound/core/control.c | 3 ++-
sound/core/pcm_lib.c | 1 +
sound/core/vmaster.c | 8 ++++++++
sound/hda/hdmi_chmap.c | 18 ++++++++++++++++++
sound/pci/hda/hda_codec.c | 23 ++++++++++++++++++-----
tools/testing/selftests/alsa/mixer-test.c | 4 ++++
6 files changed, 51 insertions(+), 6 deletions(-)
--
2.43.0
The goal of this series is to use helpers from net/lib.sh with MPTCP
selftests.
- Patches 1 to 4 are some clean-ups and preparation in net/lib.sh:
- Patch 1 simplifies the code handling errexit by ignoring possible
errors instead of disabling errexit temporary.
- Patch 2 removes the netns from the list after having cleaned it, not
to try to clean it twice.
- Patch 3 removes the 'readonly' attribute for the netns variable, to
allow using the same name in local variables.
- Patch 4 removes the local 'ns' var, not to conflict with the global
one it needs to setup.
- Patch 5 uses helpers from net/lib.sh to create and delete netns in
MPTCP selftests.
- Patch 6 uses wait_local_port_listen helper from net/net_helper.sh.
Signed-off-by: Matthieu Baerts (NGI0) <matttbe(a)kernel.org>
---
Geliang Tang (3):
selftests: net: lib: remove 'ns' var in setup_ns
selftests: mptcp: lib: use setup/cleanup_ns helpers
selftests: mptcp: lib: use wait_local_port_listen helper
Matthieu Baerts (NGI0) (3):
selftests: net: lib: ignore possible errors
selftests: net: lib: remove ns from list after clean-up
selftests: net: lib: do not set ns var as readonly
tools/testing/selftests/net/lib.sh | 55 +++++++++++++++-----------
tools/testing/selftests/net/mptcp/mptcp_lib.sh | 33 +++++-----------
2 files changed, 42 insertions(+), 46 deletions(-)
---
base-commit: a999973236543f0b8f6daeaa7ecba7488c3a593b
change-id: 20240607-upstream-net-next-20240607-selftests-mptcp-net-lib-365e43e2e1ca
Best regards,
--
Matthieu Baerts (NGI0) <matttbe(a)kernel.org>