This is an automated email from the ASF dual-hosted git repository.

ivila pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/teaclave-trustzone-sdk.git

commit 3da0b34698a343b5278857a0fa7d2612623b4d5d
Author: ivila <[email protected]>
AuthorDate: Wed Jun 24 17:18:37 2026 +0800

    optee-teec: fix bugs of ParamTypes::into_flags
---
 crates/optee-teec/src/parameter.rs | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/crates/optee-teec/src/parameter.rs 
b/crates/optee-teec/src/parameter.rs
index 963fc84..34f9d94 100644
--- a/crates/optee-teec/src/parameter.rs
+++ b/crates/optee-teec/src/parameter.rs
@@ -241,10 +241,10 @@ impl ParamTypes {
 
     pub fn into_flags(&self) -> (ParamType, ParamType, ParamType, ParamType) {
         (
-            (0x000fu32 & self.0).into(),
-            (0x00f0u32 & self.0).into(),
-            (0x0f00u32 & self.0).into(),
-            (0xf000u32 & self.0).into(),
+            (0x000f_u32 & self.0).into(),
+            ((0x00f0_u32 & self.0) >> 4).into(),
+            ((0x0f00_u32 & self.0) >> 8).into(),
+            ((0xf000_u32 & self.0) >> 12).into(),
         )
     }
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to