History

x86/vdso: Fix lsl operand order

In the __getcpu function, lsl is using the wrong target and destination registers. Luckily, the compiler tends to choose %eax for both variables, so it has been working so far.

Samuel Neves committed 8 years ago

Commit e78e5a91 parent c7486101 file · +1 −1Browse files

Unified · Split

arch/x86/include/asm/vgtod.h+1−1
@@ -93,7 +93,7 @@ static inline unsigned int __getcpu(void) · 92 unmodified lines
93 *93 *
94 * If RDPID is available, use it.94 * If RDPID is available, use it.
95 */95 */
96 alternative_io ("lsl %[p],%[seg]",96 alternative_io ("lsl %[seg],%[p]",
97 ".byte 0xf3,0x0f,0xc7,0xf8", /* RDPID %eax/rax */97 ".byte 0xf3,0x0f,0xc7,0xf8", /* RDPID %eax/rax */
98 X86_FEATURE_RDPID,98 X86_FEATURE_RDPID,
99 [p] "=a" (p), [seg] "r" (__PER_CPU_SEG));99 [p] "=a" (p), [seg] "r" (__PER_CPU_SEG));

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t