<feed xmlns='http://www.w3.org/2005/Atom'>
<title>bwlp/qemu.git/fsdev, branch master</title>
<subtitle>Experimental fork of QEMU with video encoding patches</subtitle>
<id>https://git.openslx.org/bwlp/qemu.git/atom/fsdev?h=master</id>
<link rel='self' href='https://git.openslx.org/bwlp/qemu.git/atom/fsdev?h=master'/>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/'/>
<updated>2022-10-24T10:24:32+00:00</updated>
<entry>
<title>fsdev/virtfs-proxy-helper: Use g_mkdir()</title>
<updated>2022-10-24T10:24:32+00:00</updated>
<author>
<name>Bin Meng</name>
</author>
<published>2022-09-27T11:06:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=f723f626627fda681327075105701695d7c630e5'/>
<id>urn:sha1:f723f626627fda681327075105701695d7c630e5</id>
<content type='text'>
Use g_mkdir() to create a directory on all platforms.

Signed-off-by: Bin Meng &lt;bin.meng@windriver.com&gt;
Reviewed-by: Christian Schoenebeck &lt;qemu_oss@crudebyte.com&gt;
Message-Id: &lt;20220927110632.1973965-27-bmeng.cn@gmail.com&gt;
Signed-off-by: Christian Schoenebeck &lt;qemu_oss@crudebyte.com&gt;
</content>
</entry>
<entry>
<title>Remove qemu-common.h include from most units</title>
<updated>2022-04-06T12:31:55+00:00</updated>
<author>
<name>Marc-André Lureau</name>
</author>
<published>2022-03-23T15:57:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=0f9668e0c197ab6de95f61a906703a1d127c11f8'/>
<id>urn:sha1:0f9668e0c197ab6de95f61a906703a1d127c11f8</id>
<content type='text'>
Signed-off-by: Marc-André Lureau &lt;marcandre.lureau@redhat.com&gt;
Message-Id: &lt;20220323155743.1585078-33-marcandre.lureau@redhat.com&gt;
Signed-off-by: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
</content>
</entry>
<entry>
<title>Replace GCC_FMT_ATTR with G_GNUC_PRINTF</title>
<updated>2022-03-22T10:40:51+00:00</updated>
<author>
<name>Marc-André Lureau</name>
</author>
<published>2022-02-20T16:39:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=9edc6313da34699ebd2bae4573ea22339b26450a'/>
<id>urn:sha1:9edc6313da34699ebd2bae4573ea22339b26450a</id>
<content type='text'>
One less qemu-specific macro. It also helps to make some headers/units
only depend on glib, and thus moved in standalone projects eventually.

Signed-off-by: Marc-André Lureau &lt;marcandre.lureau@redhat.com&gt;
Reviewed-by: Richard W.M. Jones &lt;rjones@redhat.com&gt;
</content>
</entry>
<entry>
<title>fsdev/p9array.h: convert Doxygen -&gt; kerneldoc format</title>
<updated>2022-03-07T10:49:31+00:00</updated>
<author>
<name>Christian Schoenebeck</name>
</author>
<published>2022-03-03T13:37:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=35b6466459f9234b9cb30296f243a70b6f1b44b7'/>
<id>urn:sha1:35b6466459f9234b9cb30296f243a70b6f1b44b7</id>
<content type='text'>
API doc comments in QEMU are supposed to be in kerneldoc format, so
convert API doc comments from Doxygen format to kerneldoc format.

Signed-off-by: Christian Schoenebeck &lt;qemu_oss@crudebyte.com&gt;
Reviewed-by: Greg Kurz &lt;groug@kaod.org&gt;
Message-Id: &lt;2e2d46a402560f155de322d95789ba107d728885.1646314856.git.qemu_oss@crudebyte.com&gt;
</content>
</entry>
<entry>
<title>9p: darwin: meson: Allow VirtFS on Darwin</title>
<updated>2022-03-07T10:49:31+00:00</updated>
<author>
<name>Keno Fischer</name>
</author>
<published>2022-02-27T22:35:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=0fb1e19d78536e23b650ca72decdc29c98f2dcc1'/>
<id>urn:sha1:0fb1e19d78536e23b650ca72decdc29c98f2dcc1</id>
<content type='text'>
To allow VirtFS on darwin, we need to check that pthread_fchdir_np is
available, which has only been available since macOS 10.12.

