[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH 3/6] mini-os/x86-64 entry: code refactoring; no functional changes
Xu Zhang, le Fri 08 Mar 2013 15:30:16 -0600, a écrit : > +#define XEN_GET_VCPU_INFO(reg) movq HYPERVISOR_shared_info,reg > +#define XEN_PUT_VCPU_INFO(reg) > +#define XEN_PUT_VCPU_INFO_fixup > +#define XEN_LOCKED_BLOCK_EVENTS(reg) movb $1,evtchn_upcall_mask(reg) > +#define XEN_LOCKED_UNBLOCK_EVENTS(reg) movb $0,evtchn_upcall_mask(reg) > +#define XEN_TEST_PENDING(reg) testb $0xFF,evtchn_upcall_pending(reg) > + > +#define XEN_BLOCK_EVENTS(reg) XEN_GET_VCPU_INFO(reg) > ; \ > + XEN_LOCKED_BLOCK_EVENTS(reg) ; \ > + XEN_PUT_VCPU_INFO(reg) > + > +#define XEN_UNBLOCK_EVENTS(reg) XEN_GET_VCPU_INFO(reg) > ; \ > + XEN_LOCKED_UNBLOCK_EVENTS(reg) > ; \ > + XEN_PUT_VCPU_INFO(reg) I agree on moving those, as they don't really have a context. > +/* Macros */ > +.macro zeroentry sym > + movq (%rsp),%rcx > + movq 8(%rsp),%r11 > + addq $0x10,%rsp /* skip rcx and r11 */ > + pushq $0 /* push error code/oldrax */ > + pushq %rax /* push real oldrax to the rdi slot */ > + leaq \sym(%rip),%rax > + jmp error_entry > +.endm > + > +.macro errorentry sym > + movq (%rsp),%rcx > + movq 8(%rsp),%r11 > + addq $0x10,%rsp /* rsp points to the error code */ > + pushq %rax > + leaq \sym(%rip),%rax > + jmp error_entry > +.endm I disagree on moving those, as they do have some context. > > ENTRY(hypervisor_callback) > zeroentry hypervisor_callback2 > > ENTRY(hypervisor_callback2) > - movq %rdi, %rsp > + movq %rdi, %rsp Please avoid such kind of difference, or make it another patch. > retint_kernel: > retint_restore_args: Please also drop these labels, they're not used. I agree on the rest. Samuel _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |