From: Christoffer Dall <cdall@cs.columbia.edu>
To: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Marc Zyngier <marc.zyngier@arm.com>,
Linux-Next Mailing List <linux-next@vger.kernel.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: linux-next: manual merge of the kvm-arm tree with Linus' tree
Date: Mon, 10 Apr 2017 01:02:22 -0700 [thread overview]
Message-ID: <20170410080222.GB32818@lvm> (raw)
In-Reply-To: <20170410140208.058f9938@canb.auug.org.au>
Hi Stephen,
On Mon, Apr 10, 2017 at 02:02:08PM +1000, Stephen Rothwell wrote:
> Hi all,
>
> Today's linux-next merge of the kvm-arm tree got conflicts in:
>
> virt/kvm/arm/vgic/vgic-v2.c
> virt/kvm/arm/vgic/vgic.h
>
> between commit:
>
> 5b0d2cc28058 ("KVM: arm64: Ensure LRs are clear when they should be")
>
> from Linus' tree and commits:
>
> 328e56647944 ("KVM: arm/arm64: vgic: Defer touching GICH_VMCR to vcpu_load/put")
> af0614991ab6 ("KVM: arm/arm64: vgic: Get rid of unnecessary process_maintenance operation")
>
> from the kvm-arm tree.
>
> I fixed it up (see below) and can carry the fix as necessary. This
> is now fixed as far as linux-next is concerned, but any non trivial
> conflicts should be mentioned to your upstream maintainer when your tree
> is submitted for merging. You may also want to consider cooperating
> with the maintainer of the conflicting tree to minimise any particularly
> complex conflicts.
>
Looks good, thanks.
-Christoffer
>
> diff --cc virt/kvm/arm/vgic/vgic-v2.c
> index b637d9c7afe3,025b57d5787e..000000000000
> --- a/virt/kvm/arm/vgic/vgic-v2.c
> +++ b/virt/kvm/arm/vgic/vgic-v2.c
> @@@ -22,36 -22,7 +22,22 @@@
>
> #include "vgic.h"
>
> - /*
> - * Call this function to convert a u64 value to an unsigned long * bitmask
> - * in a way that works on both 32-bit and 64-bit LE and BE platforms.
> - *
> - * Warning: Calling this function may modify *val.
> - */
> - static unsigned long *u64_to_bitmask(u64 *val)
> - {
> - #if defined(CONFIG_CPU_BIG_ENDIAN) && BITS_PER_LONG == 32
> - *val = (*val >> 32) | (*val << 32);
> - #endif
> - return (unsigned long *)val;
> - }
> -
> +static inline void vgic_v2_write_lr(int lr, u32 val)
> +{
> + void __iomem *base = kvm_vgic_global_state.vctrl_base;
> +
> + writel_relaxed(val, base + GICH_LR0 + (lr * 4));
> +}
> +
> +void vgic_v2_init_lrs(void)
> +{
> + int i;
> +
> + for (i = 0; i < kvm_vgic_global_state.nr_lr; i++)
> + vgic_v2_write_lr(i, 0);
> +}
> +
> - void vgic_v2_process_maintenance(struct kvm_vcpu *vcpu)
> + void vgic_v2_set_underflow(struct kvm_vcpu *vcpu)
> {
> struct vgic_v2_cpu_if *cpuif = &vcpu->arch.vgic_cpu.vgic_v2;
>
> @@@ -206,10 -160,10 +175,10 @@@ void vgic_v2_set_vmcr(struct kvm_vcpu *
> GICH_VMCR_ALIAS_BINPOINT_MASK;
> vmcr |= (vmcrp->bpr << GICH_VMCR_BINPOINT_SHIFT) &
> GICH_VMCR_BINPOINT_MASK;
> - vmcr |= (vmcrp->pmr << GICH_VMCR_PRIMASK_SHIFT) &
> - GICH_VMCR_PRIMASK_MASK;
> + vmcr |= ((vmcrp->pmr >> GICV_PMR_PRIORITY_SHIFT) <<
> + GICH_VMCR_PRIMASK_SHIFT) & GICH_VMCR_PRIMASK_MASK;
>
> - vcpu->arch.vgic_cpu.vgic_v2.vgic_vmcr = vmcr;
> + cpu_if->vgic_vmcr = vmcr;
> }
>
> void vgic_v2_get_vmcr(struct kvm_vcpu *vcpu, struct vgic_vmcr *vmcrp)
> diff --cc virt/kvm/arm/vgic/vgic.h
> index 6cf557e9f718,44445dac0835..000000000000
> --- a/virt/kvm/arm/vgic/vgic.h
> +++ b/virt/kvm/arm/vgic/vgic.h
> @@@ -137,7 -129,8 +136,9 @@@ int vgic_v2_map_resources(struct kvm *k
> int vgic_register_dist_iodev(struct kvm *kvm, gpa_t dist_base_address,
> enum vgic_type);
>
> +void vgic_v2_init_lrs(void);
> + void vgic_v2_load(struct kvm_vcpu *vcpu);
> + void vgic_v2_put(struct kvm_vcpu *vcpu);
>
> static inline void vgic_get_irq_kref(struct vgic_irq *irq)
> {
next prev parent reply other threads:[~2017-04-10 8:02 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-10 4:02 linux-next: manual merge of the kvm-arm tree with Linus' tree Stephen Rothwell
2017-04-10 8:02 ` Christoffer Dall [this message]
-- strict thread matches above, loose matches on Subject: below --
2025-03-05 4:34 Stephen Rothwell
2018-01-03 2:38 Stephen Rothwell
2018-01-03 9:50 ` Christoffer Dall
2017-11-06 2:56 Stephen Rothwell
2017-11-06 2:52 Stephen Rothwell
2015-03-18 3:41 Stephen Rothwell
2015-03-18 7:55 ` Christoffer Dall
2015-04-07 16:20 ` Paolo Bonzini
2015-04-08 8:15 ` Marc Zyngier
2015-04-08 10:57 ` Christoffer Dall
2015-04-16 19:10 ` Christoffer Dall
2015-04-16 19:39 ` Paolo Bonzini
2015-04-16 20:16 ` Christoffer Dall
2014-10-17 1:47 Stephen Rothwell
2014-07-31 6:30 Stephen Rothwell
2014-07-31 12:10 ` Marc Zyngier
[not found] ` <CAEDV+gJ1oSPzgZMO=kdFDNPnzy-EOHGuLxHqTB8KO6d_8yPrxQ@mail.gmail.com>
2014-07-31 12:15 ` Marc Zyngier
2014-07-31 14:23 ` Christoffer Dall
2014-07-31 14:30 ` Marc Zyngier
2014-08-01 5:21 ` Stephen Rothwell
2014-07-31 12:17 ` Stephen Rothwell
2014-07-31 12:41 ` Stephen Rothwell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170410080222.GB32818@lvm \
--to=cdall@cs.columbia.edu \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=marc.zyngier@arm.com \
--cc=sfr@canb.auug.org.au \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).