xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [BUGFIX][PATCH 0/1] Enable 4.4 to build on CentOS/RHEL 5.10
@ 2014-02-07 21:51 Don Slutz
  2014-02-07 21:51 ` [BUGFIX][PATCH 1/1] xenlight_stubs.c: Allow it to build with ocaml 3.09.3 Don Slutz
  0 siblings, 1 reply; 5+ messages in thread
From: Don Slutz @ 2014-02-07 21:51 UTC (permalink / raw)
  To: xen-devel
  Cc: David Scott, Stefano Stabellini, George Dunlap, Andrew Cooper,
	Ian Jackson, Don Slutz, Ian Campbell

I only did Andrew Cooper's statement of "Applying the top macro".
There is no checking of ocaml version.

Since CentOS/RHEL 5.10 (Released on 22-Oct-2013) disto provides
ocaml 3.09.3, the current code does not build.

Compile tested and simple tests done on CentOS 5.10 and Fedora 17.

Note: The formating of the code was changed to be closer to "Coding
Style for the Xen Hypervisor".  The file has a non-standard emacs
setting at the end (indent of 8 and use tabs).  And the example of
code just below was not used as an example of coding style to
follow do to lack of indent at all.

I feel this should have a release exception and go into 4.4 for 2
reasons:

1) It is a bufix for CentOS/RHEL 5.10 and looks to be low risk.

2) It make the release more awesome to run on these distros.


"What functionality is being fixed / enabled by this patch?"

4.4 Added CAML_returnT usage.  ocaml provided this at 3.09.4.


"If there was a bug in this patch, what functionality might be broken?"

ocaml may stop functioning.  Since this is conditional code, ocaml
should only possibly have issues on CentOS/RHEL 5.10.


"What is the probability that this patch has a bug?"

I feel it is low.

Mail thread:

http://lists.xen.org/archives/html/xen-devel/2014-02/msg00665.html

Don Slutz (1):
  xenlight_stubs.c: Allow it to build with ocaml 3.09.3

 tools/ocaml/libs/xl/xenlight_stubs.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)

-- 
1.8.4

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [BUGFIX][PATCH 1/1] xenlight_stubs.c: Allow it to build with ocaml 3.09.3
  2014-02-07 21:51 [BUGFIX][PATCH 0/1] Enable 4.4 to build on CentOS/RHEL 5.10 Don Slutz
@ 2014-02-07 21:51 ` Don Slutz
  2014-02-10 12:38   ` George Dunlap
  0 siblings, 1 reply; 5+ messages in thread
From: Don Slutz @ 2014-02-07 21:51 UTC (permalink / raw)
  To: xen-devel
  Cc: David Scott, Stefano Stabellini, George Dunlap, Andrew Cooper,
	Ian Jackson, Don Slutz, Ian Campbell

This code was copied from:

http://docs.camlcity.org/docs/godisrc/oasis-ocaml-fd-1.1.1.tar.gz/ocaml-fd-1.1.1/lib/fd_stubs.c

Signed-off-by: Don Slutz <dslutz@verizon.com>
---
 tools/ocaml/libs/xl/xenlight_stubs.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/tools/ocaml/libs/xl/xenlight_stubs.c b/tools/ocaml/libs/xl/xenlight_stubs.c
index 23f253a..8e825ae 100644
--- a/tools/ocaml/libs/xl/xenlight_stubs.c
+++ b/tools/ocaml/libs/xl/xenlight_stubs.c
@@ -35,6 +35,19 @@
 
 #include "caml_xentoollog.h"
 
+/*
+ * Starting with ocaml-3.09.3, CAMLreturn can only be used for ``value''
+ * types. CAMLreturnT was only added in 3.09.4, so we define our own
+ * version here if needed.
+ */
+#ifndef CAMLreturnT
+#define CAMLreturnT(type, result) do { \
+    type caml__temp_result = (result); \
+    caml_local_roots = caml__frame; \
+    return (caml__temp_result); \
+} while (0)
+#endif
+
 /* The following is equal to the CAMLreturn macro, but without the return */
 #define CAMLdone do{ \
 caml_local_roots = caml__frame; \
-- 
1.8.4

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [BUGFIX][PATCH 1/1] xenlight_stubs.c: Allow it to build with ocaml 3.09.3
  2014-02-07 21:51 ` [BUGFIX][PATCH 1/1] xenlight_stubs.c: Allow it to build with ocaml 3.09.3 Don Slutz
@ 2014-02-10 12:38   ` George Dunlap
  2014-02-10 13:49     ` David Scott
  0 siblings, 1 reply; 5+ messages in thread
From: George Dunlap @ 2014-02-10 12:38 UTC (permalink / raw)
  To: Don Slutz, xen-devel
  Cc: Andrew Cooper, Stefano Stabellini, Ian Jackson, David Scott,
	Ian Campbell

On 02/07/2014 09:51 PM, Don Slutz wrote:
> This code was copied from:
>
> http://docs.camlcity.org/docs/godisrc/oasis-ocaml-fd-1.1.1.tar.gz/ocaml-fd-1.1.1/lib/fd_stubs.c
>
> Signed-off-by: Don Slutz <dslutz@verizon.com>

Release-acked-by: George Dunlap <george.dunlap@eu.citrix.com>

