mbgtools-lx
4.2.8
|
#include <pcpsdrvr.h>
Go to the source code of this file.
Macros | |
#define | _ext extern |
Typedefs | |
typedef int(* | MBGCLOCK_DEFAULT_GET_FAST_HR_TIMESTAMP_FNC) (PCPS_TIME_STAMP *p_ts) |
typedef int(* | MBGCLOCK_DEFAULT_GET_FAST_HR_TIMESTAMP_CYCLES_FNC) (PCPS_TIME_STAMP_CYCLES *p_ts_cyc) |
typedef int(* | MBGCLOCK_DEFAULT_CLR_UCAP_BUFF_FNC) (void) |
typedef int(* | MBGCLOCK_DEFAULT_GET_UCAP_ENTRIES_FNC) (PCPS_UCAP_ENTRIES *p) |
typedef int(* | MBGCLOCK_DEFAULT_GET_UCAP_EVENT_FNC) (PCPS_HR_TIME *p) |
Functions | |
int | mbgclock_default_get_fast_hr_timestamp (PCPS_TIME_STAMP *p_ts) |
Read a high resolution PCPS_TIME_STAMP structure via memory mapped access. More... | |
int | mbgclock_default_get_fast_hr_timestamp_cycles (PCPS_TIME_STAMP_CYCLES *p_ts_cyc) |
Read a high resolution PCPS_TIME_STAMP_CYCLES structure via memory mapped access. More... | |
int | mbgclock_default_clr_ucap_buff (void) |
Clear the on-board user capture FIFO buffer. More... | |
int | mbgclock_default_get_ucap_entries (PCPS_UCAP_ENTRIES *p) |
Read user capture FIFO information. More... | |
int | mbgclock_default_get_ucap_event (PCPS_HR_TIME *p) |
Retrieve single time capture event. More... | |
#define _ext extern |
Definition at line 113 of file mbgclock.h.
typedef int(* MBGCLOCK_DEFAULT_CLR_UCAP_BUFF_FNC) (void) |
Definition at line 131 of file mbgclock.h.
typedef int(* MBGCLOCK_DEFAULT_GET_FAST_HR_TIMESTAMP_CYCLES_FNC) (PCPS_TIME_STAMP_CYCLES *p_ts_cyc) |
Definition at line 129 of file mbgclock.h.
typedef int(* MBGCLOCK_DEFAULT_GET_FAST_HR_TIMESTAMP_FNC) (PCPS_TIME_STAMP *p_ts) |
Definition at line 128 of file mbgclock.h.
typedef int(* MBGCLOCK_DEFAULT_GET_UCAP_ENTRIES_FNC) (PCPS_UCAP_ENTRIES *p) |
Definition at line 132 of file mbgclock.h.
typedef int(* MBGCLOCK_DEFAULT_GET_UCAP_EVENT_FNC) (PCPS_HR_TIME *p) |
Definition at line 133 of file mbgclock.h.
int mbgclock_default_clr_ucap_buff | ( | void | ) |
Clear the on-board user capture FIFO buffer.
Clear the user capture FIFO buffer on the first device registered by the driver which supports this call.
This function can be called from other kernel drivers to clear the user capture FIFO buffer on the first device registered by the driver which supports this call.
Definition at line 2781 of file mbgclock_main.c.
References _mbgddmsg_fnc_entry, _mbgddmsg_fnc_exit, _mbgddmsg_fnc_exit_err_dec, _pcps_sem_dec, _pcps_sem_inc_safe, _pcps_write_byte, EXPORT_SYMBOL(), MBG_ERR_IRQ_UNSAFE, MBG_ERR_NOT_SUPP_BY_DEV, and PCPS_CLR_UCAP_BUFF.
int mbgclock_default_get_fast_hr_timestamp | ( | PCPS_TIME_STAMP * | p_ts | ) |
Read a high resolution PCPS_TIME_STAMP structure via memory mapped access.
Read a high resolution PCPS_TIME_STAMP structure via memory mapped access. This function can be called from other kernel drivers and reads the timestamp from the first device registered by the driver which supports this call.
*p_ts | Pointer to a PCPS_TIME_STAMP structure to be filled up |
This function can be called from other kernel drivers to read a timestamp of the current time from the first device registered by the driver which supports this call.
*p_ts | Pointer to a PCPS_TIME_STAMP structure to be filled up |
Definition at line 2708 of file mbgclock_main.c.
References _mbg_swab_pcps_time_stamp, _mbgddmsg_fnc_entry, _mbgddmsg_fnc_exit, do_get_fast_hr_timestamp_safe(), EXPORT_SYMBOL(), MBG_ERR_NOT_SUPP_BY_DEV, and MBG_SUCCESS.
int mbgclock_default_get_fast_hr_timestamp_cycles | ( | PCPS_TIME_STAMP_CYCLES * | p_ts_cyc | ) |
Read a high resolution PCPS_TIME_STAMP_CYCLES structure via memory mapped access.
Read a high resolution PCPS_TIME_STAMP_CYCLES structure via memory mapped access. This function can be called from other kernel drivers and reads the timestamp from the first device registered by the driver which supports this call, plus an associated cycles counter which can be used to determine the latency.
*p_ts_cyc | Pointer to a PCPS_TIME_STAMP_CYCLES structure to be filled up |
This function can be called from other kernel drivers to read a timestamp of the current time from the first device registered by the driver which supports this call. The returned structure also contains an associated cycles counter value which can be used to determine the latency.
*p_ts_cyc | Pointer to a PCPS_TIME_STAMP_CYCLES structure to be filled up |
Definition at line 2745 of file mbgclock_main.c.
References _mbg_swab_pcps_time_stamp_cycles, _mbgddmsg_fnc_entry, _mbgddmsg_fnc_exit, do_get_fast_hr_timestamp_cycles_safe(), EXPORT_SYMBOL(), MBG_ERR_NOT_SUPP_BY_DEV, and MBG_SUCCESS.
int mbgclock_default_get_ucap_entries | ( | PCPS_UCAP_ENTRIES * | p | ) |
Read user capture FIFO information.
Read a PCPS_UCAP_ENTRIES structure to retrieve the number of saved user capture events and the maximum capture buffer sizefrom the first device registered by the driver which supports this call.
Read a PCPS_UCAP_ENTRIES structure to retrieve the number of saved user capture events and the maximum capture buffer size from the first device registered by the driver which supports this call.
Definition at line 2823 of file mbgclock_main.c.
References _mbg_swab_pcps_ucap_entries, _mbgddmsg_4, _mbgddmsg_fnc_entry, _mbgddmsg_fnc_exit_err_dec, _pcps_read_var, _pcps_sem_dec, _pcps_sem_inc_safe, EXPORT_SYMBOL(), PCPS_UCAP_ENTRIES::max, MBG_ERR_IRQ_UNSAFE, MBG_ERR_NOT_SUPP_BY_DEV, MBG_LOG_FMT_LEAVING, MBG_LOG_INFO, PCPS_GIVE_UCAP_ENTRIES, and PCPS_UCAP_ENTRIES::used.
int mbgclock_default_get_ucap_event | ( | PCPS_HR_TIME * | p | ) |
Retrieve single time capture event.
Retrieve a single time capture event from the on-board FIFO buffer of the first device registered by the driver which supports this call. The captured event time is returned in a PCPS_HR_TIME structure. The oldest entry of the FIFO is retrieved and then removed from the FIFO. If no capture event is available in the FIFO buffer then both the seconds and the fractions of the returned timestamp are 0.
Retrieve a single time capture event from the on-board FIFO buffer of the first device registered by the driver which supports this call. The captured event time is returned in a PCPS_HR_TIME structure. The oldest entry of the FIFO is retrieved and then removed from the FIFO. If no capture event is available in the FIFO buffer then both the seconds and the fractions of the returned timestamp are 0.
Definition at line 2871 of file mbgclock_main.c.
References _mbg_swab_pcps_hr_time, _mbgddmsg_4, _mbgddmsg_fnc_entry, _mbgddmsg_fnc_exit_err_dec, _pcps_read_var, _pcps_sem_dec, _pcps_sem_inc_safe, EXPORT_SYMBOL(), PCPS_TIME_STAMP::frac, MBG_ERR_IRQ_UNSAFE, MBG_ERR_NOT_SUPP_BY_DEV, MBG_LOG_FMT_LEAVING, MBG_LOG_INFO, PCPS_GIVE_UCAP_EVENT, PCPS_TIME_STAMP::sec, and PCPS_HR_TIME::tstamp.