Re: [PATCH 1/1] KVM: Merge kvm_ioapic_get_delivery_bitmask into kvm_get_intr_delivery_bitmask

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Mar 04, 2009 at 01:33:02PM +0800, Sheng Yang wrote:
> Gleb fixed bitmap ops usage in kvm_ioapic_get_delivery_bitmask.
> 
> Sheng merged two functions, as well as fixed several issues in
> kvm_get_intr_delivery_bitmask
> 1. deliver_bitmask is a bitmap rather than a unsigned long intereger.
> 2. Lowest priority target bitmap wrong calculated by mistake.
> 3. Prevent potential NULL reference.
> 4. Declaration in include/kvm_host.h caused powerpc compilation warning.
> 5. Add warning for guest broadcast interrupt with lowest priority delivery mode.
> 6. Removed duplicate bitmap clean up in caller of kvm_get_intr_delivery_bitmask.
> 
> Signed-off-by: Gleb Natapov <gleb@xxxxxxxxxx>
> Signed-off-by: Sheng Yang <sheng@xxxxxxxxxxxxxxx>

> +	bitmap_zero(deliver_bitmask, KVM_MAX_VCPUS);
> +
> +	if (entry->fields.dest_mode == 0) {	/* Physical mode. */
> +		if (entry->fields.dest_id == 0xFF) {	/* Broadcast. */
> +			/* Lowest priority shouldn't combine with broadcast */
> +			WARN_ON(entry->fields.delivery_mode ==
> +					IOAPIC_LOWEST_PRIORITY);

Applied with two changes:

- printk(KERN_INFO) with printk_ratelimit instead of WARN.
- bitmap_zero in the irq == 0 case.

Thanks

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux