perf record: Fix segfault with --no-mmap-pages
[linux/fpc-iii.git] / drivers / scsi / be2iscsi / be_iscsi.h
blob31ddc84943989b94eaa4682b91d1a8461c7d066c
1 /**
2 * Copyright (C) 2005 - 2013 Emulex
3 * All rights reserved.
5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License version 2
7 * as published by the Free Software Foundation. The full GNU General
8 * Public License is included in this distribution in the file called COPYING.
10 * Written by: Jayamohan Kallickal (jayamohan.kallickal@emulex.com)
12 * Contact Information:
13 * linux-drivers@emulex.com
15 * Emulex
16 * 3333 Susan Street
17 * Costa Mesa, CA 92626
20 #ifndef _BE_ISCSI_
21 #define _BE_ISCSI_
23 #include "be_main.h"
24 #include "be_mgmt.h"
26 #define BE2_IPV4 0x1
27 #define BE2_IPV6 0x10
28 #define BE2_DHCP_V4 0x05
30 #define NON_BLOCKING 0x0
31 #define BLOCKING 0x1
33 void beiscsi_create_def_ifaces(struct beiscsi_hba *phba);
35 void beiscsi_destroy_def_ifaces(struct beiscsi_hba *phba);
37 int be2iscsi_iface_get_param(struct iscsi_iface *iface,
38 enum iscsi_param_type param_type,
39 int param, char *buf);
41 int be2iscsi_iface_set_param(struct Scsi_Host *shost,
42 void *data, uint32_t count);
44 umode_t be2iscsi_attr_is_visible(int param_type, int param);
46 void beiscsi_offload_connection(struct beiscsi_conn *beiscsi_conn,
47 struct beiscsi_offload_params *params);
49 void beiscsi_offload_iscsi(struct beiscsi_hba *phba, struct iscsi_conn *conn,
50 struct beiscsi_conn *beiscsi_conn,
51 unsigned int fw_handle);
53 struct iscsi_cls_session *beiscsi_session_create(struct iscsi_endpoint *ep,
54 uint16_t cmds_max,
55 uint16_t qdepth,
56 uint32_t initial_cmdsn);
58 void beiscsi_session_destroy(struct iscsi_cls_session *cls_session);
60 struct iscsi_cls_conn *beiscsi_conn_create(struct iscsi_cls_session
61 *cls_session, uint32_t cid);
63 int beiscsi_conn_bind(struct iscsi_cls_session *cls_session,
64 struct iscsi_cls_conn *cls_conn,
65 uint64_t transport_fd, int is_leading);
67 int beiscsi_ep_get_param(struct iscsi_endpoint *ep, enum iscsi_param param,
68 char *buf);
70 int beiscsi_get_host_param(struct Scsi_Host *shost,
71 enum iscsi_host_param param, char *buf);
73 int beiscsi_get_macaddr(char *buf, struct beiscsi_hba *phba);
75 int beiscsi_set_param(struct iscsi_cls_conn *cls_conn,
76 enum iscsi_param param, char *buf, int buflen);
78 int beiscsi_conn_start(struct iscsi_cls_conn *cls_conn);
80 struct iscsi_endpoint *beiscsi_ep_connect(struct Scsi_Host *shost,
81 struct sockaddr *dst_addr,
82 int non_blocking);
84 int beiscsi_ep_poll(struct iscsi_endpoint *ep, int timeout_ms);
86 void beiscsi_ep_disconnect(struct iscsi_endpoint *ep);
88 void beiscsi_conn_get_stats(struct iscsi_cls_conn *cls_conn,
89 struct iscsi_stats *stats);
91 #endif