/*1* FC Transport Netlink Interface2*3* Copyright (C) 2006 James Smart, Emulex Corporation4*5* This program is free software; you can redistribute it and/or modify6* it under the terms of the GNU General Public License as published by7* the Free Software Foundation; either version 2 of the License, or8* (at your option) any later version.9*10* This program is distributed in the hope that it will be useful,11* but WITHOUT ANY WARRANTY; without even the implied warranty of12* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the13* GNU General Public License for more details.14*15* You should have received a copy of the GNU General Public License16* along with this program; if not, write to the Free Software17* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA18*19*/20#ifndef SCSI_NETLINK_FC_H21#define SCSI_NETLINK_FC_H2223#include <scsi/scsi_netlink.h>2425/*26* This file intended to be included by both kernel and user space27*/2829/*30* FC Transport Message Types31*/32/* kernel -> user */33#define FC_NL_ASYNC_EVENT 0x010034/* user -> kernel */35/* none */363738/*39* Message Structures :40*/4142/* macro to round up message lengths to 8byte boundary */43#define FC_NL_MSGALIGN(len) (((len) + 7) & ~7)444546/*47* FC Transport Broadcast Event Message :48* FC_NL_ASYNC_EVENT49*50* Note: if Vendor Unique message, &event_data will be start of51* vendor unique payload, and the length of the payload is52* per event_datalen53*54* Note: When specifying vendor_id, be sure to read the Vendor Type and ID55* formatting requirements specified in scsi_netlink.h56*/57struct fc_nl_event {58struct scsi_nl_hdr snlh; /* must be 1st element ! */59uint64_t seconds;60uint64_t vendor_id;61uint16_t host_no;62uint16_t event_datalen;63uint32_t event_num;64uint32_t event_code;65uint32_t event_data;66} __attribute__((aligned(sizeof(uint64_t))));676869#endif /* SCSI_NETLINK_FC_H */70717273