瀏覽代碼

regulator: core: Check for DT every time we check full constraints

Eliminate the gap between DT becoming available and this being used to say
we have full constraints by checking directly for DT every time we check
for full constraints. This improves interoperaton with optional regulator
support.

Signed-off-by: Mark Brown <broonie@linaro.org>
Tested-by: Fabio Estevam <fabio.estevam@freescale.com>
Mark Brown 11 年之前
父節點
當前提交
75bc9641ca
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/regulator/core.c

+ 1 - 1
drivers/regulator/core.c

@@ -121,7 +121,7 @@ static const char *rdev_get_name(struct regulator_dev *rdev)
 
 static bool have_full_constraints(void)
 {
-	return has_full_constraints;
+	return has_full_constraints || of_have_populated_dt();
 }
 
 /**