7
7
#ifndef _ASM_X86_MACH_DEFAULT_APM_H
8
8
#define _ASM_X86_MACH_DEFAULT_APM_H
9
9
10
- #include <asm/nospec-branch.h>
11
-
12
10
#ifdef APM_ZERO_SEGS
13
11
# define APM_DO_ZERO_SEGS \
14
12
"pushl %%ds\n\t" \
@@ -34,7 +32,6 @@ static inline void apm_bios_call_asm(u32 func, u32 ebx_in, u32 ecx_in,
34
32
* N.B. We do NOT need a cld after the BIOS call
35
33
* because we always save and restore the flags.
36
34
*/
37
- firmware_restrict_branch_speculation_start ();
38
35
__asm__ __volatile__(APM_DO_ZERO_SEGS
39
36
"pushl %%edi\n\t"
40
37
"pushl %%ebp\n\t"
@@ -47,7 +44,6 @@ static inline void apm_bios_call_asm(u32 func, u32 ebx_in, u32 ecx_in,
47
44
"=S" (* esi )
48
45
: "a" (func ), "b" (ebx_in ), "c" (ecx_in )
49
46
: "memory" , "cc" );
50
- firmware_restrict_branch_speculation_end ();
51
47
}
52
48
53
49
static inline bool apm_bios_call_simple_asm (u32 func , u32 ebx_in ,
@@ -60,7 +56,6 @@ static inline bool apm_bios_call_simple_asm(u32 func, u32 ebx_in,
60
56
* N.B. We do NOT need a cld after the BIOS call
61
57
* because we always save and restore the flags.
62
58
*/
63
- firmware_restrict_branch_speculation_start ();
64
59
__asm__ __volatile__(APM_DO_ZERO_SEGS
65
60
"pushl %%edi\n\t"
66
61
"pushl %%ebp\n\t"
@@ -73,7 +68,6 @@ static inline bool apm_bios_call_simple_asm(u32 func, u32 ebx_in,
73
68
"=S" (si )
74
69
: "a" (func ), "b" (ebx_in ), "c" (ecx_in )
75
70
: "memory" , "cc" );
76
- firmware_restrict_branch_speculation_end ();
77
71
return error ;
78
72
}
79
73
0 commit comments