netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
To: davem@davemloft.net
Cc: Don Skidmore <donald.c.skidmore@intel.com>,
	netdev@vger.kernel.org, nhorman@redhat.com, sassmann@redhat.com,
	jogreene@redhat.com, Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Subject: [net-next 08/18] ixgbe: Add const string for overheat message
Date: Tue,  9 Jun 2015 18:10:19 -0700	[thread overview]
Message-ID: <1433898629-76729-9-git-send-email-jeffrey.t.kirsher@intel.com> (raw)
In-Reply-To: <1433898629-76729-1-git-send-email-jeffrey.t.kirsher@intel.com>

From: Don Skidmore <donald.c.skidmore@intel.com>

The over heat message is displayed for multiple reasons but the text is
cut-n-pasted for each of these cases.  This patch pulls the text from the
same location.  I noticed this as I am about to add another case.

Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com>
Tested-by: Krishneil Singh <krishneil.k.singh@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
---
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
index 1b2bdbf..30adfb8 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
@@ -81,6 +81,8 @@ const char ixgbe_driver_version[] = DRV_VERSION;
 static const char ixgbe_copyright[] =
 				"Copyright (c) 1999-2014 Intel Corporation.";
 
+static const char ixgbe_overheat_msg[] = "Network adapter has been stopped because it has over heated. Restart the computer. If the problem persists, power off the system and replace the adapter";
+
 static const struct ixgbe_info *ixgbe_info_tbl[] = {
 	[board_82598]		= &ixgbe_82598_info,
 	[board_82599]		= &ixgbe_82599_info,
@@ -2390,10 +2392,7 @@ static void ixgbe_check_overtemp_subtask(struct ixgbe_adapter *adapter)
 			return;
 		break;
 	}
-	e_crit(drv,
-	       "Network adapter has been stopped because it has over heated. "
-	       "Restart the computer. If the problem persists, "
-	       "power off the system and replace the adapter\n");
+	e_crit(drv, "%s\n", ixgbe_overheat_msg);
 
 	adapter->interrupt_event = 0;
 }
@@ -2440,10 +2439,7 @@ static void ixgbe_check_overtemp_event(struct ixgbe_adapter *adapter, u32 eicr)
 		return;
 	}
 
-	e_crit(drv,
-	       "Network adapter has been stopped because it has over heated. "
-	       "Restart the computer. If the problem persists, "
-	       "power off the system and replace the adapter\n");
+	e_crit(drv, "%s\n", ixgbe_overheat_msg);
 }
 
 static void ixgbe_check_sfp_event(struct ixgbe_adapter *adapter, u32 eicr)
-- 
2.4.2

  parent reply	other threads:[~2015-06-10  1:10 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-10  1:10 [net-next 00/18][pull request] Intel Wired LAN Driver Updates 2015-06-09 Jeff Kirsher
2015-06-10  1:10 ` [net-next 01/18] ixgbe: add array of MAC type dependent values Jeff Kirsher
2015-06-10  1:10 ` [net-next 02/18] ixgbe: add support for WoL and autoneg FC for some X550 devices Jeff Kirsher
2015-06-10  1:10 ` [net-next 03/18] ixgbe: add define for X557 PHY ID Jeff Kirsher
2015-06-10  1:10 ` [net-next 04/18] ixgbe: Add a PHY power state method Jeff Kirsher
2015-06-10  1:10 ` [net-next 05/18] ixgbe: Restore ESDP settings after MAC reset Jeff Kirsher
2015-06-10  1:10 ` [net-next 06/18] ixgbe: add X550 support for external PHY and forced 1G/10G support Jeff Kirsher
2015-06-10  1:10 ` [net-next 07/18] ixgbe: Add reset for X550 device Jeff Kirsher
2015-06-10  1:10 ` Jeff Kirsher [this message]
2015-06-10  1:10 ` [net-next 09/18] ixgbe: add support for interrupts from X550 external PHY Jeff Kirsher
2015-06-10  1:10 ` [net-next 10/18] ixgbe: fix issue with sfp events with new X550 devices Jeff Kirsher
2015-06-10  1:10 ` [net-next 11/18] ixgbe: fix bug in not clearing counters for " Jeff Kirsher
2015-06-10  1:10 ` [net-next 12/18] ixgbe: fix X550 devices init flow Jeff Kirsher
2015-06-10  1:10 ` [net-next 13/18] ixgbe: fix X550 PHY function pointers Jeff Kirsher
2015-06-10  1:10 ` [net-next 14/18] ixgbe: Add support for another X550 device Jeff Kirsher
2015-06-10  1:10 ` [net-next 15/18] ixgbe: add link check for X550 copper Jeff Kirsher
2015-06-10  1:10 ` [net-next 16/18] ixgbe: Set lan_id before using I2C Jeff Kirsher
2015-06-10  1:10 ` [net-next 17/18] ixgbe: fix X550 default set_phy_power method Jeff Kirsher
2015-06-10  1:10 ` [net-next 18/18] ixgbe: Remember to write ixfi changes after modifying Jeff Kirsher
2015-06-11  5:14 ` [net-next 00/18][pull request] Intel Wired LAN Driver Updates 2015-06-09 David Miller

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=1433898629-76729-9-git-send-email-jeffrey.t.kirsher@intel.com \
    --to=jeffrey.t.kirsher@intel.com \
    --cc=davem@davemloft.net \
    --cc=donald.c.skidmore@intel.com \
    --cc=jogreene@redhat.com \
    --cc=netdev@vger.kernel.org \
    --cc=nhorman@redhat.com \
    --cc=sassmann@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).