Message ID | 20190521044912.1375-5-bauerman@linux.ibm.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | Secure Virtual Machine Enablement | expand |
Context | Check | Description |
---|---|---|
snowpatch_ozlabs/apply_patch | warning | Failed to apply on branch next (8150a153c013aa2dd1ffae43370b89ac1347a7fb) |
snowpatch_ozlabs/apply_patch | fail | Failed to apply to any branch |
diff --git a/arch/powerpc/include/asm/ultravisor-api.h b/arch/powerpc/include/asm/ultravisor-api.h index 0e8b72081718..ed68b02869fd 100644 --- a/arch/powerpc/include/asm/ultravisor-api.h +++ b/arch/powerpc/include/asm/ultravisor-api.h @@ -20,6 +20,8 @@ /* opcodes */ #define UV_WRITE_PATE 0xF104 #define UV_ESM 0xF110 +#define UV_SHARE_PAGE 0xF130 +#define UV_UNSHARE_PAGE 0xF134 #define UV_RETURN 0xF11C #endif /* _ASM_POWERPC_ULTRAVISOR_API_H */ diff --git a/arch/powerpc/include/asm/ultravisor.h b/arch/powerpc/include/asm/ultravisor.h index 09e0a615d96f..537f7717d21a 100644 --- a/arch/powerpc/include/asm/ultravisor.h +++ b/arch/powerpc/include/asm/ultravisor.h @@ -44,6 +44,20 @@ static inline int uv_register_pate(u64 lpid, u64 dw0, u64 dw1) return ucall(UV_WRITE_PATE, retbuf, lpid, dw0, dw1); } +static inline int uv_share_page(u64 pfn, u64 npages) +{ + unsigned long retbuf[UCALL_BUFSIZE]; + + return ucall(UV_SHARE_PAGE, retbuf, pfn, npages); +} + +static inline int uv_unshare_page(u64 pfn, u64 npages) +{ + unsigned long retbuf[UCALL_BUFSIZE]; + + return ucall(UV_UNSHARE_PAGE, retbuf, pfn, npages); +} + #endif /* !__ASSEMBLY__ */ #endif /* _ASM_POWERPC_ULTRAVISOR_H */