Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751646AbdCABQ6 (ORCPT ); Tue, 28 Feb 2017 20:16:58 -0500 Received: from cdptpa-outbound-snat.email.rr.com ([107.14.166.232]:23912 "EHLO cdptpa-oedge-vip.email.rr.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751486AbdCABQy (ORCPT ); Tue, 28 Feb 2017 20:16:54 -0500 X-Greylist: delayed 378 seconds by postgrey-1.27 at vger.kernel.org; Tue, 28 Feb 2017 20:16:54 EST From: Jeremy Linton To: puck.chen@hisilicon.com Cc: lgirdwood@gmail.com, broonie@kernel.org, linux-kernel@vger.kernel.org, Jeremy Linton Subject: [PATCH] regulator: hi655x: Add DT bindings so module autoloads Date: Tue, 28 Feb 2017 19:07:06 -0600 Message-Id: <20170301010706.31899-1-lintonrjeremy@gmail.com> X-Mailer: git-send-email 2.10.2 X-RR-Connecting-IP: 107.14.168.7:25 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The hi655x driver is required for mmc/sd functionality on the 96boards hikey, and likely other platforms. When built as a standalone module it doesn't get automatically loaded because it is missing the module probe hooks. Adding that boilerplate so it gets demand loaded. Signed-off-by: Jeremy Linton --- drivers/regulator/hi655x-regulator.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/regulator/hi655x-regulator.c b/drivers/regulator/hi655x-regulator.c index aca1846..924ed60 100644 --- a/drivers/regulator/hi655x-regulator.c +++ b/drivers/regulator/hi655x-regulator.c @@ -214,9 +214,16 @@ static int hi655x_regulator_probe(struct platform_device *pdev) return 0; } +static const struct of_device_id hi655x_dt_ids[] = { + { .compatible = "hisilicon,hi655x-pmic", }, + {}, +}; +MODULE_DEVICE_TABLE(of, hi655x_dt_ids); + static struct platform_driver hi655x_regulator_driver = { .driver = { .name = "hi655x-regulator", + .of_match_table = hi655x_dt_ids, }, .probe = hi655x_regulator_probe, }; -- 2.10.2