From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stanislaw Gruszka Subject: Re: [PATCH -next] qlcnic: fail when try to setup unsupported features Date: Mon, 28 Jun 2010 16:18:23 +0200 Message-ID: <20100628161823.623343d5@dhcp-lab-109.englab.brq.redhat.com> References: <20100628113134.0c5208b0@dhcp-lab-109.englab.brq.redhat.com> <99737F4847ED0A48AECC9F4A1974A4B80F82CB7D46@MNEXMB2.qlogic.org> <20100628145819.74d22d5f@dhcp-lab-109.englab.brq.redhat.com> <1277731011.2089.1.camel@achroite.uk.solarflarecom.com> <1277731840.2089.8.camel@achroite.uk.solarflarecom.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: Amit Salecha , "netdev@vger.kernel.org" , Amerigo Wang , Anirban Chakraborty To: Ben Hutchings Return-path: Received: from mx1.redhat.com ([209.132.183.28]:62220 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752541Ab0F1OSb (ORCPT ); Mon, 28 Jun 2010 10:18:31 -0400 In-Reply-To: <1277731840.2089.8.camel@achroite.uk.solarflarecom.com> Sender: netdev-owner@vger.kernel.org List-ID: On Mon, 28 Jun 2010 14:30:40 +0100 Ben Hutchings wrote: > > It would be more useful to add a supported_flags parameter to > > ethtool_op_set_flags() so it can check the requested flags against the > > driver/hardware capabilities. > > I also just noticed that ethtool.h says set_flags() will return -EINVAL > for unsupported values. The current implementations variously return > -EINVAL or -EOPNOTSUPP. We need to unify ... , I prefer EOPNOTSUPP since this is returned now if .set_flags == NULL. That will require to change a comment in ethtool.h and some drivers, I will take a look at it. Stanislaw