summaryrefslogtreecommitdiff
path: root/sys/dev/ofw
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/ofw')
-rw-r--r--sys/dev/ofw/ofw_clock.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/sys/dev/ofw/ofw_clock.c b/sys/dev/ofw/ofw_clock.c
index 459a24f3838..4242641a48d 100644
--- a/sys/dev/ofw/ofw_clock.c
+++ b/sys/dev/ofw/ofw_clock.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ofw_clock.c,v 1.9 2018/05/03 10:56:14 patrick Exp $ */
+/* $OpenBSD: ofw_clock.c,v 1.10 2018/06/03 18:17:27 kettenis Exp $ */
/*
* Copyright (c) 2016 Mark Kettenis
*
@@ -97,17 +97,13 @@ clock_set_parent_cells(uint32_t *cells, uint32_t *pcells)
struct clock_device *cd;
uint32_t phandle = cells[0];
- /* We expect that clocks are on the same handle. */
- if (phandle != pcells[0])
- return -1;
-
LIST_FOREACH(cd, &clock_devices, cd_list) {
if (cd->cd_phandle == phandle)
break;
}
if (cd && cd->cd_set_parent)
- return cd->cd_set_parent(cd->cd_cookie, &cells[1], &pcells[1]);
+ return cd->cd_set_parent(cd->cd_cookie, &cells[1], pcells);
return -1;
}