linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] i2c-i801: Standardize log messages
@ 2014-01-23 15:59 Jean Delvare
       [not found] ` <20140123165938.493ea62c-R0o5gVi9kd7kN2dkZ6Wm7A@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Jean Delvare @ 2014-01-23 15:59 UTC (permalink / raw)
  To: Linux I2C; +Cc: Wolfram Sang, Shane Huang

Use exactly the same log messages in the legacy setup function and the
SB800+ setup function. This way strings can be reused, which saves
some bytes in the generated binary.

Signed-off-by: Jean Delvare <khali-PUYAD+kWke1g9hUCZPvPmw@public.gmane.org>
Cc: Shane Huang <shane.huang-5C7GfCeVMHo@public.gmane.org>
---
Inspired by Shane's recent patch, on top of which it applies.

 drivers/i2c/busses/i2c-piix4.c |   12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

--- linux-3.13.orig/drivers/i2c/busses/i2c-piix4.c	2014-01-23 13:35:43.684040390 +0100
+++ linux-3.13/drivers/i2c/busses/i2c-piix4.c	2014-01-23 13:54:55.462751999 +0100
@@ -208,16 +208,16 @@ static int piix4_setup(struct pci_dev *P
 				   "WARNING: SMBus interface has been FORCEFULLY ENABLED!\n");
 		} else {
 			dev_err(&PIIX4_dev->dev,
-				"Host SMBus controller not enabled!\n");
+				"SMBus Host Controller not enabled!\n");
 			release_region(piix4_smba, SMBIOSIZE);
 			return -ENODEV;
 		}
 	}
 
 	if (((temp & 0x0E) == 8) || ((temp & 0x0E) == 2))
-		dev_dbg(&PIIX4_dev->dev, "Using Interrupt 9 for SMBus.\n");
+		dev_dbg(&PIIX4_dev->dev, "Using IRQ for SMBus\n");
 	else if ((temp & 0x0E) == 0)
-		dev_dbg(&PIIX4_dev->dev, "Using Interrupt SMI# for SMBus.\n");
+		dev_dbg(&PIIX4_dev->dev, "Using SMI# for SMBus\n");
 	else
 		dev_err(&PIIX4_dev->dev, "Illegal Interrupt configuration "
 			"(or code out of date)!\n");
@@ -279,7 +279,7 @@ static int piix4_setup_sb800(struct pci_
 
 	if (!smb_en_status) {
 		dev_err(&PIIX4_dev->dev,
-			"Host SMBus controller not enabled!\n");
+			"SMBus Host Controller not enabled!\n");
 		return -ENODEV;
 	}
 
@@ -311,9 +311,9 @@ static int piix4_setup_sb800(struct pci_
 	release_region(piix4_smba + i2ccfg_offset, 1);
 
 	if (i2ccfg & 1)
-		dev_dbg(&PIIX4_dev->dev, "Using IRQ for SMBus.\n");
+		dev_dbg(&PIIX4_dev->dev, "Using IRQ for SMBus\n");
 	else
-		dev_dbg(&PIIX4_dev->dev, "Using SMI# for SMBus.\n");
+		dev_dbg(&PIIX4_dev->dev, "Using SMI# for SMBus\n");
 
 	dev_info(&PIIX4_dev->dev,
 		 "SMBus Host Controller at 0x%x, revision %d\n",


-- 
Jean Delvare

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-01-24 17:01 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-23 15:59 [PATCH] i2c-i801: Standardize log messages Jean Delvare
     [not found] ` <20140123165938.493ea62c-R0o5gVi9kd7kN2dkZ6Wm7A@public.gmane.org>
2014-01-24 16:51   ` Wolfram Sang
2014-01-24 17:01     ` Jean Delvare

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).