summaryrefslogtreecommitdiffstats
path: root/net/dcb
diff options
context:
space:
mode:
authorJohn Fastabend <john.r.fastabend@intel.com>2011-10-06 08:52:38 +0000
committerDavid S. Miller <davem@davemloft.net>2011-10-06 15:49:51 -0400
commit6bd0e1cb10b6d14dda4a8806d0a2f4f0bbf01931 (patch)
treefa494e77fd2b8f4c6c99fc08e2885d50622be554 /net/dcb
parente290ed81307ca7d92675f0d9c683add693c2f377 (diff)
downloadlinux-6bd0e1cb10b6d14dda4a8806d0a2f4f0bbf01931.tar.gz
linux-6bd0e1cb10b6d14dda4a8806d0a2f4f0bbf01931.tar.bz2
linux-6bd0e1cb10b6d14dda4a8806d0a2f4f0bbf01931.zip
dcb: add DCBX mode to event notifier attributes
Add DCBX mode to event notifiers so listeners can learn currently enabled mode. Signed-off-by: John Fastabend <john.r.fastabend@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dcb')
-rw-r--r--net/dcb/dcbnl.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/net/dcb/dcbnl.c b/net/dcb/dcbnl.c
index e508593d589b..9bfbc1d1b50c 100644
--- a/net/dcb/dcbnl.c
+++ b/net/dcb/dcbnl.c
@@ -2075,6 +2075,8 @@ int dcb_setapp(struct net_device *dev, struct dcb_app *new)
event.ifindex = dev->ifindex;
memcpy(&event.app, new, sizeof(event.app));
+ if (dev->dcbnl_ops->getdcbx)
+ event.dcbx = dev->dcbnl_ops->getdcbx(dev);
spin_lock(&dcb_lock);
/* Search for existing match and replace */
@@ -2152,6 +2154,8 @@ int dcb_ieee_setapp(struct net_device *dev, struct dcb_app *new)
event.ifindex = dev->ifindex;
memcpy(&event.app, new, sizeof(event.app));
+ if (dev->dcbnl_ops->getdcbx)
+ event.dcbx = dev->dcbnl_ops->getdcbx(dev);
spin_lock(&dcb_lock);
/* Search for existing match and abort if found */
@@ -2196,6 +2200,8 @@ int dcb_ieee_delapp(struct net_device *dev, struct dcb_app *del)
event.ifindex = dev->ifindex;
memcpy(&event.app, del, sizeof(event.app));
+ if (dev->dcbnl_ops->getdcbx)
+ event.dcbx = dev->dcbnl_ops->getdcbx(dev);
spin_lock(&dcb_lock);
/* Search for existing match and remove it. */