]> asedeno.scripts.mit.edu Git - linux.git/blob - include/uapi/scsi/scsi_netlink_fc.h
Merge tag 'riscv/for-v5.3-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv...
[linux.git] / include / uapi / scsi / scsi_netlink_fc.h
1 /* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */
2 /*
3  *  FC Transport Netlink Interface
4  *
5  *  Copyright (C) 2006   James Smart, Emulex Corporation
6  */
7 #ifndef SCSI_NETLINK_FC_H
8 #define SCSI_NETLINK_FC_H
9
10 #include <scsi/scsi_netlink.h>
11
12 /*
13  * This file intended to be included by both kernel and user space
14  */
15
16 /*
17  * FC Transport Message Types
18  */
19         /* kernel -> user */
20 #define FC_NL_ASYNC_EVENT                       0x0100
21         /* user -> kernel */
22 /* none */
23
24
25 /*
26  * Message Structures :
27  */
28
29 /* macro to round up message lengths to 8byte boundary */
30 #define FC_NL_MSGALIGN(len)             (((len) + 7) & ~7)
31
32
33 /*
34  * FC Transport Broadcast Event Message :
35  *   FC_NL_ASYNC_EVENT
36  *
37  * Note: if Vendor Unique message, &event_data will be  start of
38  *       vendor unique payload, and the length of the payload is
39  *       per event_datalen
40  *
41  * Note: When specifying vendor_id, be sure to read the Vendor Type and ID
42  *   formatting requirements specified in scsi_netlink.h
43  */
44 struct fc_nl_event {
45         struct scsi_nl_hdr snlh;                /* must be 1st element ! */
46         uint64_t seconds;
47         uint64_t vendor_id;
48         uint16_t host_no;
49         uint16_t event_datalen;
50         uint32_t event_num;
51         uint32_t event_code;
52         uint32_t event_data;
53 } __attribute__((aligned(sizeof(uint64_t))));
54
55
56 #endif /* SCSI_NETLINK_FC_H */
57