spr: Cleanup decoding of SPR numbers
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Thu, 31 Oct 2019 00:42:10 +0000 (11:42 +1100)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Thu, 14 Nov 2019 04:09:37 +0000 (15:09 +1100)
commit83a8bb0238c9d8633cf234881bae28dac6526540
treee470f88f80ef76b5ac23dff8bc3bd5cc949fa1c9
parentcff4b13a9b8d0036f9441c150bfd8e1d7bc620e3
spr: Cleanup decoding of SPR numbers

Use a function to obtain the integer number and use constants
with the architected numbers. Replace std_match with a case
statement.

This also has the side effect of returning 0 instead of some
random previous result on mfspr of an unknown SPR.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
common.vhdl
execute1.vhdl