diff mbox series

[U-Boot] linux/compat.h: Add netdev_### log macros

Message ID 1532600158-23271-1-git-send-email-bmeng.cn@gmail.com
State Accepted
Commit b06d76f9ae2eae389ddaa74abeee7987bdf1b9d4
Delegated to: Joe Hershberger
Headers show
Series [U-Boot] linux/compat.h: Add netdev_### log macros | expand

Commit Message

Bin Meng July 26, 2018, 10:15 a.m. UTC
Currently there are two ethernet drivers (mvneta.c and mvpp2.c) that
has netdev_### (eg: netdev_dbg) log macros defined in its own driver
file. This adds these log macros in a common place linux/compat.h.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
---

 drivers/net/mvneta.c   |  8 --------
 drivers/net/mvpp2.c    | 10 ----------
 include/linux/compat.h | 19 +++++++++++++++++++
 3 files changed, 19 insertions(+), 18 deletions(-)

Comments

Joe Hershberger July 26, 2018, 6:51 p.m. UTC | #1
On Thu, Jul 26, 2018 at 5:15 AM, Bin Meng <bmeng.cn@gmail.com> wrote:
> Currently there are two ethernet drivers (mvneta.c and mvpp2.c) that
> has netdev_### (eg: netdev_dbg) log macros defined in its own driver
> file. This adds these log macros in a common place linux/compat.h.
>
> Signed-off-by: Bin Meng <bmeng.cn@gmail.com>

Acked-by: Joe Hershberger <joe.hershberger@ni.com>
Bin Meng Sept. 11, 2018, 10:05 a.m. UTC | #2
Hi Joe,

On Fri, Jul 27, 2018 at 2:52 AM Joe Hershberger <joe.hershberger@ni.com> wrote:
>
> On Thu, Jul 26, 2018 at 5:15 AM, Bin Meng <bmeng.cn@gmail.com> wrote:
> > Currently there are two ethernet drivers (mvneta.c and mvpp2.c) that
> > has netdev_### (eg: netdev_dbg) log macros defined in its own driver
> > file. This adds these log macros in a common place linux/compat.h.
> >
> > Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
>
> Acked-by: Joe Hershberger <joe.hershberger@ni.com>

When will the following be merged? Thanks!

http://patchwork.ozlabs.org/project/uboot/list/?series=57711
http://patchwork.ozlabs.org/project/uboot/list/?series=57715
http://patchwork.ozlabs.org/project/uboot/list/?series=58148
http://patchwork.ozlabs.org/project/uboot/list/?series=58485

Regards,
Bin
Joe Hershberger Sept. 14, 2018, 8:36 p.m. UTC | #3
Hi Bin,
On Tue, Sep 11, 2018 at 5:07 AM Bin Meng <bmeng.cn@gmail.com> wrote:
>
> Hi Joe,
>
> On Fri, Jul 27, 2018 at 2:52 AM Joe Hershberger <joe.hershberger@ni.com> wrote:
> >
> > On Thu, Jul 26, 2018 at 5:15 AM, Bin Meng <bmeng.cn@gmail.com> wrote:
> > > Currently there are two ethernet drivers (mvneta.c and mvpp2.c) that
> > > has netdev_### (eg: netdev_dbg) log macros defined in its own driver
> > > file. This adds these log macros in a common place linux/compat.h.
> > >
> > > Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
> >
> > Acked-by: Joe Hershberger <joe.hershberger@ni.com>
>
> When will the following be merged? Thanks!

Now that we have a release, I'll try to get them in my queue next week.

> http://patchwork.ozlabs.org/project/uboot/list/?series=57711
> http://patchwork.ozlabs.org/project/uboot/list/?series=57715
> http://patchwork.ozlabs.org/project/uboot/list/?series=58148
> http://patchwork.ozlabs.org/project/uboot/list/?series=58485
>
> Regards,
> Bin
> _______________________________________________
> U-Boot mailing list
> U-Boot@lists.denx.de
> https://lists.denx.de/listinfo/u-boot
Bin Meng Oct. 7, 2018, 12:53 p.m. UTC | #4
Hi Joe,

