Providing a subsystem-level API helper seems over-kill just to save a few lines of C-code. Previous commits saw us convert mfd_clone_cell()'s only user over to use a more traditional style of MFD child-device registration. Now we can remove the superfluous helper from the MFD API.
Showing the changes to include/linux (1 of 2 files). Show all
Unified · Split
| @@ -115,24 +115,6 @@ struct mfd_cell { · 114 unmodified lines | ||
| 115 | 115 | extern int mfd_cell_enable(struct platform_device *pdev); |
| 116 | 116 | extern int mfd_cell_disable(struct platform_device *pdev); |
| 117 | 117 | |
| 118 | −/* | |
| 119 | − * "Clone" multiple platform devices for a single cell. This is to be used | |
| 120 | − * for devices that have multiple users of a cell. For example, if an mfd | |
| 121 | − * driver wants the cell "foo" to be used by a GPIO driver, an MTD driver, | |
| 122 | − * and a platform driver, the following bit of code would be use after first | |
| 123 | − * calling mfd_add_devices(): | |
| 124 | − * | |
| 125 | − * const char *fclones[] = { "foo-gpio", "foo-mtd" }; | |
| 126 | − * err = mfd_clone_cells("foo", fclones, ARRAY_SIZE(fclones)); | |
| 127 | − * | |
| 128 | − * Each driver (MTD, GPIO, and platform driver) would then register | |
| 129 | − * platform_drivers for "foo-mtd", "foo-gpio", and "foo", respectively. | |
| 130 | − * The cell's .enable/.disable hooks should be used to deal with hardware | |
| 131 | − * resource contention. | |
| 132 | − */ | |
| 133 | −extern int mfd_clone_cell(const char *cell, const char **clones, | |
| 134 | − size_t n_clones); | |
| 135 | − | |
| 136 | 118 | /* |
| 137 | 119 | * Given a platform device that's been created by mfd_add_devices(), fetch |
| 138 | 120 | * the mfd_cell that created it. |