> ---
>   tools/ocaml/libs/xl/xenlight_stubs.c | 13 +++++++++++++
>   1 file changed, 13 insertions(+)
>
> diff --git a/tools/ocaml/libs/xl/xenlight_stubs.c b/tools/ocaml/libs/xl/xenlight_stubs.c
> index 23f253a..8e825ae 100644
> --- a/tools/ocaml/libs/xl/xenlight_stubs.c
> +++ b/tools/ocaml/libs/xl/xenlight_stubs.c
> @@ -35,6 +35,19 @@
>   
>   #include "caml_xentoollog.h"
>   
> +/*
> + * Starting with ocaml-3.09.3, CAMLreturn can only be used for ``value''
> + * types. CAMLreturnT was only added in 3.09.4, so we define our own
> + * version here if needed.
> + */
> +#ifndef CAMLreturnT
> +#define CAMLreturnT(type, result) do { \
> +    type caml__temp_result = (result); \
> +    caml_local_roots = caml__frame; \
> +    return (caml__temp_result); \
> +} while (0)
> +#endif
> +
>   /* The following is equal to the CAMLreturn macro, but without the return */
>   #define CAMLdone do{ \
>   caml_local_roots = caml__frame; \

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [BUGFIX][PATCH 1/1] xenlight_stubs.c: Allow it to build with ocaml 3.09.3
  2014-02-10 12:38   ` George Dunlap
@ 2014-02-10 13:49     ` David Scott
  2014-02-11 13:08       ` Ian Campbell
  0 siblings, 1 reply; 5+ messages in thread
From: David Scott @ 2014-02-10 13:49 UTC (permalink / raw)
  To: George Dunlap, Don Slutz, xen-devel
  Cc: Andrew Cooper, Ian Jackson, Ian Campbell, Stefano Stabellini

On 10/02/14 12:38, George Dunlap wrote:
> On 02/07/2014 09:51 PM, Don Slutz wrote:
>> This code was copied from:
>>
>> http://docs.camlcity.org/docs/godisrc/oasis-ocaml-fd-1.1.1.tar.gz/ocaml-fd-1.1.1/lib/fd_stubs.c
>>
>>
>> Signed-off-by: Don Slutz <dslutz@verizon.com>
>
> Release-acked-by: George Dunlap <george.dunlap@eu.citrix.com>

Also looks fine to me
Acked-by: David Scott <dave.scott@citrix.com>

>
>> ---
>>   tools/ocaml/libs/xl/xenlight_stubs.c | 13 +++++++++++++
>>   1 file changed, 13 insertions(+)
>>
>> diff --git a/tools/ocaml/libs/xl/xenlight_stubs.c
>> b/tools/ocaml/libs/xl/xenlight_stubs.c
>> index 23f253a..8e825ae 100644
>> --- a/tools/ocaml/libs/xl/xenlight_stubs.c
>> +++ b/tools/ocaml/libs/xl/xenlight_stubs.c
>> @@ -35,6 +35,19 @@
>>   #include "caml_xentoollog.h"
>> +/*
>> + * Starting with ocaml-3.09.3, CAMLreturn can only be used for ``value''
>> + * types. CAMLreturnT was only added in 3.09.4, so we define our own
>> + * version here if needed.
>> + */
>> +#ifndef CAMLreturnT
>> +#define CAMLreturnT(type, result) do { \
>> +    type caml__temp_result = (result); \
>> +    caml_local_roots = caml__frame; \
>> +    return (caml__temp_result); \
>> +} while (0)
>> +#endif
>> +
>>   /* The following is equal to the CAMLreturn macro, but without the
>> return */
>>   #define CAMLdone do{ \
>>   caml_local_roots = caml__frame; \
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [BUGFIX][PATCH 1/1] xenlight_stubs.c: Allow it to build with ocaml 3.09.3
  2014-02-10 13:49     ` David Scott
@ 2014-02-11 13:08       ` Ian Campbell
  0 siblings, 0 replies; 5+ messages in thread
From: Ian Campbell @ 2014-02-11 13:08 UTC (permalink / raw)
  To: David Scott
  Cc: Stefano Stabellini, George Dunlap, Andrew Cooper, Ian Jackson,
	Don Slutz, xen-devel

On Mon, 2014-02-10 at 13:49 +0000, David Scott wrote:
> On 10/02/14 12:38, George Dunlap wrote:
> > On 02/07/2014 09:51 PM, Don Slutz wrote:
> >> This code was copied from:
> >>
> >> http://docs.camlcity.org/docs/godisrc/oasis-ocaml-fd-1.1.1.tar.gz/ocaml-fd-1.1.1/lib/fd_stubs.c

I see an LGPL 2.1 statement in that file, so I think it is OK to copy. 

> >>
> >>
> >> Signed-off-by: Don Slutz <dslutz@verizon.com>
> >
> > Release-acked-by: George Dunlap <george.dunlap@eu.citrix.com>
> 
> Also looks fine to me
> Acked-by: David Scott <dave.scott@citrix.com>

Acked + applied, thanks.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2014-02-11 13:08 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-07 21:51 [BUGFIX][PATCH 0/1] Enable 4.4 to build on CentOS/RHEL 5.10 Don Slutz
2014-02-07 21:51 ` [BUGFIX][PATCH 1/1] xenlight_stubs.c: Allow it to build with ocaml 3.09.3 Don Slutz
2014-02-10 12:38   ` George Dunlap
2014-02-10 13:49     ` David Scott
2014-02-11 13:08       ` Ian Campbell

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).