File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -170,6 +170,7 @@ SYM_CODE_START_LOCAL_NOALIGN(identity_mapped)
170
170
wbinvd
171
171
.Lsme_off:
172
172
173
+ /* Save the preserve_context to %r11 as swap_pages clobbers %rcx. */
173
174
movq %rcx , %r11
174
175
call swap_pages
175
176
@@ -289,18 +290,21 @@ SYM_CODE_START_LOCAL_NOALIGN(swap_pages)
289
290
movq %rcx , %rsi /* For ever source page do a copy */
290
291
andq $0xfffffffffffff000 , %rsi
291
292
292
- movq %rdi , %rdx
293
- movq %rsi , %rax
293
+ movq %rdi , %rdx /* Save destination page to %rdx */
294
+ movq %rsi , %rax /* Save source page to %rax */
294
295
296
+ /* copy source page to swap page */
295
297
movq %r10 , %rdi
296
298
movl $512 , %ecx
297
299
rep ; movsq
298
300
301
+ /* copy destination page to source page */
299
302
movq %rax , %rdi
300
303
movq %rdx , %rsi
301
304
movl $512 , %ecx
302
305
rep ; movsq
303
306
307
+ /* copy swap page to destination page */
304
308
movq %rdx , %rdi
305
309
movq %r10 , %rsi
306
310
movl $512 , %ecx
You can’t perform that action at this time.
0 commit comments