soc/intel/p2sb: Drop unnecessary P2SB_GET_DEV
commite549503967aab3aabe68f686f75ca316b6bd8bf6
authorNico Huber <nico.h@gmx.de>
Mon, 17 Feb 2020 17:26:51 +0000 (17 18:26 +0100)
committerPatrick Georgi <pgeorgi@google.com>
Wed, 19 Feb 2020 12:08:53 +0000 (19 12:08 +0000)
treee224d60ea50bd79b1c695193b164b98e0e5ae27c
parent172ef5fe6182ade5fefed0e4f9e76c59fc89667d
soc/intel/p2sb: Drop unnecessary P2SB_GET_DEV

PCH_DEV_P2SB already covers both __SIMPLE_DEVICE__ cases. The values are
only used for PCI-config access functions, which also check for NULL
when necessary.

The PCI_DEV_INVALID case can't occur by definition, and if we wanted to
check, we could do so at compile time using _Static_assert().

Change-Id: I400fc20133809aaa0fd0519531a62ec9b8812ef1
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/38946
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Subrata Banik <subrata.banik@intel.com>
src/soc/intel/common/block/p2sb/p2sb.c