Skip to contentSkip to conversation

Test failure with Smartfusion2 emac block (msf2-emac)

DISCUSSION Thomas Huth 3 participants 4 messages Jul 7, 2020 – Jul 16, 2020

lore
Share & tools
lore
#0 lore raw

Hi Subbaraya,

today, I noticed that there is a test failure with msf2-emac when running the device-introspect-test in slow mode. Either run:

make check-qtest-aarch64 SPEED=slow

or as a shortcut:

make tests/qtest/device-introspect-test QTEST_QEMU_BINARY="aarch64-softmmu/qemu-system-aarch64" \
./tests/qtest/device-introspect-test -m slow

Then the test fails with:

Unexpected error in error_set_from_qdev_prop_error() at hw/core/qdev-properties.c:1251:
Property 'msf2-emac.netdev' can't take value 'hub0port0', it's in use

Could you please have a look?

Thanks,
Thomas

#1 lore raw
Quoted 14 lines · Thomas Huth

Hi Subbaraya,

today, I noticed that there is a test failure with msf2-emac when running the device-introspect-test in slow mode. Either run:

make check-qtest-aarch64 SPEED=slow

or as a shortcut:

make tests/qtest/device-introspect-test QTEST_QEMU_BINARY="aarch64-softmmu/qemu-system-aarch64" \
./tests/qtest/device-introspect-test -m slow

Quoted 7 lines

Then the test fails with:

Unexpected error in error_set_from_qdev_prop_error() at hw/core/qdev-properties.c:1251:
Property 'msf2-emac.netdev' can't take value 'hub0port0', it's in use

Could you please have a look?

The problem might be related to m2sxxx_soc_initfn() in msf2-soc.c. Looks like you are using nd_table in an instance_init function. This is almost always wrong, and should be done by the machine code instead (e.g. in msf2-som.c).

Thomas

PS: Maybe also have a look at this article, it might help to understand the idea behind instance_init a little bit:
http://people.redhat.com/~thuth/blog/qemu/2018/09/10/instance-init-realize.html

#2 lore raw

Ping?

Quoted 36 lines · Thomas Huth
Quoted 14 lines · Thomas Huth

Hi Subbaraya,

today, I noticed that there is a test failure with msf2-emac when running the device-introspect-test in slow mode. Either run:

make check-qtest-aarch64 SPEED=slow

or as a shortcut:

make tests/qtest/device-introspect-test QTEST_QEMU_BINARY="aarch64-softmmu/qemu-system-aarch64" \
./tests/qtest/device-introspect-test -m slow

Quoted 7 lines

Then the test fails with:

Unexpected error in error_set_from_qdev_prop_error() at hw/core/qdev-properties.c:1251:
Property 'msf2-emac.netdev' can't take value 'hub0port0', it's in use

Could you please have a look?

The problem might be related to m2sxxx_soc_initfn() in msf2-soc.c. Looks like you are using nd_table in an instance_init function. This is almost always wrong, and should be done by the machine code instead (e.g. in msf2-som.c).

Thomas

PS: Maybe also have a look at this article, it might help to understand the idea behind instance_init a little bit:
http://people.redhat.com/~thuth/blog/qemu/2018/09/10/instance-init-realize.html

#3 lore raw

Hi Thomas,

I will check and get back to you in a week.
Hope that's okay.

Thanks,
Sundeep

Quoted 40 lines · Philippe Mathieu-Daudé

Ping?

Quoted 36 lines · Thomas Huth
Quoted 14 lines · Thomas Huth

Hi Subbaraya,

today, I noticed that there is a test failure with msf2-emac when running the device-introspect-test in slow mode. Either run:

make check-qtest-aarch64 SPEED=slow

or as a shortcut:

make tests/qtest/device-introspect-test QTEST_QEMU_BINARY="aarch64-softmmu/qemu-system-aarch64" \
./tests/qtest/device-introspect-test -m slow

Quoted 7 lines

Then the test fails with:

Unexpected error in error_set_from_qdev_prop_error() at hw/core/qdev-properties.c:1251:
Property 'msf2-emac.netdev' can't take value 'hub0port0', it's in use

Could you please have a look?

The problem might be related to m2sxxx_soc_initfn() in msf2-soc.c. Looks like you are using nd_table in an instance_init function. This is almost always wrong, and should be done by the machine code instead (e.g. in msf2-som.c).

Thomas

PS: Maybe also have a look at this article, it might help to understand the idea behind instance_init a little bit:
http://people.redhat.com/~thuth/blog/qemu/2018/09/10/instance-init-realize.html