summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/fcoe/fcoe.h
diff options
context:
space:
mode:
authorChris Leech <christopher.leech@intel.com>2009-08-25 13:59:35 -0700
committerJames Bottomley <James.Bottomley@suse.de>2009-09-10 12:07:32 -0500
commit250249898a92a1228050f40fbe3c05deb1392da8 (patch)
tree37835c6c378c1024b1f0e3a4432d63011b3f3e61 /drivers/scsi/fcoe/fcoe.h
parent014f5c3f560a336cb8ad5b9f828c85de0398e7bb (diff)
downloadop-kernel-dev-250249898a92a1228050f40fbe3c05deb1392da8.zip
op-kernel-dev-250249898a92a1228050f40fbe3c05deb1392da8.tar.gz
[SCSI] fcoe: move netdev to fcoe_interface
The network interface needs to be shared between all NPIV VN_Ports, therefor it should be tracked in the fcoe_interface and not for each SCSI host in fcoe_port. Signed-off-by: Chris Leech <christopher.leech@intel.com> Signed-off-by: Robert Love <robert.w.love@intel.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/fcoe/fcoe.h')
-rw-r--r--drivers/scsi/fcoe/fcoe.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/scsi/fcoe/fcoe.h b/drivers/scsi/fcoe/fcoe.h
index 060a6dc..3b3886e 100644
--- a/drivers/scsi/fcoe/fcoe.h
+++ b/drivers/scsi/fcoe/fcoe.h
@@ -82,6 +82,7 @@ struct fcoe_interface {
/* This will be removed once all the shared values are
* moved out of fcoe_port */
struct fcoe_port *priv;
+ struct net_device *netdev;
};
/*
@@ -90,7 +91,6 @@ struct fcoe_interface {
*/
struct fcoe_port {
struct fcoe_interface *fcoe;
- struct net_device *netdev;
struct fc_exch_mgr *oem; /* offload exchange manger */
struct packet_type fcoe_packet_type;
struct packet_type fip_packet_type;
@@ -100,12 +100,11 @@ struct fcoe_port {
struct fcoe_ctlr ctlr;
};
-#define fcoe_from_ctlr(port) container_of(port, struct fcoe_port, ctlr)
+#define fcoe_from_ctlr(fip) container_of(fip, struct fcoe_port, ctlr)
-static inline struct net_device *fcoe_netdev(
- const struct fc_lport *lp)
+static inline struct net_device *fcoe_netdev(const struct fc_lport *lp)
{
- return ((struct fcoe_port *)lport_priv(lp))->netdev;
+ return ((struct fcoe_port *)lport_priv(lp))->fcoe->netdev;
}
#endif /* _FCOE_H_ */
OpenPOWER on IntegriCloud