On Sat, Sep 15, 2018 at 4:37 AM Joe Hershberger <joe.hershberger@ni.com> wrote:
>
> Hi Bin,
> On Tue, Sep 11, 2018 at 5:07 AM Bin Meng <bmeng.cn@gmail.com> wrote:
> >
> > Hi Joe,
> >
> > On Fri, Jul 27, 2018 at 2:52 AM Joe Hershberger <joe.hershberger@ni.com> wrote:
> > >
> > > On Thu, Jul 26, 2018 at 5:15 AM, Bin Meng <bmeng.cn@gmail.com> wrote:
> > > > Currently there are two ethernet drivers (mvneta.c and mvpp2.c) that
> > > > has netdev_### (eg: netdev_dbg) log macros defined in its own driver
> > > > file. This adds these log macros in a common place linux/compat.h.
> > > >
> > > > Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
> > >
> > > Acked-by: Joe Hershberger <joe.hershberger@ni.com>
> >
> > When will the following be merged? Thanks!
>
> Now that we have a release, I'll try to get them in my queue next week.
>

ping ?

> > http://patchwork.ozlabs.org/project/uboot/list/?series=57711
> > http://patchwork.ozlabs.org/project/uboot/list/?series=57715
> > http://patchwork.ozlabs.org/project/uboot/list/?series=58148
> > http://patchwork.ozlabs.org/project/uboot/list/?series=58485

Regards,
Bin
Joe Hershberger Oct. 9, 2018, 8:39 p.m. UTC | #5
On Sun, Oct 7, 2018 at 7:53 AM Bin Meng <bmeng.cn@gmail.com> wrote:
>
> Hi Joe,
>
> On Sat, Sep 15, 2018 at 4:37 AM Joe Hershberger <joe.hershberger@ni.com> wrote:
> >
> > Hi Bin,
> > On Tue, Sep 11, 2018 at 5:07 AM Bin Meng <bmeng.cn@gmail.com> wrote:
> > >
> > > Hi Joe,
> > >
> > > On Fri, Jul 27, 2018 at 2:52 AM Joe Hershberger <joe.hershberger@ni.com> wrote:
> > > >
> > > > On Thu, Jul 26, 2018 at 5:15 AM, Bin Meng <bmeng.cn@gmail.com> wrote:
> > > > > Currently there are two ethernet drivers (mvneta.c and mvpp2.c) that
> > > > > has netdev_### (eg: netdev_dbg) log macros defined in its own driver
> > > > > file. This adds these log macros in a common place linux/compat.h.
> > > > >
> > > > > Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
> > > >
> > > > Acked-by: Joe Hershberger <joe.hershberger@ni.com>
> > >
> > > When will the following be merged? Thanks!
> >
> > Now that we have a release, I'll try to get them in my queue next week.
> >
>
> ping ?

Part of my current test building on travis:
https://travis-ci.org/jhershbe/u-boot/builds/439322261

> > > http://patchwork.ozlabs.org/project/uboot/list/?series=57711
> > > http://patchwork.ozlabs.org/project/uboot/list/?series=57715
> > > http://patchwork.ozlabs.org/project/uboot/list/?series=58148
> > > http://patchwork.ozlabs.org/project/uboot/list/?series=58485
>
> Regards,
> Bin
> _______________________________________________
> U-Boot mailing list
> U-Boot@lists.denx.de
> https://lists.denx.de/listinfo/u-boot
Bin Meng Oct. 11, 2018, 2:35 p.m. UTC | #6
Hi Joe,

On Wed, Oct 10, 2018 at 4:39 AM Joe Hershberger <joe.hershberger@ni.com> wrote:
>
> On Sun, Oct 7, 2018 at 7:53 AM Bin Meng <bmeng.cn@gmail.com> wrote:
> >
> > Hi Joe,
> >
> > On Sat, Sep 15, 2018 at 4:37 AM Joe Hershberger <joe.hershberger@ni.com> wrote:
> > >
> > > Hi Bin,
> > > On Tue, Sep 11, 2018 at 5:07 AM Bin Meng <bmeng.cn@gmail.com> wrote:
> > > >
> > > > Hi Joe,
> > > >
> > > > On Fri, Jul 27, 2018 at 2:52 AM Joe Hershberger <joe.hershberger@ni.com> wrote:
> > > > >
> > > > > On Thu, Jul 26, 2018 at 5:15 AM, Bin Meng <bmeng.cn@gmail.com> wrote:
> > > > > > Currently there are two ethernet drivers (mvneta.c and mvpp2.c) that
> > > > > > has netdev_### (eg: netdev_dbg) log macros defined in its own driver
> > > > > > file. This adds these log macros in a common place linux/compat.h.
> > > > > >
> > > > > > Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
> > > > >
> > > > > Acked-by: Joe Hershberger <joe.hershberger@ni.com>
> > > >
> > > > When will the following be merged? Thanks!
> > >
> > > Now that we have a release, I'll try to get them in my queue next week.
> > >
> >
> > ping ?
>
> Part of my current test building on travis:
> https://travis-ci.org/jhershbe/u-boot/builds/439322261
>

