s390/sclp: convert early sclp console code to C
[deliverable/linux.git] / arch / s390 / include / asm / processor.h
index c417015c5304f9c30e78a3ba4e047ffe7f93e994..085fb0d3c54e944e2f846a2188136f7f729bef72 100644 (file)
@@ -232,6 +232,17 @@ static inline void __load_psw_mask (unsigned long mask)
                : "=&d" (addr), "=Q" (psw) : "Q" (psw) : "memory", "cc");
 }
 
+/*
+ * Extract current PSW mask
+ */
+static inline unsigned long __extract_psw(void)
+{
+       unsigned int reg1, reg2;
+
+       asm volatile("epsw %0,%1" : "=d" (reg1), "=a" (reg2));
+       return (((unsigned long) reg1) << 32) | ((unsigned long) reg2);
+}
+
 /*
  * Rewind PSW instruction address by specified number of bytes.
  */
This page took 0.025223 seconds and 5 git commands to generate.