search for: patch_default

Displaying 20 results from an estimated 25 matches for "patch_default".

2016 Dec 16
2
[PATCH] x86/paravirt: hide unused patch_default label
A bugfix introduced a harmless warning: arch/x86/kernel/paravirt_patch_32.c: In function 'native_patch': arch/x86/kernel/paravirt_patch_32.c:71:1: error: label 'patch_default' defined but not used [-Werror=unused-label] This puts it in the same #ifdef as its caller. Fixes: 45dbea5f55c0 ("x86/paravirt: Fix native_patch()") Signed-off-by: Arnd Bergmann <arnd at arndb.de> --- arch/x86/kernel/paravirt_patch_32.c | 2 ++ arch/x86/kernel/paravirt_patch_...
2016 Dec 16
2
[PATCH] x86/paravirt: hide unused patch_default label
A bugfix introduced a harmless warning: arch/x86/kernel/paravirt_patch_32.c: In function 'native_patch': arch/x86/kernel/paravirt_patch_32.c:71:1: error: label 'patch_default' defined but not used [-Werror=unused-label] This puts it in the same #ifdef as its caller. Fixes: 45dbea5f55c0 ("x86/paravirt: Fix native_patch()") Signed-off-by: Arnd Bergmann <arnd at arndb.de> --- arch/x86/kernel/paravirt_patch_32.c | 2 ++ arch/x86/kernel/paravirt_patch_...
2018 Sep 07
2
[PATCH v2] x86/paravirt: Get rid of patch_site and patch_default labels
...@@ unsigned native_patch(u8 type, void *ibuf, unsigned long addr, unsigned len) if (pv_is_native_spin_unlock()) { start = start_lock_queued_spin_unlock; end = end_lock_queued_spin_unlock; - goto patch_site; + + return paravirt_patch_insns(ibuf, len, start, end); } - goto patch_default; + return paravirt_patch_default(type, ibuf, addr, len); case PARAVIRT_PATCH(lock.vcpu_is_preempted): if (pv_is_native_vcpu_is_preempted()) { start = start_lock_vcpu_is_preempted; end = end_lock_vcpu_is_preempted; - goto patch_site; + + return paravirt_patch_insns(ibuf,...
2018 Sep 07
2
[PATCH v2] x86/paravirt: Get rid of patch_site and patch_default labels
...@@ unsigned native_patch(u8 type, void *ibuf, unsigned long addr, unsigned len) if (pv_is_native_spin_unlock()) { start = start_lock_queued_spin_unlock; end = end_lock_queued_spin_unlock; - goto patch_site; + + return paravirt_patch_insns(ibuf, len, start, end); } - goto patch_default; + return paravirt_patch_default(type, ibuf, addr, len); case PARAVIRT_PATCH(lock.vcpu_is_preempted): if (pv_is_native_vcpu_is_preempted()) { start = start_lock_vcpu_is_preempted; end = end_lock_vcpu_is_preempted; - goto patch_site; + + return paravirt_patch_insns(ibuf,...
2016 Dec 16
0
[PATCH] x86/paravirt: hide unused patch_default label
On Fri, Dec 16, 2016 at 10:16:35AM +0100, Arnd Bergmann wrote: > A bugfix introduced a harmless warning: > > arch/x86/kernel/paravirt_patch_32.c: In function 'native_patch': > arch/x86/kernel/paravirt_patch_32.c:71:1: error: label 'patch_default' defined but not used [-Werror=unused-label] > > This puts it in the same #ifdef as its caller. > > Fixes: 45dbea5f55c0 ("x86/paravirt: Fix native_patch()") > Signed-off-by: Arnd Bergmann <arnd at arndb.de> > --- This seems to work as well and is less invasi...
2018 Sep 08
0
[PATCH v2] x86/paravirt: Get rid of patch_site and patch_default labels
...ibuf, unsigned long addr, unsigned len) > if (pv_is_native_spin_unlock()) { > start = start_lock_queued_spin_unlock; > end = end_lock_queued_spin_unlock; > - goto patch_site; > + > + return paravirt_patch_insns(ibuf, len, start, end); > } > - goto patch_default; > + return paravirt_patch_default(type, ibuf, addr, len); > > case PARAVIRT_PATCH(lock.vcpu_is_preempted): > if (pv_is_native_vcpu_is_preempted()) { > start = start_lock_vcpu_is_preempted; > end = end_lock_vcpu_is_preempted; > - goto patch_site; >...
2016 Dec 08
0
[PATCH 1/2] x86,paravirt: Fix native_patch()
...l/paravirt_patch_64.c | 4 ++++ 2 files changed, 8 insertions(+) --- a/arch/x86/kernel/paravirt_patch_32.c +++ b/arch/x86/kernel/paravirt_patch_32.c @@ -56,15 +56,19 @@ unsigned native_patch(u8 type, u16 clobb end = end_pv_lock_ops_queued_spin_unlock; goto patch_site; } + goto patch_default; + case PARAVIRT_PATCH(pv_lock_ops.vcpu_is_preempted): if (pv_is_native_vcpu_is_preempted()) { start = start_pv_lock_ops_vcpu_is_preempted; end = end_pv_lock_ops_vcpu_is_preempted; goto patch_site; } + goto patch_default; #endif default: +patch_default: ret = p...
2018 Sep 08
2
[PATCH] x86/paravirt: Cleanup native_patch()
...igned len) PATCH_SITE(mmu, write_cr3); #endif #if defined(CONFIG_PARAVIRT_SPINLOCKS) - case PARAVIRT_PATCH(lock.queued_spin_unlock): - if (pv_is_native_spin_unlock()) { - start = start_lock_queued_spin_unlock; - end = end_lock_queued_spin_unlock; - goto patch_site; - } - goto patch_default; + case PARAVIRT_PATCH(lock.queued_spin_unlock): + if (pv_is_native_spin_unlock()) + return paravirt_patch_insns(ibuf, len, + start_lock_queued_spin_unlock, + end_lock_queued_spin_unlock); + else + return paravirt_patch_default(type, ibuf, addr, len); - case PARAVIRT_PATC...
2018 Sep 08
2
[PATCH] x86/paravirt: Cleanup native_patch()
...igned len) PATCH_SITE(mmu, write_cr3); #endif #if defined(CONFIG_PARAVIRT_SPINLOCKS) - case PARAVIRT_PATCH(lock.queued_spin_unlock): - if (pv_is_native_spin_unlock()) { - start = start_lock_queued_spin_unlock; - end = end_lock_queued_spin_unlock; - goto patch_site; - } - goto patch_default; + case PARAVIRT_PATCH(lock.queued_spin_unlock): + if (pv_is_native_spin_unlock()) + return paravirt_patch_insns(ibuf, len, + start_lock_queued_spin_unlock, + end_lock_queued_spin_unlock); + else + return paravirt_patch_default(type, ibuf, addr, len); - case PARAVIRT_PATC...
2016 Dec 14
1
[PATCH] arch: x86: kernel: fixed unused label issue
The patch_default label is only used from within case PARAVIRT_PATCH(pv_lock_ops.queued_spin_unlock) and case PARAVIRT_PATCH(pv_lock_ops.vcpu_is_preempted) i.e. when #if defined(CONFIG_PARAVIRT_SPINLOCKS) is true. Therefore no code jumps to this label in case CONFIG_PARAVIRT_SPINLOCKS is not defined and label shou...
2016 Dec 14
1
[PATCH] arch: x86: kernel: fixed unused label issue
The patch_default label is only used from within case PARAVIRT_PATCH(pv_lock_ops.queued_spin_unlock) and case PARAVIRT_PATCH(pv_lock_ops.vcpu_is_preempted) i.e. when #if defined(CONFIG_PARAVIRT_SPINLOCKS) is true. Therefore no code jumps to this label in case CONFIG_PARAVIRT_SPINLOCKS is not defined and label shou...
2018 Sep 07
2
[PATCH] x86/paravirt: Get rid of patch_site label
...nsigned native_patch(u8 type, void *ibuf, unsigned long addr, unsigned len) if (pv_is_native_vcpu_is_preempted()) { start = start_lock_vcpu_is_preempted; end = end_lock_vcpu_is_preempted; - goto patch_site; + + return paravirt_patch_insns(ibuf, len, start, end); } goto patch_default; #endif @@ -86,7 +87,6 @@ patch_default: __maybe_unused ret = paravirt_patch_default(type, ibuf, addr, len); break; -patch_site: ret = paravirt_patch_insns(ibuf, len, start, end); break; } -- 2.17.0.582.gccdcbd54c
2018 Sep 07
2
[PATCH] x86/paravirt: Get rid of patch_site label
...nsigned native_patch(u8 type, void *ibuf, unsigned long addr, unsigned len) if (pv_is_native_vcpu_is_preempted()) { start = start_lock_vcpu_is_preempted; end = end_lock_vcpu_is_preempted; - goto patch_site; + + return paravirt_patch_insns(ibuf, len, start, end); } goto patch_default; #endif @@ -86,7 +87,6 @@ patch_default: __maybe_unused ret = paravirt_patch_default(type, ibuf, addr, len); break; -patch_site: ret = paravirt_patch_insns(ibuf, len, start, end); break; } -- 2.17.0.582.gccdcbd54c
2016 Dec 08
3
[PATCH 0/2] Fix paravirt fail
Two patches that cure fallout from commit: 3cded4179481 ("x86/paravirt: Optimize native pv_lock_ops.vcpu_is_preempted()")
2016 Dec 08
3
[PATCH 0/2] Fix paravirt fail
Two patches that cure fallout from commit: 3cded4179481 ("x86/paravirt: Optimize native pv_lock_ops.vcpu_is_preempted()")
2018 Sep 11
1
[PATCH v2] x86/paravirt: Cleanup native_patch()
...igned len) PATCH_SITE(mmu, write_cr3); #endif #if defined(CONFIG_PARAVIRT_SPINLOCKS) - case PARAVIRT_PATCH(lock.queued_spin_unlock): - if (pv_is_native_spin_unlock()) { - start = start_lock_queued_spin_unlock; - end = end_lock_queued_spin_unlock; - goto patch_site; - } - goto patch_default; + case PARAVIRT_PATCH(lock.queued_spin_unlock): + if (pv_is_native_spin_unlock()) + return paravirt_patch_insns(ibuf, len, + start_lock_queued_spin_unlock, + end_lock_queued_spin_unlock); + break; - case PARAVIRT_PATCH(lock.vcpu_is_preempted): - if (pv_is_native_vcpu_is_...
2018 Sep 10
2
[PATCH] x86/paravirt: Cleanup native_patch()
...t; + case PARAVIRT_PATCH(lock.queued_spin_unlock): > > + if (pv_is_native_spin_unlock()) > > + return paravirt_patch_insns(ibuf, len, > > + start_lock_queued_spin_unlock, > > + end_lock_queued_spin_unlock); > > + else > > + return paravirt_patch_default(type, ibuf, addr, len); > > Why not replace the else clause by a "break;" and ... Because I think that exiting right then and there is much easier to follow than adding all those breaks and wading through ifdeffery to realize that this is the default path and we'll end up call...
2018 Sep 10
2
[PATCH] x86/paravirt: Cleanup native_patch()
...t; + case PARAVIRT_PATCH(lock.queued_spin_unlock): > > + if (pv_is_native_spin_unlock()) > > + return paravirt_patch_insns(ibuf, len, > > + start_lock_queued_spin_unlock, > > + end_lock_queued_spin_unlock); > > + else > > + return paravirt_patch_default(type, ibuf, addr, len); > > Why not replace the else clause by a "break;" and ... Because I think that exiting right then and there is much easier to follow than adding all those breaks and wading through ifdeffery to realize that this is the default path and we'll end up call...
2018 Sep 10
0
[PATCH] x86/paravirt: Cleanup native_patch()
...; #endif > #if defined(CONFIG_PARAVIRT_SPINLOCKS) > - case PARAVIRT_PATCH(lock.queued_spin_unlock): > - if (pv_is_native_spin_unlock()) { > - start = start_lock_queued_spin_unlock; > - end = end_lock_queued_spin_unlock; > - goto patch_site; > - } > - goto patch_default; > + case PARAVIRT_PATCH(lock.queued_spin_unlock): > + if (pv_is_native_spin_unlock()) > + return paravirt_patch_insns(ibuf, len, > + start_lock_queued_spin_unlock, > + end_lock_queued_spin_unlock); > + else > + return paravirt_patch_default(type, ibuf,...
2018 Aug 13
0
[PATCH v2 02/11] x86/paravirt: remove clobbers parameter from paravirt patch functions
The clobbers parameter from paravirt_patch_default() et al isn't used any longer. Remove it. Signed-off-by: Juergen Gross <jgross at suse.com> --- arch/x86/include/asm/paravirt_types.h | 7 +++---- arch/x86/kernel/alternative.c | 2 +- arch/x86/kernel/paravirt.c | 14 +++++--------- arch/x86/kernel/paravirt_patch_32...