microblaze: linux-user support.
[qemu] / hw / omap_clk.c
index 38b098e..fc86cf1 100644 (file)
@@ -1098,23 +1098,6 @@ void omap_clk_adduser(struct clk *clk, qemu_irq user)
     *i = user;
 }
 
-/* If a clock is allowed to idle, it is disabled automatically when
- * all of clock domains using it are disabled.  */
-static int omap_clk_is_idle(struct clk *clk)
-{
-    struct clk *chld;
-
-    if (!clk->enabled && (!clk->usecount || !(clk->flags && ALWAYS_ENABLED)))
-        return 1;
-    if (clk->usecount)
-        return 0;
-
-    for (chld = clk->child1; chld; chld = chld->sibling)
-        if (!omap_clk_is_idle(chld))
-            return 0;
-    return 1;
-}
-
 struct clk *omap_findclk(struct omap_mpu_state_s *mpu, const char *name)
 {
     struct clk *i;
@@ -1122,7 +1105,7 @@ struct clk *omap_findclk(struct omap_mpu_state_s *mpu, const char *name)
     for (i = mpu->clks; i->name; i ++)
         if (!strcmp(i->name, name) || (i->alias && !strcmp(i->alias, name)))
             return i;
-    cpu_abort(mpu->env, "%s: %s not found\n", __FUNCTION__, name);
+    hw_error("%s: %s not found\n", __FUNCTION__, name);
 }
 
 void omap_clk_get(struct clk *clk)
@@ -1133,8 +1116,7 @@ void omap_clk_get(struct clk *clk)
 void omap_clk_put(struct clk *clk)
 {
     if (!(clk->usecount --))
-        cpu_abort(cpu_single_env, "%s: %s is not in use\n",
-                        __FUNCTION__, clk->name);
+        hw_error("%s: %s is not in use\n", __FUNCTION__, clk->name);
 }
 
 static void omap_clk_update(struct clk *clk)