From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
To: xen-devel@lists.xenproject.org
Cc: Stefano Stabellini <sstabellini@kernel.org>,
Wei Liu <wei.liu2@citrix.com>,
Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>,
Andrew Cooper <andrew.cooper3@citrix.com>,
Ian Jackson <ian.jackson@eu.citrix.com>,
Julien Grall <julien.grall@arm.com>,
David Scott <dave@recoil.org>
Subject: [PATCH] ocaml/xc_get_cpu_featureset/arm: Return not implemented on ARM
Date: Fri, 29 Apr 2016 02:38:33 -0400 [thread overview]
Message-ID: <1461911913-11537-1-git-send-email-konrad.wilk@oracle.com> (raw)
. as it is not implemented on it.
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
---
v1: Initial botched patch that didn't compile.
v2: Andrew mentioned to "need to set ENOSYS in the xch last
error." - but we do not use 'failwith_xc', and:
a). The error codes you set are no EXX type.
b). The best I can do is set errno=ENOSYS; Is that what you would like?
Cc: David Scott <dave@recoil.org>
Cc: Ian Jackson <ian.jackson@eu.citrix.com>
Cc: Wei Liu <wei.liu2@citrix.com>
Cc: Andrew Cooper <andrew.cooper3@citrix.com>
Cc: Stefano Stabellini <sstabellini@kernel.org>
Cc: Julien Grall <julien.grall@arm.com>
----
---
tools/ocaml/libs/xc/xenctrl_stubs.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/tools/ocaml/libs/xc/xenctrl_stubs.c b/tools/ocaml/libs/xc/xenctrl_stubs.c
index 5477df3..5e45551 100644
--- a/tools/ocaml/libs/xc/xenctrl_stubs.c
+++ b/tools/ocaml/libs/xc/xenctrl_stubs.c
@@ -1218,6 +1218,7 @@ CAMLprim value stub_xc_get_cpu_featureset(value xch, value idx)
{
CAMLparam2(xch, idx);
CAMLlocal1(bitmap_val);
+#if defined(__i386__) || defined(__x86_64__)
/* Safe, because of the global ocaml lock. */
static uint32_t fs_len;
@@ -1245,7 +1246,9 @@ CAMLprim value stub_xc_get_cpu_featureset(value xch, value idx)
for (i = 0; i < len; ++i)
Store_field(bitmap_val, i, caml_copy_int64(fs[i]));
}
-
+#else
+ caml_failwith("xc_get_cpu_featureset: not implemented");
+#endif
CAMLreturn(bitmap_val);
}
--
2.5.0
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel
next reply other threads:[~2016-04-29 6:38 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-29 6:38 Konrad Rzeszutek Wilk [this message]
2016-04-29 14:54 ` [PATCH] ocaml/xc_get_cpu_featureset/arm: Return not implemented on ARM Wei Liu
2016-04-29 15:30 ` Andrew Cooper
2016-05-02 9:14 ` Wei Liu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1461911913-11537-1-git-send-email-konrad.wilk@oracle.com \
--to=konrad.wilk@oracle.com \
--cc=andrew.cooper3@citrix.com \
--cc=dave@recoil.org \
--cc=ian.jackson@eu.citrix.com \
--cc=julien.grall@arm.com \
--cc=sstabellini@kernel.org \
--cc=wei.liu2@citrix.com \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).