lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Tue, 07 Apr 2015 14:38:08 +0200
From:	Paolo Bonzini <pbonzini@...hat.com>
To:	Radim Krčmář <rkrcmar@...hat.com>,
	linux-kernel@...r.kernel.org
CC:	kvm@...r.kernel.org, Nadav Amit <namit@...technion.ac.il>,
	Gleb Natapov <gleb@...nel.org>
Subject: Re: [PATCH v2 4/4] KVM: x86: simplify kvm_apic_map



On 12/02/2015 19:41, Radim Krčmář wrote:
> +static inline void
> +apic_logical_id(struct kvm_apic_map *map, u32 dest_id, u16 *cid, u16 *lid)
> +{
> +	BUILD_BUG_ON(KVM_APIC_MODE_XAPIC_CLUSTER !=  4);
> +	BUILD_BUG_ON(KVM_APIC_MODE_XAPIC_FLAT    !=  8);
> +	BUILD_BUG_ON(KVM_APIC_MODE_X2APIC        != 16);
> +

I added

	unsigned lid_bits = map->mode;

here (used in the rest of apic_logical_id) and applied the series.

Thanks,

Paolo

> +	*cid = dest_id >> map->mode;
> +	*lid = dest_id & ((1 << map->mode) - 1);
> +}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