diff options
author | Haibo Chen <haibo.chen@nxp.com> | 2018-02-26 15:12:18 +0800 |
---|---|---|
committer | Jason Liu <jason.hui.liu@nxp.com> | 2018-10-29 11:10:38 +0800 |
commit | 1fb5c90b787b540546324478f3b1d921e20aff00 (patch) | |
tree | 5efb197f2afa253c4bead52c5c63d4f398490184 /include/linux | |
parent | 25573e1de56021a01d74ecfe1bf312f57535d411 (diff) |
MLK-17621-2 mmc: add feature of setting slot index via devicetree alias
Add feature of setting slot index via devicetree alias, to hard code the
mmc/sd root device.
The patch requires additional alias_id fix or it won't work.
Note: minor device number keep independent with this device alias.
Refer to the commit 35928d6c6a76 ("mmc: Allow setting slot index via
devicetree alias").
Acked-by: Leonard Crestez <leonard.crestez@nxp.com>
Reviewed-by: Dong Aisheng <aisheng.dong@nxp.com>
Signed-off-by: Haibo Chen <haibo.chen@nxp.com>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/of.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/of.h b/include/linux/of.h index b240ed69dc96..9719ebe26a30 100644 --- a/include/linux/of.h +++ b/include/linux/of.h @@ -382,6 +382,7 @@ extern int of_phandle_iterator_args(struct of_phandle_iterator *it, extern void of_alias_scan(void * (*dt_alloc)(u64 size, u64 align)); extern int of_alias_get_id(struct device_node *np, const char *stem); extern int of_alias_get_highest_id(const char *stem); +extern int of_alias_max_index(const char *stem); extern int of_machine_is_compatible(const char *compat); @@ -818,6 +819,11 @@ static inline int of_alias_get_highest_id(const char *stem) return -ENOSYS; } +static inline int of_alias_max_index(const char *stem) +{ + return -ENODEV; +} + static inline int of_machine_is_compatible(const char *compat) { return 0; |