All of lore.kernel.org
 help / color / mirror / Atom feed
From: Giuseppe CAVALLARO <peppe.cavallaro@st.com>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org, bhutchings@solarflare.com,
	rayagond@vayavyalabs.com
Subject: Re: [net-next 3/4 (V3)] stmmac: add the Energy Efficient Ethernet support
Date: Fri, 13 Apr 2012 08:35:26 +0200	[thread overview]
Message-ID: <4F87C92E.7040503@st.com> (raw)
In-Reply-To: <20120412.163258.602029261264172098.davem@davemloft.net>

On 4/12/2012 10:32 PM, David Miller wrote:
> From: Giuseppe CAVALLARO <peppe.cavallaro@st.com>
> Date: Fri,  6 Apr 2012 11:29:17 +0200
> 
>> +static int stmmac_ethtool_op_set_eee(struct net_device *dev,
>> +				     struct ethtool_value *eee)
>> +{
>> +	struct stmmac_priv *priv = netdev_priv(dev);
>> +
>> +	if ((!eee->data) && (priv->eee_enabled)) {
>> +		stmmac_disable_eee_mode(priv);
>> +		priv->eee_enabled = eee->data;
>> +	} else if ((eee->data) && (!priv->eee_enabled))
>> +		/* We are asking for enabling the EEE but this
>> +		 * has to be verified by invoking the eee_init function.
>> +		 * For this reason we cannot set eee_enabled to
>> +		 * eee->data, directly. */
>> +		priv->eee_enabled = stmmac_eee_init(priv);
>> +
>> +	return 0;
> 
> If stmmac_eee_init() determines that it cannot enable eee, you should
> return an appropriate error code here so that ethtool can report that
> fact.

Ok, thanks

peppe

  reply	other threads:[~2012-04-13  6:37 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-06  9:29 [net-next 0/4 (V3)] stmmac & EEE support Giuseppe CAVALLARO
2012-04-06  9:29 ` [net-next 1/4 (V3)] net: ethtool: add the " Giuseppe CAVALLARO
2012-04-12 22:26   ` Ben Hutchings
2012-04-16  5:41     ` Giuseppe CAVALLARO
2012-04-19 12:58       ` Giuseppe CAVALLARO
2012-04-19 13:48         ` Yuval Mintz
2012-04-19 15:14           ` Ben Hutchings
2012-04-19 15:30         ` Ben Hutchings
2012-04-26  7:48           ` Giuseppe CAVALLARO
2012-04-26 17:17             ` Ben Hutchings
2012-04-27 14:11               ` Giuseppe CAVALLARO
2012-04-29  9:20                 ` Yuval Mintz
2012-04-29 21:56                   ` Ben Hutchings
2012-05-07  5:25                     ` Giuseppe CAVALLARO
2012-04-06  9:29 ` [net-next 2/4 (V3)] phy: add the EEE support and the way to access to the MMD regs Giuseppe CAVALLARO
2012-04-06  9:29 ` [net-next 3/4 (V3)] stmmac: add the Energy Efficient Ethernet support Giuseppe CAVALLARO
2012-04-12 20:32   ` David Miller
2012-04-13  6:35     ` Giuseppe CAVALLARO [this message]
2012-04-06  9:29 ` [net-next 4/4 (V3)] stmmac: update the driver Documentation and add EEE Giuseppe CAVALLARO
2012-04-06  9:29 ` [PATCH] ethtool: add the EEE option Giuseppe CAVALLARO

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F87C92E.7040503@st.com \
    --to=peppe.cavallaro@st.com \
    --cc=bhutchings@solarflare.com \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=rayagond@vayavyalabs.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.