diff options
Diffstat (limited to 'drivers/scsi/fcoe')
-rw-r--r-- | drivers/scsi/fcoe/fcoe.c | 14 | ||||
-rw-r--r-- | drivers/scsi/fcoe/fcoe.h | 2 |
2 files changed, 7 insertions, 9 deletions
diff --git a/drivers/scsi/fcoe/fcoe.c b/drivers/scsi/fcoe/fcoe.c index 078d262ac7cc..666b7ac4475f 100644 --- a/drivers/scsi/fcoe/fcoe.c +++ b/drivers/scsi/fcoe/fcoe.c | |||
@@ -1643,7 +1643,7 @@ static int fcoe_xmit(struct fc_lport *lport, struct fc_frame *fp) | |||
1643 | skb_reset_network_header(skb); | 1643 | skb_reset_network_header(skb); |
1644 | skb->mac_len = elen; | 1644 | skb->mac_len = elen; |
1645 | skb->protocol = htons(ETH_P_FCOE); | 1645 | skb->protocol = htons(ETH_P_FCOE); |
1646 | skb->priority = port->priority; | 1646 | skb->priority = fcoe->priority; |
1647 | 1647 | ||
1648 | if (fcoe->netdev->priv_flags & IFF_802_1Q_VLAN && | 1648 | if (fcoe->netdev->priv_flags & IFF_802_1Q_VLAN && |
1649 | fcoe->realdev->features & NETIF_F_HW_VLAN_TX) { | 1649 | fcoe->realdev->features & NETIF_F_HW_VLAN_TX) { |
@@ -1917,7 +1917,6 @@ static int fcoe_dcb_app_notification(struct notifier_block *notifier, | |||
1917 | struct fcoe_ctlr *ctlr; | 1917 | struct fcoe_ctlr *ctlr; |
1918 | struct fcoe_interface *fcoe; | 1918 | struct fcoe_interface *fcoe; |
1919 | struct net_device *netdev; | 1919 | struct net_device *netdev; |
1920 | struct fcoe_port *port; | ||
1921 | int prio; | 1920 | int prio; |
1922 | 1921 | ||
1923 | if (entry->app.selector != DCB_APP_IDTYPE_ETHTYPE) | 1922 | if (entry->app.selector != DCB_APP_IDTYPE_ETHTYPE) |
@@ -1946,10 +1945,8 @@ static int fcoe_dcb_app_notification(struct notifier_block *notifier, | |||
1946 | entry->app.protocol == ETH_P_FCOE) | 1945 | entry->app.protocol == ETH_P_FCOE) |
1947 | ctlr->priority = prio; | 1946 | ctlr->priority = prio; |
1948 | 1947 | ||
1949 | if (entry->app.protocol == ETH_P_FCOE) { | 1948 | if (entry->app.protocol == ETH_P_FCOE) |
1950 | port = lport_priv(ctlr->lp); | 1949 | fcoe->priority = prio; |
1951 | port->priority = prio; | ||
1952 | } | ||
1953 | 1950 | ||
1954 | return NOTIFY_OK; | 1951 | return NOTIFY_OK; |
1955 | } | 1952 | } |
@@ -2180,7 +2177,6 @@ static void fcoe_dcb_create(struct fcoe_interface *fcoe) | |||
2180 | u8 fup, up; | 2177 | u8 fup, up; |
2181 | struct net_device *netdev = fcoe->realdev; | 2178 | struct net_device *netdev = fcoe->realdev; |
2182 | struct fcoe_ctlr *ctlr = fcoe_to_ctlr(fcoe); | 2179 | struct fcoe_ctlr *ctlr = fcoe_to_ctlr(fcoe); |
2183 | struct fcoe_port *port = lport_priv(ctlr->lp); | ||
2184 | struct dcb_app app = { | 2180 | struct dcb_app app = { |
2185 | .priority = 0, | 2181 | .priority = 0, |
2186 | .protocol = ETH_P_FCOE | 2182 | .protocol = ETH_P_FCOE |
@@ -2202,8 +2198,8 @@ static void fcoe_dcb_create(struct fcoe_interface *fcoe) | |||
2202 | fup = dcb_getapp(netdev, &app); | 2198 | fup = dcb_getapp(netdev, &app); |
2203 | } | 2199 | } |
2204 | 2200 | ||
2205 | port->priority = ffs(up) ? ffs(up) - 1 : 0; | 2201 | fcoe->priority = ffs(up) ? ffs(up) - 1 : 0; |
2206 | ctlr->priority = ffs(fup) ? ffs(fup) - 1 : port->priority; | 2202 | ctlr->priority = ffs(fup) ? ffs(fup) - 1 : fcoe->priority; |
2207 | } | 2203 | } |
2208 | #endif | 2204 | #endif |
2209 | } | 2205 | } |
diff --git a/drivers/scsi/fcoe/fcoe.h b/drivers/scsi/fcoe/fcoe.h index a624add4f8ec..b42dc32cb5eb 100644 --- a/drivers/scsi/fcoe/fcoe.h +++ b/drivers/scsi/fcoe/fcoe.h | |||
@@ -71,6 +71,7 @@ do { \ | |||
71 | * @oem: The offload exchange manager for all local port | 71 | * @oem: The offload exchange manager for all local port |
72 | * instances associated with this port | 72 | * instances associated with this port |
73 | * @removed: Indicates fcoe interface removed from net device | 73 | * @removed: Indicates fcoe interface removed from net device |
74 | * @priority: Priority for the FCoE packet (DCB) | ||
74 | * This structure is 1:1 with a net device. | 75 | * This structure is 1:1 with a net device. |
75 | */ | 76 | */ |
76 | struct fcoe_interface { | 77 | struct fcoe_interface { |
@@ -81,6 +82,7 @@ struct fcoe_interface { | |||
81 | struct packet_type fip_packet_type; | 82 | struct packet_type fip_packet_type; |
82 | struct fc_exch_mgr *oem; | 83 | struct fc_exch_mgr *oem; |
83 | u8 removed; | 84 | u8 removed; |
85 | u8 priority; | ||
84 | }; | 86 | }; |
85 | 87 | ||
86 | #define fcoe_to_ctlr(x) \ | 88 | #define fcoe_to_ctlr(x) \ |