Searched refs:nsec (Results 1 - 142 of 142) sorted by relevance

/linux-4.4.14/kernel/time/
H A Dtimecounter.c27 tc->nsec = start_tstamp; timecounter_init()
67 u64 nsec; timecounter_read() local
70 nsec = timecounter_read_delta(tc); timecounter_read()
71 nsec += tc->nsec; timecounter_read()
72 tc->nsec = nsec; timecounter_read()
74 return nsec; timecounter_read()
96 u64 nsec = tc->nsec, frac = tc->frac; timecounter_cyc2time() local
105 nsec -= cc_cyc2ns_backwards(tc->cc, delta, tc->mask, frac); timecounter_cyc2time()
107 nsec += cyclecounter_cyc2ns(tc->cc, delta, tc->mask, &frac); timecounter_cyc2time()
110 return nsec; timecounter_cyc2time()
H A Dtime.c348 * set_normalized_timespec - set timespec sec and nsec parts and normalize
352 * @nsec: nanoseconds to set
361 void set_normalized_timespec(struct timespec *ts, time_t sec, s64 nsec) set_normalized_timespec() argument
363 while (nsec >= NSEC_PER_SEC) { set_normalized_timespec()
369 asm("" : "+rm"(nsec)); set_normalized_timespec()
370 nsec -= NSEC_PER_SEC; set_normalized_timespec()
373 while (nsec < 0) { set_normalized_timespec()
374 asm("" : "+rm"(nsec)); set_normalized_timespec()
375 nsec += NSEC_PER_SEC; set_normalized_timespec()
379 ts->tv_nsec = nsec; set_normalized_timespec()
385 * @nsec: the nanoseconds value to be converted
387 * Returns the timespec representation of the nsec parameter.
389 struct timespec ns_to_timespec(const s64 nsec) ns_to_timespec() argument
394 if (!nsec) ns_to_timespec()
397 ts.tv_sec = div_s64_rem(nsec, NSEC_PER_SEC, &rem); ns_to_timespec()
410 * @nsec: the nanoseconds value to be converted
412 * Returns the timeval representation of the nsec parameter.
414 struct timeval ns_to_timeval(const s64 nsec) ns_to_timeval() argument
416 struct timespec ts = ns_to_timespec(nsec); ns_to_timeval()
428 * set_normalized_timespec - set timespec sec and nsec parts and normalize
432 * @nsec: nanoseconds to set
441 void set_normalized_timespec64(struct timespec64 *ts, time64_t sec, s64 nsec) set_normalized_timespec64() argument
443 while (nsec >= NSEC_PER_SEC) { set_normalized_timespec64()
449 asm("" : "+rm"(nsec)); set_normalized_timespec64()
450 nsec -= NSEC_PER_SEC; set_normalized_timespec64()
453 while (nsec < 0) { set_normalized_timespec64()
454 asm("" : "+rm"(nsec)); set_normalized_timespec64()
455 nsec += NSEC_PER_SEC; set_normalized_timespec64()
459 ts->tv_nsec = nsec; set_normalized_timespec64()
465 * @nsec: the nanoseconds value to be converted
467 * Returns the timespec64 representation of the nsec parameter.
469 struct timespec64 ns_to_timespec64(const s64 nsec) ns_to_timespec64() argument
474 if (!nsec) ns_to_timespec64()
477 ts.tv_sec = div_s64_rem(nsec, NSEC_PER_SEC, &rem); ns_to_timespec64()
535 * nsec -= nsec % TICK_NSEC; is NOT a correct resolution rounding.
543 * The >> (NSEC_JIFFIE_SC - SEC_JIFFIE_SC) converts the scaled nsec
547 __timespec64_to_jiffies(u64 sec, long nsec) __timespec64_to_jiffies() argument
549 nsec = nsec + TICK_NSEC - 1; __timespec64_to_jiffies()
553 nsec = 0; __timespec64_to_jiffies()
556 (((u64)nsec * NSEC_CONVERSION) >> __timespec64_to_jiffies()
562 __timespec_to_jiffies(unsigned long sec, long nsec) __timespec_to_jiffies() argument
564 return __timespec64_to_jiffies((u64)sec, nsec); __timespec_to_jiffies()
590 * different multiplier for usec instead of nsec). But this has a
H A Dtimekeeping.c225 * Calculates a fixed cycle/nsec interval for a given clocksource/adjustment
304 s64 nsec; timekeeping_get_ns() local
308 nsec = (delta * tkr->mult + tkr->xtime_nsec) >> tkr->shift; timekeeping_get_ns()
311 return nsec + arch_gettimeoffset(); timekeeping_get_ns()
528 * Update the ktime_t based scalar nsec members of the timekeeper
533 u32 nsec; tk_update_ktime_data() local
537 * nsec = (xtime_sec + wtm_sec) * 1e9 + wtm_nsec + now(); tk_update_ktime_data()
539 * nsec = base_mono + now(); tk_update_ktime_data()
543 nsec = (u32) tk->wall_to_monotonic.tv_nsec; tk_update_ktime_data()
544 tk->tkr_mono.base = ns_to_ktime(seconds * NSEC_PER_SEC + nsec); tk_update_ktime_data()
554 nsec += (u32)(tk->tkr_mono.xtime_nsec >> tk->tkr_mono.shift); tk_update_ktime_data()
555 if (nsec >= NSEC_PER_SEC) tk_update_ktime_data()
600 s64 nsec; timekeeping_forward_now() local
614 nsec = clocksource_cyc2ns(delta, tk->tkr_raw.mult, tk->tkr_raw.shift); timekeeping_forward_now()
615 timespec64_add_ns(&tk->raw_time, nsec); timekeeping_forward_now()
781 s64 nsec; ktime_get_ts64() local
789 nsec = timekeeping_get_ns(&tk->tkr_mono); ktime_get_ts64()
796 timespec64_add_ns(ts, nsec + tomono.tv_nsec); ktime_get_ts64()
1391 s64 nsec = 0; timekeeping_resume() local
1404 nsec = (((u64) max * mult) >> shift) * num; timekeeping_resume()
1407 nsec += ((u64) cycle_delta * mult) >> shift; timekeeping_resume()
1409 ts_delta = ns_to_timespec64(nsec); timekeeping_resume()
H A Dntp.c773 * pps_normtime.nsec has a range of ( -NSEC_PER_SEC / 2, NSEC_PER_SEC / 2 ]
777 long nsec; /* nanoseconds */ member in struct:pps_normtime
780 /* normalize the timestamp so that nsec is in the
786 .nsec = ts.tv_nsec pps_normalize_ts()
789 if (norm.nsec > (NSEC_PER_SEC >> 1)) { pps_normalize_ts()
790 norm.nsec -= NSEC_PER_SEC; pps_normalize_ts()
873 ftemp = div_s64(((s64)(-freq_norm.nsec)) << NTP_SCALE_SHIFT, hardpps_update_freq()
977 (freq_norm.nsec > MAXFREQ * freq_norm.sec) || __hardpps()
978 (freq_norm.nsec < -MAXFREQ * freq_norm.sec)) { __hardpps()
996 hardpps_update_phase(pts_norm.nsec); __hardpps()
H A Dclockevents.c60 * from nsec to device ticks will be correct. cev_delta2ns()
229 "CE: %s increased min_delta_ns to %llu nsec\n", clockevents_increase_min_delta()
/linux-4.4.14/arch/xtensa/include/asm/
H A Ddelay.h55 static inline void __ndelay(unsigned long nsec) __ndelay() argument
59 * for legitimate nsec values __ndelay()
61 unsigned long cycles = (nsec * (ccount_freq >> 15)) >> 15; __ndelay()
67 static inline void ndelay(unsigned long nsec) ndelay() argument
69 if (__builtin_constant_p(nsec) && nsec >= __MAX_NDELAY) ndelay()
72 __ndelay(nsec); ndelay()
/linux-4.4.14/arch/um/os-Linux/
H A Dtime.c63 unsigned long long nsec; os_timer_set_interval() local
71 nsec = UM_NSEC_PER_SEC / UM_HZ; os_timer_set_interval()
78 its.it_value.tv_nsec = nsec; os_timer_set_interval()
82 its.it_interval.tv_nsec = nsec; os_timer_set_interval()
119 unsigned long long nsec; os_timer_one_shot() local
122 nsec = (ticks + 1); os_timer_one_shot()
123 sec = nsec / UM_NSEC_PER_SEC; os_timer_one_shot()
124 nsec = nsec % UM_NSEC_PER_SEC; os_timer_one_shot()
126 its.it_value.tv_sec = nsec / UM_NSEC_PER_SEC; os_timer_one_shot()
127 its.it_value.tv_nsec = nsec; os_timer_one_shot()
/linux-4.4.14/fs/proc/
H A Duptime.c15 u64 nsec; uptime_proc_show() local
24 nsec = cputime64_to_jiffies64(idletime) * TICK_NSEC; uptime_proc_show()
25 idle.tv_sec = div_u64_rem(nsec, NSEC_PER_SEC, &rem); uptime_proc_show()
H A Darray.c471 /* convert nsec -> ticks */ do_task_stat()
/linux-4.4.14/tools/perf/scripts/python/
H A Dnetdev-times.py55 # Calculate a time interval(msec) from src(nsec) to dst(nsec)
227 def irq__softirq_entry(name, context, cpu, sec, nsec, pid, comm, callchain, vec):
230 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm, vec)
233 def irq__softirq_exit(name, context, cpu, sec, nsec, pid, comm, callchain, vec):
236 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm, vec)
239 def irq__softirq_raise(name, context, cpu, sec, nsec, pid, comm, callchain, vec):
242 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm, vec)
245 def irq__irq_handler_entry(name, context, cpu, sec, nsec, pid, comm,
247 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
251 def irq__irq_handler_exit(name, context, cpu, sec, nsec, pid, comm, callchain, irq, ret):
252 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm, irq, ret)
255 def napi__napi_poll(name, context, cpu, sec, nsec, pid, comm, callchain, napi, dev_name):
256 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
260 def net__netif_receive_skb(name, context, cpu, sec, nsec, pid, comm, callchain, skbaddr,
262 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
266 def net__netif_rx(name, context, cpu, sec, nsec, pid, comm, callchain, skbaddr,
268 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
272 def net__net_dev_queue(name, context, cpu, sec, nsec, pid, comm, callchain,
274 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
278 def net__net_dev_xmit(name, context, cpu, sec, nsec, pid, comm, callchain,
280 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
284 def skb__kfree_skb(name, context, cpu, sec, nsec, pid, comm, callchain,
286 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
290 def skb__consume_skb(name, context, cpu, sec, nsec, pid, comm, callchain, skbaddr):
291 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
295 def skb__skb_copy_datagram_iovec(name, context, cpu, sec, nsec, pid, comm, callchain,
297 event_info = (name, context, cpu, nsecs(sec, nsec), pid, comm,
H A Dnet_dropmonitor.py69 def skb__kfree_skb(name, context, cpu, sec, nsec, pid, comm, callchain,
H A Dcompaction-times.py48 def ns(sec, nsec):
49 return (sec * 1000000000) + nsec
/linux-4.4.14/security/selinux/
H A Dnetnode.c55 struct netnode_security_struct nsec; member in struct:sel_netnode
132 if (node->nsec.family == family) sel_netnode_find()
135 if (node->nsec.addr.ipv4 == *(__be32 *)addr) sel_netnode_find()
139 if (ipv6_addr_equal(&node->nsec.addr.ipv6, sel_netnode_find()
160 switch (node->nsec.family) { sel_netnode_insert()
162 idx = sel_netnode_hashfn_ipv4(node->nsec.addr.ipv4); sel_netnode_insert()
165 idx = sel_netnode_hashfn_ipv6(&node->nsec.addr.ipv6); sel_netnode_insert()
209 *sid = node->nsec.sid; sel_netnode_sid_slow()
220 new->nsec.addr.ipv4 = *(__be32 *)addr; sel_netnode_sid_slow()
225 new->nsec.addr.ipv6 = *(struct in6_addr *)addr; sel_netnode_sid_slow()
234 new->nsec.family = family; sel_netnode_sid_slow()
235 new->nsec.sid = *sid; sel_netnode_sid_slow()
270 *sid = node->nsec.sid; sel_netnode_sid()
H A Dnetif.c37 struct netif_security_struct nsec; member in struct:sel_netif
78 if (net_eq(netif->nsec.ns, ns) && sel_netif_find()
79 netif->nsec.ifindex == ifindex) sel_netif_find()
101 idx = sel_netif_hashfn(netif->nsec.ns, netif->nsec.ifindex); sel_netif_insert()
157 *sid = netif->nsec.sid; sel_netif_sid_slow()
166 ret = security_netif_sid(dev->name, &new->nsec.sid); sel_netif_sid_slow()
169 new->nsec.ns = ns; sel_netif_sid_slow()
170 new->nsec.ifindex = ifindex; sel_netif_sid_slow()
174 *sid = new->nsec.sid; sel_netif_sid_slow()
210 *sid = netif->nsec.sid; sel_netif_sid()
/linux-4.4.14/drivers/gpu/drm/nouveau/nvkm/subdev/pmu/
H A Dmemx.c107 u32 addr, u32 mask, u32 data, u32 nsec) nvkm_memx_wait()
110 addr, mask, data, nsec); nvkm_memx_wait()
111 memx_cmd(memx, MEMX_WAIT, 4, (u32[]){ addr, mask, data, nsec }); nvkm_memx_wait()
116 nvkm_memx_nsec(struct nvkm_memx *memx, u32 nsec) nvkm_memx_nsec() argument
118 nvkm_debug(&memx->pmu->subdev, " DELAY = %d ns\n", nsec); nvkm_memx_nsec()
119 memx_cmd(memx, MEMX_DELAY, 1, (u32[]){ nsec }); nvkm_memx_nsec()
106 nvkm_memx_wait(struct nvkm_memx *memx, u32 addr, u32 mask, u32 data, u32 nsec) nvkm_memx_wait() argument
/linux-4.4.14/tools/testing/selftests/mqueue/
H A Dmq_perf_tests.c353 nsec = ((middle.tv_sec - start.tv_sec) * 1000000000) + \
355 send_total.tv_nsec += nsec; \
360 nsec = ((end.tv_sec - middle.tv_sec) * 1000000000) + \
362 recv_total.tv_nsec += nsec; \
428 unsigned long long nsec; perf_test_thread() local
444 printf("\t\tClock resolution:\t\t%lu nsec%s\n", res.tv_nsec, perf_test_thread()
460 nsec = ((unsigned long long)send_total.tv_sec * 1000000000 + perf_test_thread()
462 printf("\t\t\t\t\t\t%lld nsec/msg\n", nsec); perf_test_thread()
465 nsec = ((unsigned long long)recv_total.tv_sec * 1000000000 + perf_test_thread()
467 printf("\t\t\t\t\t\t%lld nsec/msg\n", nsec); perf_test_thread()
486 nsec = ((unsigned long long)(end.tv_sec - start.tv_sec) * perf_test_thread()
488 printf("done.\t\t%lld.%llds\n", nsec / 1000000000, perf_test_thread()
489 nsec % 1000000000); perf_test_thread()
499 nsec = ((unsigned long long)send_total.tv_sec * 1000000000 + perf_test_thread()
501 printf("\t\t\t\t\t\t%lld nsec/msg\n", nsec); perf_test_thread()
504 nsec = ((unsigned long long)recv_total.tv_sec * 1000000000 + perf_test_thread()
506 printf("\t\t\t\t\t\t%lld nsec/msg\n", nsec); perf_test_thread()
512 nsec = ((unsigned long long)(end.tv_sec - start.tv_sec) * perf_test_thread()
514 printf("done.\t\t%lld.%llds\n", nsec / 1000000000, perf_test_thread()
515 nsec % 1000000000); perf_test_thread()
/linux-4.4.14/arch/tile/gxio/
H A Diorpc_mpipe.c414 uint64_t nsec; member in struct:get_timestamp_aux_param
419 uint64_t *nsec, uint64_t *cycles) gxio_mpipe_get_timestamp_aux()
429 *nsec = params->nsec; gxio_mpipe_get_timestamp_aux()
439 uint64_t nsec; member in struct:set_timestamp_aux_param
444 uint64_t nsec, uint64_t cycles) gxio_mpipe_set_timestamp_aux()
450 params->nsec = nsec; gxio_mpipe_set_timestamp_aux()
460 int64_t nsec; member in struct:adjust_timestamp_aux_param
463 int gxio_mpipe_adjust_timestamp_aux(gxio_mpipe_context_t *context, int64_t nsec) gxio_mpipe_adjust_timestamp_aux() argument
468 params->nsec = nsec; gxio_mpipe_adjust_timestamp_aux()
418 gxio_mpipe_get_timestamp_aux(gxio_mpipe_context_t *context, uint64_t *sec, uint64_t *nsec, uint64_t *cycles) gxio_mpipe_get_timestamp_aux() argument
443 gxio_mpipe_set_timestamp_aux(gxio_mpipe_context_t *context, uint64_t sec, uint64_t nsec, uint64_t cycles) gxio_mpipe_set_timestamp_aux() argument
/linux-4.4.14/drivers/gpu/drm/nouveau/nvkm/subdev/fb/
H A Dramfuc.h122 ramfuc_wait(struct ramfuc *ram, u32 addr, u32 mask, u32 data, u32 nsec) ramfuc_wait() argument
124 nvkm_memx_wait(ram->memx, addr, mask, data, nsec); ramfuc_wait()
128 ramfuc_nsec(struct ramfuc *ram, u32 nsec) ramfuc_nsec() argument
130 nvkm_memx_nsec(ram->memx, nsec); ramfuc_nsec()
/linux-4.4.14/drivers/net/ethernet/stmicro/stmmac/
H A Dstmmac_hwtstamp.c54 static int stmmac_init_systime(void __iomem *ioaddr, u32 sec, u32 nsec) stmmac_init_systime() argument
60 writel(nsec, ioaddr + PTP_STNSUR); stmmac_init_systime()
103 static int stmmac_adjust_systime(void __iomem *ioaddr, u32 sec, u32 nsec, stmmac_adjust_systime() argument
110 writel(((add_sub << PTP_STNSUR_ADDSUB_SHIFT) | nsec), stmmac_adjust_systime()
H A Dstmmac_ptp.c77 u32 sec, nsec; stmmac_adjust_time() local
88 nsec = reminder; stmmac_adjust_time()
92 priv->hw->ptp->adjust_systime(priv->ioaddr, sec, nsec, neg_adj); stmmac_adjust_time()
H A Dcommon.h417 int (*init_systime) (void __iomem *ioaddr, u32 sec, u32 nsec);
419 int (*adjust_systime) (void __iomem *ioaddr, u32 sec, u32 nsec,
/linux-4.4.14/drivers/gpu/drm/nouveau/include/nvkm/subdev/
H A Dbus.h18 void nvkm_hwsq_nsec(struct nvkm_hwsq *, u32 nsec);
H A Dpmu.h44 void nvkm_memx_wait(struct nvkm_memx *, u32 addr, u32 mask, u32 data, u32 nsec);
45 void nvkm_memx_nsec(struct nvkm_memx *, u32 nsec);
H A Dtimer.h27 void nvkm_timer_alarm(struct nvkm_timer *, u32 nsec, struct nvkm_alarm *);
/linux-4.4.14/arch/ia64/include/asm/
H A Dcputime.h14 * If we have CONFIG_VIRT_CPU_ACCOUNTING_NATIVE, we measure cpu time in nsec.
/linux-4.4.14/arch/arm/common/
H A Dlocomo.c635 udelay(DAC_LOW_SETUP_TIME); /* 300 nsec */ locomo_m62332_sendbit()
636 udelay(DAC_DATA_HOLD_TIME); /* 300 nsec */ locomo_m62332_sendbit()
640 udelay(DAC_LOW_SETUP_TIME); /* 300 nsec */ locomo_m62332_sendbit()
647 udelay(DAC_HIGH_SETUP_TIME); /* 1000 nsec */ locomo_m62332_sendbit()
652 udelay(DAC_LOW_SETUP_TIME); /* 300 nsec */ locomo_m62332_sendbit()
655 udelay(DAC_DATA_SETUP_TIME); /* 250 nsec */ locomo_m62332_sendbit()
659 udelay(DAC_HIGH_SETUP_TIME); /* 1000 nsec */ locomo_m62332_sendbit()
679 udelay(DAC_HIGH_SETUP_TIME); /* 1000 nsec */ locomo_m62332_senddata()
685 udelay(DAC_DATA_HOLD_TIME); /* 300 nsec */ locomo_m62332_senddata()
697 udelay(DAC_LOW_SETUP_TIME); /* 300 nsec */ locomo_m62332_senddata()
702 udelay(DAC_LOW_SETUP_TIME); /* 300 nsec */ locomo_m62332_senddata()
706 udelay(DAC_HIGH_SETUP_TIME); /* 1000 nsec */ locomo_m62332_senddata()
725 udelay(DAC_LOW_SETUP_TIME); /* 300 nsec */ locomo_m62332_senddata()
730 udelay(DAC_LOW_SETUP_TIME); /* 300 nsec */ locomo_m62332_senddata()
734 udelay(DAC_HIGH_SETUP_TIME); /* 1000 nsec */ locomo_m62332_senddata()
750 udelay(DAC_LOW_SETUP_TIME); /* 300 nsec */ locomo_m62332_senddata()
755 udelay(DAC_LOW_SETUP_TIME); /* 300 nsec */ locomo_m62332_senddata()
759 udelay(DAC_HIGH_SETUP_TIME); /* 1000 nsec */ locomo_m62332_senddata()
770 udelay(DAC_LOW_SETUP_TIME); /* 300 nsec */ locomo_m62332_senddata()
775 udelay(DAC_HIGH_SETUP_TIME); /* 1000 nsec */ locomo_m62332_senddata()
780 udelay(DAC_HIGH_SETUP_TIME); /* 1000 nsec */ locomo_m62332_senddata()
786 udelay(DAC_LOW_SETUP_TIME); /* 1000 nsec */ locomo_m62332_senddata()
/linux-4.4.14/kernel/sched/
H A Ddebug.c37 * Ease the printing of nsec fields:
39 static long long nsec_high(unsigned long long nsec) nsec_high() argument
41 if ((long long)nsec < 0) { nsec_high()
42 nsec = -nsec; nsec_high()
43 do_div(nsec, 1000000); nsec_high()
44 return -nsec; nsec_high()
46 do_div(nsec, 1000000); nsec_high()
48 return nsec; nsec_high()
51 static unsigned long nsec_low(unsigned long long nsec) nsec_low() argument
53 if ((long long)nsec < 0) nsec_low()
54 nsec = -nsec; nsec_low()
56 return do_div(nsec, 1000000); nsec_low()
/linux-4.4.14/drivers/misc/sgi-gru/
H A Dgruhandles.c44 unsigned long nsec; update_mcs_stats() local
46 nsec = CLKS2NSEC(clks); update_mcs_stats()
48 atomic_long_add(nsec, &mcs_op_statistics[op].total); update_mcs_stats()
49 if (mcs_op_statistics[op].max < nsec) update_mcs_stats()
50 mcs_op_statistics[op].max = nsec; update_mcs_stats()
/linux-4.4.14/drivers/pps/
H A Dkapi.c43 ts->nsec += offset->nsec; pps_add_offset()
44 while (ts->nsec >= NSEC_PER_SEC) { pps_add_offset()
45 ts->nsec -= NSEC_PER_SEC; pps_add_offset()
48 while (ts->nsec < 0) { pps_add_offset()
49 ts->nsec += NSEC_PER_SEC; pps_add_offset()
177 struct pps_ktime ts_real = { .sec = 0, .nsec = 0, .flags = 0 }; pps_event()
H A Dsysfs.c41 (long long) pps->assert_tu.sec, pps->assert_tu.nsec, assert_show()
55 (long long) pps->clear_tu.sec, pps->clear_tu.nsec, clear_show()
H A Dpps.c166 fdata.timeout.nsec); pps_cdev_ioctl()
168 ticks += fdata.timeout.nsec / (NSEC_PER_SEC / HZ); pps_cdev_ioctl()
/linux-4.4.14/include/linux/
H A Dtime.h57 extern void set_normalized_timespec(struct timespec *ts, time_t sec, s64 nsec);
211 * @nsec: the nanoseconds value to be converted
213 * Returns the timespec representation of the nsec parameter.
215 extern struct timespec ns_to_timespec(const s64 nsec);
219 * @nsec: the nanoseconds value to be converted
221 * Returns the timeval representation of the nsec parameter.
223 extern struct timeval ns_to_timeval(const s64 nsec);
H A Dtime64.h135 extern void set_normalized_timespec64(struct timespec64 *ts, time64_t sec, s64 nsec);
205 * @nsec: the nanoseconds value to be converted
207 * Returns the timespec64 representation of the nsec parameter.
209 extern struct timespec64 ns_to_timespec64(const s64 nsec);
H A Dtimecounter.h60 * @nsec: continuously increasing count
67 u64 nsec; member in struct:timecounter
95 tc->nsec += delta; timecounter_adjtime()
H A Dpps_kernel.h111 kt->nsec = ts.tv_nsec; timespec_to_pps_ktime()
H A Dclockchips.h171 div_sc(unsigned long ticks, unsigned long nsec, int shift) div_sc() argument
175 do_div(tmp, nsec); div_sc()
H A Dpoll.h162 extern int poll_select_set_timeout(struct timespec *to, long sec, long nsec);
H A Dtimex.h140 extern unsigned long tick_nsec; /* SHIFTED_HZ period (nsec) */
H A Djiffies.h60 /* TICK_NSEC is the time between ticks in nsec assuming SHIFTED_HZ */
H A Dsched.h1534 u64 start_time; /* monotonic time in nsec */
1535 u64 real_start_time; /* boot based time in nsec */
/linux-4.4.14/drivers/net/ethernet/amd/xgbe/
H A Dxgbe-ptp.c130 u64 nsec; xgbe_cc_read() local
132 nsec = pdata->hw_if.get_tstamp_time(pdata); xgbe_cc_read()
134 return nsec; xgbe_cc_read()
188 u64 nsec; xgbe_gettime() local
192 nsec = timecounter_read(&pdata->tstamp_tc); xgbe_gettime()
196 *ts = ns_to_timespec64(nsec); xgbe_gettime()
208 u64 nsec; xgbe_settime() local
210 nsec = timespec64_to_ns(ts); xgbe_settime()
214 timecounter_init(&pdata->tstamp_tc, &pdata->tstamp_cc, nsec); xgbe_settime()
H A Dxgbe-dev.c1203 unsigned int nsec) xgbe_set_tstamp_time()
1207 XGMAC_IOWRITE(pdata, MAC_STNUR, nsec); xgbe_set_tstamp_time()
1217 u64 nsec; xgbe_get_tstamp_time() local
1219 nsec = XGMAC_IOREAD(pdata, MAC_STSR); xgbe_get_tstamp_time()
1220 nsec *= NSEC_PER_SEC; xgbe_get_tstamp_time()
1221 nsec += XGMAC_IOREAD(pdata, MAC_STNR); xgbe_get_tstamp_time()
1223 return nsec; xgbe_get_tstamp_time()
1229 u64 nsec; xgbe_get_tx_tstamp() local
1235 nsec = XGMAC_IOREAD(pdata, MAC_TXSSR); xgbe_get_tx_tstamp()
1236 nsec *= NSEC_PER_SEC; xgbe_get_tx_tstamp()
1237 nsec += tx_snr; xgbe_get_tx_tstamp()
1239 return nsec; xgbe_get_tx_tstamp()
1245 u64 nsec; xgbe_get_rx_tstamp() local
1249 nsec = le32_to_cpu(rdesc->desc1); xgbe_get_rx_tstamp()
1250 nsec <<= 32; xgbe_get_rx_tstamp()
1251 nsec |= le32_to_cpu(rdesc->desc0); xgbe_get_rx_tstamp()
1252 if (nsec != 0xffffffffffffffffULL) { xgbe_get_rx_tstamp()
1253 packet->rx_tstamp = nsec; xgbe_get_rx_tstamp()
1202 xgbe_set_tstamp_time(struct xgbe_prv_data *pdata, unsigned int sec, unsigned int nsec) xgbe_set_tstamp_time() argument
H A Dxgbe-drv.c991 u64 nsec; xgbe_tx_tstamp() local
995 nsec = timecounter_cyc2time(&pdata->tstamp_tc, xgbe_tx_tstamp()
999 hwtstamps.hwtstamp = ns_to_ktime(nsec); xgbe_tx_tstamp()
2011 u64 nsec; xgbe_rx_poll() local
2013 nsec = timecounter_cyc2time(&pdata->tstamp_tc, xgbe_rx_poll()
2016 hwtstamps->hwtstamp = ns_to_ktime(nsec); xgbe_rx_poll()
H A Dxgbe.h202 * 50MHz => 20 nsec
671 unsigned int nsec);
/linux-4.4.14/sound/core/seq/
H A Dseq_timer.h29 unsigned long resolution; /* time per tick in nsec */
30 unsigned long fraction; /* current time per tick in nsec */
116 static inline void snd_seq_inc_time_nsec(snd_seq_real_time_t *tm, unsigned long nsec) snd_seq_inc_time_nsec() argument
118 tm->tv_nsec += nsec; snd_seq_inc_time_nsec()
/linux-4.4.14/arch/mips/vdso/
H A Dgettimeofday.c99 u64 cycle_now, delta, nsec; get_ns() local
118 nsec = (delta * data->cs_mult) + data->xtime_nsec; get_ns()
119 nsec >>= data->cs_shift; get_ns()
121 return nsec; get_ns()
/linux-4.4.14/arch/arm/vdso/
H A Dvgettimeofday.c124 u64 nsec; get_ns() local
130 nsec = (cycle_delta * vdata->cs_mult) + vdata->xtime_clock_snsec; get_ns()
131 nsec >>= vdata->cs_shift; get_ns()
133 return nsec; get_ns()
/linux-4.4.14/drivers/gpu/drm/nouveau/nvkm/subdev/bus/
H A Dhwsq.h143 hwsq_nsec(struct hwsq *ram, u32 nsec) hwsq_nsec() argument
145 nvkm_hwsq_nsec(ram->hwsq, nsec); hwsq_nsec()
H A Dhwsq.c167 nvkm_hwsq_nsec(struct nvkm_hwsq *hwsq, u32 nsec) nvkm_hwsq_nsec() argument
169 u8 shift = 0, usec = nsec / 1000; nvkm_hwsq_nsec()
175 nvkm_debug(hwsq->subdev, " DELAY = %d ns\n", nsec); nvkm_hwsq_nsec()
/linux-4.4.14/Documentation/ptp/
H A Dtestptp.c110 return t->sec * 1000000000LL + t->nsec; pctns()
367 event.t.sec, event.t.nsec); main()
446 perout_request.start.nsec = 0; main()
448 perout_request.period.nsec = perout; main()
505 (pct+2*i)->sec, (pct+2*i)->nsec); main()
507 (pct+2*i+1)->sec, (pct+2*i+1)->nsec); main()
509 (pct+2*i+2)->sec, (pct+2*i+2)->nsec); main()
/linux-4.4.14/fs/
H A Dutimes.c43 static bool nsec_valid(long nsec) nsec_valid() argument
45 if (nsec == UTIME_OMIT || nsec == UTIME_NOW) nsec_valid()
48 return nsec >= 0 && nsec <= 999999999; nsec_valid()
H A Dselect.c265 * @nsec: nanoseconds (from user space)
270 * Returns -EINVAL if sec/nsec are not normalized. Otherwise 0.
272 int poll_select_set_timeout(struct timespec *to, long sec, long nsec) poll_select_set_timeout() argument
274 struct timespec ts = {.tv_sec = sec, .tv_nsec = nsec}; poll_select_set_timeout()
280 if (!sec && !nsec) { poll_select_set_timeout()
/linux-4.4.14/drivers/gpu/drm/nouveau/nvkm/subdev/timer/
H A Dbase.c63 nvkm_timer_alarm(struct nvkm_timer *tmr, u32 nsec, struct nvkm_alarm *alarm) nvkm_timer_alarm() argument
68 alarm->timestamp = nvkm_timer_read(tmr) + nsec; nvkm_timer_alarm()
72 if (!nsec) { nvkm_timer_alarm()
/linux-4.4.14/arch/tile/include/gxio/
H A Diorpc_mpipe.h124 uint64_t *nsec, uint64_t *cycles);
127 uint64_t nsec, uint64_t cycles);
130 int64_t nsec);
/linux-4.4.14/sound/soc/intel/skylake/
H A Dskl-pcm.c821 u64 nsec) skl_adjust_codec_delay()
828 return nsec; skl_adjust_codec_delay()
835 return nsec + codec_nsecs; skl_adjust_codec_delay()
837 return (nsec > codec_nsecs) ? nsec - codec_nsecs : 0; skl_adjust_codec_delay()
847 u64 nsec; skl_get_time_info() local
854 nsec = timecounter_read(&hstr->tc); skl_get_time_info()
855 nsec = div_u64(nsec, 3); /* can be optimized */ skl_get_time_info()
857 nsec = skl_adjust_codec_delay(substream, nsec); skl_get_time_info()
859 *audio_ts = ns_to_timespec(nsec); skl_get_time_info()
820 skl_adjust_codec_delay(struct snd_pcm_substream *substream, u64 nsec) skl_adjust_codec_delay() argument
/linux-4.4.14/arch/mips/kernel/
H A Dbinfmt_elfn32.c105 u64 nsec = (u64)jiffies * TICK_NSEC; jiffies_to_compat_timeval() local
107 value->tv_sec = div_u64_rem(nsec, NSEC_PER_SEC, &rem); jiffies_to_compat_timeval()
H A Dbinfmt_elfo32.c126 u64 nsec = (u64)jiffies * TICK_NSEC; jiffies_to_compat_timeval() local
128 value->tv_sec = div_u64_rem(nsec, NSEC_PER_SEC, &rem); jiffies_to_compat_timeval()
/linux-4.4.14/drivers/ptp/
H A Dptp_chardev.c171 enable = req.perout.period.sec || req.perout.period.nsec; ptp_ioctl()
202 pct->nsec = ts.tv_nsec; ptp_ioctl()
206 pct->nsec = ts.tv_nsec; ptp_ioctl()
211 pct->nsec = ts.tv_nsec; ptp_ioctl()
H A Dptp_sysfs.c122 event.index, event.t.sec, event.t.nsec); extts_fifo_show()
138 &req.perout.start.sec, &req.perout.start.nsec, period_store()
139 &req.perout.period.sec, &req.perout.period.nsec); period_store()
145 enable = req.perout.period.sec || req.perout.period.nsec; period_store()
H A Dptp_clock.c68 dst->t.nsec = remainder; enqueue_external_timestamp()
/linux-4.4.14/drivers/net/ethernet/renesas/
H A Dravb_ptp.c228 start_ns = req->start.sec * NSEC_PER_SEC + req->start.nsec; ravb_ptp_perout()
229 period_ns = req->period.sec * NSEC_PER_SEC + req->period.nsec; ravb_ptp_perout()
233 "ptp: start value (nsec) is over limit. Maximum size of start is only 32 bits\n"); ravb_ptp_perout()
239 "ptp: period value (nsec) is over limit. Maximum size of period is only 32 bits\n"); ravb_ptp_perout()
H A Dravb.h694 __le32 ts_n; /* Timestampe nsec */
/linux-4.4.14/arch/x86/include/asm/
H A Dpvclock-abi.h39 u32 nsec; member in struct:pvclock_wall_clock
/linux-4.4.14/fs/adfs/
H A Dinode.c178 s64 nsec; adfs_adfs2unix_time() local
189 nsec = (((s64) high << 32) | (s64) low) * 10000000; /* cs to ns */ adfs_adfs2unix_time()
192 if (nsec < nsec_unix_epoch_diff_risc_os_epoch) adfs_adfs2unix_time()
196 nsec -= nsec_unix_epoch_diff_risc_os_epoch; adfs_adfs2unix_time()
198 *tv = ns_to_timespec(nsec); adfs_adfs2unix_time()
/linux-4.4.14/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/
H A Dbit.c56 nvkm_i2c_delay(struct nvkm_i2c_bus *bus, u32 nsec) nvkm_i2c_delay() argument
58 udelay((nsec + 500) / 1000); nvkm_i2c_delay()
/linux-4.4.14/include/asm-generic/
H A Dcputime_nsecs.h74 * Convert cputime <-> timespec (nsec)
/linux-4.4.14/arch/arm/include/asm/xen/
H A Dinterface.h78 u32 nsec; member in struct:pvclock_wall_clock
/linux-4.4.14/drivers/net/ethernet/mellanox/mlx4/
H A Den_clock.c66 u64 nsec; mlx4_en_fill_hwtstamps() local
69 nsec = timecounter_cyc2time(&mdev->clock, timestamp); mlx4_en_fill_hwtstamps()
73 hwts->hwtstamp = ns_to_ktime(nsec); mlx4_en_fill_hwtstamps()
/linux-4.4.14/arch/powerpc/kernel/vdso32/
H A Dgettimeofday.S87 50: bl __do_get_tspec@local /* get sec/nsec from tb & kernel */
97 * At this point, r3,r4 contain our sec/nsec values, r5 and r6
115 * which may cause funny results if nsec goes negative... is that
/linux-4.4.14/sound/pci/hda/
H A Dhda_controller.c68 u64 nsec) azx_adjust_codec_delay()
75 return nsec; azx_adjust_codec_delay()
82 return nsec + codec_nsecs; azx_adjust_codec_delay()
84 return (nsec > codec_nsecs) ? nsec - codec_nsecs : 0; azx_adjust_codec_delay()
346 u64 nsec; azx_get_time_info() local
353 nsec = timecounter_read(&azx_dev->core.tc); azx_get_time_info()
354 nsec = div_u64(nsec, 3); /* can be optimized */ azx_get_time_info()
356 nsec = azx_adjust_codec_delay(substream, nsec); azx_get_time_info()
358 *audio_ts = ns_to_timespec(nsec); azx_get_time_info()
67 azx_adjust_codec_delay(struct snd_pcm_substream *substream, u64 nsec) azx_adjust_codec_delay() argument
/linux-4.4.14/drivers/char/
H A Dmmtimer.c483 u64 nsec; sgi_clock_get() local
485 nsec = rtc_time() * sgi_clock_period sgi_clock_get()
487 *tp = ns_to_timespec(nsec); sgi_clock_get()
495 u64 nsec; sgi_clock_set() local
498 nsec = rtc_time() * sgi_clock_period; sgi_clock_set()
500 sgi_clock_offset.tv_sec = tp->tv_sec - div_u64_rem(nsec, NSEC_PER_SEC, &rem); sgi_clock_set()
/linux-4.4.14/drivers/ide/
H A Dpalm_bk3710.c63 unsigned int rptime; /* tRP -- Ready to pause time (nsec) */
64 unsigned int cycletime; /* tCYCTYP2/2 -- avg Cycle Time (nsec) */
65 /* tENV is always a minimum of 20 nsec */
/linux-4.4.14/include/uapi/linux/
H A Dgfs2_ondisk.h287 __be32 di_atime_nsec; /* nsec portion of atime */
288 __be32 di_mtime_nsec; /* nsec portion of mtime */
289 __be32 di_ctime_nsec; /* nsec portion of ctime */
H A Dpps.h55 __s32 nsec; member in struct:pps_ktime
H A Dptp_clock.h43 __u32 nsec; /* nanoseconds */ member in struct:ptp_clock_time
H A Dbtrfs.h474 __u32 nsec; member in struct:btrfs_ioctl_timespec
/linux-4.4.14/arch/x86/kernel/
H A Dpvclock.c131 now.tv_nsec = wall_clock->nsec; pvclock_read_wallclock()
/linux-4.4.14/drivers/char/mwave/
H A Dtp3780i.h68 #define TP_CFG_IsaMemCmdWidth 3 /* 295 nsec (16-bit) */
/linux-4.4.14/kernel/
H A Dtsacct.c39 /* calculate task elapsed time in nsec */ bacct_add_tsk()
H A Dacct.c427 /* calculate run_time in nsec*/ fill_ac()
430 /* convert nsec -> AHZ */ fill_ac()
/linux-4.4.14/include/sound/
H A Dtimer.h58 unsigned long resolution; /* average timer resolution for one tick in nsec */
/linux-4.4.14/drivers/net/ethernet/intel/igb/
H A Digb_ptp.c123 u32 sec, nsec; igb_ptp_read_i210() local
130 nsec = rd32(E1000_SYSTIML); igb_ptp_read_i210()
134 ts->tv_nsec = nsec; igb_ptp_read_i210()
525 ts.tv_nsec = rq->perout.period.nsec; igb_ptp_feature_enable_i210()
571 igb->perout[i].start.tv_nsec = rq->perout.start.nsec; igb_ptp_feature_enable_i210()
575 wr32(trgttiml, rq->perout.start.nsec); igb_ptp_feature_enable_i210()
H A Digb_main.c5396 u32 ack = 0, tsauxc, sec, nsec, tsicr = rd32(E1000_TSICR); igb_tsync_interrupt() local
5443 nsec = rd32(E1000_AUXSTMPL0); igb_tsync_interrupt()
5447 event.timestamp = sec * 1000000000ULL + nsec; igb_tsync_interrupt()
5453 nsec = rd32(E1000_AUXSTMPL1); igb_tsync_interrupt()
5457 event.timestamp = sec * 1000000000ULL + nsec; igb_tsync_interrupt()
/linux-4.4.14/drivers/net/phy/
H A Ddp83640.c312 u32 sec, nsec, pwidth; periodic_output() local
342 nsec = clkreq->perout.start.nsec; periodic_output()
344 pwidth += clkreq->perout.period.nsec; periodic_output()
354 ext_write(0, phydev, PAGE4, PTP_TDR, nsec & 0xffff); /* ns[15:0] */ periodic_output()
355 ext_write(0, phydev, PAGE4, PTP_TDR, nsec >> 16); /* ns[31:16] */ periodic_output()
/linux-4.4.14/drivers/block/xen-blkback/
H A Dblkback.c972 seg[n].nsec = last_sect - first_sect + 1; xen_blkbk_parse_indirect()
974 preq->nr_sects += seg[n].nsec; xen_blkbk_parse_indirect()
1274 seg[i].nsec = req->u.rw.seg[i].last_sect - dispatch_rw_block_io()
1281 preq.nr_sects += seg[i].nsec; dispatch_rw_block_io()
1304 if (((int)preq.sector_number|(int)seg[i].nsec) & dispatch_rw_block_io()
1338 seg[i].nsec << 9, dispatch_rw_block_io()
1353 preq.sector_number += seg[i].nsec; dispatch_rw_block_io()
H A Dcommon.h338 unsigned int nsec; member in struct:seg_buf
/linux-4.4.14/sound/hda/
H A Dhdac_stream.c480 u64 nsec; azx_timecounter_init() local
498 nsec = 0; /* audio time is elapsed time since trigger */ azx_timecounter_init()
499 timecounter_init(tc, cc, nsec); azx_timecounter_init()
/linux-4.4.14/drivers/net/wireless/iwlwifi/mvm/
H A Dfw-api-tof.h132 * @toa_offset: Artificial addition [0.1nsec] for the ToA - to be used for debug
303 * values measured for current AP in the current session [nsec]
/linux-4.4.14/lib/
H A Dcrc32.c983 u64 nsec; crc32c_test() local
1013 nsec = stop.tv_nsec - start.tv_nsec + crc32c_test()
1021 pr_info("crc32c: self tests passed, processed %d bytes in %lld nsec\n", crc32c_test()
1022 bytes, nsec); crc32c_test()
1069 u64 nsec; crc32_test() local
1106 nsec = stop.tv_nsec - start.tv_nsec + crc32_test()
1115 pr_info("crc32: self tests passed, processed %d bytes in %lld nsec\n", crc32_test()
1116 bytes, nsec); crc32_test()
/linux-4.4.14/drivers/staging/rdma/hfi1/
H A Dmad.h116 /* number of 4nsec cycles equaling 2secs */
H A Dinit.c454 unsigned long nsec = 1024 * ccti_timer; cca_timer_fn() local
456 hrtimer_forward_now(t, ns_to_ktime(nsec)); cca_timer_fn()
H A Drc.c1913 unsigned long nsec = 1024 * ccti_timer; process_becn() local
1915 hrtimer_start(&cca_timer->hrtimer, ns_to_ktime(nsec), process_becn()
/linux-4.4.14/drivers/infiniband/hw/qib/
H A Dqib_mad.h88 /* number of 4nsec cycles equaling 2secs */
H A Dqib_iba7220.c478 /* HW counter clock is at 4nsec */
2422 * 0x00 = 10x link transfer rate or 4 nsec. for 2.5Gbs qib_7220_get_ib_cfg()
H A Dqib_iba7322.c226 /* HW counter clock is at 4nsec */
4088 * 0x00 = 10x link transfer rate or 4 nsec. for 2.5Gbs qib_7322_get_ib_cfg()
/linux-4.4.14/arch/cris/arch-v10/kernel/
H A Dtime.c67 /* Convert timer value to nsec */ cris_v10_gettimeoffset()
/linux-4.4.14/drivers/staging/rdma/ipath/
H A Dipath_mad.c852 * nsec. 0 == 4 nsec., 1 == 8 nsec., ..., 255 == 1020 nsec. Sample recv_pma_get_portsamplescontrol()
/linux-4.4.14/drivers/spi/
H A Dspi-bitbang.c206 dev_dbg(&spi->dev, "%s, %u nsec/bit\n", __func__, 2 * cs->nsecs); spi_bitbang_setup()
H A Dspi-txx9.c159 /* CS setup/hold/recovery time in nsec */ txx9spi_work_one()
/linux-4.4.14/drivers/scsi/aic7xxx/
H A Daic7xxx_93cx6.c57 * 1 usec, with the clock high and low a minimum of 750 and 250 nsec
/linux-4.4.14/drivers/clocksource/
H A Dtcb_clksrc.c21 * resolution better than 200 nsec).
/linux-4.4.14/include/net/
H A Dcodel.h59 /* CoDel uses a 1024 nsec clock, encoded in u32
/linux-4.4.14/fs/btrfs/
H A Dioctl.c71 __u32 nsec; member in struct:btrfs_ioctl_timespec_32
5170 sa->rtime.nsec = ct.tv_nsec; _btrfs_ioctl_set_received_subvol()
5184 btrfs_set_stack_timespec_nsec(&root_item->stime, sa->stime.nsec); _btrfs_ioctl_set_received_subvol()
5186 btrfs_set_stack_timespec_nsec(&root_item->rtime, sa->rtime.nsec); _btrfs_ioctl_set_received_subvol()
5241 args64->stime.nsec = args32->stime.nsec; btrfs_ioctl_set_received_subvol_32()
5243 args64->rtime.nsec = args32->rtime.nsec; btrfs_ioctl_set_received_subvol_32()
5254 args32->stime.nsec = args64->stime.nsec; btrfs_ioctl_set_received_subvol_32()
5256 args32->rtime.nsec = args64->rtime.nsec; btrfs_ioctl_set_received_subvol_32()
H A Dctree.h705 __le32 nsec; member in struct:btrfs_timespec
2551 BTRFS_SETGET_FUNCS(timespec_nsec, struct btrfs_timespec, nsec, 32);
2553 BTRFS_SETGET_STACK_FUNCS(stack_timespec_nsec, struct btrfs_timespec, nsec, 32);
/linux-4.4.14/drivers/net/ethernet/intel/fm10k/
H A Dfm10k_ptp.c357 period = t->sec * 1000000000LL + t->nsec; fm10k_ptp_enable()
/linux-4.4.14/drivers/ata/
H A Dpata_at91.c194 * cycles = x [nsec] * f [Hz] / 10^9 [ns in sec] = calc_mck_cycles()
/linux-4.4.14/tools/perf/util/
H A Dutil.c410 /* make it nsec precision */ parse_nsec_time()
/linux-4.4.14/drivers/pci/pcie/
H A Daspm.c37 u32 l0s; /* L0s latency (nsec) */
38 u32 l1; /* L1 latency (nsec) */
/linux-4.4.14/drivers/crypto/
H A Dhifn_795x.c796 s64 nsec; hifn_rng_data_present() local
798 nsec = ktime_to_ns(ktime_sub(ktime_get(), dev->rngtime)); hifn_rng_data_present()
799 nsec -= dev->rng_wait_time; hifn_rng_data_present()
800 if (nsec <= 0) hifn_rng_data_present()
804 ndelay(nsec); hifn_rng_data_present()
/linux-4.4.14/arch/x86/lguest/
H A Dboot.c935 unsigned long sec, nsec; lguest_clock_read() local
953 nsec = lguest_data.time.tv_nsec; lguest_clock_read()
960 return sec*1000000000ULL + nsec; lguest_clock_read()
/linux-4.4.14/fs/fuse/
H A Ddir.c76 static u64 time_to_jiffies(unsigned long sec, unsigned long nsec) time_to_jiffies() argument
78 if (sec || nsec) { time_to_jiffies()
79 struct timespec ts = {sec, nsec}; time_to_jiffies()
/linux-4.4.14/drivers/sh/maple/
H A Dmaple.c103 * bits 31 - 16 timeout in units of 20nsec maple_dma_reset()
/linux-4.4.14/drivers/net/can/softing/
H A Dsofting_fw.c406 /* find nsec from card */ softing_raw2ktime()
/linux-4.4.14/drivers/gpu/drm/nouveau/nvkm/subdev/pmu/fuc/
H A Dgf100.fuc3.h955 /* 0x007f: nsec */
H A Dgf119.fuc4.h948 /* 0x0067: nsec */
H A Dgk208.fuc5.h946 /* 0x005d: nsec */
H A Dgt215.fuc3.h955 /* 0x007f: nsec */
/linux-4.4.14/arch/x86/kvm/
H A Di8254.c345 pr_debug("create pit timer, interval is %llu nsec\n", interval); create_pit_timer()
H A Dx86.c1184 wc.nsec = boot.tv_nsec; kvm_write_wall_clock()
1243 static inline u64 nsec_to_cycles(struct kvm_vcpu *vcpu, u64 nsec) nsec_to_cycles() argument
1245 return pvclock_scale_delta(nsec, vcpu->arch.virtual_tsc_mult, nsec_to_cycles()
/linux-4.4.14/kernel/trace/
H A Dtrace_output.c451 unsigned long long val; /* unit: nsec */
H A Dtrace.c242 unsigned long long ns2usecs(cycle_t nsec) ns2usecs() argument
244 nsec += 500; ns2usecs()
245 do_div(nsec, 1000); ns2usecs()
246 return nsec; ns2usecs()
H A Dtrace.h702 extern unsigned long long ns2usecs(cycle_t nsec);
/linux-4.4.14/drivers/infiniband/hw/cxgb4/
H A Ddevice.c169 seq_printf(seq, "%04u: sec %lu nsec %lu qid %u opcode " wr_log_show()
170 "%u %s 0x%x host_wr_delta sec %lu nsec %lu " wr_log_show()
/linux-4.4.14/kernel/events/
H A Dcore.c2884 static u64 perf_calculate_period(struct perf_event *event, u64 nsec, u64 count) perf_calculate_period() argument
2893 nsec_fls = fls64(nsec); perf_calculate_period()
2898 * We got @count in @nsec, with a target of sample_freq HZ perf_calculate_period()
2903 * @nsec * sample_freq perf_calculate_period()
2927 REDUCE_FLS(nsec, frequency); perf_calculate_period()
2932 divisor = nsec * frequency; perf_calculate_period()
2944 REDUCE_FLS(nsec, frequency); perf_calculate_period()
2948 divisor = nsec * frequency; perf_calculate_period()
2960 static void perf_adjust_period(struct perf_event *event, u64 nsec, u64 count, bool disable) perf_adjust_period() argument
2966 period = perf_calculate_period(event, nsec, count); perf_adjust_period()
/linux-4.4.14/drivers/media/dvb-core/
H A Ddvb_demux.c422 1000000); /* nsec -> usec */ dvb_dmx_swfilter_packet()
/linux-4.4.14/drivers/net/wireless/ath/ath10k/
H A Drx_desc.h1151 * nsec. The value starts at 0 and increments to 79 and
/linux-4.4.14/drivers/cpufreq/
H A Dlonghaul.c909 policy->cpuinfo.transition_latency = 200000; /* nsec */ longhaul_cpu_init()
/linux-4.4.14/fs/ext4/
H A Dext4.h693 __le32 i_ctime_extra; /* extra Change time (nsec << 2 | epoch) */
694 __le32 i_mtime_extra; /* extra Modification time(nsec << 2 | epoch) */
695 __le32 i_atime_extra; /* extra Access time (nsec << 2 | epoch) */
697 __le32 i_crtime_extra; /* extra FileCreationtime (nsec << 2 | epoch) */
/linux-4.4.14/include/linux/usb/
H A Dhcd.h611 #define USB2_HOST_DELAY 5 /* nsec, guess */
/linux-4.4.14/tools/perf/
H A Dbuiltin-kvm.c1363 kvm->duration *= NSEC_PER_USEC; /* convert usec to nsec */ kvm_events_live()
/linux-4.4.14/drivers/usb/host/
H A Dehci-q.c792 * - allowing for high bandwidth, how many nsec/uframe are used? qh_make()
H A Doxu210hp-hcd.c1382 * - allowing for high bandwidth, how many nsec/uframe are used? qh_make()
H A Dfotg210-hcd.c2774 * - allowing for high bandwidth, how many nsec/uframe are used? qh_make()
/linux-4.4.14/drivers/net/ethernet/mellanox/mlx5/core/
H A Dcmd.c802 "fw exec time for %s is %lld nsec\n", mlx5_cmd_invoke()
/linux-4.4.14/drivers/net/ethernet/dlink/
H A Ddl2k.c490 /* Set RIO to poll every N*320nsec. */ rio_open()
H A Dsundance.c888 /* Set the chip to poll every N*320nsec. */ netdev_open()
/linux-4.4.14/fs/nfs/
H A Dnfs4xdr.c4063 uint32_t nsec; decode_attr_time() local
4069 nsec = be32_to_cpup(p); decode_attr_time()
4071 time->tv_nsec = (long)nsec; decode_attr_time()
/linux-4.4.14/fs/nfsd/
H A Dvfs.c1384 /* XXX someone who knows this better please fix it for nsec */ do_nfsd_create()
/linux-4.4.14/drivers/net/ethernet/broadcom/
H A Dtg3.c6268 u64 nsec; tg3_ptp_enable() local
6270 nsec = rq->perout.start.sec * 1000000000ULL + tg3_ptp_enable()
6271 rq->perout.start.nsec; tg3_ptp_enable()
6273 if (rq->perout.period.sec || rq->perout.period.nsec) { tg3_ptp_enable()
6280 if (nsec & (1ULL << 63)) { tg3_ptp_enable()
6282 "Start value (nsec) is over limit. Maximum size of start is only 63 bits\n"); tg3_ptp_enable()
6287 tw32(TG3_EAV_WATCHDOG0_LSB, (nsec & 0xffffffff)); tg3_ptp_enable()
6290 ((nsec >> 32) & TG3_EAV_WATCHDOG_MSB_MASK)); tg3_ptp_enable()
/linux-4.4.14/fs/ocfs2/
H A Ddlmglue.c2053 u32 nsec = spec->tv_nsec; ocfs2_pack_timespec() local
2055 res = (sec << OCFS2_SEC_SHIFT) | (nsec & OCFS2_NSEC_MASK); ocfs2_pack_timespec()
/linux-4.4.14/kernel/printk/
H A Dprintk.c192 * 0000 ff 8f 00 00 00 00 00 00 monotonic time in nsec
/linux-4.4.14/drivers/char/ipmi/
H A Dipmi_si_intf.c1019 * Use -1 in the nsec value of the busy waiting timespec to tell that

Completed in 6473 milliseconds