Re: [PATCH v7 0/5] Introducing QMP query-netdev command

2021-03-12 Thread Alexey Kirillov
ping Patchew page: https://patchew.org/QEMU/20210303095910.78277-1-lekir...@yandex-team.ru 03.03.2021, 13:01, "Alexey Kirillov" : > This patch series introduces a new QMP command "query-netdev" to get > information about currently attached backend network devices

[PATCH v7 5/5] net: Do not fill legacy info_str for backends

2021-03-03 Thread Alexey Kirillov
As we use QAPI NetClientState->stored_config to store and get information about backend network devices, we can drop fill of legacy field info_str for them. We still use info_str field for NIC and hubports, so we can not completely remove it. Signed-off-by: Alexey Kirillov --- net/l2tpv

[PATCH v7 3/5] net: Move NetClientState.info_str to dynamic allocations

2021-03-03 Thread Alexey Kirillov
painlessly discard usage of this field for backend devices. Signed-off-by: Alexey Kirillov --- hw/net/xen_nic.c | 5 ++--- include/net/net.h | 2 +- net/l2tpv3.c | 3 +-- net/net.c | 14 -- net/slirp.c | 5 ++--- net/socket.c

[PATCH v7 1/5] qapi: net: Add query-netdev command

2021-03-03 Thread Alexey Kirillov
le through the NetClientState->stored_config. Signed-off-by: Alexey Kirillov Acked-by: Markus Armbruster --- include/net/net.h | 3 ++ net/l2tpv3.c | 7 +++ net/net.c | 30 +++- net/netmap.c | 7 +++ net/slirp.c | 122 ++

[PATCH v7 4/5] hmp: Use QAPI NetdevInfo in hmp_info_network

2021-03-03 Thread Alexey Kirillov
d hubports still use legacy info_str field. Signed-off-by: Alexey Kirillov --- include/qapi/hmp-output-visitor.h | 30 + net/net.c | 31 - qapi/hmp-output-visitor.c | 193 ++ qapi/meson.build | 1 + 4 fil

[PATCH v7 2/5] tests: Add tests for query-netdev command

2021-03-03 Thread Alexey Kirillov
A simply qtest that checks for correct number of netdevs in the response of the query-netdev. Signed-off-by: Alexey Kirillov Acked-by: Thomas Huth --- tests/qtest/meson.build | 3 + tests/qtest/test-query-netdev.c | 120 2 files changed, 123

[PATCH v7 0/5] Introducing QMP query-netdev command

2021-03-03 Thread Alexey Kirillov
gt;v6: - Add QAPI visitor to generate info_str replacement directly from NetdevInfo. - Make info_str dynamically allocated. - Make commit messages more meaningful. v4->v5: - Enable qtest of query-netdevs for AVR and RX archs. - Bump "Since" version in QAPI to 6.0. v3->v4: - Rename &

[PATCH v6 4/5] hmp: Use QAPI NetdevInfo in hmp_info_network

2021-03-02 Thread Alexey Kirillov
d hubports still use legacy info_str field. Signed-off-by: Alexey Kirillov --- include/qapi/hmp-output-visitor.h | 30 + net/net.c | 31 - qapi/hmp-output-visitor.c | 193 ++ qapi/meson.build | 1 + 4 fil

[PATCH v6 5/5] net: Do not fill legacy info_str for backends

2021-03-02 Thread Alexey Kirillov
As we use QAPI NetClientState->stored_config to store and get information about backend network devices, we can drop fill of legacy field info_str for them. We still use info_str field for NIC and hubports, so we can not completely remove it. Signed-off-by: Alexey Kirillov --- net/l2tpv

[PATCH v6 3/5] net: Move NetClientState.info_str to dynamic allocations

2021-03-02 Thread Alexey Kirillov
painlessly discard usage of this field for backend devices. Signed-off-by: Alexey Kirillov --- hw/net/xen_nic.c | 5 ++--- include/net/net.h | 2 +- net/l2tpv3.c | 3 +-- net/net.c | 14 -- net/slirp.c | 5 ++--- net/socket.c

[PATCH v6 2/5] tests: Add tests for query-netdev command

