* [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
* Re: [PATCH] i2c-i801: Standardize log messages
[not found] ` <20140123165938.493ea62c-R0o5gVi9kd7kN2dkZ6Wm7A@public.gmane.org>
@ 2014-01-24 16:51 ` Wolfram Sang
2014-01-24 17:01 ` Jean Delvare
0 siblings, 1 reply; 3+ messages in thread
From: Wolfram Sang @ 2014-01-24 16:51 UTC (permalink / raw)
To: Jean Delvare; +Cc: Linux I2C, Shane Huang
[-- Attachment #1: Type: text/plain, Size: 488 bytes --]
On Thu, Jan 23, 2014 at 04:59:38PM +0100, Jean Delvare wrote:
> 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>
Subject is wrong. This is about piix4, not i801.
Fixed and applied to for-current, thanks!
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] i2c-i801: Standardize log messages
2014-01-24 16:51 ` Wolfram Sang
@ 2014-01-24 17:01 ` Jean Delvare
0 siblings, 0 replies; 3+ messages in thread
From: Jean Delvare @ 2014-01-24 17:01 UTC (permalink / raw)
To: Wolfram Sang; +Cc: Linux I2C, Shane Huang
On Fri, 24 Jan 2014 17:51:54 +0100, Wolfram Sang wrote:
> On Thu, Jan 23, 2014 at 04:59:38PM +0100, Jean Delvare wrote:
> > 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>
>
> Subject is wrong. This is about piix4, not i801.
> Fixed and applied to for-current, thanks!
D'oh! Working too much on the same driver over the years I guess.
Anyway, thanks for catching my mistake.
--
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).