




已阅读5页,还剩3页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
INTRODUCTION Automotive recalls which are due to software problems have increased exponentially over the last decade. Very recently Jaguar has announced the recall of 17.600 units only in the UK. The reasons have been hidden software glitches within the cruise control system 1. The problem is not only the direct costs of bringing the cars to a garage and patch the software, but the indirect costs associated to brand image damage even in cases where no accidents or injuries are involved 2, 3. In order to improve the quality of the software in a vehicle, it is not only a matter of performing more tests, but also a matter of increasing the quality of the tests. In order to increase the quality of the tests it needs to be measured whether the tests are exercising all the software functionality. That includes corner cases that are not triggered during normal operation, but which are triggered when the underlying hardware fails or the software gets corrupted. Todays safety critical systems include multiple fault tolerant mechanisms which are implemented both on hardware and software. Those mechanisms are able to detect and even 2012-01-0001 Published 04/16/2012 Copyright 2012 SAE International doi:10.4271/2012-01-0001 Virtualized Fault Injection Methods in the Context of the ISO 26262 Standard Victor Reyes Synopsys Inc. ABSTRACT Software quality is one of the biggest concerns of the automotive industry. Releasing a product with defects and having a recall can have enormous direct and indirect cost for an automotive OEM. In order to improve software quality is not sufficient to only increase the number of tests. It is extremely important to establish more sophisticated tests that can cover corner cases which are not unveiled during normal operation. Typically, corner cases are very difficult to test as those are often only triggered when the underlying hardware fails or the software gets unexpectedly corrupted. How to test those cases, to make sure that the right SW routines are executed and that the system moves back on time to a safe state? Fault- injection methods are typically used to cover a subset of these tests. However, there are quite some limitations on how effective and cost efficient existing methods can be applied for a more extensive coverage. The upcoming ISO 26262 Functional Safety standard defines fault-injection testing as a relevant method to be applied for different parts of the standard. At the system level (part 4) fault-injection testing is proposed as a highly recommended method for ASIL C/D to improve test coverage of safety measures that are not invoked during normal operation. At the hardware level (part 5) fault-injection testing is also recommended for highest ASIL whenever a hardware safety mechanism is defined to analyze its response to faults. And finally, at the software level (part 6) fault-injection testing is highly recommended for ASIL C/D where arbitrary faults corrupting software or hardware components must be injected to test the safety mechanism. However the standard does not define how the existing fault-injection techniques can be applied in order to satisfy its requirements. In this paper a simulation-based fault-injection solution based on Virtual Prototyping technology is presented. Real fault-injection scenarios are described using a Freescale dual core virtual MCU model. This work illustrates how the unmatched visibility and controllability capabilities of virtual prototypes are leveraged to build a fault-injection framework. This fault-injection framework enables the description of very complex test scenarios involving software and hardware elements. Moreover, the analysis capabilities of our solution allow tracing the software and hardware activities over time. This enables a better understanding of the correlation between fault and response and allows validating whether it is correct or not. The scripting capabilities of our framework allow fault-injection tests to be part of the overall regression testing. This removes the human interaction and reduces the effort for this type of testing dramatically. CITATION: Reyes, V., Virtualized Fault Injection Methods in the Context of the ISO 26262 Standard, SAE Int. J. Passeng. Cars - Electron. Electr. Syst. 5(1):2012, doi:10.4271/2012-01-0001. _ 9 Downloaded from SAE International by Jilin University, Monday, January 20, 2014 08:11:47 AM correct such faults. However, this comes with a huge impact on the overall development cost. For instance, diagnostic software takes today up to 40% of the total lines of code of an ECU and counts for up to 50% of the processor runtime 4. Moreover, testing the diagnostic software already counts for up to 25% of the total testing costs. Code coverage measurement and fault injection testing are two very important activities to increase the quality of the tests. However, the application of both activities during the software integration and testing phases is very limited. On the one hand, code coverage is mainly applied to on-host software unit testing only. Although useful, on-host testing at the unit test level does not exercise big parts of the embedded software running on the device. Moreover, due to the adaptations required, on-host testing is not sufficient to credibly guarantee that faulty software is not being deployed. On the other hand, conventional fault injection techniques that can be applied during software integration and test phases have multiple limitations in terms of intrusiveness, controllability and limited set of injection points that can help reaching a more extensive coverage. This will be discussed more in the next sections of the paper. The new ISO 26262 standard 5 is imposing more severe certification requirements during the design and validation of safety critical systems. When it comes to software integration and test in particular, ISO 26262 highly recommends both fault injection testing and structural coverage metrics for the highest safety integrity levels (ASIL C/D). Due to all the extra requirements, being compliant to the new standard will obviously increase the quality of the final results, but it will also increase significantly the development and testing costs of bringing a new product to the market. This paper discusses how to specifically apply virtual prototyping technology to enhance fault injection testing during software integration and test phases. Virtual prototype based fault injection overcomes important limitations of existing fault injection methods, such as intrusiveness, controllability and access to injection points for both permanent and transient faults. The rest of the article is structured as follows. As part of the introduction a high level overview of the ISO 26262 standard with specific focus on its fault injection requirements is presented. After that, conventional fault injection techniques are analyzed with respect to their advantages and limitations. In the following section our proposed virtual prototype based fault injection framework is introduced in more detail. Then, we describe two fault injection scenarios and how they can be reproduced using our virtual prototype based framework. Finally, we close the paper with our conclusions. ISO 26262 FUNCTIONAL SAFETY STANDARD ISO 26262 is a functional safety standard that replaces the older and more generic IEC 61508 for passenger vehicles. ISO 26262 addresses hazards caused by malfunctioning behavior of electric and electronic safety related systems. The standard provides: An automotive specific safety lifecycle - The safety lifecycle is composed of three phases: concept phase, product development phase and after start of production phase. An automotive specific risk-based approach based on Automotive Safety Integrity Levels (or ASIL) - Three aspects define the ranking of an item onto a specific Automotive Safety Integrity Level. Severity, which varies from light injuries to fatal injuries in case of failure of the item under investigation. Exposure, which indicates the probability that the item fails. And controllability, which indicates how difficult is to control the effects of the hazard by the driver. ASIL D requires the highest safety integrity level for the item and ASIL A the lowest. Requirements and recommended methods for the validation of the safety levels - The standard breaks down the requirements to verify and validate the item under- consideration on different sub-parts (system-level, hardware, software). For each of these sub-parts a set of verification methods are described on the standard, with specific weights for the different ASIL levels: no recommendation, recommended and highly recommended. For example, section 4.7 (system design) highly recommends simulation as a method to verify the system for ASIL C and D compliancy. On the other side of the V curve, section 4.8 (item integration and test) highly recommends fault injection testing for ASIL C and D compliancy. In general ISO 26262 highly recommends simulation and prototyping methods for system, hardware and software design and verification, especially as a fault-injection technique. Fault-injection is more specifically mentioned for system, HW and SW integration and test activities. Fault- injection can be applied successfully to improve the test coverage of safety mechanisms at the system level, covering corner cases difficult to trigger during normal operation. It can also be applied whenever a hardware safety mechanism is defined to analyze its response to faults, or where arbitrary faults corrupting software or hardware components must be injected to test the safety mechanisms. CONVENTIONAL FAULT INJECTION OVERVIEW Fault injection helps to determine whether the response of a system matches its specification, in presence of faults. It helps understanding the effects of faults on the target system behavior, as well as assessing how efficient the existing fault tolerance mechanisms are 6. Faults can be categorized in two big buckets: hardware faults and software faults. Hardware faults can be categorized by their duration as: permanent faults (triggered by component damage), transient faults (triggered by Reyes / SAE Int. J. Passeng. Cars - Electron. Electr. Syst. / Volume 5, Issue 1(May 2012)10 Downloaded from SAE International by Jilin University, Monday, January 20, 2014 08:11:47 AM environmental conditions, also known as soft-errors), and intermittent faults (triggered by unstable hardware). Software faults are always the consequence of an incorrect design, at the specification or at the coding time. Software faults are latent in the code and show up only during operation. Despite their permanent nature, their behaviors are transient. Conventional fault injection methods are hardware based fault injection, software based fault injection and simulation based fault injection 7. Hardware based fault injection is performed at the physical level by typically modifying the value of the pins of the Electronic Control Unit (ECU) (a.k.a. with contact) or by disturbing the hardware with electromagnetic interference or heavy ion radiation (a.k.a. without contact). Software based fault injection aims to reproduce at the software level the errors introduced by hardware faults without physically modifying the hardware. Finally, simulation based fault injection uses an implementation model at gate or RTL level to perform the experiments. Later in the paper the benefits and limitations of every method will be described in more detail. A basic fault injection framework, as described in 8, is composed of the following parts (see Figure 1): Target system, Fault injector (that injects faults from a library), Workload generator (to create stimuli according to the test scenarios), Monitor that feed information back from the target system Data collector and analyzer. Everything orchestrated by a controller. Figure 1. Conventional fault injection framework FAULT INJECTION WITH VIRTUAL PROTOTYPES General information about virtual prototype technology can be found in 12, 13. In the context of this paper we will describe virtual prototypes being used as a framework to perform fault injection tests, see Figure 2. This virtual prototype based framework is composed of two main parts: the model of the target system and the tooling around it. Obviously the model of the target system varies depending on the ECU/MCU hardware to be used, whereas the rest of the tool framework remains the same. Virtual prototype target - A VP of the target system is a software simulation that emulates the digital hardware. In our cases it is created using the standard SystemC programming language 10 at the transactional modeling level 11. This virtual prototype target is functionality equivalent to the actual hardware and allows running the same binary software that runs on the actual hardware. It also exposes the same external interfaces which allow connecting plant models and environment models to it. A virtual prototype provides also hooks to the tooling for inspection and modification of the internal values, something that it is not possible to do with real hardware. Figure 2. Virtual prototype based fault injection framework Fault injection API - A key link of the fault injection framework to the virtual prototype target, is the generic control and inspection interface exposed by the VP. This interface allows inspecting and modifying internal and boundary values of the target system (e.g. component registers, memory content, signals, etc). This interface is also used to control the simulation execution. Based on this generic interface a higher level fault injection API is defined to inject the faults. This API has two fundamental commands: trigger and inject. The trigger command invokes an injector routine when a trigger event happens. Trigger events can be software events (for example, entering a specific software routine), hardware events (for example, when an interrupt lines goes active), time events (for example, after 1 second of simulation time) or any combination of then. Triggers can be concatenated and enable other triggers dynamically based on system status. This increases the precision on when a fault can be injected. The inject command sets the element specified to a certain value. Supported elements are IO pins, registers, internal signals and memory locations. The value can be set just once (transient) or can be forced permanently. Reyes / SAE Int. J. Passeng. Cars - Electron. Electr. Syst. / Volume 5, Issue 1(May 2012)11 Downloaded from SAE International by Jilin University, Monday, January 20, 2014 08:11:47 AM Besides these two commands, model dependent commands can be added for specific purposes. For instance, a memory can implement a specific command to flag an ECC error after a read/write access. Figure 3. Fault injection API Workload generation - For workload generation the fault injection framework can also use the virtual prototypes control and inspection interface to introduce stimuli on the target system. When more complex workload generation is required the framework can integrate external plant models or “rest bus” simulation and connect them to the virtual prototype based target system. Monitoring and analysis - The virtual prototype based framework provides built-in monitoring, tracing and analysis views to all hardware and software elements on the virtual target system. This is partially achieved by instrumenting the individual components that are part of the virtual target system. Analysis examples will be shown in the examples section. Controller - The controller allows the user to drive the scenario through the tool GUI and console in an interactive manner. Alternatively, complete scenarios can be described using the scripting interface and re-played automatically during regressions. COMPARISON OF FAULT INJECTION METHODS Table 1 compares the conventional fault-injection methods with our solution according to the following criteria: Fault injection points define what type of faults can be triggered with the technique, Whether the technique is able or not to model permanent faults Intrusiveness, or how the injection of the fault changes the original execution flow of the system Observability defines how well the set of reactions (or events) triggered by the fault can be seen and recorded Controllability defines the precision in terms of exact time and location where the fault can be injected Repeatability, or the ability to repeat the experiment in a deterministic fashion and finally the experiment speed, which will define to same extent the complexity and duration of the test scenarios Hardware based fault injection with contact is used to inject errors on the IO boundary of the ECU, whereas without contact is used to trigger soft errors, for instance, memory corruption due to radiation or electromagnetic interference. Techniques with contact are able to model permanent faults and they are not intrusive, although there is a risk of damage if misused. Techniques without contact are more focused on transient errors and they are also not intrusive (with less risk of damage if any). Software based fault injection techniques have the limitations that can only inject errors on those locations accessible by the SW, that is memory and memory-mapped peripherals registers. Therefore, there are only able to model transient faults. The biggest problem with SW based fault injection techniques is their intrusiveness. They modified the SW binary with the code to inject the errors, which could lead to differences on behavior compared to the production SW running on the field. For these two techniques the fact that the experiments are performed on real HW limits the capabilities to observe all the intermediate effects triggered by a fault. Experiments are
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2025年法律职业资格考试试题及答案
- 2025武威中考数学试卷
- 正常血糖标准一览表
- 2025年营口货运从业资格证好考吗
- 2025年西藏危运驾驶员考试题
- 机械工程自动化技术应用测试题
- 春天的小使者描写春天气息的日记作文14篇
- 2025年南宁危险品道路运输从业资格证模拟考试题库
- 中学生饮食健康
- 零售超市行业试卷
- 体检中心投诉处理流程
- 2025山西焦煤集团公司招聘高频重点模拟试卷提升(共500题附带答案详解)
- 2025年中国东方航空股份有限公司招聘笔试参考题库含答案解析
- 畜牧饲养行业安全生产培训
- 《水龙头知识培训》课件
- (八省联考)河南省2025年高考综合改革适应性演练 化学试卷合集(含答案逐题解析)
- 用户体验量化评估-洞察分析
- 农场租赁合同范本:养殖场租赁
- 材料科学基础知到智慧树章节测试课后答案2024年秋西南科技大学
- 道路交通安全上下班安全培训教育课件
- 2024年司法考试完整真题及答案
评论
0/150
提交评论