Recommending Interface Patches for Forward Porting of Linux Device Drivers Based on Existing Instances
-
摘要: Linux内核版本频繁升级对驱动程序带来的关联影响程度和影响范围都很大,为了修复这种关联影响带来的驱动程序调用内核接口的不一致性错误,不断修改旧版本驱动代码进行前向移植是一个持续和紧迫的问题.驱动演化辅助理解、驱动移植中间库辅助适配和驱动移植辅助信息等方面的已有研究,通过检索语句级别的辅助信息提高了驱动移植的效率.但是已有方法仅关注了检索辅助信息本身却并没有区分其中包含的有效补丁素材,因此还需要人工分析和手工构造适配性补丁.为了克服上述限制,提出了一种全新的方法旨在推荐驱动前向移植中接口错误的高质量补丁.观察发现,依赖相同内核接口服务的多个不同驱动程序之间存在相同或相似的内核接口调用,内核版本升级后其他驱动的历史开发信息中可能存在这种复用接口及其使用变更的已有实例代码.利用出错接口语句和相似已有实例的共性分析错误问题的特点,通过已有实例的辅助作用抽取针对性的接口修改方式和修改内容等细粒度素材生成待推荐补丁.具体结合分界点识别、相似度计算、细粒度差异比较和频度计算确定有效修改方式.提出了一种基于已有实例差异特征的分类算法,通过区分修改内容的不同类型分别从2种数据源提取.最后使用编辑脚本技术生成推荐补丁列表.在9个不同类型的真实驱动程序上的实验表明,该方法能够推荐驱动移植中7类接口错误补丁,有效补丁占比约67.4%,对现有辅助方法形成了有效补充和拓展.Abstract: The extent and scope of associated impact of Linux kernel version upgraded frequently on the drivers are very large. In order to repair the inconsistency error of the driver calling the kernel interface caused by this related impact, constantly modifying the old version drivers’ codes for forward porting is a continuing and urgent problem. There are existing researches on assistant understanding of driven evolution, assistant adaptation of driver porting middle lib and assistant information of driver porting. The efficiency of driver porting is improved by retrieving assistant information at the statement level. However, the existing methods only focus on retrieving assistant information itself without distinguishing the effective patch materials. Therefore, manual analysis and manual construction of adaptable patches are required. To overcome the above limitations, in this paper we propose a new method to recommend high quality patches for interface errors in drivers forward porting. We observe that: there are the same or similar kernel interfaces’ calls between multiple different drivers that rely on the same kernel interface services, and there may be existing instance codes in the development history of other drivers, which share the same interfaces reuse and interfaces changes after kernel version is upgraded. This paper uses the commonality of the error interface statements and similar existing instances in historical development information to analyze the characteristics of the error problem, and extracts targeted interface modification modes and contents of fine-grained materials to generate patches to be recommended. Specifically, the effective modification modes are determined by combining boundary point identification, similarity calculation, fine-grained difference comparison and frequency calculation. A classification algorithm based on the different characteristics of existing instances is proposed for the first time, by distinguishing the different types of modification contents, then content materials from two data sources are extracted respectively. Finally we use the editing script technology to generate the recommended patches using above materials. Experiment on 9 different types of real drivers shows that this method can recommend for 7 types of interface errors patches in driver porting, and the effective patches account for about 67.4%. Partly, it effectively supplements and expands existing assistant methods for driver porting.
-
Keywords:
- driver porting /
- existing instances /
- interface reuse /
- modification modes /
- patches recommend /
- interface error
-
-
期刊类型引用(27)
1. 顾敏,徐雅男,王辛迪,花敏,周雯. 多用户MIMO-MEC网络中基于APSO的任务卸载研究. 无线电工程. 2024(03): 711-718 . 百度学术
2. 王斐然,郭昕阳,张峰. 基于边缘计算的输电线路巡检设备协同调配研究. 自动化仪表. 2024(05): 123-126 . 百度学术
3. 史晓蒙,吕晓鹏,魏健康,王凌. 基于算法组合的端边云任务处理方法. 价值工程. 2024(36): 108-112 . 百度学术
4. 向朝参,程文辉,张昭,焦贤龙,屈毓锛,陈超,戴海鹏. 基于边缘智能计算的城市交通感知数据自适应恢复. 计算机研究与发展. 2023(03): 619-634 . 本站查看
5. 邵梁,何星舟,尚俊娜. 边缘计算中利用改进型遗传算法的任务卸载策略. 计算机应用与软件. 2023(11): 48-57 . 百度学术
6. 高仕斌,刘帝洋,韦晓广,康高强,罗嘉明,雷杰宇. 基于数字孪生网络的牵引供电智能运维体系与应用架构. 铁道学报. 2023(12): 1-15 . 百度学术
7. 张彦虎,鄢丽娟,马志愤,张彦军. 一种适用于多任务多资源移动边缘计算环境下的改进粒子群算力卸载算法. 计算机与现代化. 2022(05): 54-60+67 . 百度学术
8. 刘春林,秦进. 面向5G网络的移动边缘计算节点部署算法设计. 计算机仿真. 2022(12): 436-439+473 . 百度学术
9. 张开强,蒋从锋,程小兰,贾刚勇,张纪林,万健. 多分辨率下资源感知的图像目标自适应缩放检测. 计算机科学. 2021(04): 180-186 . 百度学术
10. 乐光学,陈光鲁,卢敏,杨晓慧,刘建华,黄淳岚,杨忠明. 一种基于K-shell影响力最大化的路径择优计算迁移算法. 计算机研究与发展. 2021(09): 2025-2039 . 本站查看
11. 苏命峰,王国军,李仁发. 边云协同计算中基于预测的资源部署与任务调度优化. 计算机研究与发展. 2021(11): 2558-2570 . 本站查看
12. 贾觐,暴占彪. 改进GA的边缘计算任务卸载与资源分配策略. 计算机工程与设计. 2021(11): 3009-3017 . 百度学术
13. 汪小威,林宁,胡玉平. 移动边缘计算中利用BPSO的任务卸载策略. 计算机工程与设计. 2021(12): 3333-3341 . 百度学术
14. 尹高,石远明. 移动边缘网络中深度学习任务卸载方案. 重庆邮电大学学报(自然科学版). 2020(01): 38-46 . 百度学术
15. 丁雪乾,薛建彬. 边缘计算下基于Lyapunov优化的系统资源分配策略. 微电子学与计算机. 2020(02): 63-68 . 百度学术
16. 白昱阳,黄彦浩,陈思远,张俊,李柏青,王飞跃. 云边智能:电力系统运行控制的边缘计算方法及其应用现状与展望. 自动化学报. 2020(03): 397-410 . 百度学术
17. 乐光学,戴亚盛,杨晓慧,刘建华,游真旭,朱友康. 边缘计算可信协同服务策略建模. 计算机研究与发展. 2020(05): 1080-1102 . 本站查看
18. 盛津芳,滕潇雨,李伟民,王斌. 移动边缘计算中基于改进拍卖模型的计算卸载策略. 计算机应用研究. 2020(06): 1688-1692 . 百度学术
19. 胡锦天,王高才,徐晓桐. 移动边缘计算中具有能耗优化的任务迁移策略. 计算机科学. 2020(06): 260-265 . 百度学术
20. 周振宇,陈亚鹏,潘超,赵雄文,张磊,汪中原. 面向智能电力巡检的高可靠低时延移动边缘计算技术. 高电压技术. 2020(06): 1895-1902 . 百度学术
21. 吕洁娜,张家波,张祖凡,甘臣权. 移动边缘计算卸载策略综述. 小型微型计算机系统. 2020(09): 1866-1877 . 百度学术
22. 张伟. 边缘计算的任务迁移机制研究. 软件导刊. 2020(09): 48-53 . 百度学术
23. 路亚. MEC多服务器启发式联合任务卸载和资源分配策略. 计算机应用与软件. 2020(10): 77-84 . 百度学术
24. 方加娟,李凯. 基于边缘云和移动辅助设备的计算卸载优化方案. 计算机应用与软件. 2020(12): 6-12 . 百度学术
25. 危泽华,曾玲玲. 基于Stackelberg博弈论的边缘计算卸载决策方法. 数学的实践与认识. 2019(11): 91-100 . 百度学术
26. 居晓琴. 移动边缘计算的QoE视频缓存方法. 电脑与信息技术. 2019(05): 44-47 . 百度学术
27. 乐光学,戴亚盛,杨晓慧,朱友康,游真旭,刘建生. 边缘计算多约束可信协同任务迁移策略. 电信科学. 2019(11): 36-50 . 百度学术
其他类型引用(65)
计量
- 文章访问数: 568
- HTML全文浏览量: 1
- PDF下载量: 365
- 被引次数: 92