Skip to content

chardev/mux: implement frontend detach

Roman Penyaev qemu-devel 2 versions In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest8 patches 6 repliesIn review
  2. v18 patches 6 repliesSuperseded

Changes in v2 from the cover letter

* improve if condition and assert for bit verification

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/8chardev/char: fix qemu_chr_is_busy() checkchardev/char.c+1 -10 replies
2/8chardev/chardev-internal: remove unused `max_size` struct memberchardev/chardev-internal.h+0 -11 reply
3/8chardev/mux: use bool type for `linestart` and `term_got_escape`chardev/char-mux.c chardev/chardev-internal.h+7 -71 reply
4/8chardev/mux: convert size members to unsigned intchardev/char-fe.c chardev/char-mux.c chardev/chardev-internal.h +1 more+11 -110 replies
5/8chardev/mux: introduce `mux_chr_attach_frontend() callchardev/char-fe.c chardev/char-mux.c chardev/chardev-internal.h+20 -80 replies
6/8chardev/mux: switch mux frontends management to bitsetchardev/char-mux.c chardev/char.c chardev/chardev-internal.h+30 -160 replies
7/8chardev/mux: implement detach of frontends from muxchardev/char-fe.c chardev/char-mux.c chardev/chardev-internal.h+20 -42 replies
8/8tests/unit/test-char: implement a few mux remove test casestests/unit/test-char.c+23 -12 replies

Reviews trailers per patch

2 of 8 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchMarc-André LureauClément Mathieu--Drif
SeriesR-b
1/8
2/8R-b
3/8R-b
4/8
5/8
6/8
7/8
8/8

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/8] chardev/mux: implement frontend detach

Frontend device can be detached in run-time, which can lead to a "Chardev 'MUX' is busy" error (see the last patch with the test case implementation). This series implements frontend detach for the multiplexer based on bitset, which provides the ability to attach or detach frontend devices in any order.

Also first patches do some refactoring the purpose of which is to make integer unsigned where possible (such as sizes or lengths).

v1->v2:
* improve if condition and assert for bit verification

Roman Penyaev (8):
chardev/char: fix qemu_chr_is_busy() check chardev/chardev-internal: remove unused max_size struct member chardev/mux: use bool type for linestart and term_got_escape chardev/mux: convert size members to unsigned int chardev/mux: introduce `mux_chr_attach_frontend() call chardev/mux: switch mux frontends management to bitset chardev/mux: implement detach of frontends from mux tests/unit/test-char: implement a few mux remove test cases

 chardev/char-fe.c          | 13 ++----
 chardev/char-mux.c         | 90 ++++++++++++++++++++++++++++----------
 chardev/char.c             |  2 +-
 chardev/chardev-internal.h | 16 ++++---
 include/chardev/char-fe.h  |  2 +-
 tests/unit/test-char.c     | 24 +++++++++-
 6 files changed, 105 insertions(+), 42 deletions(-)
Signature · 1 line
2.34.1