]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
powerpc/pseries: Return req#msi(-x) if request is larger
authorMichael Ellerman <michael@ellerman.id.au>
Tue, 17 Feb 2009 00:18:49 +0000 (00:18 +0000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Mon, 23 Feb 2009 04:53:03 +0000 (15:53 +1100)
commitd523cc379da57f1c39f5db9c47bdaa94f74727ff
tree633a0fdaed64cea289706aa00063de9705cb29f2
parent620165f971753c2c451c880796bac7cd66f3534a
powerpc/pseries: Return req#msi(-x) if request is larger

If a driver asks for more MSIs than the devices "req#msi(-x)" property,
we currently return -ENOSPC. This doesn't give the driver any chance to
make a new request with a number that might work.

So if "req#msi(-x)" is less than the request, return its value. To be
100% safe, make sure we return an error if req_msi == 0.

Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/platforms/pseries/msi.c