mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
mfd: core: propagate device properties to sub devices drivers
In the similar way like we do for the platform data we propagate the device properties. For example, in case of Intel LPSS drivers we may provide a specific property to tell the actual device driver an additional information such as platform name. Signed-off-by: Andy Shevchenko <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
This commit is contained in:
parent
55f89a8a45
commit
4d215cabc7
2 changed files with 12 additions and 0 deletions
|
|
@ -14,6 +14,7 @@
|
|||
#include <linux/kernel.h>
|
||||
#include <linux/platform_device.h>
|
||||
#include <linux/acpi.h>
|
||||
#include <linux/property.h>
|
||||
#include <linux/mfd/core.h>
|
||||
#include <linux/pm_runtime.h>
|
||||
#include <linux/slab.h>
|
||||
|
|
@ -192,6 +193,12 @@ static int mfd_add_device(struct device *parent, int id,
|
|||
goto fail_alias;
|
||||
}
|
||||
|
||||
if (cell->pset) {
|
||||
ret = platform_device_add_properties(pdev, cell->pset);
|
||||
if (ret)
|
||||
goto fail_alias;
|
||||
}
|
||||
|
||||
ret = mfd_platform_add_cell(pdev, cell, usage_count);
|
||||
if (ret)
|
||||
goto fail_alias;
|
||||
|
|
|
|||
Loading…
Reference in a new issue