kernel-fxtec-pro1x/include/uapi/linux/qrtr.h
Chris Lew 91959cec0a net: qrtr: Add support for DEL_PROC control message
Add the DEL_PROC control message for forwarding usecases. If this proc
acts as a gateway between two procs then they need a notification to
clean up servers and client ports when either goes down. This message
acts as notification to clean up all resources associated with the node
in the message.

Change-Id: I3514f54aa0221e104196e2120e929cc9f351847d
Signed-off-by: Chris Lew <clew@codeaurora.org>
2019-01-04 12:09:41 +05:30

56 lines
963 B
C

/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
#ifndef _LINUX_QRTR_H
#define _LINUX_QRTR_H
#include <linux/socket.h>
#include <linux/types.h>
#define QRTR_NODE_BCAST 0xffffffffu
#define QRTR_PORT_CTRL 0xfffffffeu
struct sockaddr_qrtr {
__kernel_sa_family_t sq_family;
__u32 sq_node;
__u32 sq_port;
};
enum qrtr_pkt_type {
QRTR_TYPE_DATA = 1,
QRTR_TYPE_HELLO = 2,
QRTR_TYPE_BYE = 3,
QRTR_TYPE_NEW_SERVER = 4,
QRTR_TYPE_DEL_SERVER = 5,
QRTR_TYPE_DEL_CLIENT = 6,
QRTR_TYPE_RESUME_TX = 7,
QRTR_TYPE_EXIT = 8,
QRTR_TYPE_PING = 9,
QRTR_TYPE_NEW_LOOKUP = 10,
QRTR_TYPE_DEL_LOOKUP = 11,
};
#define QRTR_TYPE_DEL_PROC 13
struct qrtr_ctrl_pkt {
__le32 cmd;
union {
struct {
__le32 service;
__le32 instance;
__le32 node;
__le32 port;
} server;
struct {
__le32 node;
__le32 port;
} client;
struct {
__le32 rsvd;
__le32 node;
} proc;
};
} __packed;
#endif /* _LINUX_QRTR_H */