mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [next-net PATCH] drivers/net/ethernet/intel/e1000e: fix unregistered net_device ethX name output by e1000e
@ 2012-06-06 14:57 Ethan Zhao
  2012-06-07  0:41 ` [E1000-devel] " Jeff Kirsher
  0 siblings, 1 reply; 4+ messages in thread
From: Ethan Zhao @ 2012-06-06 14:57 UTC (permalink / raw)
  To: eric.dumazet, linux.nics, e1000-devel; +Cc: LKML

commit ca3ccc6835943287b6f69e973c126a02bc4de409
Author: ethan.zhao <ethan.kernel@gmail.com>
Date:   Wed Jun 6 07:32:11 2012 -0700

        modified:   drivers/net/ethernet/intel/e1000e/param.c

    While e1000e_check_options() is called, netdev is not registered, so the
    e1000e driver will print out confused ethernet interface name
(unregistered net_device) :

    e1000e 0000:04:00.0:(unregistered net_device): Interrupt
Throttling Rate (ints/sec) set to dynamic conservative mode

    So change e_info() back to dev_printk() by simply redefine the
e_info macro used by
    e1000e_check_options() and e1000_validate_option

    after applied this patch, we got:

    e1000e 0000:04:00.0: Interrupt Throttling Rate (ints/sec) set to
dynamic conservative mode
    e1000e 0000:04:00.0: irq 95 for MSI/MSI-X

diff --git a/drivers/net/ethernet/intel/e1000e/param.c
b/drivers/net/ethernet/intel/e1000e/param.c
index 55cc156..0f4f9db 100644
--- a/drivers/net/ethernet/intel/e1000e/param.c
+++ b/drivers/net/ethernet/intel/e1000e/param.c
@@ -186,6 +186,17 @@ struct e1000_option {
        } arg;
 };

+
+/**
+ * For netdev is not registered here, will get (unregistered
net_device) such confused
+ * name, so change back to dev_printk() lazy redfine the e_info()
+ */
+#ifdef e_info
+#undef e_info
+#define e_info(format, arg...) \
+       dev_printk(KERN_INFO,&adapter->pdev->dev, format, ## arg)
+#endif
+
 static int __devinit e1000_validate_option(unsigned int *value,
                                           const struct e1000_option *opt,
                                           struct e1000_adapter *adapter)

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

end of thread, other threads:[~2012-06-08  0:55 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-06-06 14:57 [next-net PATCH] drivers/net/ethernet/intel/e1000e: fix unregistered net_device ethX name output by e1000e Ethan Zhao
2012-06-07  0:41 ` [E1000-devel] " Jeff Kirsher
2012-06-07  0:56   ` Allan, Bruce W
     [not found]     ` <CABawtvNAtJ=W=rztnizPz=ZXGcLoGHPNJn4XUZMQyQJQ46nooQ@mail.gmail.com>
     [not found]       ` <804857E1F29AAC47BF68C404FC60A18428444C0A@ORSMSX102.amr.corp.intel.com>
     [not found]         ` <9DA1E3A1-025A-474C-811A-957B57E74911@gmail.com>
     [not found]           ` <1339108741.21222.21.camel@jtkirshe-mobl>
2012-06-08  0:55             ` Ethan Zhao

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®