Skip to content

Commit

Permalink
astbmc/slots: Add SW_PLUGGABLE() macro
Browse files Browse the repository at this point in the history
Add a macro to help with defining ports that are under a switch. This is
different to the existing ST_PLUGGABLE() macro in that it can be used to
define a slot inside a slot_table_entry array.

Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
  • Loading branch information
oohal authored and stewartsmith committed Sep 13, 2018
1 parent d76e4fb commit c079587
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions platforms/astbmc/astbmc.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,14 @@ static struct slot_table_entry st_name[] = \
{ .etype = st_end }, \
}

#define SW_PLUGGABLE(slot_name, port, ...) \
{ \
.etype = st_pluggable_slot, \
.name = slot_name, \
.location = ST_LOC_DEVFN(port, 0), \
##__VA_ARGS__ \
}

extern const struct bmc_platform astbmc_ami;
extern const struct bmc_platform astbmc_openbmc;

Expand Down

0 comments on commit c079587

Please sign in to comment.