mirror of
https://github.com/linux-sunxi/u-boot-sunxi.git
synced 2024-02-12 11:16:03 +08:00
dm: blk: Add a function to find an interface-type name
Add a function to find the name of an interface type (e.g. "sata", "scsi") from the interface type enum. This is useful for generic code (not specific to SATA or SCSI, for example) that wants to display the type of interface it is dealing with. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:

committed by
Jaehoon Chung

parent
745fb9c25e
commit
6faa4ed74d
@ -624,4 +624,12 @@ ulong blk_write_devnum(enum if_type if_type, int devnum, lbaint_t start,
|
||||
*/
|
||||
int blk_select_hwpart_devnum(enum if_type if_type, int devnum, int hwpart);
|
||||
|
||||
/**
|
||||
* blk_get_if_type_name() - Get the name of an interface type
|
||||
*
|
||||
* @if_type: Interface type to check
|
||||
* @return name of interface, or NULL if none
|
||||
*/
|
||||
const char *blk_get_if_type_name(enum if_type if_type);
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user