cost 341 ms
设备树如何提供“数据”字段(对于平台设备案例)?

[英]How is the 'data' field provided by the device tree (for platform devce case)?

我不明白设备树信息是如何在特定的驱动程序中使用的。 这是来自 linux-6.15.68 drivers/pci/controller/dwc/pcie-designware-plat.c 的代码片段。 因此,kernel 在为平台设备运行此探测器 function 时解析设备树(连接到 stru ...

Linux Kernel - Linux 文件标志如何工作?

[英]Linux Kernel - How do Linux file flags work?

我目前正在为一个项目开发自定义 kernel,我需要做的一件事是创建一个新的自定义文件标志,类似于这个问题: Passing custom flags to "open" in a device driver 我已经能够创建它们,并毫无问题地编译 kernel,但是,我真的不明白这些标志在实践中是 ...

在 Kernel 模块中存储每个进程的数据/在 sys_enter 和 sys_exit 探针之间传递数据

[英]Storing Per-Process Data in Kernel Module / Passing Data Between sys_enter and sys_exit Probe

赏金将在 6 天后到期。 此问题的答案有资格获得+100声望赏金。 anroesti想让更多人关注这个问题。 不一定需要熟悉Linux Kernel Tracepoints 的工作原理来帮助解决这个问题,这正是引发这个问题的原因。 本质上,我正在寻找一种方法来存储 kernel 模块的每个进程数 ...

尽管已经为 C++ 构建了独立库,但仍无法找到 uint8_t

[英]Unable to find uint8_t despite having build the freestanding libs for C++

编辑:这与此错误报告有关吗? 尽管已经为 C++ 构建了独立库,但仍无法找到 uint8_t 我得到的错误是: 这似乎是一个简单的修复,只需添加#include <cstdint> ,但我的文件看起来像: 这是加重。 我知道我有库本身,因为我在我的工具链中看到它: 我的工具链文件Too ...

Pktgen 编译失败 - 错误:包含 '<ctype.h> ' 或提供 'isspace' / 'isblank' 的声明</ctype.h>

[英]Pktgen fails to compile - Error: include ‘<ctype.h>’ or provide a declaration of ‘isspace’ / ’isblank’

我正在尝试编译 pktgen,但在尝试编译时不断出现此错误: 我正在运行的 DPDK 版本是dpdk-stable-22.11.1并且我正在遵循官方指南Getting Started with Pktgen并且在cd进入 pktgen 存储库并运行make后我收到错误消息。 在此之前,我在dpdk ...

使用 Open API Definition 通过 Ubuntu 命令行从 OWASP ZAP 运行主动扫描

[英]Run a active scan from OWASP ZAP through Ubuntu command line using Open API Definition

我正在尝试通过导入外部开放 API 定义,仅使用我的 Ubuntu(22.04) 终端从 OWASP ZAP 运行主动扫描。 这可以通过 GUI 轻松完成,但我需要仅使用命令行来完成相同的过程。 我也没有找到合适的文档来遵循。 我已尝试按照命令结构进行主动扫描,但似乎失败了。 谁能建议一种通过 Ub ...

为 linux 构建自定义驱动程序

[英]Build custom driver for linux

我是构建 C lib 的新手,主要使用 python。我的目标是从https://github.com/torvalds/linux获取源代码,并为 USB/IP (https://github. com/torvalds/linux/tree/master/drivers/usb/usbip ) ...

linux 源代码中定义的函数“pci_bus_write_config_dword”在哪里? (linux-5.15.68)

[英]Where is the funcion 'pci_bus_write_config_dword' defined in linux source code? (linux-5.15.68)

在 linux-5.15.68 源代码树中,我试图搜索 function 'pci_write_config_dword' 的定义,这是在调用 'pci_bus_write_config_dword'。 因此,使用 grep,我搜索了“pci_bus_write_config_dword”的定义, ...

如何以编程方式获取 ipset 超时?

[英]How to get ipset timeout programmatically?

我试图以编程方式获取 ipset 的超时值(不使用用户空间ipset工具)。 以下示例尝试从使用此命令创建的名为“my_set”的集合中获取超时: ipset create my_set hash:ip timeout 86400 这是示例代码,我尝试了几种不同的方法来访问超时数据字段: 编译: ...

有没有办法理解 Linux 系统不会提供任何 TX 时间戳?

[英]Is there a way to understand that Linux system will not provide any TX timestamp?

我正在练习 Linux 时间戳功能(TX 部分): https://docs.kernel.org.networking/timestamping.html 似乎没有简单的方法可以理解系统永远不会在运行时为我提供 TX 时间戳。 这意味着我可以通过setsockopt启用 TX 时间戳而不会出错: ...

DTS 文件中的 STM32MP1 linux IRQ 和 EXTI controller 配置

[英]STM32MP1 linux IRQs & EXTI controller config in DTS file

我在 STM32MP157 开发板上运行 buildroot linux 环境。 我在引脚 B12 上有一个带有内部上拉电阻的按钮。 一旦线路变低,我想触发一个中断。 在 RPi 等其他 linux 板上,我已经能够调用 gpio_to_irq(&lt;gpio#&gt;) 并获取该引脚的 IRQ。 ...

以下两种eBPF程序类型BPF_PROG_TYPE_SYSCALL和BPF_PROG_TYPE_KPROBE有什么区别?

[英]What is the difference between the following two eBPF program types BPF_PROG_TYPE_SYSCALL and BPF_PROG_TYPE_KPROBE?

所以我假设只要在 kernel 中执行特定的系统调用,就会触发BPF_PROG_TYPE_SYSCALL程序BPF_PROG_TYPE_KPROBE ebpf 程序不能用于该目的吗? kprobes 可以挂接到任何 kernel function 和系统调用也是 kernel 函数。 那么这两种 ...

在 Linux 系统调用 getdents64 中编写的 linux_dirent64 结构中,为什么 d_off 不是所有早期条目的 d_reclens 的总和?

[英]In the linux_dirent64 structs written in the Linux syscall getdents64, why is d_off not the sum of the d_reclens of all earlier entries?

根据getdents 的手册页: d_off是从目录开始到下一个linux_dirent开始的距离。 d_reclen是整个linux_dirent的大小。 所以我希望如果第一个条目有d_reclen n ,它的d_off也将是n (对于第i个条目, d_off将是从0到i的所有条目的d_re ...

为什么忽略 SIGCONT 仍会使进程继续?

[英]Why does ignoring SIGCONT still make a process continue?

这是我的代码,忽略了SIGCONT :int main() { signal(SIGCONT, SIG_IGN); while(1); } 这是发生了什么: 看来SIGCONT还是让我的进程继续了。 这是否意味着SIGCONT的处理程序只是一个“副作用”? 我想知道什么时候SIG ...


 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM