diff options
author | Shawn Nematbakhsh <shawnn@chromium.org> | 2017-05-16 17:46:48 +0200 |
---|---|---|
committer | Benson Leung <bleung@chromium.org> | 2017-06-23 16:12:01 -0700 |
commit | 8d4a3dc423a2695be51ac864eefb8ba7688b1240 (patch) | |
tree | 5a8861e1cec25fcaf756822f0e035200a0e1cab1 /drivers/platform/chrome/cros_ec_lpc.c | |
parent | bce70fef7279243d62adbf5f53998b8d3d016144 (diff) | |
download | talos-obmc-linux-8d4a3dc423a2695be51ac864eefb8ba7688b1240.tar.gz talos-obmc-linux-8d4a3dc423a2695be51ac864eefb8ba7688b1240.zip |
platform/chrome: cros_ec_lpc: Add support for mec1322 EC
This adds support for the ChromeOS LPC Microchip Embedded Controller
(mec1322) variant.
mec1322 accesses I/O region [800h, 9ffh] through embedded memory
interface (EMI) rather than LPC.
Signed-off-by: Shawn Nematbakhsh <shawnn@chromium.org>
Signed-off-by: Thierry Escande <thierry.escande@collabora.com>
Acked-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Benson Leung <bleung@chromium.org>
Diffstat (limited to 'drivers/platform/chrome/cros_ec_lpc.c')
-rw-r--r-- | drivers/platform/chrome/cros_ec_lpc.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/platform/chrome/cros_ec_lpc.c b/drivers/platform/chrome/cros_ec_lpc.c index 6a782a695eb6..bc2dc6210d7b 100644 --- a/drivers/platform/chrome/cros_ec_lpc.c +++ b/drivers/platform/chrome/cros_ec_lpc.c @@ -346,10 +346,13 @@ static int __init cros_ec_lpc_init(void) return -ENODEV; } + cros_ec_lpc_reg_init(); + /* Register the driver */ ret = platform_driver_register(&cros_ec_lpc_driver); if (ret) { pr_err(DRV_NAME ": can't register driver: %d\n", ret); + cros_ec_lpc_reg_destroy(); return ret; } @@ -358,6 +361,7 @@ static int __init cros_ec_lpc_init(void) if (ret) { pr_err(DRV_NAME ": can't register device: %d\n", ret); platform_driver_unregister(&cros_ec_lpc_driver); + cros_ec_lpc_reg_destroy(); return ret; } @@ -368,6 +372,7 @@ static void __exit cros_ec_lpc_exit(void) { platform_device_unregister(&cros_ec_lpc_device); platform_driver_unregister(&cros_ec_lpc_driver); + cros_ec_lpc_reg_destroy(); } module_init(cros_ec_lpc_init); |