include/linux/usb/xhci-sideband.h
Source file repositories/reference/linux-study-clean/include/linux/usb/xhci-sideband.h
File Facts
- System
- Linux kernel
- Corpus path
include/linux/usb/xhci-sideband.h- Extension
.h- Size
- 3394 bytes
- Lines
- 112
- 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.
- Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/scatterlist.hlinux/usb.hlinux/usb/hcd.h
Detected Declarations
struct xhci_sidebandstruct xhci_sideband_eventstruct xhci_sidebandenum xhci_sideband_typeenum xhci_sideband_notify_typefunction xhci_sideband_checkfunction xhci_sideband_notify_ep_ring_free
Annotated Snippet
struct xhci_sideband_event {
enum xhci_sideband_notify_type type;
void *evt_data;
};
/**
* struct xhci_sideband - representation of a sideband accessed usb device.
* @xhci: The xhci host controller the usb device is connected to
* @vdev: the usb device accessed via sideband
* @eps: array of endpoints controlled via sideband
* @ir: event handling and buffer for sideband accessed device
* @type: xHCI sideband type
* @mutex: mutex for sideband operations
* @intf: USB sideband client interface
* @notify_client: callback for xHCI sideband sequences
*
* FIXME usb device accessed via sideband Keeping track of sideband accessed usb devices.
*/
struct xhci_sideband {
struct xhci_hcd *xhci;
struct xhci_virt_device *vdev;
struct xhci_virt_ep *eps[EP_CTX_PER_DEV];
struct xhci_interrupter *ir;
enum xhci_sideband_type type;
/* Synchronizing xHCI sideband operations with client drivers operations */
struct mutex mutex;
struct usb_interface *intf;
int (*notify_client)(struct usb_interface *intf,
struct xhci_sideband_event *evt);
};
struct xhci_sideband *
xhci_sideband_register(struct usb_interface *intf, enum xhci_sideband_type type,
int (*notify_client)(struct usb_interface *intf,
struct xhci_sideband_event *evt));
void
xhci_sideband_unregister(struct xhci_sideband *sb);
int
xhci_sideband_add_endpoint(struct xhci_sideband *sb,
struct usb_host_endpoint *host_ep);
int
xhci_sideband_remove_endpoint(struct xhci_sideband *sb,
struct usb_host_endpoint *host_ep);
int
xhci_sideband_stop_endpoint(struct xhci_sideband *sb,
struct usb_host_endpoint *host_ep);
struct sg_table *
xhci_sideband_get_endpoint_buffer(struct xhci_sideband *sb,
struct usb_host_endpoint *host_ep);
struct sg_table *
xhci_sideband_get_event_buffer(struct xhci_sideband *sb);
#if IS_ENABLED(CONFIG_USB_XHCI_SIDEBAND)
bool xhci_sideband_check(struct usb_hcd *hcd);
#else
static inline bool xhci_sideband_check(struct usb_hcd *hcd)
{ return false; }
#endif /* IS_ENABLED(CONFIG_USB_XHCI_SIDEBAND) */
int
xhci_sideband_create_interrupter(struct xhci_sideband *sb, int num_seg,
bool ip_autoclear, u32 imod_interval, int intr_num);
void
xhci_sideband_remove_interrupter(struct xhci_sideband *sb);
int
xhci_sideband_interrupter_id(struct xhci_sideband *sb);
#if IS_ENABLED(CONFIG_USB_XHCI_SIDEBAND)
void xhci_sideband_notify_ep_ring_free(struct xhci_sideband *sb,
unsigned int ep_index);
#else
static inline void xhci_sideband_notify_ep_ring_free(struct xhci_sideband *sb,
unsigned int ep_index)
{ }
#endif /* IS_ENABLED(CONFIG_USB_XHCI_SIDEBAND) */
#endif /* __LINUX_XHCI_SIDEBAND_H */
Annotation
- Immediate include surface: `linux/scatterlist.h`, `linux/usb.h`, `linux/usb/hcd.h`.
- Detected declarations: `struct xhci_sideband`, `struct xhci_sideband_event`, `struct xhci_sideband`, `enum xhci_sideband_type`, `enum xhci_sideband_notify_type`, `function xhci_sideband_check`, `function xhci_sideband_notify_ep_ring_free`.
- Atlas domain: Core OS / Core Kernel Interface.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.