opp: Don't decrement uninitialized list_kref
[linux-2.6-block.git] / drivers / opp / core.c
index 0ee8c0133d3e5183175c8ec95ae33055bfad485b..9ff0538ee83a015d68af4425547a9998656d28eb 100644 (file)
@@ -988,6 +988,7 @@ static struct opp_table *_allocate_opp_table(struct device *dev, int index)
        BLOCKING_INIT_NOTIFIER_HEAD(&opp_table->head);
        INIT_LIST_HEAD(&opp_table->opp_list);
        kref_init(&opp_table->kref);
+       kref_init(&opp_table->list_kref);
 
        /* Secure the device table modification */
        list_add(&opp_table->node, &opp_tables);