Skip to main navigation Skip to search Skip to main content

Detecting Data Races Caused by Inconsistent Lock Protection in Device Drivers

  • Qiu Liang Chen
  • , Jia Ju Bai*
  • , Zu Ming Jiang
  • , Julia Lawall
  • , Shi Min Hu
  • *Corresponding author for this work
  • Tsinghua University
  • Sorbonne Université

Research output: Chapter in Book/Report/Conference proceedingConference contributionpeer-review

Abstract

Data races are often hard to detect in device drivers, due to the non-determinism of concurrent execution. According to our study of Linux driver patches that fix data races, more than 38% of patches involve a pattern that we call inconsistent lock protection. Specifically, if a variable is accessed within two concurrently executed functions, the sets of locks held around each access are disjoint, at least one of the locksets is non-empty, and at least one of the involved accesses is a write, then a data race may occur.In this paper, we present a runtime analysis approach, named DILP, to detect data races caused by inconsistent lock protection in device drivers. By monitoring driver execution, DILP collects the information about runtime variable accesses and executed functions. Then after driver execution, DILP analyzes the collected information to detect and report data races caused by inconsistent lock protection. We evaluate DILP on 12 device drivers in Linux 4.16.9, and find 25 real data races.

Original languageEnglish
Title of host publicationSANER 2019 - Proceedings of the 2019 IEEE 26th International Conference on Software Analysis, Evolution, and Reengineering
EditorsEmad Shihab, David Lo, Xinyu Wang
PublisherInstitute of Electrical and Electronics Engineers Inc.
Pages366-376
Number of pages11
ISBN (Electronic)9781728105918
DOIs
StatePublished - 15 Mar 2019
Externally publishedYes
Event26th IEEE International Conference on Software Analysis, Evolution, and Reengineering, SANER 2019 - Hangzhou, China
Duration: 24 Feb 201927 Feb 2019

Publication series

NameSANER 2019 - Proceedings of the 2019 IEEE 26th International Conference on Software Analysis, Evolution, and Reengineering

Conference

Conference26th IEEE International Conference on Software Analysis, Evolution, and Reengineering, SANER 2019
Country/TerritoryChina
CityHangzhou
Period24/02/1927/02/19

Keywords

  • Data race
  • device driver
  • inconsistent lock protection
  • runtime analysis

Fingerprint

Dive into the research topics of 'Detecting Data Races Caused by Inconsistent Lock Protection in Device Drivers'. Together they form a unique fingerprint.

Cite this