|
|
|
|
|
|
|
|
|
|
xen-ppc-devel
[XenPPC] [pushed] [ppc] update intf->in_cons when reading
changeset: 27808:0163968f7fce161f427479ec6ffed893ed6ee01e
tag: tip
user: jimix@xxxxxxxxxxxxxxxxxxxxx
date: Tue May 16 15:55:19 2006 -0400
files: arch/powerpc/platforms/xen/udbg_xen.c
description:
[ppc] update intf->in_cons when reading
diff -r 79d69778918c4efd751fb564d2b8c96bcfd74a43 -r
0163968f7fce161f427479ec6ffed893ed6ee01e arch/powerpc/platforms/xen/udbg_xen.c
--- a/arch/powerpc/platforms/xen/udbg_xen.c Tue May 16 15:44:25 2006 -0400
+++ b/arch/powerpc/platforms/xen/udbg_xen.c Tue May 16 15:55:19 2006 -0400
@@ -87,6 +87,7 @@ static int udbg_getc_poll_domu_xen(void)
static int udbg_getc_poll_domu_xen(void)
{
XENCONS_RING_IDX cons, prod;
+ int c;
cons = intf->in_cons;
prod = intf->in_prod;
@@ -96,7 +97,10 @@ static int udbg_getc_poll_domu_xen(void)
if (cons == prod)
return -1;
- return intf->in[MASK_XENCONS_IDX(cons,intf->in)];
+ c = intf->in[MASK_XENCONS_IDX(cons++, intf->in)];
+ wmb();
+ intf->in_cons = cons;
+ return c;
}
static int udbg_getc_domu_xen(void)
_______________________________________________
Xen-ppc-devel mailing list
Xen-ppc-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ppc-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread>
|
- [XenPPC] [pushed] [ppc] update intf->in_cons when reading,
jimix <=
|
|
|
|
|