Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/evbarm/rockchip Enable LDO2 for HDMI driver.



details:   https://anonhg.NetBSD.org/src/rev/7aa7aea8be79
branches:  trunk
changeset: 805429:7aa7aea8be79
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Fri Jan 02 00:50:56 2015 +0000

description:
Enable LDO2 for HDMI driver.

diffstat:

 sys/arch/evbarm/rockchip/rockchip_machdep.c |  19 +++++++++++++++++--
 1 files changed, 17 insertions(+), 2 deletions(-)

diffs (52 lines):

diff -r de78e5083e8e -r 7aa7aea8be79 sys/arch/evbarm/rockchip/rockchip_machdep.c
--- a/sys/arch/evbarm/rockchip/rockchip_machdep.c       Thu Jan 01 22:15:40 2015 +0000
+++ b/sys/arch/evbarm/rockchip/rockchip_machdep.c       Fri Jan 02 00:50:56 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: rockchip_machdep.c,v 1.12 2014/12/30 03:53:52 jmcneill Exp $ */
+/*     $NetBSD: rockchip_machdep.c,v 1.13 2015/01/02 00:50:56 jmcneill Exp $ */
 
 /*
  * Machine dependent functions for kernel setup for TI OSK5912 board.
@@ -125,7 +125,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rockchip_machdep.c,v 1.12 2014/12/30 03:53:52 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rockchip_machdep.c,v 1.13 2015/01/02 00:50:56 jmcneill Exp $");
 
 #include "opt_machdep.h"
 #include "opt_ddb.h"
@@ -143,6 +143,7 @@
 #include "ukbd.h"
 #endif
 #include "arml2cc.h"
+#include "act8846pm.h"
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -182,6 +183,8 @@
 #include <dev/ic/ns16550reg.h>
 #include <dev/ic/comreg.h>
 
+#include <dev/i2c/act8846.h>
+
 #include <arm/rockchip/rockchip_reg.h>
 #include <arm/rockchip/rockchip_crureg.h>
 #include <arm/rockchip/rockchip_var.h>
@@ -750,4 +753,16 @@
                return;
        }
 #endif
+
+       if (device_is_a(self, "ithdmi")) {
+#if NACT8846PM > 0
+               device_t pmic = device_find_by_driver_unit("act8846pm", 0);
+               if (pmic == NULL)
+                       return;
+               struct act8846_ctrl *ctrl = act8846_lookup(pmic, "LDO2");
+               if (ctrl == NULL)
+                       return;
+               act8846_enable(ctrl);
+#endif
+       }
 }



Home | Main Index | Thread Index | Old Index