xsm: Error code consistency
PATCH 1/1 xsm: Error code consistency
Changes to support consistency of error codes within XSM and Flask XSM functions.
include/xsm/xsm.h | 6 +++++- xsm/flask/flask_op.c | 3 +++ 2 files changed, 8 insertions(+), 1 deletion(-)
Signed-off-by [email protected]
--
Machon Gregory
National Information Assurance Research Lab (NIARL)
xen/include/xsm/xsm.h +5 -1
@@ -427,7 +427,11 @@static inline long __do_xsm_op (XEN_GUEST_HANDLE (xsm_op_t) op) { -return xsm_call (__do_xsm_op (op)); +#ifdef XSM_ENABLE +return xsm_ops->__do_xsm_op (op); +#else +return -ENOSYS ; +#endif }#ifdef XSM_ENABLE
xen/xsm/flask/flask_op.c +3 -0
@@ -485,6 +485,9 @@if ( length <0 ) goto out; +if (len > count) +return -ERANGE ; +memset (buf,0 , count);memcpy (buf, context, len); length = len;
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel