[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen staging] x86/gnttab: Use explicit instruction size in gnttab_clear_flags()



commit c1247554578180ba1ff688fd4892f498243c230e
Author:     Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
AuthorDate: Mon Jul 8 23:12:06 2019 +0100
Commit:     Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
CommitDate: Tue Jul 9 09:06:05 2019 -0500

    x86/gnttab: Use explicit instruction size in gnttab_clear_flags()
    
    The OpenSUSE Leap compilers complain about ambiguity:
    
    In file included from grant_table.c:33:
    In file included from ...xen/include/xen/grant_table.h:30:
    ...xen/include/asm/grant_table.h:67:19: error: ambiguous instructions 
require
    an explicit suffix (could be 'andb', 'andw', 'andl', or 'andq')
        asm volatile ("lock and %1,%0" : "+m" (*addr) : "ir" ((uint16_t)~mask));
                      ^
    <inline asm>:1:2: note: instantiated into assembly here
            lock and $-17,(%rsi)
            ^
    
    Full logs: 
https://gitlab.com/xen-project/people/andyhhp/xen/-/jobs/247600284
    Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
    Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx>
---
 xen/include/asm-x86/grant_table.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xen/include/asm-x86/grant_table.h 
b/xen/include/asm-x86/grant_table.h
index 568a6bb57c..61c889b297 100644
--- a/xen/include/asm-x86/grant_table.h
+++ b/xen/include/asm-x86/grant_table.h
@@ -64,7 +64,7 @@ static inline void gnttab_clear_flags(struct domain *d,
                                       unsigned int mask, uint16_t *addr)
 {
     /* Access must be confined to the specified 2 bytes. */
-    asm volatile ("lock and %1,%0" : "+m" (*addr) : "ir" ((uint16_t)~mask));
+    asm volatile ("lock andw %1,%0" : "+m" (*addr) : "ir" ((uint16_t)~mask));
 }
 
 /* Foreign mappings of HVM-guest pages do not modify the type count. */
--
generated by git-patchbot for /home/xen/git/xen.git#staging

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.