Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F170600596
D23216.id67013.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D23216.id67013.diff
View Options
Index: head/sys/arm64/rockchip/rk805.c
===================================================================
--- head/sys/arm64/rockchip/rk805.c
+++ head/sys/arm64/rockchip/rk805.c
@@ -97,6 +97,9 @@
int nregs;
};
+static int rk805_regnode_set_voltage(struct regnode *regnode, int min_uvolt,
+ int max_uvolt, int *udelay);
+
static struct rk805_regdef rk805_regdefs[] = {
{
.id = RK805_DCDC1,
@@ -354,7 +357,26 @@
static int
rk805_regnode_init(struct regnode *regnode)
{
- return (0);
+ struct rk805_reg_sc *sc;
+ struct regnode_std_param *param;
+ int rv, udelay;
+
+ sc = regnode_get_softc(regnode);
+ param = regnode_get_stdparam(regnode);
+ if (param->min_uvolt == 0)
+ return (0);
+
+ /*
+ * Set the regulator at the correct voltage
+ * Do not enable it, this is will be done either by a
+ * consumer or by regnode_set_constraint if boot_on is true
+ */
+ rv = rk805_regnode_set_voltage(regnode, param->min_uvolt,
+ param->max_uvolt, &udelay);
+ if (rv != 0)
+ DELAY(udelay);
+
+ return (rv);
}
static int
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Sep 6, 2:25 PM (15 h, 48 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
38389045
Default Alt Text
D23216.id67013.diff (1 KB)
Attached To
Mode
D23216: rk805: Add a regnode_init method
Attached
Detach File
Event Timeline
Log In to Comment