diff --git a/drivers/block/blk-uclass.c b/drivers/block/blk-uclass.c index b60a856daa..f258206e88 100644 --- a/drivers/block/blk-uclass.c +++ b/drivers/block/blk-uclass.c @@ -49,7 +49,7 @@ static enum uclass_id if_type_uclass_id[IF_TYPE_COUNT] = { [IF_TYPE_SYSTEMACE] = UCLASS_INVALID, }; -static enum if_type if_typename_to_iftype(const char *if_typename) +enum if_type if_typename_to_iftype(const char *if_typename) { int i; diff --git a/include/blk.h b/include/blk.h index 4eb79ed748..d1e82f574c 100644 --- a/include/blk.h +++ b/include/blk.h @@ -670,4 +670,12 @@ const char *blk_get_if_type_name(enum if_type if_type); int blk_common_cmd(int argc, char * const argv[], enum if_type if_type, int *cur_devnump); +/** + * if_typename_to_iftype() - get iftype according to iftype name + * + * @if_typename: iftype name + * @return iftype index + */ +enum if_type if_typename_to_iftype(const char *if_typename); + #endif