linux-sgx.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sean Christopherson <sean.j.christopherson@intel.com>
To: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Cc: linux-sgx@vger.kernel.org
Subject: [PATCH 1/2] x86/sgx: Revert using BIT() to define ENCLS_FAULT_FLAG
Date: Mon,  7 Oct 2019 21:12:25 -0700	[thread overview]
Message-ID: <20191008041226.2974-2-sean.j.christopherson@intel.com> (raw)
In-Reply-To: <20191008041226.2974-1-sean.j.christopherson@intel.com>

ENCLS_FAULT_FLAG is run through __stringify() in the ENCLS asm helpers,
the build fails miserably if its defined via BIT().

Signed-off-by: Sean Christopherson <sean.j.christopherson@intel.com>
---
 arch/x86/kernel/cpu/sgx/encls.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/kernel/cpu/sgx/encls.h b/arch/x86/kernel/cpu/sgx/encls.h
index f286ba85773e..1676571c8a59 100644
--- a/arch/x86/kernel/cpu/sgx/encls.h
+++ b/arch/x86/kernel/cpu/sgx/encls.h
@@ -60,7 +60,7 @@ enum sgx_encls_leaf {
  * between positive (faults and SGX error codes) and negative (system
  * error codes) values.
  */
-#define ENCLS_FAULT_FLAG BIT(30)
+#define ENCLS_FAULT_FLAG 0x40000000
 
 /* Retrieve the encoded trapnr from the specified return code. */
 #define ENCLS_TRAPNR(r) ((r) & ~ENCLS_FAULT_FLAG)
-- 
2.22.0


  reply	other threads:[~2019-10-08  4:12 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-08  4:12 [PATCH 0/2] x86/sgx: Revert two recent master changes Sean Christopherson
2019-10-08  4:12 ` Sean Christopherson [this message]
2019-10-08  4:12 ` [PATCH 2/2] x86/sgx: Revert moving sgx_init() call to sgx_detect() Sean Christopherson
2019-10-08 23:28 ` [PATCH 0/2] x86/sgx: Revert two recent master changes Jarkko Sakkinen

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=20191008041226.2974-2-sean.j.christopherson@intel.com \
    --to=sean.j.christopherson@intel.com \
    --cc=jarkko.sakkinen@linux.intel.com \
    --cc=linux-sgx@vger.kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).