/linux-6.6.21/tools/net/ynl/generated/ |
D | fou-user.c | 75 struct nlmsghdr *nlh; in fou_add() local 78 nlh = ynl_gemsg_start_req(ys, ys->family_id, FOU_CMD_ADD, 1); in fou_add() 82 mnl_attr_put_u16(nlh, FOU_ATTR_PORT, req->port); in fou_add() 84 mnl_attr_put_u8(nlh, FOU_ATTR_IPPROTO, req->ipproto); in fou_add() 86 mnl_attr_put_u8(nlh, FOU_ATTR_TYPE, req->type); in fou_add() 88 mnl_attr_put(nlh, FOU_ATTR_REMCSUM_NOPARTIAL, 0, NULL); in fou_add() 90 mnl_attr_put_u32(nlh, FOU_ATTR_LOCAL_V4, req->local_v4); in fou_add() 92 mnl_attr_put_u32(nlh, FOU_ATTR_PEER_V4, req->peer_v4); in fou_add() 94 mnl_attr_put(nlh, FOU_ATTR_LOCAL_V6, req->_present.local_v6_len, req->local_v6); in fou_add() 96 mnl_attr_put(nlh, FOU_ATTR_PEER_V6, req->_present.peer_v6_len, req->peer_v6); in fou_add() [all …]
|
D | ethtool-user.c | 675 int ethtool_header_put(struct nlmsghdr *nlh, unsigned int attr_type, in ethtool_header_put() argument 680 nest = mnl_attr_nest_start(nlh, attr_type); in ethtool_header_put() 682 mnl_attr_put_u32(nlh, ETHTOOL_A_HEADER_DEV_INDEX, obj->dev_index); in ethtool_header_put() 684 mnl_attr_put_strz(nlh, ETHTOOL_A_HEADER_DEV_NAME, obj->dev_name); in ethtool_header_put() 686 mnl_attr_put_u32(nlh, ETHTOOL_A_HEADER_FLAGS, obj->flags); in ethtool_header_put() 687 mnl_attr_nest_end(nlh, nest); in ethtool_header_put() 732 int ethtool_pause_stat_put(struct nlmsghdr *nlh, unsigned int attr_type, in ethtool_pause_stat_put() argument 737 nest = mnl_attr_nest_start(nlh, attr_type); in ethtool_pause_stat_put() 739 mnl_attr_put_u64(nlh, ETHTOOL_A_PAUSE_STAT_TX_FRAMES, obj->tx_frames); in ethtool_pause_stat_put() 741 mnl_attr_put_u64(nlh, ETHTOOL_A_PAUSE_STAT_RX_FRAMES, obj->rx_frames); in ethtool_pause_stat_put() [all …]
|
D | devlink-user.c | 438 int devlink_get_rsp_parse(const struct nlmsghdr *nlh, void *data) in devlink_get_rsp_parse() argument 448 mnl_attr_for_each(attr, nlh, sizeof(struct genlmsghdr)) { in devlink_get_rsp_parse() 503 struct nlmsghdr *nlh; in devlink_get() local 506 nlh = ynl_gemsg_start_req(ys, ys->family_id, DEVLINK_CMD_GET, 1); in devlink_get() 511 mnl_attr_put_strz(nlh, DEVLINK_ATTR_BUS_NAME, req->bus_name); in devlink_get() 513 mnl_attr_put_strz(nlh, DEVLINK_ATTR_DEV_NAME, req->dev_name); in devlink_get() 520 err = ynl_exec(ys, nlh, &yrs); in devlink_get() 550 struct nlmsghdr *nlh; in devlink_get_dump() local 559 nlh = ynl_gemsg_start_dump(ys, ys->family_id, DEVLINK_CMD_GET, 1); in devlink_get_dump() 561 err = ynl_exec_dump(ys, nlh, &yds); in devlink_get_dump() [all …]
|
/linux-6.6.21/tools/testing/selftests/netfilter/ |
D | nf-queue.c | 77 static int queue_cb(const struct nlmsghdr *nlh, void *data) in queue_cb() argument 85 mnl_attr_parse(nlh, sizeof(struct nfgenmsg), parse_attr_cb, tb); in queue_cb() 123 struct nlmsghdr *nlh = mnl_nlmsg_put_header(buf); in nfq_build_cfg_request() local 130 nlh->nlmsg_type = (NFNL_SUBSYS_QUEUE << 8) | NFQNL_MSG_CONFIG; in nfq_build_cfg_request() 131 nlh->nlmsg_flags = NLM_F_REQUEST; in nfq_build_cfg_request() 133 nfg = mnl_nlmsg_put_extra_header(nlh, sizeof(*nfg)); in nfq_build_cfg_request() 139 mnl_attr_put(nlh, NFQA_CFG_CMD, sizeof(cmd), &cmd); in nfq_build_cfg_request() 141 return nlh; in nfq_build_cfg_request() 147 struct nlmsghdr *nlh = mnl_nlmsg_put_header(buf); in nfq_build_cfg_params() local 154 nlh->nlmsg_type = (NFNL_SUBSYS_QUEUE << 8) | NFQNL_MSG_CONFIG; in nfq_build_cfg_params() [all …]
|
/linux-6.6.21/drivers/staging/gdm724x/ |
D | netlink_k.c | 20 #define ND_NLMSG_DATA(nlh) ((void *)((char *)NLMSG_DATA(nlh) + \ argument 23 #define ND_NLMSG_R_LEN(nlh) ((nlh)->nlmsg_len - ND_IFINDEX_LEN) argument 24 #define ND_NLMSG_IFIDX(nlh) NLMSG_DATA(nlh) argument 31 struct nlmsghdr *nlh; in netlink_rcv_cb() local 47 nlh = (struct nlmsghdr *)skb->data; in netlink_rcv_cb() 49 if (skb->len < nlh->nlmsg_len || nlh->nlmsg_len > ND_MAX_MSG_LEN) { in netlink_rcv_cb() 51 skb->len, nlh->nlmsg_len); in netlink_rcv_cb() 55 memcpy(&ifindex, ND_NLMSG_IFIDX(nlh), ND_IFINDEX_LEN); in netlink_rcv_cb() 56 msg = ND_NLMSG_DATA(nlh); in netlink_rcv_cb() 57 mlen = ND_NLMSG_R_LEN(nlh); in netlink_rcv_cb() [all …]
|
/linux-6.6.21/net/netfilter/ |
D | nfnetlink.c | 216 static int nfnetlink_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, in nfnetlink_rcv_msg() argument 225 if (nlmsg_len(nlh) < sizeof(struct nfgenmsg)) in nfnetlink_rcv_msg() 228 type = nlh->nlmsg_type; in nfnetlink_rcv_msg() 256 u8 cb_id = NFNL_MSG_TYPE(nlh->nlmsg_type); in nfnetlink_rcv_msg() 258 struct nlattr *attr = (void *)nlh + min_len; in nfnetlink_rcv_msg() 259 int attrlen = nlh->nlmsg_len - min_len; in nfnetlink_rcv_msg() 264 .nlh = nlh, in nfnetlink_rcv_msg() 265 .nfmsg = nlmsg_data(nlh), in nfnetlink_rcv_msg() 318 struct nlmsghdr *nlh; member 323 static int nfnl_err_add(struct list_head *list, struct nlmsghdr *nlh, int err, in nfnl_err_add() argument [all …]
|
/linux-6.6.21/drivers/infiniband/core/ |
D | netlink.c | 131 void *ibnl_put_msg(struct sk_buff *skb, struct nlmsghdr **nlh, int seq, in ibnl_put_msg() argument 134 *nlh = nlmsg_put(skb, 0, seq, RDMA_NL_GET_TYPE(client, op), len, flags); in ibnl_put_msg() 135 if (!*nlh) in ibnl_put_msg() 137 return nlmsg_data(*nlh); in ibnl_put_msg() 141 int ibnl_put_attr(struct sk_buff *skb, struct nlmsghdr *nlh, in ibnl_put_attr() argument 145 nlmsg_cancel(skb, nlh); in ibnl_put_attr() 152 static int rdma_nl_rcv_msg(struct sk_buff *skb, struct nlmsghdr *nlh, in rdma_nl_rcv_msg() argument 155 int type = nlh->nlmsg_type; in rdma_nl_rcv_msg() 181 err = cb_table[op].doit(skb, nlh, extack); in rdma_nl_rcv_msg() 185 if ((nlh->nlmsg_flags & NLM_F_DUMP) || index == RDMA_NL_IWCM) { in rdma_nl_rcv_msg() [all …]
|
D | iwpm_msg.c | 67 struct nlmsghdr *nlh; in iwpm_register_pid() local 75 skb = iwpm_create_nlmsg(RDMA_NL_IWPM_REG_PID, &nlh, nl_client); in iwpm_register_pid() 80 nlh->nlmsg_seq = iwpm_get_nlmsg_seq(); in iwpm_register_pid() 81 nlmsg_request = iwpm_get_nlmsg_request(nlh->nlmsg_seq, nl_client, GFP_KERNEL); in iwpm_register_pid() 90 ret = ibnl_put_attr(skb, nlh, sizeof(u32), &msg_seq, IWPM_NLA_REG_PID_SEQ); in iwpm_register_pid() 93 ret = ibnl_put_attr(skb, nlh, IFNAMSIZ, in iwpm_register_pid() 97 ret = ibnl_put_attr(skb, nlh, IWPM_DEVNAME_SIZE, in iwpm_register_pid() 101 ret = ibnl_put_attr(skb, nlh, IWPM_ULIBNAME_SIZE, in iwpm_register_pid() 106 nlmsg_end(skb, nlh); in iwpm_register_pid() 147 struct nlmsghdr *nlh; in iwpm_add_mapping() local [all …]
|
D | nldev.c | 1017 static int nldev_get_doit(struct sk_buff *skb, struct nlmsghdr *nlh, in nldev_get_doit() argument 1026 err = nlmsg_parse_deprecated(nlh, 0, tb, RDMA_NLDEV_ATTR_MAX - 1, in nldev_get_doit() 1043 nlh = nlmsg_put(msg, NETLINK_CB(skb).portid, nlh->nlmsg_seq, in nldev_get_doit() 1046 if (!nlh) { in nldev_get_doit() 1055 nlmsg_end(msg, nlh); in nldev_get_doit() 1067 static int nldev_set_doit(struct sk_buff *skb, struct nlmsghdr *nlh, in nldev_set_doit() argument 1075 err = nlmsg_parse_deprecated(nlh, 0, tb, RDMA_NLDEV_ATTR_MAX - 1, in nldev_set_doit() 1126 struct nlmsghdr *nlh; in _nldev_get_dumpit() local 1131 nlh = nlmsg_put(skb, NETLINK_CB(cb->skb).portid, cb->nlh->nlmsg_seq, in _nldev_get_dumpit() 1135 if (!nlh || fill_dev_info(skb, device)) { in _nldev_get_dumpit() [all …]
|
D | iwpm_util.c | 438 struct sk_buff *iwpm_create_nlmsg(u32 nl_op, struct nlmsghdr **nlh, in iwpm_create_nlmsg() argument 447 if (!(ibnl_put_msg(skb, nlh, 0, 0, nl_client, nl_op, in iwpm_create_nlmsg() 465 ret = nlmsg_validate_deprecated(cb->nlh, nlh_len, policy_max - 1, in iwpm_parse_nlmsg() 471 ret = nlmsg_parse_deprecated(cb->nlh, nlh_len, nltb, policy_max - 1, in iwpm_parse_nlmsg() 581 struct nlmsghdr *nlh; in send_mapinfo_num() local 586 skb = iwpm_create_nlmsg(RDMA_NL_IWPM_MAPINFO_NUM, &nlh, nl_client); in send_mapinfo_num() 591 nlh->nlmsg_seq = iwpm_get_nlmsg_seq(); in send_mapinfo_num() 594 ret = ibnl_put_attr(skb, nlh, sizeof(u32), &msg_seq, IWPM_NLA_MAPINFO_SEQ); in send_mapinfo_num() 597 ret = ibnl_put_attr(skb, nlh, sizeof(u32), in send_mapinfo_num() 602 nlmsg_end(skb, nlh); in send_mapinfo_num() [all …]
|
/linux-6.6.21/drivers/scsi/ |
D | scsi_netlink.c | 34 struct nlmsghdr *nlh; in scsi_nl_rcv_msg() local 42 nlh = nlmsg_hdr(skb); in scsi_nl_rcv_msg() 43 if ((nlh->nlmsg_len < (sizeof(*nlh) + sizeof(*hdr))) || in scsi_nl_rcv_msg() 44 (skb->len < nlh->nlmsg_len)) { in scsi_nl_rcv_msg() 50 rlen = NLMSG_ALIGN(nlh->nlmsg_len); in scsi_nl_rcv_msg() 54 if (nlh->nlmsg_type != SCSI_TRANSPORT_MSG) { in scsi_nl_rcv_msg() 59 hdr = nlmsg_data(nlh); in scsi_nl_rcv_msg() 71 if (nlh->nlmsg_len < (sizeof(*nlh) + hdr->msglen)) { in scsi_nl_rcv_msg() 99 if ((err) || (nlh->nlmsg_flags & NLM_F_ACK)) in scsi_nl_rcv_msg() 100 netlink_ack(skb, nlh, err, NULL); in scsi_nl_rcv_msg()
|
/linux-6.6.21/net/phonet/ |
D | pn_netlink.c | 51 static int addr_doit(struct sk_buff *skb, struct nlmsghdr *nlh, in addr_doit() argument 69 err = nlmsg_parse_deprecated(nlh, sizeof(*ifm), tb, IFA_MAX, in addr_doit() 74 ifm = nlmsg_data(nlh); in addr_doit() 86 if (nlh->nlmsg_type == RTM_NEWADDR) in addr_doit() 91 phonet_address_notify(nlh->nlmsg_type, dev, pnaddr); in addr_doit() 99 struct nlmsghdr *nlh; in fill_addr() local 101 nlh = nlmsg_put(skb, portid, seq, event, sizeof(*ifm), 0); in fill_addr() 102 if (nlh == NULL) in fill_addr() 105 ifm = nlmsg_data(nlh); in fill_addr() 113 nlmsg_end(skb, nlh); in fill_addr() [all …]
|
/linux-6.6.21/tools/net/ynl/lib/ |
D | ynl.c | 139 ynl_ext_ack_check(struct ynl_sock *ys, const struct nlmsghdr *nlh, in ynl_ext_ack_check() argument 148 if (!(nlh->nlmsg_flags & NLM_F_ACK_TLVS)) in ynl_ext_ack_check() 151 mnl_attr_for_each(attr, nlh, hlen) { in ynl_ext_ack_check() 191 start = mnl_nlmsg_get_payload_offset(ys->nlh, in ynl_ext_ack_check() 193 end = mnl_nlmsg_get_payload_tail(ys->nlh); in ynl_ext_ack_check() 217 start = mnl_nlmsg_get_payload_offset(ys->nlh, in ynl_ext_ack_check() 219 end = mnl_nlmsg_get_payload_tail(ys->nlh); in ynl_ext_ack_check() 256 static int ynl_cb_error(const struct nlmsghdr *nlh, void *data) in ynl_cb_error() argument 258 const struct nlmsgerr *err = mnl_nlmsg_get_payload(nlh); in ynl_cb_error() 268 if (!(nlh->nlmsg_flags & NLM_F_CAPPED)) in ynl_cb_error() [all …]
|
/linux-6.6.21/tools/include/uapi/linux/ |
D | netlink.h | 94 #define NLMSG_DATA(nlh) ((void*)(((char*)nlh) + NLMSG_LENGTH(0))) argument 95 #define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \ argument 96 (struct nlmsghdr*)(((char*)(nlh)) + NLMSG_ALIGN((nlh)->nlmsg_len))) 97 #define NLMSG_OK(nlh,len) ((len) >= (int)sizeof(struct nlmsghdr) && \ argument 98 (nlh)->nlmsg_len >= sizeof(struct nlmsghdr) && \ 99 (nlh)->nlmsg_len <= (len)) 100 #define NLMSG_PAYLOAD(nlh,len) ((nlh)->nlmsg_len - NLMSG_SPACE((len))) argument
|
/linux-6.6.21/include/net/ |
D | netlink.h | 466 struct nlmsghdr *nlh; member 580 static inline void *nlmsg_data(const struct nlmsghdr *nlh) in nlmsg_data() argument 582 return (unsigned char *) nlh + NLMSG_HDRLEN; in nlmsg_data() 589 static inline int nlmsg_len(const struct nlmsghdr *nlh) in nlmsg_len() argument 591 return nlh->nlmsg_len - NLMSG_HDRLEN; in nlmsg_len() 599 static inline struct nlattr *nlmsg_attrdata(const struct nlmsghdr *nlh, in nlmsg_attrdata() argument 602 unsigned char *data = nlmsg_data(nlh); in nlmsg_attrdata() 611 static inline int nlmsg_attrlen(const struct nlmsghdr *nlh, int hdrlen) in nlmsg_attrlen() argument 613 return nlmsg_len(nlh) - NLMSG_ALIGN(hdrlen); in nlmsg_attrlen() 621 static inline int nlmsg_ok(const struct nlmsghdr *nlh, int remaining) in nlmsg_ok() argument [all …]
|
/linux-6.6.21/net/ipv6/ |
D | addrlabel.c | 384 static int ip6addrlbl_newdel(struct sk_buff *skb, struct nlmsghdr *nlh, in ip6addrlbl_newdel() argument 394 err = nlmsg_parse_deprecated(nlh, sizeof(*ifal), tb, IFAL_MAX, in ip6addrlbl_newdel() 399 ifal = nlmsg_data(nlh); in ip6addrlbl_newdel() 415 switch (nlh->nlmsg_type) { in ip6addrlbl_newdel() 423 nlh->nlmsg_flags & NLM_F_REPLACE); in ip6addrlbl_newdel() 435 static void ip6addrlbl_putmsg(struct nlmsghdr *nlh, in ip6addrlbl_putmsg() argument 438 struct ifaddrlblmsg *ifal = nlmsg_data(nlh); in ip6addrlbl_putmsg() 453 struct nlmsghdr *nlh = nlmsg_put(skb, portid, seq, event, in ip6addrlbl_fill() local 455 if (!nlh) in ip6addrlbl_fill() 458 ip6addrlbl_putmsg(nlh, p->prefixlen, p->ifindex, lseq); in ip6addrlbl_fill() [all …]
|
/linux-6.6.21/net/xfrm/ |
D | xfrm_user.c | 782 static int xfrm_add_sa(struct sk_buff *skb, struct nlmsghdr *nlh, in xfrm_add_sa() argument 786 struct xfrm_usersa_info *p = nlmsg_data(nlh); in xfrm_add_sa() 800 if (nlh->nlmsg_type == XFRM_MSG_NEWSA) in xfrm_add_sa() 817 c.seq = nlh->nlmsg_seq; in xfrm_add_sa() 818 c.portid = nlh->nlmsg_pid; in xfrm_add_sa() 819 c.event = nlh->nlmsg_type; in xfrm_add_sa() 861 static int xfrm_del_sa(struct sk_buff *skb, struct nlmsghdr *nlh, in xfrm_del_sa() argument 868 struct xfrm_usersa_id *p = nlmsg_data(nlh); in xfrm_del_sa() 887 c.seq = nlh->nlmsg_seq; in xfrm_del_sa() 888 c.portid = nlh->nlmsg_pid; in xfrm_del_sa() [all …]
|
/linux-6.6.21/include/uapi/linux/ |
D | netlink.h | 103 #define NLMSG_DATA(nlh) ((void *)(((char *)nlh) + NLMSG_HDRLEN)) argument 104 #define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \ argument 105 (struct nlmsghdr *)(((char *)(nlh)) + \ 106 NLMSG_ALIGN((nlh)->nlmsg_len))) 107 #define NLMSG_OK(nlh,len) ((len) >= (int)sizeof(struct nlmsghdr) && \ argument 108 (nlh)->nlmsg_len >= sizeof(struct nlmsghdr) && \ 109 (nlh)->nlmsg_len <= (len)) 110 #define NLMSG_PAYLOAD(nlh,len) ((nlh)->nlmsg_len - NLMSG_SPACE((len))) argument
|
/linux-6.6.21/security/selinux/ |
D | netlink.c | 43 static void selnl_add_payload(struct nlmsghdr *nlh, int len, int msgtype, void *data) in selnl_add_payload() argument 47 struct selnl_msg_setenforce *msg = nlmsg_data(nlh); in selnl_add_payload() 55 struct selnl_msg_policyload *msg = nlmsg_data(nlh); in selnl_add_payload() 72 struct nlmsghdr *nlh; in selnl_notify() local 81 nlh = nlmsg_put(skb, 0, 0, msgtype, len, 0); in selnl_notify() 82 if (!nlh) in selnl_notify() 84 selnl_add_payload(nlh, len, msgtype, data); in selnl_notify() 85 nlh->nlmsg_len = skb->tail - tmp; in selnl_notify()
|
/linux-6.6.21/tools/testing/selftests/net/af_unix/ |
D | diag_uid.c | 81 struct nlmsghdr nlh; in send_request() member 84 .nlh = { in send_request() 151 struct nlmsghdr *nlh; in receive_response() local 157 nlh = (struct nlmsghdr *)buf; in receive_response() 158 ASSERT_NE(NLMSG_OK(nlh, ret), 0); in receive_response() 159 ASSERT_EQ(nlh->nlmsg_type, SOCK_DIAG_BY_FAMILY); in receive_response() 161 render_response(_metadata, NLMSG_DATA(nlh), nlh->nlmsg_len); in receive_response() 163 nlh = NLMSG_NEXT(nlh, ret); in receive_response() 164 ASSERT_EQ(NLMSG_OK(nlh, ret), 0); in receive_response()
|
/linux-6.6.21/tools/bpf/bpftool/ |
D | net.c | 204 static int __dump_class_nlmsg(struct nlmsghdr *nlh, in __dump_class_nlmsg() argument 209 struct tcmsg *t = NLMSG_DATA(nlh); in __dump_class_nlmsg() 212 len = nlh->nlmsg_len - NLMSG_LENGTH(sizeof(*t)); in __dump_class_nlmsg() 224 struct nlmsghdr nlh; in netlink_get_class() member 227 .nlh.nlmsg_len = NLMSG_LENGTH(sizeof(struct tcmsg)), in netlink_get_class() 228 .nlh.nlmsg_type = RTM_GETTCLASS, in netlink_get_class() 229 .nlh.nlmsg_flags = NLM_F_DUMP | NLM_F_REQUEST, in netlink_get_class() 235 req.nlh.nlmsg_seq = seq; in netlink_get_class() 236 if (send(sock, &req, req.nlh.nlmsg_len, 0) < 0) in netlink_get_class() 243 static int __dump_qdisc_nlmsg(struct nlmsghdr *nlh, in __dump_qdisc_nlmsg() argument [all …]
|
/linux-6.6.21/net/ipv4/ |
D | inet_diag.c | 206 static int inet_diag_parse_attrs(const struct nlmsghdr *nlh, int hdrlen, in inet_diag_parse_attrs() argument 212 nlmsg_for_each_attr(nla, nlh, hdrlen, remaining) { in inet_diag_parse_attrs() 244 struct nlmsghdr *nlh; in inet_sk_diag_fill() local 252 nlh = nlmsg_put(skb, NETLINK_CB(cb->skb).portid, cb->nlh->nlmsg_seq, in inet_sk_diag_fill() 253 cb->nlh->nlmsg_type, sizeof(*r), nlmsg_flags); in inet_sk_diag_fill() 254 if (!nlh) in inet_sk_diag_fill() 257 r = nlmsg_data(nlh); in inet_sk_diag_fill() 367 bool first_nlmsg = ((unsigned char *)nlh == skb->data); in inet_sk_diag_fill() 373 msg_len = skb_tail_pointer(skb) - (unsigned char *)nlh; in inet_sk_diag_fill() 405 nlmsg_end(skb, nlh); in inet_sk_diag_fill() [all …]
|
/linux-6.6.21/crypto/ |
D | crypto_user_base.c | 159 struct nlmsghdr *nlh; in crypto_report_alg() local 163 nlh = nlmsg_put(skb, NETLINK_CB(in_skb).portid, info->nlmsg_seq, in crypto_report_alg() 165 if (!nlh) { in crypto_report_alg() 170 ualg = nlmsg_data(nlh); in crypto_report_alg() 174 nlmsg_cancel(skb, nlh); in crypto_report_alg() 178 nlmsg_end(skb, nlh); in crypto_report_alg() 234 info.nlmsg_seq = cb->nlh->nlmsg_seq; in crypto_dump_report() 260 static int crypto_update_alg(struct sk_buff *skb, struct nlmsghdr *nlh, in crypto_update_alg() argument 264 struct crypto_user_alg *p = nlmsg_data(nlh); in crypto_update_alg() 296 static int crypto_del_alg(struct sk_buff *skb, struct nlmsghdr *nlh, in crypto_del_alg() argument [all …]
|
/linux-6.6.21/include/linux/netfilter/ |
D | nfnetlink.h | 13 const struct nlmsghdr *nlh; member 67 static inline void nfnl_fill_hdr(struct nlmsghdr *nlh, u8 family, u8 version, in nfnl_fill_hdr() argument 72 nfmsg = nlmsg_data(nlh); in nfnl_fill_hdr() 83 struct nlmsghdr *nlh; in nfnl_msg_put() local 85 nlh = nlmsg_put(skb, portid, seq, type, sizeof(struct nfgenmsg), flags); in nfnl_msg_put() 86 if (!nlh) in nfnl_msg_put() 89 nfnl_fill_hdr(nlh, family, version, res_id); in nfnl_msg_put() 91 return nlh; in nfnl_msg_put()
|
/linux-6.6.21/net/core/ |
D | sock_diag.c | 20 static int (*inet_rcv_compat)(struct sk_buff *skb, struct nlmsghdr *nlh); 169 void sock_diag_register_inet_compat(int (*fn)(struct sk_buff *skb, struct nlmsghdr *nlh)) in sock_diag_register_inet_compat() argument 177 void sock_diag_unregister_inet_compat(int (*fn)(struct sk_buff *skb, struct nlmsghdr *nlh)) in sock_diag_unregister_inet_compat() argument 217 static int __sock_diag_cmd(struct sk_buff *skb, struct nlmsghdr *nlh) in __sock_diag_cmd() argument 220 struct sock_diag_req *req = nlmsg_data(nlh); in __sock_diag_cmd() 223 if (nlmsg_len(nlh) < sizeof(*req)) in __sock_diag_cmd() 237 else if (nlh->nlmsg_type == SOCK_DIAG_BY_FAMILY) in __sock_diag_cmd() 238 err = hndl->dump(skb, nlh); in __sock_diag_cmd() 239 else if (nlh->nlmsg_type == SOCK_DESTROY && hndl->destroy) in __sock_diag_cmd() 240 err = hndl->destroy(skb, nlh); in __sock_diag_cmd() [all …]
|