STRUCT NVMET_FC_TARGET_PORT(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– struct nvmet_fc_target_port(9) πŸ’–

okay bestie, this is the Kernel API Manual entry for struct nvmet_fc_target_port, and it’s literally the little bridge between NVME-FC transport and a LLDD so they can reference a local NVME subsystem port. slay ✨


🌸 NAME 🌸

struct nvmet_fc_target_port β€” this is a structure used between NVME-FC transport and a LLDD to reference a local NVME subsystem port. It’s allocated/created by the nvme_fc_register_targetport() transport interface. no cap 🫢


✨ SYNOPSIS ✨

here’s the exact shape of it, bestie:

       struct nvmet_fc_target_port {
           u32 port_num;
           u64 node_name;
           u64 port_name;
           void *private;
           u32 port_id;
           enum nvme_fc_obj_state port_state;
        };

πŸŽ€ Members πŸŽ€

  • port_num β€” NVME-FC transport subsystem port number πŸ’…
  • node_name β€” FC WWNN for the port πŸ¦‹
  • port_name β€” FC WWPN for the port πŸŽ€
  • private β€” pointer to memory allocated alongside the local port structure that is specifically for the LLDD to use. The length of the buffer corresponds to the target_priv_sz value specified in the nvme_fc_target_template supplied by the LLDD. πŸ‘‘
  • port_id β€” FC N_Port_ID currently assigned the port. Upper 8 bits must be set to 0. ⚠️
  • port_state β€” Operational state of the port. ⭐

πŸ’… Description πŸ’…

so the fields with static values for the port are initialized by the port_info struct supplied to the registration call. 🧚

then there are the fields with dynamic values. Values may change base on link state. The LLDD may reference fields directly to change them. They’re initialized by the port_info struct supplied to the registration call too. πŸ’–


πŸ¦‹ SEE ALSO πŸ¦‹

peep the kernel file ./include/linux/nvme-fc-driver.h, plus these iconic structs:

  • struct nvmefc_ls_req(9)
  • struct nvmefc_ls_rsp(9)
  • struct nvme_fc_port_info(9)
  • struct nvmefc_fcp_req(9)
  • struct nvme_fc_local_port(9)
  • struct nvme_fc_remote_port(9)
  • struct nvme_fc_port_template(9)
  • struct nvmet_fc_port_info(9)
  • struct nvmefc_tgt_fcp_req(9)
  • struct nvmet_fc_target_template(9)

source/version: ./include/linux Β· dated October 2026 Β· manual: struct nvmet_fc_target_port(9) β€” mwah πŸ’‹

πŸ“¦ where this page comes from