nvethernet: unregister HW timestamp source in close

Issue: ether_get_ptptime() is registered as a callback
       function to read ptp time using tegra_register_hwtime_source.
       But it is not unregistered before interface is brought down.
       This causes clients to still query for timestamp even though
       interface is down and MAC is in reset, resulting in CBB errors.
Fix:   Unregister the callback function in ether_close()

Bug 200556936

Change-Id: Idb5b698460f02101c931fd64fbdfc9c06949e05a
Signed-off-by: Bhadram Varka <vbhadram@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/2210705
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Bhadram Varka
2019-10-03 14:54:04 +05:30
committed by Revanth Kumar Uppala
parent 05e0c8f037
commit 1c6a1e3f7b
3 changed files with 4 additions and 1 deletions

View File

@@ -17,6 +17,7 @@
#ifndef ETHER_LINUX_H
#define ETHER_LINUX_H
#include <linux/platform/tegra/ptp-notifier.h>
#include <linux/ptp_clock_kernel.h>
#include <linux/platform_device.h>
#include <linux/etherdevice.h>