lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1365873936-9521-1-git-send-email-festevam@gmail.com>
Date:	Sat, 13 Apr 2013 14:25:36 -0300
From:	Fabio Estevam <festevam@...il.com>
To:	davem@...emloft.net
Cc:	Frank.Li@...escale.com, netdev@...r.kernel.org, joe@...ches.com,
	Fabio Estevam <fabio.estevam@...escale.com>
Subject: [PATCH v2] fec: Fix PHC device log

From: Fabio Estevam <fabio.estevam@...escale.com>

Currently when booting a mx6 device we get the following on boot:

registered PHC device on eth%d

Fix it by printing the network device name only after it gets registered, so
that the following can be read now:

fec 2188000.ethernet eth0: registered PHC device 0

Signed-off-by: Fabio Estevam <fabio.estevam@...escale.com>
---
Changes since v1:
- Use netdev_info
- Only print the interface name after it gets registered.

 drivers/net/ethernet/freescale/fec_main.c |    3 +++
 drivers/net/ethernet/freescale/fec_ptp.c  |    2 --
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/freescale/fec_main.c b/drivers/net/ethernet/freescale/fec_main.c
index 806a56d..e8858a6 100644
--- a/drivers/net/ethernet/freescale/fec_main.c
+++ b/drivers/net/ethernet/freescale/fec_main.c
@@ -1858,6 +1858,9 @@ fec_probe(struct platform_device *pdev)
 	if (ret)
 		goto failed_register;
 
+	if (fep->bufdesc_ex && fep->ptp_clock)
+		netdev_info(ndev, "registered PHC device %d\n", fep->dev_id);
+
 	return 0;
 
 failed_register:
diff --git a/drivers/net/ethernet/freescale/fec_ptp.c b/drivers/net/ethernet/freescale/fec_ptp.c
index 1f17ca0..e040c8b 100644
--- a/drivers/net/ethernet/freescale/fec_ptp.c
+++ b/drivers/net/ethernet/freescale/fec_ptp.c
@@ -379,7 +379,5 @@ void fec_ptp_init(struct net_device *ndev, struct platform_device *pdev)
 	if (IS_ERR(fep->ptp_clock)) {
 		fep->ptp_clock = NULL;
 		pr_err("ptp_clock_register failed\n");
-	} else {
-		pr_info("registered PHC device on %s\n", ndev->name);
 	}
 }
-- 
1.7.9.5

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