/* * sunxi-clk-prepare.c clk prepare Interlace driver * * Copyright (C) 2014-2016 allwinner. * Ming Li * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. */ #include #include #include #include #include #include "sunxi-clk-prepare.h" static u32 debug_mask = 0x0; /** * sunxi_clk_enable_prepare - prapare something before enable clk * Input: * clk: clk point * return value: 0 : success * -EIO : i/o err. */ int sunxi_clk_enable_prepare(struct clk *clk) { unsigned int i = 0; unsigned int mask_bit = 0; struct clk *clk_handle = NULL; if(NULL == clk) { printk(KERN_ERR "%s: clk is NULL!\n", __func__); return -1; } for (i=0; iname)) { mask_bit = clk_bitmap_name_mapping[i].mask_bit; break; } } } if (0 == mask_bit) { printk(KERN_ERR "%s: donot find related module\n", __func__); return 0; } for (i=0; iname, clk_bitmap_name_mapping[i].id_name)) { mask_bit = clk_bitmap_name_mapping[i].mask_bit; break; } } } if (0 == mask_bit) { printk(KERN_ERR "%s: donot find related module\n", __func__); return 0; } for (i=0; i"); MODULE_LICENSE("GPL");