const void *dma;
        const void *mac;
        const void *hwtimestamp;
+       const void *ptp;
        const void *mode;
        const void *tc;
        const void *mmc;
                .dma = &dwmac100_dma_ops,
                .mac = &dwmac100_ops,
                .hwtimestamp = &stmmac_ptp,
+               .ptp = &stmmac_ptp_clock_ops,
                .mode = NULL,
                .tc = NULL,
                .mmc = &dwmac_mmc_ops,
                .dma = &dwmac1000_dma_ops,
                .mac = &dwmac1000_ops,
                .hwtimestamp = &stmmac_ptp,
+               .ptp = &stmmac_ptp_clock_ops,
                .mode = NULL,
                .tc = NULL,
                .mmc = &dwmac_mmc_ops,
                .dma = &dwmac4_dma_ops,
                .mac = &dwmac4_ops,
                .hwtimestamp = &stmmac_ptp,
+               .ptp = &stmmac_ptp_clock_ops,
                .mode = NULL,
                .tc = &dwmac4_tc_ops,
                .mmc = &dwmac_mmc_ops,
                .dma = &dwmac4_dma_ops,
                .mac = &dwmac410_ops,
                .hwtimestamp = &stmmac_ptp,
+               .ptp = &stmmac_ptp_clock_ops,
                .mode = &dwmac4_ring_mode_ops,
                .tc = &dwmac510_tc_ops,
                .mmc = &dwmac_mmc_ops,
                .dma = &dwmac410_dma_ops,
                .mac = &dwmac410_ops,
                .hwtimestamp = &stmmac_ptp,
+               .ptp = &stmmac_ptp_clock_ops,
                .mode = &dwmac4_ring_mode_ops,
                .tc = &dwmac510_tc_ops,
                .mmc = &dwmac_mmc_ops,
                .dma = &dwmac410_dma_ops,
                .mac = &dwmac510_ops,
                .hwtimestamp = &stmmac_ptp,
+               .ptp = &stmmac_ptp_clock_ops,
                .mode = &dwmac4_ring_mode_ops,
                .tc = &dwmac510_tc_ops,
                .mmc = &dwmac_mmc_ops,
                .dma = &dwxgmac210_dma_ops,
                .mac = &dwxgmac210_ops,
                .hwtimestamp = &stmmac_ptp,
+               .ptp = &stmmac_ptp_clock_ops,
                .mode = NULL,
                .tc = &dwxgmac_tc_ops,
                .mmc = &dwxgmac_mmc_ops,
                .dma = &dwxgmac210_dma_ops,
                .mac = &dwxlgmac2_ops,
                .hwtimestamp = &stmmac_ptp,
+               .ptp = &stmmac_ptp_clock_ops,
                .mode = NULL,
                .tc = &dwxgmac_tc_ops,
                .mmc = &dwxgmac_mmc_ops,
                priv->fpe_cfg.reg = entry->regs.fpe_reg;
                priv->ptpaddr = priv->ioaddr + entry->regs.ptp_off;
                priv->mmcaddr = priv->ioaddr + entry->regs.mmc_off;
+               memcpy(&priv->ptp_clock_ops, entry->ptp,
+                      sizeof(struct ptp_clock_info));
                if (entry->est)
                        priv->estaddr = priv->ioaddr + entry->regs.est_off;
 
 
 }
 
 /* structure describing a PTP hardware clock */
-static struct ptp_clock_info stmmac_ptp_clock_ops = {
+const struct ptp_clock_info stmmac_ptp_clock_ops = {
        .owner = THIS_MODULE,
        .name = "stmmac ptp",
        .max_adj = 62500000,
        if (priv->plat->has_gmac4 && priv->plat->clk_ptp_rate)
                priv->plat->cdc_error_adj = (2 * NSEC_PER_SEC) / priv->plat->clk_ptp_rate;
 
-       priv->ptp_clock_ops = stmmac_ptp_clock_ops;
-
        priv->ptp_clock_ops.n_per_out = priv->dma_cap.pps_out_num;
        priv->ptp_clock_ops.n_ext_ts = priv->dma_cap.aux_snapshot_n;