From 9da978cc1d7f4c31cf0d01134e392a5b86c0ecc4 Mon Sep 17 00:00:00 2001 From: LinuxDev9002 Date: Tue, 14 Jul 2026 04:00:28 -0700 Subject: [PATCH] docs: link hardirqs example headers --- src/10-hardirqs/README.md | 2 ++ src/10-hardirqs/README.zh.md | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/10-hardirqs/README.md b/src/10-hardirqs/README.md index c7fef37..650ab4a 100644 --- a/src/10-hardirqs/README.md +++ b/src/10-hardirqs/README.md @@ -35,6 +35,8 @@ By following the above approach, we can use hardirqs and softirqs in eBPF to cap The main purpose of the hardirqs program is to obtain the name, execution count, and execution time of interrupt handlers and display the distribution of execution time in the form of a histogram. Let's analyze this code step by step. +The custom headers used below are part of the complete example rather than system headers. Build from the `src/10-hardirqs` directory, which contains [`hardirqs.h`](https://github.com/eunomia-bpf/bpf-developer-tutorial/blob/main/src/10-hardirqs/hardirqs.h), [`bits.bpf.h`](https://github.com/eunomia-bpf/bpf-developer-tutorial/blob/main/src/10-hardirqs/bits.bpf.h), and [`maps.bpf.h`](https://github.com/eunomia-bpf/bpf-developer-tutorial/blob/main/src/10-hardirqs/maps.bpf.h) alongside the source file. + ```c // SPDX-License-Identifier: GPL-2.0 // Copyright (c) 2020 Wenbo Zhang diff --git a/src/10-hardirqs/README.zh.md b/src/10-hardirqs/README.zh.md index 574b6ed..9821ebb 100644 --- a/src/10-hardirqs/README.zh.md +++ b/src/10-hardirqs/README.zh.md @@ -26,6 +26,8 @@ softirqs 是软件中断处理程序。它们是内核中的一种底层异步 hardirqs 程序的主要目的是获取中断处理程序的名称、执行次数和执行时间,并以直方图的形式展示执行时间的分布。让我们一步步分析这段代码。 +下面引用的自定义头文件属于完整示例,并不是系统头文件。请在 `src/10-hardirqs` 目录中编译,该目录在源码旁提供了 [`hardirqs.h`](https://github.com/eunomia-bpf/bpf-developer-tutorial/blob/main/src/10-hardirqs/hardirqs.h)、[`bits.bpf.h`](https://github.com/eunomia-bpf/bpf-developer-tutorial/blob/main/src/10-hardirqs/bits.bpf.h) 和 [`maps.bpf.h`](https://github.com/eunomia-bpf/bpf-developer-tutorial/blob/main/src/10-hardirqs/maps.bpf.h)。 + ```c // SPDX-License-Identifier: GPL-2.0 // Copyright (c) 2020 Wenbo Zhang