]> git.baikalelectronics.ru Git - kernel.git/commit
mfd: Add mfd_clone_cell(), convert cs5535-mfd/olpc-xo1 to it
authorAndres Salomon <dilinger@queued.net>
Tue, 22 Mar 2011 02:19:35 +0000 (19:19 -0700)
committerSamuel Ortiz <sameo@linux.intel.com>
Sat, 26 Mar 2011 23:09:30 +0000 (00:09 +0100)
commite516ba68f5682c676a89e653cbe72dda7ae02c03
tree83df18f1d427115c0016a059535b04f2d600a2d0
parentb0775d884c4792a6ae8ac0e695a41188e32ae24f
mfd: Add mfd_clone_cell(), convert cs5535-mfd/olpc-xo1 to it

Replace mfd_shared_platform_driver_register with mfd_clone_cell.  The
former was called by an mfd client, and registered both a platform driver
and device.  The latter is called by an mfd driver, and registers only a
platform device.

The downside of this is that mfd drivers need to be modified whenever
new clients are added that share a cell; the upside is that it fits
Linux's driver model better.  It's also simpler.

This also converts cs5535-mfd/olpc-xo1 from the old API.  cs5535-mfd
now creates the olpc-xo1-{acpi,pms} devices, while olpc-xo1 binds to
them via platform drivers.

Signed-off-by: Andres Salomon <dilinger@queued.net>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
arch/x86/platform/olpc/olpc-xo1.c
drivers/mfd/cs5535-mfd.c
drivers/mfd/mfd-core.c
include/linux/mfd/core.h