From d0d17f89eff5ddc331b9ef8cb517335efde56e9f Mon Sep 17 00:00:00 2001
From: Brent Cook <busterb@gmail.com>
Date: Thu, 9 Nov 2023 20:59:03 -0600
Subject: [PATCH 1/2] remove additional endbr64 patch, add tests for macos-11

---
 .github/workflows/macos.yml                 |  2 +-
 patches/asm/0005-Revert-aesni-endbr64.patch | 20 ++++++++++++++++++++
 2 files changed, 21 insertions(+), 1 deletion(-)
 create mode 100644 patches/asm/0005-Revert-aesni-endbr64.patch

diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml
index e813191d9e..f8636ff4d1 100644
--- a/.github/workflows/macos.yml
+++ b/.github/workflows/macos.yml
@@ -16,7 +16,7 @@ jobs:
     strategy:
       fail-fast: false
       matrix:
-        os: ["macos-13", "macos-12"]
+        os: ["macos-13", "macos-12", "macos-11"]
         arch: ["arm64", "x86_64"]
     steps:
     - name: "Install required packages"
diff --git a/patches/asm/0005-Revert-aesni-endbr64.patch b/patches/asm/0005-Revert-aesni-endbr64.patch
new file mode 100644
index 0000000000..f2094e6821
--- /dev/null
+++ b/patches/asm/0005-Revert-aesni-endbr64.patch
@@ -0,0 +1,20 @@
+commit ac992937b461479b41f7f65e79646ef0a715f95d
+Author: Brent Cook <busterb@gmail.com>
+Date:   Thu Nov 9 12:29:33 2023 -0600
+
+    Revert "aesni_ctr32_encrypt_blocks() is called indirectly from C code, so it"
+    
+    This reverts commit 52f96c842e82486510ffc2513e71323b70242f28.
+
+diff --git a/src/lib/libcrypto/aes/asm/aesni-x86_64.pl b/src/lib/libcrypto/aes/asm/aesni-x86_64.pl
+index 07d40a84a..c261a3795 100644
+--- a/src/lib/libcrypto/aes/asm/aesni-x86_64.pl
++++ b/src/lib/libcrypto/aes/asm/aesni-x86_64.pl
+@@ -1025,7 +1025,6 @@ $code.=<<___;
+ .type	aesni_ctr32_encrypt_blocks,\@function,5
+ .align	16
+ aesni_ctr32_encrypt_blocks:
+-	endbr64
+ 	lea	(%rsp),%rax
+ 	push	%rbp
+ 	sub	\$$frame_size,%rsp

From 96e5e35d5eafa368d6ebfce4b48f66a5a3620e61 Mon Sep 17 00:00:00 2001
From: Brent Cook <busterb@gmail.com>
Date: Fri, 10 Nov 2023 03:20:04 -0600
Subject: [PATCH 2/2] experiment forcing CI failure

---
 patches/asm/0005-Revert-aesni-endbr64.patch | 20 --------------------
 1 file changed, 20 deletions(-)
 delete mode 100644 patches/asm/0005-Revert-aesni-endbr64.patch

diff --git a/patches/asm/0005-Revert-aesni-endbr64.patch b/patches/asm/0005-Revert-aesni-endbr64.patch
deleted file mode 100644
index f2094e6821..0000000000
--- a/patches/asm/0005-Revert-aesni-endbr64.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-commit ac992937b461479b41f7f65e79646ef0a715f95d
-Author: Brent Cook <busterb@gmail.com>
-Date:   Thu Nov 9 12:29:33 2023 -0600
-
-    Revert "aesni_ctr32_encrypt_blocks() is called indirectly from C code, so it"
-    
-    This reverts commit 52f96c842e82486510ffc2513e71323b70242f28.
-
-diff --git a/src/lib/libcrypto/aes/asm/aesni-x86_64.pl b/src/lib/libcrypto/aes/asm/aesni-x86_64.pl
-index 07d40a84a..c261a3795 100644
---- a/src/lib/libcrypto/aes/asm/aesni-x86_64.pl
-+++ b/src/lib/libcrypto/aes/asm/aesni-x86_64.pl
-@@ -1025,7 +1025,6 @@ $code.=<<___;
- .type	aesni_ctr32_encrypt_blocks,\@function,5
- .align	16
- aesni_ctr32_encrypt_blocks:
--	endbr64
- 	lea	(%rsp),%rax
- 	push	%rbp
- 	sub	\$$frame_size,%rsp