I'm working on a block device driver kernel module. Most tutorials use the genhd.h
header file, but when I checked my kernel code (version Linux 5.19.8), I couldn't find that header file. How should I proceed? Where has the content of that header file been moved in the newer versions? Or how can I implement the block device driver kernel module without using that header file?
I'm working on a block device driver kernel module. Most tutorials use the genhd.h
header file, but when I checked my kernel code (version Linux 5.19.8), I couldn't find that header file. How should I proceed? Where has the content of that header file been moved in the newer versions? Or how can I implement the block device driver kernel module without using that header file?
1 Answer
Reset to default 0Apparently genhd.h
has been removed; see https://lore.kernel./all/[email protected]/t/
Commit message says:
This patchset removes the
<linux/genhd.h>
header, which has no clearly split responsibilities from<linux/blkdev.h>
and is included by the latter
From that I would infer that the workaround is to #include blkdev.h
instead. (Or drop the genhd.h
#include entirely if it was redundant.)
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1742382901a4433474.html
评论列表(0条)