* [PATCH net-next-2.6] IB/{nes,ipoib}: Pass supported flags to ethtool_op_set_flags() [not found] ` <1278184884.4878.559.camel@localhost> @ 2010-07-03 19:41 ` Ben Hutchings 2010-07-03 20:08 ` Roland Dreier 2010-07-06 16:22 ` [PATCH net-next-2.6] IB/{nes, ipoib}: " Randy Dunlap 0 siblings, 2 replies; 5+ messages in thread From: Ben Hutchings @ 2010-07-03 19:41 UTC (permalink / raw) To: David Miller, Roland Dreier Cc: Randy Dunlap, netdev-u79uwXL29TY76Z2rM5mHXA, linux-net-drivers-s/n/eUQHGBpZroRs9YW3xA, sgruszka-H+wXaHxf7aLQT0dZR+AlfA, amit.salecha-h88ZbnxC6KDQT0dZR+AlfA, amwang-H+wXaHxf7aLQT0dZR+AlfA, anirban.chakraborty-h88ZbnxC6KDQT0dZR+AlfA, dm-ut6Up61K2wZBDgjK7y7TUQ, scofeldm-FYB4Gu1CFyUAvxtiuMwx3w, vkolluri-FYB4Gu1CFyUAvxtiuMwx3w, roprabhu-FYB4Gu1CFyUAvxtiuMwx3w, e1000-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f, buytenh-OLH4Qvv75CYX/NnBR394Jw, gallatin-vV262kQ/Wyo, brice-vV262kQ/Wyo, shemminger-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b, jgarzik-H+wXaHxf7aLQT0dZR+AlfA, Faisal Latif, Chien Tung, linux-rdma-u79uwXL29TY76Z2rM5mHXA Following commit 1437ce3983bcbc0447a0dedcd644c14fe833d266 "ethtool: Change ethtool_op_set_flags to validate flags", ethtool_op_set_flags takes a third parameter and cannot be used directly as an implementation of ethtool_ops::set_flags. Changes nes and ipoib driver to pass in the appropriate value. Signed-off-by: Ben Hutchings <bhutchings-s/n/eUQHGBpZroRs9YW3xA@public.gmane.org> --- This is compile-tested only. Dave, Roland, you'd better decide between yourselves should apply this. Ben. drivers/infiniband/hw/nes/nes_nic.c | 8 +++++++- drivers/infiniband/ulp/ipoib/ipoib_ethtool.c | 7 ++++++- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/drivers/infiniband/hw/nes/nes_nic.c b/drivers/infiniband/hw/nes/nes_nic.c index 5cc0a9a..42e7aad 100644 --- a/drivers/infiniband/hw/nes/nes_nic.c +++ b/drivers/infiniband/hw/nes/nes_nic.c @@ -1567,6 +1567,12 @@ static int nes_netdev_set_settings(struct net_device *netdev, struct ethtool_cmd } +static int nes_netdev_set_flags(struct net_device *netdev, u32 flags) +{ + return ethtool_op_set_flags(netdev, flags, ETH_FLAG_LRO); +} + + static const struct ethtool_ops nes_ethtool_ops = { .get_link = ethtool_op_get_link, .get_settings = nes_netdev_get_settings, @@ -1588,7 +1594,7 @@ static const struct ethtool_ops nes_ethtool_ops = { .get_tso = ethtool_op_get_tso, .set_tso = ethtool_op_set_tso, .get_flags = ethtool_op_get_flags, - .set_flags = ethtool_op_set_flags, + .set_flags = nes_netdev_set_flags, }; diff --git a/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c b/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c index 40e8584..1a1657c 100644 --- a/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c +++ b/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c @@ -147,6 +147,11 @@ static void ipoib_get_ethtool_stats(struct net_device *dev, data[index++] = priv->lro.lro_mgr.stats.no_desc; } +static int ipoib_set_flags(struct net_device *dev, u32 flags) +{ + return ethtool_op_set_flags(dev, flags, ETH_FLAG_LRO); +} + static const struct ethtool_ops ipoib_ethtool_ops = { .get_drvinfo = ipoib_get_drvinfo, .get_rx_csum = ipoib_get_rx_csum, @@ -154,7 +159,7 @@ static const struct ethtool_ops ipoib_ethtool_ops = { .get_coalesce = ipoib_get_coalesce, .set_coalesce = ipoib_set_coalesce, .get_flags = ethtool_op_get_flags, - .set_flags = ethtool_op_set_flags, + .set_flags = ipoib_set_flags, .get_strings = ipoib_get_strings, .get_sset_count = ipoib_get_sset_count, .get_ethtool_stats = ipoib_get_ethtool_stats, -- 1.7.1 -- Ben Hutchings, Senior Software Engineer, Solarflare Communications Not speaking for my employer; that's the marketing department's job. They asked us to note that Solarflare product names are trademarked. -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH net-next-2.6] IB/{nes,ipoib}: Pass supported flags to ethtool_op_set_flags() 2010-07-03 19:41 ` [PATCH net-next-2.6] IB/{nes,ipoib}: Pass supported flags to ethtool_op_set_flags() Ben Hutchings @ 2010-07-03 20:08 ` Roland Dreier 2010-07-03 20:40 ` [PATCH net-next-2.6] IB/{nes, ipoib}: " Ben Hutchings 2010-07-04 18:48 ` [PATCH net-next-2.6] IB/{nes,ipoib}: " David Miller 2010-07-06 16:22 ` [PATCH net-next-2.6] IB/{nes, ipoib}: " Randy Dunlap 1 sibling, 2 replies; 5+ messages in thread From: Roland Dreier @ 2010-07-03 20:08 UTC (permalink / raw) To: Ben Hutchings Cc: David Miller, Roland Dreier, Randy Dunlap, netdev-u79uwXL29TY76Z2rM5mHXA, linux-net-drivers-s/n/eUQHGBpZroRs9YW3xA, sgruszka-H+wXaHxf7aLQT0dZR+AlfA, amit.salecha-h88ZbnxC6KDQT0dZR+AlfA, amwang-H+wXaHxf7aLQT0dZR+AlfA, anirban.chakraborty-h88ZbnxC6KDQT0dZR+AlfA, dm-ut6Up61K2wZBDgjK7y7TUQ, scofeldm-FYB4Gu1CFyUAvxtiuMwx3w, vkolluri-FYB4Gu1CFyUAvxtiuMwx3w, roprabhu-FYB4Gu1CFyUAvxtiuMwx3w, e1000-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f, buytenh-OLH4Qvv75CYX/NnBR394Jw, gallatin-vV262kQ/Wyo, brice-vV262kQ/Wyo, shemminger-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b, jgarzik-H+wXaHxf7aLQT0dZR+AlfA, Faisal Latif, Chien Tung, linux-rdma-u79uwXL29TY76Z2rM5mHXA > Following commit 1437ce3983bcbc0447a0dedcd644c14fe833d266 "ethtool: > Change ethtool_op_set_flags to validate flags", ethtool_op_set_flags > takes a third parameter and cannot be used directly as an > implementation of ethtool_ops::set_flags. I assume this commit is in one of Dave's trees and breaks nes and ipoib because it changed the ethtool_op_set_flags prototype? > Dave, Roland, you'd better decide between yourselves should apply this. Since this depends on a commit already in Dave's tree, Dave should probably take it into the same tree. I guess there's no way to roll this into the original patch to avoid breaking bisects once this ends up upstream? anyway, Acked-by: Roland Dreier <rolandd-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org> > +static int nes_netdev_set_flags(struct net_device *netdev, u32 flags) > +{ > + return ethtool_op_set_flags(netdev, flags, ETH_FLAG_LRO); > +} > + > + > static const struct ethtool_ops nes_ethtool_ops = { Also would have been a bit nicer to avoid adding a double blank line here, although that's obviously a trivial issue. - R. -- Roland Dreier <rolandd-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org> || For corporate legal information go to: http://www.cisco.com/web/about/doing_business/legal/cri/index.html -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH net-next-2.6] IB/{nes, ipoib}: Pass supported flags to ethtool_op_set_flags() 2010-07-03 20:08 ` Roland Dreier @ 2010-07-03 20:40 ` Ben Hutchings 2010-07-04 18:48 ` [PATCH net-next-2.6] IB/{nes,ipoib}: " David Miller 1 sibling, 0 replies; 5+ messages in thread From: Ben Hutchings @ 2010-07-03 20:40 UTC (permalink / raw) To: Roland Dreier Cc: Randy Dunlap, amit.salecha, Chien Tung, sgruszka, amwang, dm, brice, gallatin, shemminger, jgarzik, roprabhu, e1000-devel, scofeldm, Roland Dreier, buytenh, Faisal Latif, vkolluri, linux-net-drivers, netdev, anirban.chakraborty, linux-rdma, David Miller On Sat, 2010-07-03 at 13:08 -0700, Roland Dreier wrote: > > Following commit 1437ce3983bcbc0447a0dedcd644c14fe833d266 "ethtool: > > Change ethtool_op_set_flags to validate flags", ethtool_op_set_flags > > takes a third parameter and cannot be used directly as an > > implementation of ethtool_ops::set_flags. > > I assume this commit is in one of Dave's trees and breaks nes and ipoib > because it changed the ethtool_op_set_flags prototype? Right. > > Dave, Roland, you'd better decide between yourselves should apply this. > > Since this depends on a commit already in Dave's tree, Dave should > probably take it into the same tree. I guess there's no way to roll > this into the original patch to avoid breaking bisects once this ends up > upstream? Unfortunately it's too late to do that. > anyway, > > Acked-by: Roland Dreier <rolandd@cisco.com> > > > +static int nes_netdev_set_flags(struct net_device *netdev, u32 flags) > > +{ > > + return ethtool_op_set_flags(netdev, flags, ETH_FLAG_LRO); > > +} > > + > > + > > static const struct ethtool_ops nes_ethtool_ops = { > > Also would have been a bit nicer to avoid adding a double blank line > here, although that's obviously a trivial issue. This spacing is consistent with the surrounding code. Ben. -- Ben Hutchings, Senior Software Engineer, Solarflare Communications Not speaking for my employer; that's the marketing department's job. They asked us to note that Solarflare product names are trademarked. ------------------------------------------------------------------------------ This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first _______________________________________________ E1000-devel mailing list E1000-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/e1000-devel To learn more about Intel® Ethernet, visit http://communities.intel.com/community/wired ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH net-next-2.6] IB/{nes,ipoib}: Pass supported flags to ethtool_op_set_flags() 2010-07-03 20:08 ` Roland Dreier 2010-07-03 20:40 ` [PATCH net-next-2.6] IB/{nes, ipoib}: " Ben Hutchings @ 2010-07-04 18:48 ` David Miller 1 sibling, 0 replies; 5+ messages in thread From: David Miller @ 2010-07-04 18:48 UTC (permalink / raw) To: rdreier Cc: bhutchings, rolandd, randy.dunlap, netdev, linux-net-drivers, sgruszka, amit.salecha, amwang, anirban.chakraborty, dm, scofeldm, vkolluri, roprabhu, e1000-devel, buytenh, gallatin, brice, shemminger, jgarzik, faisal.latif, chien.tin.tung, linux-rdma From: Roland Dreier <rdreier@cisco.com> Date: Sat, 03 Jul 2010 13:08:29 -0700 > > Following commit 1437ce3983bcbc0447a0dedcd644c14fe833d266 "ethtool: > > Change ethtool_op_set_flags to validate flags", ethtool_op_set_flags > > takes a third parameter and cannot be used directly as an > > implementation of ethtool_ops::set_flags. > > Acked-by: Roland Dreier <rolandd@cisco.com> Applied, thanks guys. ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH net-next-2.6] IB/{nes, ipoib}: Pass supported flags to ethtool_op_set_flags() 2010-07-03 19:41 ` [PATCH net-next-2.6] IB/{nes,ipoib}: Pass supported flags to ethtool_op_set_flags() Ben Hutchings 2010-07-03 20:08 ` Roland Dreier @ 2010-07-06 16:22 ` Randy Dunlap 1 sibling, 0 replies; 5+ messages in thread From: Randy Dunlap @ 2010-07-06 16:22 UTC (permalink / raw) To: Ben Hutchings Cc: amit.salecha, linux-net-drivers, dm, sgruszka, amwang, Faisal Latif, e1000-devel, netdev, anirban.chakraborty, jgarzik, vkolluri, Chien Tung, brice, gallatin, linux-rdma, scofeldm, Roland Dreier, shemminger, David Miller, buytenh, roprabhu On 07/03/10 12:41, Ben Hutchings wrote: > Following commit 1437ce3983bcbc0447a0dedcd644c14fe833d266 "ethtool: > Change ethtool_op_set_flags to validate flags", ethtool_op_set_flags > takes a third parameter and cannot be used directly as an > implementation of ethtool_ops::set_flags. > > Changes nes and ipoib driver to pass in the appropriate value. > > Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> > --- > This is compile-tested only. Ack, thanks. > Dave, Roland, you'd better decide between yourselves should apply this. > > Ben. > > drivers/infiniband/hw/nes/nes_nic.c | 8 +++++++- > drivers/infiniband/ulp/ipoib/ipoib_ethtool.c | 7 ++++++- > 2 files changed, 13 insertions(+), 2 deletions(-) > > diff --git a/drivers/infiniband/hw/nes/nes_nic.c b/drivers/infiniband/hw/nes/nes_nic.c > index 5cc0a9a..42e7aad 100644 > --- a/drivers/infiniband/hw/nes/nes_nic.c > +++ b/drivers/infiniband/hw/nes/nes_nic.c > @@ -1567,6 +1567,12 @@ static int nes_netdev_set_settings(struct net_device *netdev, struct ethtool_cmd > } > > > +static int nes_netdev_set_flags(struct net_device *netdev, u32 flags) > +{ > + return ethtool_op_set_flags(netdev, flags, ETH_FLAG_LRO); > +} > + > + > static const struct ethtool_ops nes_ethtool_ops = { > .get_link = ethtool_op_get_link, > .get_settings = nes_netdev_get_settings, > @@ -1588,7 +1594,7 @@ static const struct ethtool_ops nes_ethtool_ops = { > .get_tso = ethtool_op_get_tso, > .set_tso = ethtool_op_set_tso, > .get_flags = ethtool_op_get_flags, > - .set_flags = ethtool_op_set_flags, > + .set_flags = nes_netdev_set_flags, > }; > > > diff --git a/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c b/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c > index 40e8584..1a1657c 100644 > --- a/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c > +++ b/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c > @@ -147,6 +147,11 @@ static void ipoib_get_ethtool_stats(struct net_device *dev, > data[index++] = priv->lro.lro_mgr.stats.no_desc; > } > > +static int ipoib_set_flags(struct net_device *dev, u32 flags) > +{ > + return ethtool_op_set_flags(dev, flags, ETH_FLAG_LRO); > +} > + > static const struct ethtool_ops ipoib_ethtool_ops = { > .get_drvinfo = ipoib_get_drvinfo, > .get_rx_csum = ipoib_get_rx_csum, > @@ -154,7 +159,7 @@ static const struct ethtool_ops ipoib_ethtool_ops = { > .get_coalesce = ipoib_get_coalesce, > .set_coalesce = ipoib_set_coalesce, > .get_flags = ethtool_op_get_flags, > - .set_flags = ethtool_op_set_flags, > + .set_flags = ipoib_set_flags, > .get_strings = ipoib_get_strings, > .get_sset_count = ipoib_get_sset_count, > .get_ethtool_stats = ipoib_get_ethtool_stats, -- ~Randy *** Remember to use Documentation/SubmitChecklist when testing your code *** ------------------------------------------------------------------------------ This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first _______________________________________________ E1000-devel mailing list E1000-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/e1000-devel To learn more about Intel® Ethernet, visit http://communities.intel.com/community/wired ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-07-06 16:22 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1277901872.2082.10.camel@achroite.uk.solarflarecom.com>
[not found] ` <20100702095514.7fb324c8.randy.dunlap@oracle.com>
[not found] ` <20100702.220711.39188625.davem@davemloft.net>
[not found] ` <20100703120729.f2a2715b.randy.dunlap@oracle.com>
[not found] ` <1278184884.4878.559.camel@localhost>
2010-07-03 19:41 ` [PATCH net-next-2.6] IB/{nes,ipoib}: Pass supported flags to ethtool_op_set_flags() Ben Hutchings
2010-07-03 20:08 ` Roland Dreier
2010-07-03 20:40 ` [PATCH net-next-2.6] IB/{nes, ipoib}: " Ben Hutchings
2010-07-04 18:48 ` [PATCH net-next-2.6] IB/{nes,ipoib}: " David Miller
2010-07-06 16:22 ` [PATCH net-next-2.6] IB/{nes, ipoib}: " Randy Dunlap
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox