Message ID | 1462272910-41200-2-git-send-email-roger.pau@citrix.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Tue, May 03, 2016 at 12:55:05PM +0200, Roger Pau Monne wrote: > Currently FreeBSD lacks the ENODATA errno value, so the privcmd driver > always translates ENODATA to ENOENT, add a define to libxl in order to > correctly match ENODATA with ENOENT on FreeBSD. > > Signed-off-by: Roger Pau Monné <roger.pau@citrix.com> Acked-by: Wei Liu <wei.liu2@citrix.com> As a related note, I guess the long term plan is to add ENODATA to FreeBSD? > --- > Cc: Ian Jackson <ian.jackson@eu.citrix.com> > Cc: Wei Liu <wei.liu2@citrix.com> > --- > tools/libxl/libxl_osdeps.h | 7 +++++++ > 1 file changed, 7 insertions(+) > > diff --git a/tools/libxl/libxl_osdeps.h b/tools/libxl/libxl_osdeps.h > index 10ce703..a40d620 100644 > --- a/tools/libxl/libxl_osdeps.h > +++ b/tools/libxl/libxl_osdeps.h > @@ -52,6 +52,13 @@ > #include <libutil.h> > #include <sys/endian.h> > #include <uuid.h> > +/* > + * FreeBSD doesn't have ENODATA errno ATM, so privcmd always translates > + * ENODATA into ENOENT. > + */ > +#ifndef ENODATA > +#define ENODATA ENOENT > +#endif > #endif > > #ifndef SYSFS_USBBACK_DRIVER > -- > 2.6.4 (Apple Git-63) >
diff --git a/tools/libxl/libxl_osdeps.h b/tools/libxl/libxl_osdeps.h index 10ce703..a40d620 100644 --- a/tools/libxl/libxl_osdeps.h +++ b/tools/libxl/libxl_osdeps.h @@ -52,6 +52,13 @@ #include <libutil.h> #include <sys/endian.h> #include <uuid.h> +/* + * FreeBSD doesn't have ENODATA errno ATM, so privcmd always translates + * ENODATA into ENOENT. + */ +#ifndef ENODATA +#define ENODATA ENOENT +#endif #endif #ifndef SYSFS_USBBACK_DRIVER
Currently FreeBSD lacks the ENODATA errno value, so the privcmd driver always translates ENODATA to ENOENT, add a define to libxl in order to correctly match ENODATA with ENOENT on FreeBSD. Signed-off-by: Roger Pau Monné <roger.pau@citrix.com> --- Cc: Ian Jackson <ian.jackson@eu.citrix.com> Cc: Wei Liu <wei.liu2@citrix.com> --- tools/libxl/libxl_osdeps.h | 7 +++++++ 1 file changed, 7 insertions(+)