Re: [PATCH] KVM: s390: Fix potential spectre warnings

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

 



On 17/04/19 09:49, David Hildenbrand wrote:
> return kvm->arch.adapters[array_index_nospec(id, MAX_S390_IO_ADAPTERS)];
> 
> should exactly fit into a single line if I am not wrong.

git grep "\\[.*array_index_nospec" suggests that the preferred idiom is

	var = array_index_nospec(var, SIZE)

which makes sense since it sanitizes var once and for all.

Paolo



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Kernel Development]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Info]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Linux Media]     [Device Mapper]

  Powered by Linux