summary refs log tree commit diff
path: root/crypto/lzo.c
diff options
context:
space:
mode:
authorBjorn Helgaas <bhelgaas@google.com>2014-03-07 13:39:01 -0700
committerBjorn Helgaas <bhelgaas@google.com>2014-03-19 15:00:16 -0600
commitaa11fc58dc71c27701b1f9a529a36a38d4337722 (patch)
tree626a75fa7f73d6c078c637a0404f4079b61be2f3 /crypto/lzo.c
parent6404e88e8385638123f4b18b104430480870601a (diff)
downloadlinux-aa11fc58dc71c27701b1f9a529a36a38d4337722.tar.gz
PCI: Check all IORESOURCE_TYPE_BITS in pci_bus_alloc_from_region()
When allocating space from a bus resource, i.e., from apertures leading to
this bus, make sure the entire resource type matches.  The previous code
assumed the IORESOURCE_TYPE_BITS field was a bitmask with only a single bit
set, but this is not true.  IORESOURCE_TYPE_BITS is really an enumeration,
and we have to check all the bits.

See 72dcb1197228 ("resources: Add register address resource type").

No functional change.  If we used this path for allocating IRQs, DMA
channels, or bus numbers, this would fix a bug because those types are
indistinguishable when masked by IORESOURCE_IO | IORESOURCE_MEM.  But we
don't, so this shouldn't make any difference.

Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'crypto/lzo.c')
0 files changed, 0 insertions, 0 deletions