STRUCT SSH_REQUEST_OPS(9)
π struct ssh_request_ops π
okay so this is a page from the Kernel API Manual, bestie, and we're doing struct ssh_request_ops(9) β the callback operations for a SSH request. it's giving "small struct, big main-character energy," and yes, every callback here matters. obsessed. π«Ά
π NAME π
struct ssh_request_ops β callback operations for a SSH request. that's it, that's the name section, and she ate. periodt. β¨
β¨ SYNOPSIS β¨
here's the struct in all her glory β keep the formatting exactly, no cap:
struct ssh_request_ops {
void (*release)(struct ssh_request *rqst);
void (*complete)(struct ssh_request *rqst, const struct ssh_command
*cmd, const struct ssam_span *data, int status);
};
π«Ά Members π«Ά
releaseβ function called when the request's reference count reaches zero. this callback must be relied upon to ensure that the request has left the transport systems (both the packet and request systems). do not skip her, she's literally the cleanup icon. π§Ήcompleteβ function called when the request is completed, either with success or failure. the command data for the request response is provided via thestruct ssh_commandparameter (cmd), and the command payload of the request response comes via thestruct ssh_spanparameter (data). (and yeah, the synopsis spells that typestruct ssam_span, iykyk π)
πΈ Description πΈ
so here's the vibe check on the parameters, bestie:
- if the request does not have any response, or has not been completed with success, both the
cmdanddataparameters will beNULL. - if the request response does not have any command payload, the
dataspan will be an empty (zero-length) span.
in case of failure, the reason for the failure is indicated by the value of the provided status code argument (status). this value will be zero in case of success and a regular errno otherwise.
note that a call to this callback does not guarantee that the request is not in use by the transport systems any more. so likeβ¦ don't assume she's fully done just because the callback rang, okay? π
π₯ SEE ALSO π₯
Kernel file ./include/linux/surface_aggregator/serial_hub.h, plus all these refs β collect them all, pokΓ©mon-style:
enum ssh_frame_type(9)struct ssh_frame(9)enum ssh_payload_type(9)struct ssh_command(9)SSH_MESSAGE_LENGTH(9)SSH_COMMAND_MESSAGE_LENGTH(9)SSH_MSGOFFSET_FRAME(9)SSH_MSGOFFSET_COMMAND(9)ssh_crc(9)ssh_rqid_next_valid(9)ssh_rqid_to_event(9)ssh_rqid_is_event(9)ssh_tc_to_rqid(9)ssh_tid_to_index(9)ssh_tid_is_valid(9)struct ssam_span(9)enum ssam_ssh_tid(9)enum ssh_packet_base_priority(9)SSH_PACKET_PRIORITY(9)ssh_packet_priority_get_try(9)ssh_packet_priority_get_base(9)struct ssh_packet_ops(9)struct ssh_packet(9)ssh_packet_set_data(9)struct ssh_request(9)to_ssh_request(9)ssh_request_get(9)ssh_request_put(9)ssh_request_set_data(9)
mwah π β source/version: ./include/linux/surface_aggreg..., dated October 2026. now go forth and callback responsibly, bestie π«Ά
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms