Home
last modified time | relevance | path

Searched refs:scaled_ppm (Results 1 – 25 of 25) sorted by relevance

/drivers/net/ethernet/marvell/octeontx2/af/
Dptp.c102 static int ptp_adjfine(struct ptp *ptp, long scaled_ppm) in ptp_adjfine() argument
109 if (scaled_ppm < 0) { in ptp_adjfine()
111 scaled_ppm = -scaled_ppm; in ptp_adjfine()
130 ppb = 1 + scaled_ppm; in ptp_adjfine()
272 err = ptp_adjfine(rvu->ptp, req->scaled_ppm); in rvu_mbox_handler_ptp_op()
Dmbox.h1390 s64 scaled_ppm; member
/drivers/net/ethernet/cavium/common/
Dcavium_ptp.c93 static int cavium_ptp_adjfine(struct ptp_clock_info *ptp_info, long scaled_ppm) in cavium_ptp_adjfine() argument
102 if (scaled_ppm < 0) { in cavium_ptp_adjfine()
104 scaled_ppm = -scaled_ppm; in cavium_ptp_adjfine()
123 adj = comp * scaled_ppm; in cavium_ptp_adjfine()
/drivers/net/ethernet/mscc/
Docelot_ptp.c124 int ocelot_ptp_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in ocelot_ptp_adjfine() argument
133 if (!scaled_ppm) in ocelot_ptp_adjfine()
136 if (scaled_ppm < 0) { in ocelot_ptp_adjfine()
138 scaled_ppm = -scaled_ppm; in ocelot_ptp_adjfine()
142 do_div(adj, scaled_ppm); in ocelot_ptp_adjfine()
/drivers/net/ethernet/marvell/mvpp2/
Dmvpp2_tai.c164 static int mvpp22_tai_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in mvpp22_tai_adjfine() argument
173 neg_adj = scaled_ppm < 0; in mvpp22_tai_adjfine()
175 scaled_ppm = -scaled_ppm; in mvpp22_tai_adjfine()
177 val = mvpp22_calc_frac_ppm(tai, scaled_ppm); in mvpp22_tai_adjfine()
/drivers/net/dsa/hirschmann/
Dhellcreek_ptp.c126 static int hellcreek_ptp_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in hellcreek_ptp_adjfine() argument
133 if (scaled_ppm < 0) { in hellcreek_ptp_adjfine()
135 scaled_ppm = -scaled_ppm; in hellcreek_ptp_adjfine()
150 adj = scaled_ppm; in hellcreek_ptp_adjfine()
/drivers/net/ethernet/marvell/octeontx2/nic/
Dotx2_ptp.c11 static int otx2_ptp_adjfine(struct ptp_clock_info *ptp_info, long scaled_ppm) in otx2_ptp_adjfine() argument
25 req->scaled_ppm = scaled_ppm; in otx2_ptp_adjfine()
/drivers/net/dsa/mv88e6xxx/
Dptp.c199 static int mv88e6xxx_ptp_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in mv88e6xxx_ptp_adjfine() argument
207 if (scaled_ppm < 0) { in mv88e6xxx_ptp_adjfine()
209 scaled_ppm = -scaled_ppm; in mv88e6xxx_ptp_adjfine()
214 adj *= scaled_ppm; in mv88e6xxx_ptp_adjfine()
/drivers/net/ethernet/cadence/
Dmacb_ptp.c117 static int gem_ptp_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in gem_ptp_adjfine() argument
125 if (scaled_ppm < 0) { in gem_ptp_adjfine()
127 scaled_ppm = -scaled_ppm; in gem_ptp_adjfine()
136 adj = (u64)scaled_ppm * word; in gem_ptp_adjfine()
/drivers/ptp/
Dptp_qoriq.c177 int ptp_qoriq_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in ptp_qoriq_adjfine() argument
185 if (scaled_ppm < 0) { in ptp_qoriq_adjfine()
187 scaled_ppm = -scaled_ppm; in ptp_qoriq_adjfine()
198 diff = mul_u64_u64_div_u64(adj, scaled_ppm, 32768000000); in ptp_qoriq_adjfine()
Dptp_idt82p33.c319 static int _idt82p33_adjfine(struct idt82p33_channel *channel, long scaled_ppm) in _idt82p33_adjfine() argument
326 if (scaled_ppm == channel->current_freq_ppb) in _idt82p33_adjfine()
343 fcw = scaled_ppm * 244140625ULL; in _idt82p33_adjfine()
360 channel->current_freq_ppb = scaled_ppm; in _idt82p33_adjfine()
747 static int idt82p33_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in idt82p33_adjfine() argument
755 err = _idt82p33_adjfine(channel, scaled_ppm); in idt82p33_adjfine()
Dptp_vclock.c16 static int ptp_vclock_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in ptp_vclock_adjfine() argument
22 adj = (s64)scaled_ppm << PTP_VCLOCK_FADJ_SHIFT; in ptp_vclock_adjfine()
Dptp_clockmatrix.c1454 static int _idtcm_adjfine(struct idtcm_channel *channel, long scaled_ppm) in _idtcm_adjfine() argument
1483 fcw = scaled_ppm * 244140625ULL; in _idtcm_adjfine()
1626 static int idtcm_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in idtcm_adjfine() argument
1634 err = _idtcm_adjfine(channel, scaled_ppm); in idtcm_adjfine()
Dptp_ocp.c458 ptp_ocp_null_adjfine(struct ptp_clock_info *ptp_info, long scaled_ppm) in ptp_ocp_null_adjfine() argument
460 if (scaled_ppm == 0) in ptp_ocp_null_adjfine()
/drivers/net/ethernet/intel/ice/
Dice_ptp.c456 static int ice_ptp_adjfine(struct ptp_clock_info *info, long scaled_ppm) in ice_ptp_adjfine() argument
467 if (scaled_ppm < 0) { in ice_ptp_adjfine()
469 scaled_ppm = -scaled_ppm; in ice_ptp_adjfine()
472 while ((u64)scaled_ppm > div64_u64(U64_MAX, incval)) { in ice_ptp_adjfine()
476 scaled_ppm >>= 2; in ice_ptp_adjfine()
480 freq = (incval * (u64)scaled_ppm) >> 16; in ice_ptp_adjfine()
/drivers/net/ethernet/intel/igc/
Digc_ptp.c47 static int igc_ptp_adjfine_i225(struct ptp_clock_info *ptp, long scaled_ppm) in igc_ptp_adjfine_i225() argument
56 if (scaled_ppm < 0) { in igc_ptp_adjfine_i225()
58 scaled_ppm = -scaled_ppm; in igc_ptp_adjfine_i225()
60 rate = scaled_ppm; in igc_ptp_adjfine_i225()
/drivers/net/ethernet/microchip/
Dlan743x_ptp.c321 static int lan743x_ptpci_adjfine(struct ptp_clock_info *ptpci, long scaled_ppm) in lan743x_ptpci_adjfine() argument
331 if ((scaled_ppm < (-LAN743X_PTP_MAX_FINE_ADJ_IN_SCALED_PPM)) || in lan743x_ptpci_adjfine()
332 scaled_ppm > LAN743X_PTP_MAX_FINE_ADJ_IN_SCALED_PPM) { in lan743x_ptpci_adjfine()
335 if (scaled_ppm > 0) { in lan743x_ptpci_adjfine()
336 u64_delta = (u64)scaled_ppm; in lan743x_ptpci_adjfine()
339 u64_delta = (u64)(-scaled_ppm); in lan743x_ptpci_adjfine()
/drivers/net/ethernet/intel/igb/
Digb_ptp.c223 static int igb_ptp_adjfine_82580(struct ptp_clock_info *ptp, long scaled_ppm) in igb_ptp_adjfine_82580() argument
232 if (scaled_ppm < 0) { in igb_ptp_adjfine_82580()
234 scaled_ppm = -scaled_ppm; in igb_ptp_adjfine_82580()
236 rate = scaled_ppm; in igb_ptp_adjfine_82580()
/drivers/net/phy/
Ddp83640.c374 static int ptp_dp83640_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in ptp_dp83640_adjfine() argument
383 if (scaled_ppm < 0) { in ptp_dp83640_adjfine()
385 scaled_ppm = -scaled_ppm; in ptp_dp83640_adjfine()
387 rate = scaled_ppm; in ptp_dp83640_adjfine()
Dnxp-c45-tja11xx.c281 static int nxp_c45_ptp_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in nxp_c45_ptp_adjfine() argument
284 s32 ppb = scaled_ppm_to_ppb(scaled_ppm); in nxp_c45_ptp_adjfine()
/drivers/net/phy/mscc/
Dmscc_ptp.c610 static int vsc85xx_adjfine(struct ptp_clock_info *info, long scaled_ppm) in vsc85xx_adjfine() argument
618 if (abs(scaled_ppm) < 66 || abs(scaled_ppm) > 65536UL * 1000000UL) in vsc85xx_adjfine()
621 adj = div64_u64(1000000ULL * 65536ULL, abs(scaled_ppm)); in vsc85xx_adjfine()
626 val |= scaled_ppm > 0 ? PTP_AUTO_ADJ_ADD_1NS : PTP_AUTO_ADJ_SUB_1NS; in vsc85xx_adjfine()
/drivers/net/ethernet/pensando/ionic/
Dionic_phc.c317 static int ionic_phc_adjfine(struct ptp_clock_info *info, long scaled_ppm) in ionic_phc_adjfine() argument
330 adj = (s64)scaled_ppm * phc->init_cc_mult; in ionic_phc_adjfine()
/drivers/net/dsa/sja1105/
Dsja1105_ptp.c616 static int sja1105_ptp_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in sja1105_ptp_adjfine() argument
625 clkrate = (s64)scaled_ppm * SJA1105_CC_MULT_NUM; in sja1105_ptp_adjfine()
/drivers/net/ethernet/mellanox/mlxsw/
Dspectrum_ptp.c151 static int mlxsw_sp1_ptp_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in mlxsw_sp1_ptp_adjfine() argument
160 ppb = scaled_ppm_to_ppb(scaled_ppm); in mlxsw_sp1_ptp_adjfine()
/drivers/net/ethernet/aquantia/atlantic/
Daq_ptp.c278 static int aq_ptp_adjfine(struct ptp_clock_info *ptp, long scaled_ppm) in aq_ptp_adjfine() argument
285 scaled_ppm_to_ppb(scaled_ppm)); in aq_ptp_adjfine()