Home
last modified time | relevance | path

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

1234567

/linux/kernel/time/
H A Dvsyscall.c22 u64 nsec, sec; in update_vdso_data() local
43 nsec = tk->tkr_mono.xtime_nsec; in update_vdso_data()
46 nsec -= (((u64)NSEC_PER_SEC) << tk->tkr_mono.shift); in update_vdso_data()
49 vdso_ts->nsec = nsec; in update_vdso_data()
65 vdso_ts->nsec = nsec; in update_vdso_data()
70 vdso_ts->nsec = tk->tkr_raw.xtime_nsec; in update_vdso_data()
75 vdso_ts->nsec = tk->tkr_mono.xtime_nsec; in update_vdso_data()
83 u64 nsec; in update_vsyscall() local
95 vdso_ts->nsec = tk->tkr_mono.xtime_nsec; in update_vsyscall()
106 nsec = nsec + tk->wall_to_monotonic.tv_nsec; in update_vsyscall()
[all …]
H A Dtimecounter.c14 tc->nsec = start_tstamp; in timecounter_init()
54 u64 nsec; in timecounter_read() local
57 nsec = timecounter_read_delta(tc); in timecounter_read()
58 nsec += tc->nsec; in timecounter_read()
59 tc->nsec = nsec; in timecounter_read()
61 return nsec; in timecounter_read()
83 u64 nsec = tc->nsec, frac = tc->frac; in timecounter_cyc2time() local
92 nsec -= cc_cyc2ns_backwards(tc->cc, delta, tc->mask, frac); in timecounter_cyc2time()
94 nsec += cyclecounter_cyc2ns(tc->cc, delta, tc->mask, &frac); in timecounter_cyc2time()
97 return nsec; in timecounter_cyc2time()
H A Dtime.c497 while (nsec >= NSEC_PER_SEC) { in set_normalized_timespec64()
503 asm("" : "+rm"(nsec)); in set_normalized_timespec64()
504 nsec -= NSEC_PER_SEC; in set_normalized_timespec64()
507 while (nsec < 0) { in set_normalized_timespec64()
508 asm("" : "+rm"(nsec)); in set_normalized_timespec64()
509 nsec += NSEC_PER_SEC; in set_normalized_timespec64()
513 ts->tv_nsec = nsec; in set_normalized_timespec64()
528 if (likely(nsec > 0)) { in ns_to_timespec64()
531 } else if (nsec < 0) { in ns_to_timespec64()
624 nsec = 0; in timespec64_to_jiffies()
[all …]
/linux/Documentation/sound/designs/
H A Dtimestamping.rst163 playback: systime: 341053347 nsec, audio time 341062500 nsec, systime delta -9153
164 playback: systime: 426072447 nsec, audio time 426062500 nsec, systime delta 9947
165 playback: systime: 596899518 nsec, audio time 596895833 nsec, systime delta 3685
166 playback: systime: 681915317 nsec, audio time 681916666 nsec, systime delta -1349
167 playback: systime: 852741306 nsec, audio time 852750000 nsec, systime delta -8694
173 playback: systime: 341060004 nsec, audio time 341062791 nsec, systime delta -2787
174 playback: systime: 426242074 nsec, audio time 426244875 nsec, systime delta -2801
175 playback: systime: 597080992 nsec, audio time 597084583 nsec, systime delta -3591
176 playback: systime: 682084512 nsec, audio time 682088291 nsec, systime delta -3779
177 playback: systime: 852936229 nsec, audio time 852940916 nsec, systime delta -4687
[all …]
/linux/tools/testing/radix-tree/
H A Dbenchmark.c19 long long nsec; in benchmark_iter() local
42 if (loops == 1 && nsec * 5 < NSEC_PER_SEC) { in benchmark_iter()
43 loops = NSEC_PER_SEC / nsec / 4 + 1; in benchmark_iter()
48 nsec /= loops; in benchmark_iter()
49 return nsec; in benchmark_iter()
57 long long nsec; in benchmark_insert() local
70 size, step, nsec); in benchmark_insert()
78 long long nsec; in benchmark_tagging() local
91 size, step, nsec); in benchmark_tagging()
99 long long nsec; in benchmark_delete() local
[all …]
/linux/security/selinux/
H A Dnetnode.c45 struct netnode_security_struct nsec; member
121 if (node->nsec.family == family) in sel_netnode_find()
124 if (node->nsec.addr.ipv4 == *(const __be32 *)addr) in sel_netnode_find()
128 if (ipv6_addr_equal(&node->nsec.addr.ipv6, in sel_netnode_find()
149 switch (node->nsec.family) { in sel_netnode_insert()
199 *sid = node->nsec.sid; in sel_netnode_sid_slow()
210 new->nsec.addr.ipv4 = *(__be32 *)addr; in sel_netnode_sid_slow()
216 new->nsec.addr.ipv6 = *(struct in6_addr *)addr; in sel_netnode_sid_slow()
223 new->nsec.family = family; in sel_netnode_sid_slow()
224 new->nsec.sid = *sid; in sel_netnode_sid_slow()
[all …]
H A Dnetif.c34 struct netif_security_struct nsec; member
74 if (net_eq(netif->nsec.ns, ns) && in sel_netif_find()
75 netif->nsec.ifindex == ifindex) in sel_netif_find()
97 idx = sel_netif_hashfn(netif->nsec.ns, netif->nsec.ifindex); in sel_netif_insert()
152 *sid = netif->nsec.sid; in sel_netif_sid_slow()
161 new->nsec.ns = ns; in sel_netif_sid_slow()
162 new->nsec.ifindex = ifindex; in sel_netif_sid_slow()
163 new->nsec.sid = *sid; in sel_netif_sid_slow()
198 *sid = netif->nsec.sid; in sel_netif_sid()
/linux/arch/xtensa/include/asm/
H A Ddelay.h55 static inline void __ndelay(unsigned long nsec) in __ndelay() argument
61 unsigned long cycles = (nsec * (ccount_freq >> 15)) >> 15; in __ndelay()
67 static inline void ndelay(unsigned long nsec) in ndelay() argument
69 if (__builtin_constant_p(nsec) && nsec >= __MAX_NDELAY) in ndelay()
72 __ndelay(nsec); in ndelay()
/linux/tools/perf/scripts/python/
H A Dnetdev-times.py235 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm, vec)
241 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm, vec)
252 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
262 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
268 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
274 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
280 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
286 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
292 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
297 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
[all …]
H A Dpowerpc-hcalls.py173 def powerpc__hcall_exit(name, context, cpu, sec, nsec, pid, comm, callchain, argument
176 diff = nsecs(sec, nsec) - d_enter[cpu][opcode]
197 def powerpc__hcall_entry(event_name, context, cpu, sec, nsec, pid, comm, argument
200 d_enter[cpu][opcode] = nsecs(sec, nsec)
202 d_enter[cpu] = {opcode: nsecs(sec, nsec)}
/linux/drivers/net/ethernet/amd/xgbe/
H A Dxgbe-ptp.c130 u64 nsec; in xgbe_cc_read() local
132 nsec = pdata->hw_if.get_tstamp_time(pdata); in xgbe_cc_read()
134 return nsec; in xgbe_cc_read()
176 u64 nsec; in xgbe_gettime() local
180 nsec = timecounter_read(&pdata->tstamp_tc); in xgbe_gettime()
184 *ts = ns_to_timespec64(nsec); in xgbe_gettime()
196 u64 nsec; in xgbe_settime() local
198 nsec = timespec64_to_ns(ts); in xgbe_settime()
202 timecounter_init(&pdata->tstamp_tc, &pdata->tstamp_cc, nsec); in xgbe_settime()
/linux/lib/
H A Dcrc32test.c669 u64 nsec; in crc32c_test() local
687 nsec = ktime_get_ns(); in crc32c_test()
693 nsec = ktime_get_ns() - nsec; in crc32c_test()
703 bytes, nsec); in crc32c_test()
749 u64 nsec; in crc32_test() local
770 nsec = ktime_get_ns(); in crc32_test()
780 nsec = ktime_get_ns() - nsec; in crc32_test()
791 bytes, nsec); in crc32_test()
/linux/tools/testing/selftests/ptp/
H A Dtestptp.c113 return t->sec * NSEC_PER_SEC + t->nsec; in pctns()
438 event.t.sec, event.t.nsec); in main()
488 perout_request.period.nsec = perout % NSEC_PER_SEC; in main()
501 perout_request.start.nsec = 0; in main()
548 (pct+2*i)->sec, (pct+2*i)->nsec); in main()
550 (pct+2*i+1)->sec, (pct+2*i+1)->nsec); in main()
552 (pct+2*i+2)->sec, (pct+2*i+2)->nsec); in main()
578 i, soe->ts[i][0].sec, soe->ts[i][0].nsec); in main()
580 soe->ts[i][1].sec, soe->ts[i][1].nsec); in main()
582 soe->ts[i][2].sec, soe->ts[i][2].nsec); in main()
[all …]
/linux/tools/testing/selftests/mqueue/
H A Dmq_perf_tests.c360 send_total.tv_nsec += nsec; \
367 recv_total.tv_nsec += nsec; \
433 unsigned long long nsec; in perf_test_thread() local
467 printf("\t\t\t\t\t\t%lld nsec/msg\n", nsec); in perf_test_thread()
472 printf("\t\t\t\t\t\t%lld nsec/msg\n", nsec); in perf_test_thread()
493 printf("done.\t\t%lld.%llds\n", nsec / 1000000000, in perf_test_thread()
494 nsec % 1000000000); in perf_test_thread()
506 printf("\t\t\t\t\t\t%lld nsec/msg\n", nsec); in perf_test_thread()
511 printf("\t\t\t\t\t\t%lld nsec/msg\n", nsec); in perf_test_thread()
519 printf("done.\t\t%lld.%llds\n", nsec / 1000000000, in perf_test_thread()
[all …]
/linux/drivers/pps/
H A Dkapi.c29 ts->nsec += offset->nsec; in pps_add_offset()
30 while (ts->nsec >= NSEC_PER_SEC) { in pps_add_offset()
31 ts->nsec -= NSEC_PER_SEC; in pps_add_offset()
34 while (ts->nsec < 0) { in pps_add_offset()
35 ts->nsec += NSEC_PER_SEC; in pps_add_offset()
164 struct pps_ktime ts_real = { .sec = 0, .nsec = 0, .flags = 0 }; in pps_event()
/linux/drivers/net/ethernet/stmicro/stmmac/
H A Dstmmac_hwtstamp.c105 static int init_systime(void __iomem *ioaddr, u32 sec, u32 nsec) in init_systime() argument
110 writel(nsec, ioaddr + PTP_STNSUR); in init_systime()
146 static int adjust_systime(void __iomem *ioaddr, u32 sec, u32 nsec, in adjust_systime() argument
162 nsec = (PTP_DIGITAL_ROLLOVER_MODE - nsec); in adjust_systime()
164 nsec = (PTP_BINARY_ROLLOVER_MODE - nsec); in adjust_systime()
168 value = (add_sub << PTP_STNSUR_ADDSUB_SHIFT) | nsec; in adjust_systime()
/linux/lib/vdso/
H A Dgettimeofday.c99 ns = vdso_calc_ns(vd, cycles, vdso_ts->nsec); in do_hres_timens()
105 ns += offs->nsec; in do_hres_timens()
167 ns = vdso_calc_ns(vd, cycles, vdso_ts->nsec); in do_hres()
188 u64 nsec; in do_coarse_timens() local
195 nsec = vdso_ts->nsec; in do_coarse_timens()
200 nsec += offs->nsec; in do_coarse_timens()
206 ts->tv_sec = sec + __iter_div_u64_rem(nsec, NSEC_PER_SEC, &nsec); in do_coarse_timens()
207 ts->tv_nsec = nsec; in do_coarse_timens()
238 ts->tv_nsec = vdso_ts->nsec; in do_coarse()
/linux/tools/testing/selftests/net/tcp_ao/
H A Dbench-lookups.c96 uint64_t nsec; in measure_call() local
106 nsec = (end.tv_sec - start.tv_sec) * NSEC_PER_SEC; in measure_call()
108 nsec += end.tv_nsec - start.tv_nsec; in measure_call()
110 nsec -= start.tv_nsec - end.tv_nsec; in measure_call()
113 st->min = st->max = nsec; in measure_call()
115 if (st->min > nsec) in measure_call()
116 st->min = nsec; in measure_call()
117 if (st->max < nsec) in measure_call()
118 st->max = nsec; in measure_call()
123 delta = (double)nsec - st->mean; in measure_call()
[all …]
/linux/drivers/net/ethernet/mellanox/mlxsw/
H A Dspectrum_ptp.c154 u64 cycles = (u64) nsec; in mlxsw_sp1_ptp_ns2cycles()
208 u64 nsec; in mlxsw_sp1_ptp_adjtime() local
223 u64 cycles, nsec; in mlxsw_sp1_ptp_gettimex() local
230 *ts = ns_to_timespec64(nsec); in mlxsw_sp1_ptp_gettimex()
394 u64 nsec; in mlxsw_sp2_ptp_adjtime() local
397 nsec += delta; in mlxsw_sp2_ptp_adjtime()
414 u64 nsec; in mlxsw_sp2_ptp_gettimex() local
417 *ts = ns_to_timespec64(nsec); in mlxsw_sp2_ptp_gettimex()
620 u64 nsec; in mlxsw_sp1_packet_timestamp() local
1407 u64 ts_sec, ts_nsec, nsec; in mlxsw_sp2_ptp_hwtstamp_fill() local
[all …]
/linux/drivers/ptp/
H A Dptp_chardev.c274 perout->on.nsec > perout->period.nsec)) { in ptp_ioctl()
287 perout->phase.nsec >= perout->period.nsec)) { in ptp_ioctl()
338 precise_offset.device.nsec = ts.tv_nsec; in ptp_ioctl()
341 precise_offset.sys_realtime.nsec = ts.tv_nsec; in ptp_ioctl()
344 precise_offset.sys_monoraw.nsec = ts.tv_nsec; in ptp_ioctl()
372 extoff->ts[i][0].nsec = sts.pre_ts.tv_nsec; in ptp_ioctl()
374 extoff->ts[i][1].nsec = ts.tv_nsec; in ptp_ioctl()
376 extoff->ts[i][2].nsec = sts.post_ts.tv_nsec; in ptp_ioctl()
398 pct->nsec = ts.tv_nsec; in ptp_ioctl()
407 pct->nsec = ts.tv_nsec; in ptp_ioctl()
[all …]
/linux/fs/adfs/
H A Dinode.c181 s64 nsec; in adfs_adfs2unix_time() local
192 nsec = (((s64) high << 32) | (s64) low) * 10000000; /* cs to ns */ in adfs_adfs2unix_time()
195 if (nsec < nsec_unix_epoch_diff_risc_os_epoch) in adfs_adfs2unix_time()
199 nsec -= nsec_unix_epoch_diff_risc_os_epoch; in adfs_adfs2unix_time()
201 *tv = ns_to_timespec64(nsec); in adfs_adfs2unix_time()
217 s64 cs, nsec = timespec64_to_ns(ts); in adfs_unix2adfs_time() local
220 nsec += nsec_unix_epoch_diff_risc_os_epoch; in adfs_unix2adfs_time()
223 cs = div_s64(nsec, 10000000); in adfs_unix2adfs_time()
/linux/drivers/gpu/drm/nouveau/nvkm/subdev/pmu/
H A Dmemx.c108 u32 addr, u32 mask, u32 data, u32 nsec) in nvkm_memx_wait() argument
111 addr, mask, data, nsec); in nvkm_memx_wait()
112 memx_cmd(memx, MEMX_WAIT, 4, (u32[]){ addr, mask, data, nsec }); in nvkm_memx_wait()
117 nvkm_memx_nsec(struct nvkm_memx *memx, u32 nsec) in nvkm_memx_nsec() argument
119 nvkm_debug(&memx->pmu->subdev, " DELAY = %d ns\n", nsec); in nvkm_memx_nsec()
120 memx_cmd(memx, MEMX_DELAY, 1, (u32[]){ nsec }); in nvkm_memx_nsec()
/linux/drivers/gpu/drm/nouveau/nvkm/subdev/timer/
H A Dbase.c54 nvkm_timer_wait_init(struct nvkm_device *device, u64 nsec, in nvkm_timer_wait_init() argument
58 wait->limit = nsec; in nvkm_timer_wait_init()
106 nvkm_timer_alarm(struct nvkm_timer *tmr, u32 nsec, struct nvkm_alarm *alarm) in nvkm_timer_alarm() argument
119 if (nsec) { in nvkm_timer_alarm()
121 alarm->timestamp = nvkm_timer_read(tmr) + nsec; in nvkm_timer_alarm()
/linux/drivers/misc/sgi-gru/
H A Dgruhandles.c26 unsigned long nsec; in update_mcs_stats() local
28 nsec = CLKS2NSEC(clks); in update_mcs_stats()
30 atomic_long_add(nsec, &mcs_op_statistics[op].total); in update_mcs_stats()
31 if (mcs_op_statistics[op].max < nsec) in update_mcs_stats()
32 mcs_op_statistics[op].max = nsec; in update_mcs_stats()
/linux/drivers/net/ethernet/microchip/
H A Dlan743x_ptp.c195 u32 *sec, u32 *nsec, u32 *sub_nsec);
529 ts_on.tv_nsec = perout_request->on.nsec; in lan743x_ptp_perout()
1042 u32 sec, nsec; in lan743x_ptp_io_event_clock_get() local
1058 extts->ts.tv_nsec = nsec; in lan743x_ptp_io_event_clock_get()
1060 ts->tv_nsec = nsec; in lan743x_ptp_io_event_clock_get()
1069 u32 cap_info, cause, header, nsec, seconds; in lan743x_ptpci_do_aux_work() local
1088 nsec = lan743x_csr_read(adapter, in lan743x_ptpci_do_aux_work()
1090 cause = (nsec & in lan743x_ptpci_do_aux_work()
1097 nsec &= PTP_TX_EGRESS_NS_TS_NS_MASK_; in lan743x_ptpci_do_aux_work()
1100 nsec, in lan743x_ptpci_do_aux_work()
[all …]

1234567