Additionally, virtfs_proxy_helper is disabled on Darwin. This patch
series does not currently provide an implementation of the proxy-helper,
but this functionality could be implemented later on.

Signed-off-by: Keno Fischer &lt;keno@juliacomputing.com&gt;
[Michael Roitzsch: - Rebase for NixOS]
Signed-off-by: Michael Roitzsch &lt;reactorcontrol@icloud.com&gt;
[Will Cohen: - Rebase to master]
Signed-off-by: Will Cohen &lt;wwcohen@gmail.com&gt;
Reviewed-by: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
[Will Cohen: - Add check for pthread_fchdir_np to virtfs
             - Add comments to patch commit
             - Note that virtfs_proxy_helper does not work
               on macOS
             - Fully adjust meson virtfs error note to specify
               macOS
             - Rebase to master]
Signed-off-by: Will Cohen &lt;wwcohen@gmail.com&gt;
Message-Id: &lt;20220227223522.91937-12-wwcohen@gmail.com&gt;
Signed-off-by: Christian Schoenebeck &lt;qemu_oss@crudebyte.com&gt;
Acked-by: Christian Schoenebeck &lt;qemu_oss@crudebyte.com&gt;
</content>
</entry>
<entry>
<title>9p: linux: Fix a couple Linux assumptions</title>
<updated>2022-03-07T10:49:30+00:00</updated>
<author>
<name>Keno Fischer</name>
</author>
<published>2022-02-27T22:35:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=e0bd743bb2dd4985791d4de880446bdbb4e04fed'/>
<id>urn:sha1:e0bd743bb2dd4985791d4de880446bdbb4e04fed</id>
<content type='text'>
 - Guard Linux only headers.
 - Add qemu/statfs.h header to abstract over the which
   headers are needed for struct statfs
 - Define `ENOATTR` only if not only defined
   (it's defined in system headers on Darwin).

Signed-off-by: Keno Fischer &lt;keno@juliacomputing.com&gt;
[Michael Roitzsch: - Rebase for NixOS]
Signed-off-by: Michael Roitzsch &lt;reactorcontrol@icloud.com&gt;

While it might at first appear that fsdev/virtfs-proxy-header.c would
need similar adjustment for darwin as file-op-9p here, a later patch in
this series disables virtfs-proxy-helper for non-Linux. Allowing
virtfs-proxy-helper on darwin could potentially be an additional
optimization later.

[Will Cohen: - Fix headers for Alpine
             - Integrate statfs.h back into file-op-9p.h
             - Remove superfluous header guards from file-opt-9p
             - Add note about virtfs-proxy-helper being disabled
               on non-Linux for this patch series]
Signed-off-by: Will Cohen &lt;wwcohen@gmail.com&gt;
Reviewed-by: Philippe Mathieu-Daudé &lt;f4bug@amsat.org&gt;
Reviewed-by: Greg Kurz &lt;groug@kaod.org&gt;
Message-Id: &lt;20220227223522.91937-2-wwcohen@gmail.com&gt;
Signed-off-by: Christian Schoenebeck &lt;qemu_oss@crudebyte.com&gt;
</content>
</entry>
<entry>
<title>9pfs: make V9fsPath usable via P9Array API</title>
<updated>2021-10-27T12:45:22+00:00</updated>
<author>
<name>Christian Schoenebeck</name>
</author>
<published>2021-10-01T14:27:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=cc82fde9c7b4b598907914896ee6942fa866258c'/>
<id>urn:sha1:cc82fde9c7b4b598907914896ee6942fa866258c</id>
<content type='text'>
Signed-off-by: Christian Schoenebeck &lt;qemu_oss@crudebyte.com&gt;
Message-Id: &lt;79a0ddf8375f6c95f0565ef155a1bf1e9387664f.1633097129.git.qemu_oss@crudebyte.com&gt;
</content>
</entry>
<entry>
<title>9pfs: make V9fsString usable via P9Array API</title>
<updated>2021-10-27T12:45:22+00:00</updated>
<author>
<name>Christian Schoenebeck</name>
</author>
<published>2021-10-01T14:27:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=42bdeb04b6a4bf3e54f4d7f87193803268ba8255'/>
<id>urn:sha1:42bdeb04b6a4bf3e54f4d7f87193803268ba8255</id>
<content type='text'>
Signed-off-by: Christian Schoenebeck &lt;qemu_oss@crudebyte.com&gt;
Message-Id: &lt;ce9f7a0a63585dc27f4545c485109efbec1251da.1633097129.git.qemu_oss@crudebyte.com&gt;
</content>
</entry>
<entry>
<title>fsdev/p9array.h: check scalar type in P9ARRAY_NEW()</title>
<updated>2021-10-27T12:45:22+00:00</updated>
<author>
<name>Christian Schoenebeck</name>
</author>
<published>2021-10-01T14:27:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=c0451f0bc4210d262268ff51c053a9277f20f862'/>
<id>urn:sha1:c0451f0bc4210d262268ff51c053a9277f20f862</id>
<content type='text'>
Make sure at compile time that the scalar type of the array
requested to be created via P9ARRAY_NEW() matches the scalar
type of the passed auto reference variable (unique pointer).

Suggested-by: Richard Henderson &lt;richard.henderson@linaro.org&gt;
Signed-off-by: Christian Schoenebeck &lt;qemu_oss@crudebyte.com&gt;
Message-Id: &lt;c1965e2a096835dc9e1d4d659dfb15d96755cbe0.1633097129.git.qemu_oss@crudebyte.com&gt;
</content>
</entry>
<entry>
<title>9pfs: introduce P9Array</title>
<updated>2021-10-27T12:45:22+00:00</updated>
<author>
<name>Christian Schoenebeck</name>
</author>
<published>2021-10-01T14:26:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.openslx.org/bwlp/qemu.git/commit/?id=30e702abf6fa8a7f1e6ad11a75d6f3ab6fcb2155'/>
<id>urn:sha1:30e702abf6fa8a7f1e6ad11a75d6f3ab6fcb2155</id>
<content type='text'>
Implements deep auto free of arrays while retaining common C-style
squared bracket access. Main purpose of this API is to get rid of
error prone individual array deallocation pathes in user code, i.e.
turning something like this:

  void doSomething(size_t n) {
      Foo *foos = malloc(n * sizeof(Foo));
      for (...) {
          foos[i].s = malloc(...);
          if (...) {
              goto out;
          }
      }
  out:
      if (...) {
          for (...) {
              /* deep deallocation */
              free(foos[i].s);
          }
          /* array deallocation */
          free(foos);
      }
  }

into something more simple and safer like:

  void doSomething(size_t n) {
      P9ARRAY_REF(Foo) foos = NULL;
      P9ARRAY_NEW(Foo, foos, n);
      for (...) {
          foos[i].s = malloc(...);
          if (...) {
              return; /* array auto freed here */
          }
      }
      /* array auto freed here */
  }

Unlike GArray, P9Array does not require special macros, function
calls or struct member dereferencing to access the individual array
elements:

  C-array = P9Array:   vs.  GArray:

  for (...) {           |   for (...) {
      ... = arr[i].m;   |       ... = g_array_index(arr, Foo, i).m;
      arr[i].m = ... ;  |       g_array_index(arr, Foo, i).m = ... ;
  }                     |   }

So existing C-style array code can be retained with only very little
changes; basically limited to replacing array allocation call and of
course removing individual array deallocation pathes.

In this initial version P9Array only supports the concept of unique
pointers, i.e. it does not support reference counting. The array (and
all dynamically allocated memory of individual array elements) is auto
freed once execution leaves the scope of the reference variable (unique
pointer) associated with the array.

Internally a flex array struct is used in combination with macros
spanned over a continuous memory space for both the array's meta data
(private) and the actual C-array user data (public):

  struct P9Array##scalar_type {
    size_t len;            /* private, hidden from user code */
    scalar_type first[];   /* public, directly exposed to user code */
  };

Which has the advantage that the compiler automatically takes care
about correct padding, alignment and overall size for all scalar data
types on all systems and that the user space exposed pointer can
directly be translated back and forth between user space C-array
pointer and internal P9Array struct whenever needed, in a type-safe
manner.

This header file is released under MIT license, to allow this file
being used in other C-projects as well. The common QEMU license
GPL2+ might have construed a conflict for other projects.

Signed-off-by: Christian Schoenebeck &lt;qemu_oss@crudebyte.com&gt;
Message-Id: &lt;a954ef47b5ac26085a16c5c2aec8695374e0424d.1633097129.git.qemu_oss@crudebyte.com&gt;
</content>
</entry>
</feed>
