]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - arch/s390/include/asm/idals.h
KVM: x86: fix RSM into 64-bit protected mode
[karo-tx-linux.git] / arch / s390 / include / asm / idals.h
index ea5a6e45fd936412b537b5fd34828a54f57ac325..a7b2d7504049a00d286c74aee5bd3ae39e5e9f55 100644 (file)
 #include <asm/cio.h>
 #include <asm/uaccess.h>
 
-#ifdef CONFIG_64BIT
 #define IDA_SIZE_LOG 12 /* 11 for 2k , 12 for 4k */
-#else
-#define IDA_SIZE_LOG 11 /* 11 for 2k , 12 for 4k */
-#endif
 #define IDA_BLOCK_SIZE (1L<<IDA_SIZE_LOG)
 
 /*
 static inline int
 idal_is_needed(void *vaddr, unsigned int length)
 {
-#ifdef CONFIG_64BIT
        return ((__pa(vaddr) + length - 1) >> 31) != 0;
-#else
-       return 0;
-#endif
 }
 
 
@@ -77,7 +69,6 @@ static inline unsigned long *idal_create_words(unsigned long *idaws,
 static inline int
 set_normalized_cda(struct ccw1 * ccw, void *vaddr)
 {
-#ifdef CONFIG_64BIT
        unsigned int nridaws;
        unsigned long *idal;
 
@@ -93,7 +84,6 @@ set_normalized_cda(struct ccw1 * ccw, void *vaddr)
                ccw->flags |= CCW_FLAG_IDA;
                vaddr = idal;
        }
-#endif
        ccw->cda = (__u32)(unsigned long) vaddr;
        return 0;
 }
@@ -104,12 +94,10 @@ set_normalized_cda(struct ccw1 * ccw, void *vaddr)
 static inline void
 clear_normalized_cda(struct ccw1 * ccw)
 {
-#ifdef CONFIG_64BIT
        if (ccw->flags & CCW_FLAG_IDA) {
                kfree((void *)(unsigned long) ccw->cda);
                ccw->flags &= ~CCW_FLAG_IDA;
        }
-#endif
        ccw->cda = 0;
 }
 
@@ -181,12 +169,8 @@ idal_buffer_free(struct idal_buffer *ib)
 static inline int
 __idal_buffer_is_needed(struct idal_buffer *ib)
 {
-#ifdef CONFIG_64BIT
        return ib->size > (4096ul << ib->page_order) ||
                idal_is_needed(ib->data[0], ib->size);
-#else
-       return ib->size > (4096ul << ib->page_order);
-#endif
 }
 
 /*