From: Jarkko Sakkinen <jarkko@kernel.org>
To: Haitao Huang <haitao.huang@linux.intel.com>
Cc: linux-sgx@vger.kernel.org, dave.hansen@linux.intel.com,
reinette.chatre@intel.com, vijay.dhanraj@intel.com
Subject: Re: [RFC PATCH v3 1/4] x86/sgx: Export sgx_encl_eaug_page
Date: Tue, 15 Nov 2022 23:54:03 +0200 [thread overview]
Message-ID: <Y3QKXQjydl7WwAzZ@kernel.org> (raw)
In-Reply-To: <20221107220212.257422-2-haitao.huang@linux.intel.com>
On Mon, Nov 07, 2022 at 02:02:09PM -0800, Haitao Huang wrote:
> This function will be called by both the page fault handler
> and the fops->fadvise callback.
>
> Signed-off-by: Haitao Huang <haitao.huang@linux.intel.com>
> ---
> arch/x86/kernel/cpu/sgx/encl.c | 4 ++--
> arch/x86/kernel/cpu/sgx/encl.h | 2 ++
> 2 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/arch/x86/kernel/cpu/sgx/encl.c b/arch/x86/kernel/cpu/sgx/encl.c
> index 8bdeae2fc309..1abc5e7f2660 100644
> --- a/arch/x86/kernel/cpu/sgx/encl.c
> +++ b/arch/x86/kernel/cpu/sgx/encl.c
> @@ -308,8 +308,8 @@ struct sgx_encl_page *sgx_encl_load_page(struct sgx_encl *encl,
> * Returns: Appropriate vm_fault_t: VM_FAULT_NOPAGE when PTE was installed
> * successfully, VM_FAULT_SIGBUS or VM_FAULT_OOM as error otherwise.
> */
> -static vm_fault_t sgx_encl_eaug_page(struct vm_area_struct *vma,
> - struct sgx_encl *encl, unsigned long addr)
> +vm_fault_t sgx_encl_eaug_page(struct vm_area_struct *vma,
> + struct sgx_encl *encl, unsigned long addr)
> {
> vm_fault_t vmret = VM_FAULT_SIGBUS;
> struct sgx_pageinfo pginfo = {0};
> diff --git a/arch/x86/kernel/cpu/sgx/encl.h b/arch/x86/kernel/cpu/sgx/encl.h
> index a65a952116fd..557d4abb13fc 100644
> --- a/arch/x86/kernel/cpu/sgx/encl.h
> +++ b/arch/x86/kernel/cpu/sgx/encl.h
> @@ -127,5 +127,7 @@ struct sgx_encl_page *sgx_encl_load_page(struct sgx_encl *encl,
> unsigned long addr);
> struct sgx_va_page *sgx_encl_grow(struct sgx_encl *encl, bool reclaim);
> void sgx_encl_shrink(struct sgx_encl *encl, struct sgx_va_page *va_page);
> +vm_fault_t sgx_encl_eaug_page(struct vm_area_struct *vma,
> + struct sgx_encl *encl, unsigned long addr);
>
> #endif /* _X86_ENCL_H */
> --
> 2.25.1
>
Acked-by: Jarkko Sakkinen <jarkko@kernel.org>
BR, Jarkko
prev parent reply other threads:[~2022-11-15 21:54 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-07 22:02 [RFC PATCH v3 0/4] x86/sgx: implement support for MADV_WILLNEED Haitao Huang
2022-11-07 22:02 ` [RFC PATCH v3 1/4] x86/sgx: Export sgx_encl_eaug_page Haitao Huang
2022-11-07 22:02 ` [RFC PATCH v3 2/4] x86/sgx: Implement support for MADV_WILLNEED Haitao Huang
2022-11-07 22:02 ` [RFC PATCH v3 3/4] selftests/sgx: add len field for EACCEPT op Haitao Huang
2022-11-07 22:02 ` [RFC PATCH v3 4/4] selftests/sgx: Add test for madvise(..., WILLNEED) Haitao Huang
2022-11-15 23:24 ` [RFC PATCH v3 3/4] selftests/sgx: add len field for EACCEPT op Jarkko Sakkinen
2022-11-16 19:26 ` Haitao Huang
2022-11-27 17:16 ` Jarkko Sakkinen
2022-11-15 22:03 ` [RFC PATCH v3 2/4] x86/sgx: Implement support for MADV_WILLNEED Jarkko Sakkinen
2023-01-25 19:40 ` Haitao Huang
2023-01-26 21:24 ` Jarkko Sakkinen
2022-11-15 21:54 ` Jarkko Sakkinen [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Y3QKXQjydl7WwAzZ@kernel.org \
--to=jarkko@kernel.org \
--cc=dave.hansen@linux.intel.com \
--cc=haitao.huang@linux.intel.com \
--cc=linux-sgx@vger.kernel.org \
--cc=reinette.chatre@intel.com \
--cc=vijay.dhanraj@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox