Merge branch 'parisc-3.11-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/delle...
[linux-2.6.git] / include / scsi / scsi_transport_srp.h
blobff0f04ac91aad7c2311f9b889aa09c0accb90cc6
1 #ifndef SCSI_TRANSPORT_SRP_H
2 #define SCSI_TRANSPORT_SRP_H
4 #include <linux/transport_class.h>
5 #include <linux/types.h>
6 #include <linux/mutex.h>
8 #define SRP_RPORT_ROLE_INITIATOR 0
9 #define SRP_RPORT_ROLE_TARGET 1
11 struct srp_rport_identifiers {
12 u8 port_id[16];
13 u8 roles;
16 struct srp_rport {
17 /* for initiator and target drivers */
19 struct device dev;
21 u8 port_id[16];
22 u8 roles;
24 /* for initiator drivers */
26 void *lld_data; /* LLD private data */
29 struct srp_function_template {
30 /* for initiator drivers */
31 void (*rport_delete)(struct srp_rport *rport);
32 /* for target drivers */
33 int (* tsk_mgmt_response)(struct Scsi_Host *, u64, u64, int);
34 int (* it_nexus_response)(struct Scsi_Host *, u64, int);
37 extern struct scsi_transport_template *
38 srp_attach_transport(struct srp_function_template *);
39 extern void srp_release_transport(struct scsi_transport_template *);
41 extern struct srp_rport *srp_rport_add(struct Scsi_Host *,
42 struct srp_rport_identifiers *);
43 extern void srp_rport_del(struct srp_rport *);
45 extern void srp_remove_host(struct Scsi_Host *);
47 #endif