/**
* __clocksource_register_scale - Used to install new clocksources
* @cs: clocksource to be registered
* @scale: Scale factor multiplied against freq to get clocksource hz
* @freq: clocksource frequency (cycles per second) divided by scale
*
* Returns -EBUSY if registration fails, zero otherwise.
*
* This *SHOULD NOT* be called directly! Please use the
* clocksource_register_hz() or clocksource_register_khz helper functions.
*/
int __clocksource_register_scale(struct clocksource *cs, u32 scale, u32 freq)
{
/* Initialize mult/shift and max_idle_ns */
__clocksource_update_freq_scale(cs, scale, freq);
/* Add clocksource to the clocksource list */
mutex_lock(&clocksource_mutex);
clocksource_enqueue(cs);
clocksource_enqueue_watchdog(cs);
clocksource_select();
clocksource_select_watchdog(false);
mutex_unlock(&clocksource_mutex);
return 0;
}
EXPORT_SYMBOL_GPL(__clocksource_register_scale);
Linux 内核时钟架构之时钟源设备注册
原创sunlei0625 ©著作权
文章标签 sed ide 文章分类 JavaScript 前端开发
-
Linux驱动开发之杂项设备注册和Linux2.6设备注册
Linux设备驱动开发中,需要向内核正确注册设备,才能创建设备节点,以供应用层访问。本文将详细介绍Linux下的两种设备注册方法:杂项设备注册和Linux 2.6新方法注册。
Linux驱动开发 杂项设备注册 Linux2.6设备注册 例程分享 相关API -
mysql迁移达梦提示无效的表名
-- Created on 2012/8/17 by ZHOUXX declare -- Local variables here i integer; v_sql varchar2(2000); ERR1 varchar2(2000); TOM_SQLCODE varchar2(2000);
mysql迁移达梦提示无效的表名 object sql variables exception