@@ -60,6 +60,18 @@ static inline bool guest_mode(const struct cpu_user_regs *r)
register_t get_user_reg(struct cpu_user_regs *regs, int reg);
void set_user_reg(struct cpu_user_regs *regs, int reg, register_t value);
+static inline uint64_t regpair_to_uint64(register_t reg0, register_t reg1)
+{
+ return ((uint64_t)reg0 << 32) | (uint32_t)reg1;
+}
+
+static inline void uint64_to_regpair(register_t *reg0, register_t *reg1,
+ uint64_t val)
+{
+ *reg0 = val >> 32;
+ *reg1 = (uint32_t)val;
+}
+
#endif
#endif /* __ARM_REGS_H__ */
@@ -273,17 +273,6 @@ static int optee_domain_teardown(struct domain *d)
return 0;
}
-static uint64_t regpair_to_uint64(register_t reg0, register_t reg1)
-{
- return ((uint64_t)reg0 << 32) | (uint32_t)reg1;
-}
-
-static void uint64_to_regpair(register_t *reg0, register_t *reg1, uint64_t val)
-{
- *reg0 = val >> 32;
- *reg1 = (uint32_t)val;
-}
-
static struct page_info *get_domain_ram_page(gfn_t gfn)
{
struct page_info *page;