Skip to contentSkip to conversation

drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h: remove unused macro pr_fmt()

PATCH In review [email protected] 3 participants 6 messages Nov 15, 2011 – Nov 16, 2011

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h: remove unused macro pr_fmt()

From: Andrew Morton <[email protected]>
Subject: drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h: remove unused macro pr_fmt()

In file included from drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c:22:
drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h:24:1: warning: "pr_fmt" redefined In file included from include/linux/kernel.h:20,
from include/linux/cache.h:4,
from include/linux/time.h:7,
from include/linux/stat.h:60,
from include/linux/module.h:10,
from drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c:21:
include/linux/printk.h:152:1: warning: this is the location of the previous definition

Cc Tomoya <[email protected]>
Cc Toshiharu Okada <[email protected]>
Cc Jeff Kirsher <[email protected]>
Cc David Miller <[email protected]>

---

 drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h |    2 --
 1 file changed, 2 deletions(-)
drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h renamed from drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h~drivers-net-ethernet-oki-semi-pch_gbe-pch_gbeh-remove-unused-macro-pr_fmt +0 -2
diff -puN drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h~drivers-net-ethernet-oki-semi-pch_gbe-pch_gbeh-remove-unused-macro-pr_fmt drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h
@@ -21,8 +21,6 @@
 #ifndef _PCH_GBE_H_
 #define _PCH_GBE_H_
 
-#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
-
 #include <linux/mii.h>
 #include <linux/delay.h>
 #include <linux/pci.h>

_

maintainer
#1 lore raw

From: [email protected]
Date: Tue, 15 Nov 2011 14:55:29 -0800

Quoted 2 lines

From: Andrew Morton <[email protected]>
Subject: drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h: remove unused macro pr_fmt()

It's not unused, it just isn't properly coming before the linux/printk.h include.

#2 lore raw
Quoted 8 lines · On Tue, 15 Nov 2011 18:38:08 -0500 (EST) David Miller <[email protected]>…

From: [email protected]
Date: Tue, 15 Nov 2011 14:55:29 -0800

Quoted 2 lines

From: Andrew Morton <[email protected]>
Subject: drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h: remove unused macro pr_fmt()

It's not unused, it just isn't properly coming before the linux/printk.h include.

Oh well, I'll drop it. Please treat the patch as a bug report instead.

#3 lore raw

PATCH 1/1 pch_gbe: Move #include of module.h

The first #include must be pch_gbe.h as it
does a #define of pr_fmt.

---
 .../net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c  |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c +1 -1
index 9c075ea..9cb5f91 100644
@@ -18,8 +18,8 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307, USA.
  */
 
-#include <linux/module.h>	/* for __MODULE_STRING */
 #include "pch_gbe.h"
+#include <linux/module.h>	/* for __MODULE_STRING */
 
 #define OPTION_UNSET   -1
 #define OPTION_DISABLED 0
maintainer
#5 lore raw
In reply to Andrew Morton

From: Andrew Morton <[email protected]>
Date: Tue, 15 Nov 2011 15:52:10 -0800

Quoted 6 lines
Quoted 3 lines · On Tue, 15 Nov 2011 18:38:08 -0500 (EST) David Miller <[email protected]>…

From: [email protected]
Date: Tue, 15 Nov 2011 14:55:29 -0800

Quoted 7 lines
Quoted 5 lines
Quoted 2 lines

From: Andrew Morton <[email protected]>
Subject: drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe.h: remove unused macro pr_fmt()

It's not unused, it just isn't properly coming before the linux/printk.h include.

Oh well, I'll drop it. Please treat the patch as a bug report instead.

Joe Perches took care of it, I just applied a proper fix from him.

Thanks.