2021-03-02 Thread Alexey Kirillov
A simply qtest that checks for correct number of netdevs in the response of the query-netdev. Signed-off-by: Alexey Kirillov Acked-by: Thomas Huth --- tests/qtest/meson.build | 3 + tests/qtest/test-query-netdev.c | 120 2 files changed, 123

[PATCH v6 1/5] qapi: net: Add query-netdev command

2021-03-02 Thread Alexey Kirillov
le through the NetClientState->stored_config. Signed-off-by: Alexey Kirillov Acked-by: Markus Armbruster --- include/net/net.h | 3 ++ net/l2tpv3.c | 7 +++ net/net.c | 32 +++- net/netmap.c | 7 +++ net/slirp.c | 124 ++

[PATCH v6 0/5] Introducing QMP query-netdev command

2021-03-02 Thread Alexey Kirillov
Make commit messages more meaningful. v4->v5: - Enable qtest of query-netdevs for AVR and RX archs. - Bump "Since" version in QAPI to 6.0. v3->v4: - Rename "query-netdevs" to "query-netdev". - Copy netdev drivers to new QAPI enum "NetBackend"

Re: [PATCH v2 1/4] qapi: net: Add query-netdevs command

2020-06-23 Thread Alexey Kirillov
`. There is no such trouble to split `query-netdevs` by two, for example, `query-front-netdevs` and `query-back-netdevs`, but in my opinion it'll break consistancy in getting links between netdevs. 05.03.2020, 17:26, "Alexey Kirillov" : > 05.03.2020, 15:03, "Markus Armbruster"

Re: [Xen-devel] [PATCH v2 1/4] qapi: net: Add query-netdevs command

2020-03-05 Thread Alexey Kirillov
05.03.2020, 15:03, "Markus Armbruster" : > Alexey Kirillov writes: > >>  Add a qmp command that provides information about currently attached >>  network devices and their configuration. > > Closes a gap in QMP; appreciated! > >>  Signed-off-by: Alexe

Re: [Xen-devel] [PATCH v2 1/4] qapi: net: Add query-netdevs command

2020-03-05 Thread Alexey Kirillov
04.03.2020, 18:57, "Laurent Vivier" : > On 04/03/2020 14:06, Alexey Kirillov wrote: >>  Add a qmp command that provides information about currently attached >>  network devices and their configuration. >> >>  Signed-off-by: Alexey Kirillov >>  --- >

[Xen-devel] [PATCH v2 0/4] Introducing QMP query-netdevs command

2020-03-04 Thread Alexey Kirillov
"ipv6-prefix": "fec0::", "net": "10.0.2.0/255.255.255.0", "ipv6-host": "fec0::2", "type": "user", "dns": "10.0.2.3", "hostf

[Xen-devel] [PATCH v2 3/4] hmp: Use QMP query-netdevs in hmp_info_network

2020-03-04 Thread Alexey Kirillov
Replace legacy field info_str of NetClientState with result of QMP command query-netdevs. Signed-off-by: Alexey Kirillov --- include/net/net.h | 3 +- net/clients.h | 1 + net/hub.c | 4 +- net/hub.h | 2 +- net/net.c | 175

[Xen-devel] [PATCH v2 4/4] net: Remove field info_str of NetClientState

2020-03-04 Thread Alexey Kirillov
Completely remove the info_str field of struct NetClientState because it is no longer required due to the addition of the QMP query-netdevs command. Signed-off-by: Alexey Kirillov --- hw/net/allwinner_emac.c | 2 +- hw/net/dp8393x.c| 2 +- hw/net/e1000.c | 4

[Xen-devel] [PATCH v2 1/4] qapi: net: Add query-netdevs command

2020-03-04 Thread Alexey Kirillov
Add a qmp command that provides information about currently attached network devices and their configuration. Signed-off-by: Alexey Kirillov --- include/net/net.h | 1 + net/hub.c | 8 +++ net/l2tpv3.c | 19 +++ net/net.c | 91

[Xen-devel] [PATCH v2 2/4] tests: Add tests for query-netdevs command

2020-03-04 Thread Alexey Kirillov
Signed-off-by: Alexey Kirillov --- tests/qtest/Makefile.include | 2 + tests/qtest/test-query-netdevs.c | 120 +++ 2 files changed, 122 insertions(+) create mode 100644 tests/qtest/test-query-netdevs.c diff --git a/tests/qtest/Makefile.include b/tests/qtest