Commit afbf8ec7 authored by Javier Martinez Canillas's avatar Javier Martinez Canillas Committed by Olof Johansson
Browse files

platform/chrome: cros_ec_dev - Add a platform device ID table



If the cros_ec_dev driver is built as a module, modalias information is
not filled so the module is not autoloaded. Add a platform device table
and use the MODULE_DEVICE_TABLE() macro to export that information in
the module so user-space can match the modalias uevent and autoload it.

Signed-off-by: default avatarJavier Martinez Canillas <javier.martinez@collabora.co.uk>
Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
parent 85bba84e
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -287,6 +287,12 @@ static int ec_device_remove(struct platform_device *pdev)
	return 0;
}

static const struct platform_device_id cros_ec_id[] = {
	{ "cros-ec-ctl", 0 },
	{ /* sentinel */ },
};
MODULE_DEVICE_TABLE(platform, cros_ec_id);

static struct platform_driver cros_ec_dev_driver = {
	.driver = {
		.name = "cros-ec-ctl",