The atomic_sub_64() should use sbbl instead of adcl. In user
space these atomics are used for statistics tracking and aren't
critical which explain how this was overlooked. The kernel
space implementation of these atomics are layered on the
architecture specific implementations provided by the kernel.
Reviewed by: Stefan Ring <stefanrin@gmail.com>
Reviewed-by: Gvozden Neskovic <neskovic@gmail.com>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #5671
Closes #5717
movl 16(%esp), %ebx
movl 20(%esp), %ecx
subl %eax, %ebx
- adcl %edx, %ecx
+ sbbl %edx, %ecx
lock
cmpxchg8b (%edi)
jne 1b