Please let me know when the PR will be sent. I have some patches that
are dependent on these. Thanks!

Regards,
Bin
Joe Hershberger Oct. 11, 2018, 7:24 p.m. UTC | #7
Hi Bin,

https://patchwork.ozlabs.org/patch/949577/ was applied to http://git.denx.de/?p=u-boot/u-boot-net.git

Thanks!
-Joe
diff mbox series

Patch

diff --git a/drivers/net/mvneta.c b/drivers/net/mvneta.c
index ab697b9..8cb04b5 100644
--- a/drivers/net/mvneta.c
+++ b/drivers/net/mvneta.c
@@ -34,14 +34,6 @@  DECLARE_GLOBAL_DATA_PTR;
 # error Marvell mvneta requires PHYLIB
 #endif
 
-/* Some linux -> U-Boot compatibility stuff */
-#define netdev_err(dev, fmt, args...)		\
-	printf(fmt, ##args)
-#define netdev_warn(dev, fmt, args...)		\
-	printf(fmt, ##args)
-#define netdev_info(dev, fmt, args...)		\
-	printf(fmt, ##args)
-
 #define CONFIG_NR_CPUS		1
 #define ETH_HLEN		14	/* Total octets in header */
 
diff --git a/drivers/net/mvpp2.c b/drivers/net/mvpp2.c
index 62c0c2b..5c1f5fc 100644
--- a/drivers/net/mvpp2.c
+++ b/drivers/net/mvpp2.c
@@ -35,16 +35,6 @@ 
 
 DECLARE_GLOBAL_DATA_PTR;
 
-/* Some linux -> U-Boot compatibility stuff */
-#define netdev_err(dev, fmt, args...)		\
-	printf(fmt, ##args)
-#define netdev_warn(dev, fmt, args...)		\
-	printf(fmt, ##args)
-#define netdev_info(dev, fmt, args...)		\
-	printf(fmt, ##args)
-#define netdev_dbg(dev, fmt, args...)		\
-	printf(fmt, ##args)
-
 #define ETH_ALEN	6		/* Octets in one ethernet addr	*/
 
 #define __verify_pcpu_ptr(ptr)						\
diff --git a/include/linux/compat.h b/include/linux/compat.h
index 6e3feb6..d0f51ba 100644
--- a/include/linux/compat.h
+++ b/include/linux/compat.h
@@ -43,6 +43,25 @@  extern struct p_current *current;
 #define dev_warn(dev, fmt, args...)		\
 	printf(fmt, ##args)
 
+#define netdev_emerg(dev, fmt, args...)		\
+	printf(fmt, ##args)
+#define netdev_alert(dev, fmt, args...)		\
+	printf(fmt, ##args)
+#define netdev_crit(dev, fmt, args...)		\
+	printf(fmt, ##args)
+#define netdev_err(dev, fmt, args...)		\
+	printf(fmt, ##args)
+#define netdev_warn(dev, fmt, args...)		\
+	printf(fmt, ##args)
+#define netdev_notice(dev, fmt, args...)	\
+	printf(fmt, ##args)
+#define netdev_info(dev, fmt, args...)		\
+	printf(fmt, ##args)
+#define netdev_dbg(dev, fmt, args...)		\
+	debug(fmt, ##args)
+#define netdev_vdbg(dev, fmt, args...)		\
+	debug(fmt, ##args)
+
 #define GFP_ATOMIC ((gfp_t) 0)
 #define GFP_KERNEL ((gfp_t) 0)
 #define GFP_NOFS ((gfp_t) 0)