]> git.baikalelectronics.ru Git - kernel.git/commit
net: hns3: change the method of obtaining default ptp cycle
authorYufeng Mo <moyufeng@huawei.com>
Tue, 27 Jul 2021 14:03:50 +0000 (22:03 +0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 27 Jul 2021 19:59:32 +0000 (20:59 +0100)
commit84f251c3bcf47a96b485b5b98e709a4a3b3d6ce8
treed7ca4107040832bebf59fbddcac93332304758a9
parent8c3b7082072d81d53c9b94e9c8717c525f180794
net: hns3: change the method of obtaining default ptp cycle

The ptp cycle is related to the hardware, so it may cause compatibility
issues if a fixed value is used in driver. Therefore, the method of
obtaining this value is changed to read from the register rather than
use a fixed value in driver.

Fixes: 541a8362ff41 ("net: hns3: add support for PTP")
Signed-off-by: Yufeng Mo <moyufeng@huawei.com>
Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_ptp.c
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_ptp.h