From: Thomas Huth <thuth@redhat.com>
To: Ninad Palsule <ninad@linux.ibm.com>,
qemu-devel@nongnu.org, clg@kaod.org, peter.maydell@linaro.org,
andrew@aj.id.au, joel@jms.id.au, pbonzini@redhat.com,
marcandre.lureau@redhat.com, berrange@redhat.com,
philmd@linaro.org, lvivier@redhat.com
Cc: qemu-arm@nongnu.org
Subject: Re: [PATCH v5 08/10] hw/fsi: Added qtest
Date: Wed, 11 Oct 2023 17:35:09 +0200 [thread overview]
Message-ID: <cacc4a01-88e9-4631-a6d6-fbee2b483fd6@redhat.com> (raw)
In-Reply-To: <20231011151339.2782132-9-ninad@linux.ibm.com>
On 11/10/2023 17.13, Ninad Palsule wrote:
> Added basic qtests for FSI model.
>
> Signed-off-by: Ninad Palsule <ninad@linux.ibm.com>
> ---
> v3:
> - Added new qtest as per Cedric's comment.
> V4:
> - Remove MAINTAINER and documentation changes from this commit
> ---
> tests/qtest/fsi-test.c | 210 ++++++++++++++++++++++++++++++++++++++++
> tests/qtest/meson.build | 2 +
> 2 files changed, 212 insertions(+)
> create mode 100644 tests/qtest/fsi-test.c
>
> diff --git a/tests/qtest/fsi-test.c b/tests/qtest/fsi-test.c
> new file mode 100644
> index 0000000000..30bb7475c7
> --- /dev/null
> +++ b/tests/qtest/fsi-test.c
> @@ -0,0 +1,210 @@
...
> +int main(int argc, char **argv)
> +{
> + int ret = -1;
> + QTestState *s;
> +
> + g_test_init(&argc, &argv, NULL);
> +
> + s = qtest_init("-machine ast2600-evb ");
> + if (s == NULL) {
> + return -ENOMEM;
returning -ENOMEM here does not make too much sense ... and actually
qtest_init() cannot return NULL. So please drop this if-statement.
> + }
> +
> + /* Tests for OPB/FSI0 */
> + qtest_add_data_func("/fsi-test/test_fsi0_master_regs", s,
> + test_fsi0_master_regs);
> +
> + qtest_add_data_func("/fsi-test/test_fsi0_getcfam_addr0", s,
> + test_fsi0_getcfam_addr0);
> +
> + /* Tests for OPB/FSI1 */
> + qtest_add_data_func("/fsi-test/test_fsi1_master_regs", s,
> + test_fsi1_master_regs);
> +
> + qtest_add_data_func("/fsi-test/test_fsi1_getcfam_addr0", s,
> + test_fsi1_getcfam_addr0);
> +
> + ret = g_test_run();
> + qtest_quit(s);
> +
> + return ret;
> +}
> diff --git a/tests/qtest/meson.build b/tests/qtest/meson.build
> index b071d400b3..5976081b44 100644
> --- a/tests/qtest/meson.build
> +++ b/tests/qtest/meson.build
> @@ -207,6 +207,7 @@ qtests_arm = \
> (config_all_devices.has_key('CONFIG_TPM_TIS_I2C') ? ['tpm-tis-i2c-test'] : []) + \
> (config_all_devices.has_key('CONFIG_VEXPRESS') ? ['test-arm-mptimer'] : []) + \
> (config_all_devices.has_key('CONFIG_MICROBIT') ? ['microbit-test'] : []) + \
> + (config_all_devices.has_key('CONFIG_FSI_APB2OPB_ASPEED') ? ['fsi-test'] : []) + \
> ['arm-cpu-features',
> 'boot-serial-test']
>
> @@ -318,6 +319,7 @@ qtests = {
> 'tpm-tis-device-test': [io, tpmemu_files, 'tpm-tis-util.c'],
> 'vmgenid-test': files('boot-sector.c', 'acpi-utils.c'),
> 'netdev-socket': files('netdev-socket.c', '../unit/socket-helpers.c'),
> + 'fsi-test': files('fsi-test.c'),
I think this hunk here is not required - you only need to specify additional
dependencies here, not the main file.
Thomas
next prev parent reply other threads:[~2023-10-11 15:35 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-11 15:13 [PATCH v5 00/10] Introduce model for IBM's FSI Ninad Palsule
2023-10-11 15:13 ` [PATCH v5 01/10] hw/fsi: Introduce IBM's Local bus Ninad Palsule
2023-10-19 8:03 ` Cédric Le Goater
2023-10-21 20:20 ` Ninad Palsule
2023-10-19 8:08 ` Cédric Le Goater
2023-10-21 20:21 ` Ninad Palsule
2023-10-19 8:14 ` Daniel P. Berrangé
2023-10-19 15:34 ` Ninad Palsule
2023-10-19 16:09 ` Daniel P. Berrangé
2023-10-21 20:22 ` Ninad Palsule
2023-10-11 15:13 ` [PATCH v5 02/10] hw/fsi: Introduce IBM's scratchpad Ninad Palsule
2023-10-19 8:20 ` Daniel P. Berrangé
2023-10-21 20:27 ` Ninad Palsule
2023-10-11 15:13 ` [PATCH v5 03/10] hw/fsi: Introduce IBM's cfam,fsi-slave Ninad Palsule
2023-10-19 8:00 ` Cédric Le Goater
2023-10-21 20:33 ` Ninad Palsule
2023-10-19 8:26 ` Daniel P. Berrangé
2023-10-21 20:34 ` Ninad Palsule
2023-10-19 17:28 ` Cédric Le Goater
2023-10-21 20:35 ` Ninad Palsule
2023-10-11 15:13 ` [PATCH v5 04/10] hw/fsi: Introduce IBM's FSI Ninad Palsule
2023-10-19 7:44 ` Cédric Le Goater
2023-10-21 20:36 ` Ninad Palsule
2023-10-19 8:28 ` Daniel P. Berrangé
2023-10-21 20:37 ` Ninad Palsule
2023-10-11 15:13 ` [PATCH v5 05/10] hw/fsi: IBM's On-chip Peripheral Bus Ninad Palsule
2023-10-19 7:26 ` Cédric Le Goater
2023-10-21 20:40 ` Ninad Palsule
2023-10-19 8:30 ` Daniel P. Berrangé
2023-10-21 20:42 ` Ninad Palsule
2023-10-11 15:13 ` [PATCH v5 06/10] hw/fsi: Aspeed APB2OPB interface Ninad Palsule
2023-10-19 7:16 ` Cédric Le Goater
2023-10-21 20:43 ` Ninad Palsule
2023-10-11 15:13 ` [PATCH v5 07/10] hw/arm: Hook up FSI module in AST2600 Ninad Palsule
2023-10-11 15:13 ` [PATCH v5 08/10] hw/fsi: Added qtest Ninad Palsule
2023-10-11 15:35 ` Thomas Huth [this message]
2023-10-11 16:54 ` Ninad Palsule
2023-10-11 15:13 ` [PATCH v5 09/10] hw/fsi: Added FSI documentation Ninad Palsule
2023-10-11 15:13 ` [PATCH v5 10/10] hw/fsi: Update MAINTAINER list Ninad Palsule
2023-10-19 8:16 ` [PATCH v5 00/10] Introduce model for IBM's FSI Cédric Le Goater
2023-10-21 20:45 ` Ninad Palsule
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=cacc4a01-88e9-4631-a6d6-fbee2b483fd6@redhat.com \
--to=thuth@redhat.com \
--cc=andrew@aj.id.au \
--cc=berrange@redhat.com \
--cc=clg@kaod.org \
--cc=joel@jms.id.au \
--cc=lvivier@redhat.com \
--cc=marcandre.lureau@redhat.com \
--cc=ninad@linux.ibm.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=philmd@linaro.org \
--cc=qemu-arm@nongnu.org \
--cc=qemu-devel@nongnu.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).