include/linux/bsg.h

Source file repositories/reference/linux-study-clean/include/linux/bsg.h

File Facts

System
Linux kernel
Corpus path
include/linux/bsg.h
Extension
.h
Size
696 bytes
Lines
24
Domain
Core OS
Bucket
Core Kernel Interface
Inferred role
Core OS: implementation source
Status
source implementation candidate

Why This File Exists

Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.

Dependency Surface

Detected Declarations

Annotated Snippet

#ifndef _LINUX_BSG_H
#define _LINUX_BSG_H

#include <uapi/linux/bsg.h>

struct bsg_device;
struct device;
struct request_queue;
struct io_uring_cmd;

typedef int (bsg_sg_io_fn)(struct request_queue *, struct sg_io_v4 *hdr,
		bool open_for_write, unsigned int timeout);

typedef int (bsg_uring_cmd_fn)(struct request_queue *q, struct io_uring_cmd *ioucmd,
			       unsigned int issue_flags, bool open_for_write);

struct bsg_device *bsg_register_queue(struct request_queue *q,
		struct device *parent, const char *name,
		bsg_sg_io_fn *sg_io_fn, bsg_uring_cmd_fn *uring_cmd_fn);
void bsg_unregister_queue(struct bsg_device *bcd);

#endif /* _LINUX_BSG_H */

Annotation

Implementation Notes