mbgtools-lx  4.2.8
pcpsdev.h File Reference
#include <mbg_tgt.h>
#include <mbgtime.h>
#include <mbgsystm.h>
#include <mbgpccyc.h>
#include <pcpsdefs.h>
#include <gpsdefs.h>
#include <usbdefs.h>
#include <use_pack.h>
#include <string.h>
#include <unistd.h>

Go to the source code of this file.

Data Structures

struct  MBG_SYS_TIME_CYCLES
 System time plus associated cycles counter values. More...
 
struct  PCPS_DEV_TYPE
 Device type specification. More...
 
struct  PCPS_SHORT_PORT_RSRC
 An I/O port resource used by a device. More...
 
struct  PCPS_MAPPED_MEM
 A structure used to retrieve an address to be mapped into user space. More...
 
struct  PCPS_DEV_CFG
 Device information. More...
 
struct  PCPS_DEV
 Device info structure. More...
 
struct  PCPS_DRVR_INFO
 Device driver information. More...
 
struct  PCPS_TIME_CYCLES
 Time read from a device plus associated system cycles count. More...
 
struct  PCPS_TIME_STAMP_CYCLES
 High resolution time stamp plus associated system cycles count. More...
 
struct  PCPS_HR_TIME_CYCLES
 High resolution time plus associated system cycles count. More...
 
struct  MBG_TIME_INFO_HRT
 High resolution device time, system time, and associated cycles counts. More...
 
struct  MBG_TIME_INFO_TSTAMP
 High resolution device time stamp, system time, and associated cycles counts. More...
 

Macros

#define MBG_TGT_SUPP_MEM_ACC   1
 
#define _mbg_swab_mbg_sys_time_cycles(_p)
 
#define PCPS_BUS_ISA   0x0001
 IBM compatible PC/AT ISA bus. More...
 
#define PCPS_BUS_MCA   0x0002
 IBM PS/2 micro channel. More...
 
#define PCPS_BUS_PCI   0x0004
 PCI. More...
 
#define PCPS_BUS_USB   0x0008
 USB. More...
 
#define PCPS_BUS_PCI_CHIP_S5920   0x8000
 S5920 PCI interface chip. More...
 
#define PCPS_BUS_PCI_CHIP_ASIC   0x4000
 Meinberg's own PCI interface chip. More...
 
#define PCPS_BUS_PCI_CHIP_PEX8311   0x2000
 PEX8311 PCI Express interface chip. More...
 
#define PCPS_BUS_PCI_CHIP_MBGPEX   0x1000
 Meinberg's own PCI Express interface chip. More...
 
#define PCPS_BUS_PCI_S5933   ( PCPS_BUS_PCI )
 
#define PCPS_BUS_PCI_S5920   ( PCPS_BUS_PCI | PCPS_BUS_PCI_CHIP_S5920 )
 
#define PCPS_BUS_PCI_ASIC   ( PCPS_BUS_PCI | PCPS_BUS_PCI_CHIP_ASIC )
 
#define PCPS_BUS_PCI_PEX8311   ( PCPS_BUS_PCI | PCPS_BUS_PCI_CHIP_PEX8311 )
 
#define PCPS_BUS_PCI_MBGPEX   ( PCPS_BUS_PCI | PCPS_BUS_PCI_CHIP_MBGPEX )
 
#define PCPS_BUS_USB_FLAG_V2   0x8000
 
#define PCPS_BUS_USB_V2   ( PCPS_BUS_USB | PCPS_BUS_USB_FLAG_V2 )
 
#define PCPS_CLOCK_NAME_SZ   10
 
#define N_PCPS_PORT_RSRC   2
 The max. number of I/O port resources used by a clock. More...
 
#define PCPS_FEATURE_NAMES
 
#define PCPS_FEAT_PC31PS31   0
 
#define PCPS_FEAT_LVL2
 
#define PCPS_FEAT_PC32   ( PCPS_FEAT_LVL2 )
 
#define PCPS_FEAT_PCI32   ( PCPS_FEAT_LVL2 )
 
#define PCPS_FEAT_PCI509
 
#define PCPS_FEAT_PCI510   ( PCPS_FEAT_PCI509 )
 
#define PCPS_FEAT_PCI511   ( PCPS_FEAT_PCI510 )
 
#define PCPS_FEAT_GPS167PC
 
#define PCPS_FEAT_GPS167PCI
 
#define PCPS_FEAT_GPS168PCI
 
#define PCPS_FEAT_GPS169PCI
 
#define PCPS_FEAT_GPS170PCI
 
#define PCPS_FEAT_TCR510PCI
 
#define PCPS_FEAT_TCR167PCI
 
#define PCPS_FEAT_TCR511PCI
 
#define PCPS_FEAT_PEX511   ( PCPS_FEAT_PCI511 )
 
#define PCPS_FEAT_TCR511PEX   ( PCPS_FEAT_TCR511PCI )
 
#define PCPS_FEAT_GPS170PEX   ( PCPS_FEAT_GPS170PCI )
 
#define PCPS_FEAT_USB5131
 
#define PCPS_FEAT_TCR51USB
 
#define PCPS_FEAT_MSF51USB
 
#define PCPS_FEAT_PTP270PEX
 
#define PCPS_FEAT_FRC511PEX
 
#define PCPS_FEAT_TCR170PEX   ( PCPS_FEAT_TCR167PCI )
 
#define PCPS_FEAT_WWVB51USB   ( PCPS_FEAT_MSF51USB )
 
#define PCPS_FEAT_GPS180PEX
 IRIG TX only supp. if GPS_HAS_IRIG_TX. More...
 
#define PCPS_FEAT_TCR180PEX
 IRIG TX only supp. if GPS_HAS_IRIG_TX. More...
 
#define PCPS_FEAT_DCF600USB   ( PCPS_FEAT_USB5131 )
 
#define PCPS_FEAT_PZF180PEX
 
#define PCPS_FEAT_TCR600USB
 
#define PCPS_FEAT_MSF600USB   ( PCPS_FEAT_MSF51USB )
 
#define PCPS_FEAT_WVB600USB   ( PCPS_FEAT_WWVB51USB )
 
#define PCPS_FEAT_GLN180PEX   ( PCPS_FEAT_GPS180PEX | PCPS_IS_GNSS )
 
#define PCPS_FEAT_GPS180AMC   ( PCPS_FEAT_GPS180PEX )
 
#define PCPS_FEAT_GNS181PEX   ( PCPS_FEAT_GLN180PEX )
 
#define PCPS_FEAT_TCR180USB
 IRIG TX only supp. if GPS_HAS_IRIG_TX. More...
 
#define REV_HAS_IRQ_FIX_MINOR_PEX511   0x0106
 
#define REV_HAS_IRQ_FIX_MINOR_TCR511PEX   0x0105
 
#define REV_HAS_IRQ_FIX_MINOR_GPS170PEX   0x0104
 
#define _pcps_pex_irq_is_safe(_curr_fw_ver, _req_fw_ver, _curr_asic_ver, _req_asic_ver_major, _req_asic_ver_minor)
 
#define REV_HAS_RAW_IRIG_DATA_TCR511PEX   0x0111
 
#define REV_HAS_RAW_IRIG_DATA_TCR511PCI   0x0111
 
#define REV_HAS_RAW_IRIG_DATA_TCR51USB   0x0106
 
#define REV_HAS_IRIG_TIME_TCR511PEX   0x0109
 
#define REV_HAS_IRIG_TIME_TCR511PCI   0x0109
 
#define REV_HAS_IRIG_TIME_TCR51USB   0x0106
 
#define REV_HAS_IRIG_CTRL_BITS_TCR511PEX   0x0107
 
#define REV_HAS_IRIG_CTRL_BITS_TCR511PCI   0x0107
 
#define REV_HAS_IRIG_CTRL_BITS_TCR51USB   0x0106
 
#define REV_HAS_GPS_DATA_16_GPS169PCI   0x0202
 
#define REV_HAS_SERIAL_HS_PCI509   0x0104
 
#define REV_HAS_UCAP_GPS167PCI   0x0421
 
#define REV_HAS_UCAP_GPS168PCI   0x0104
 
#define REV_CAN_CLR_UCAP_BUFF_GPS167PCI   0x0419
 
#define REV_CAN_CLR_UCAP_BUFF_GPS168PCI   0x0101
 
#define REV_HAS_CABLE_LEN_GPS167PCI   0x0411
 
#define REV_HAS_CABLE_LEN_GPS167PC   0x0411
 
#define REV_HAS_HR_TIME_GPS167PC   0x0305
 
#define REV_HAS_HR_TIME_TCR510PCI   0x0200
 
#define REV_HAS_HR_TIME_PEX511   0x0105
 
#define REV_HAS_HR_TIME_PCI511   0x0103
 
#define REV_HAS_UTC_OFFS_PC31PS31   0x0300
 
#define REV_HAS_SYNC_TIME_PC31PS31   0x0300
 
#define REV_HAS_SERIAL_PC31PS31   0x0300
 
#define REV_GIVE_TIME_NOCLEAR_PC31PS31   0x0300
 
#define REV_PCPS_LS_ANN_PC31PS31   0x0300
 
#define REV_PCPS_IFTM_PC31PS31   0x0300
 
#define REV_CAN_SET_TIME_PC31PS31   0x0240
 
#define _USE_DEV_MACROS   1
 
#define _pcps_type_num(_d)   ( (_d)->type.num )
 
#define _pcps_type_name(_d)   ( (_d)->type.name )
 
#define _pcps_dev_id(_d)   ( (_d)->type.dev_id )
 
#define _pcps_ref_type(_d)   ( (_d)->type.ref_type )
 
#define _pcps_bus_flags(_d)   ( (_d)->type.bus_flags )
 
#define _pcps_is_gps(_d)   ( _pcps_ref_type( _d ) == PCPS_REF_GPS )
 
#define _pcps_is_dcf(_d)   ( _pcps_ref_type( _d ) == PCPS_REF_DCF )
 
#define _pcps_is_msf(_d)   ( _pcps_ref_type( _d ) == PCPS_REF_MSF )
 
#define _pcps_is_wwvb(_d)   ( _pcps_ref_type( _d ) == PCPS_REF_WWVB )
 
#define _pcps_is_irig_rx(_d)   ( _pcps_ref_type( _d ) == PCPS_REF_IRIG )
 
#define _pcps_is_ptp(_d)   ( _pcps_ref_type( _d ) == PCPS_REF_PTP )
 
#define _pcps_is_frc(_d)   ( _pcps_ref_type( _d ) == PCPS_REF_FRC )
 
#define _pcps_is_gnss(_d)   _pcps_has_feature( (_d), PCPS_IS_GNSS )
 
#define _pcps_is_lwr(_d)   ( _pcps_is_dcf( _d ) || _pcps_is_msf( _d ) || _pcps_is_wwvb( _d ) )
 
#define _pcps_is_isa(_d)   ( _pcps_bus_flags( _d ) & PCPS_BUS_ISA )
 
#define _pcps_is_mca(_d)   ( _pcps_bus_flags( _d ) & PCPS_BUS_MCA )
 
#define _pcps_is_pci(_d)   ( _pcps_bus_flags( _d ) & PCPS_BUS_PCI )
 
#define _pcps_is_usb(_d)   ( _pcps_bus_flags( _d ) & PCPS_BUS_USB )
 
#define _pcps_is_usb_v2(_d)   ( _pcps_bus_flags( _d ) == PCPS_BUS_USB_V2 )
 
#define _pcps_is_pci_s5933(_d)   ( _pcps_bus_flags( _d ) == PCPS_BUS_PCI_S5933 )
 
#define _pcps_is_pci_s5920(_d)   ( _pcps_bus_flags( _d ) == PCPS_BUS_PCI_S5920 )
 
#define _pcps_is_pci_amcc(_d)   ( _pcps_is_pci_s5920( _d ) || _pcps_is_pci_s5933( _d ) )
 
#define _pcps_is_pci_asic(_d)   ( _pcps_bus_flags( _d ) == PCPS_BUS_PCI_ASIC )
 
#define _pcps_is_pci_pex8311(_d)   ( _pcps_bus_flags( _d ) == PCPS_BUS_PCI_PEX8311 )
 
#define _pcps_is_pci_mbgpex(_d)   ( _pcps_bus_flags( _d ) == PCPS_BUS_PCI_MBGPEX )
 
#define _pcps_bus_num(_d)   ( (_d)->cfg.bus_num )
 
#define _pcps_slot_num(_d)   ( (_d)->cfg.slot_num )
 
#define _pcps_cfg_short_port_rsrc(_c, _n)   ( (_c)->port[_n] )
 
#define _pcps_short_port_rsrc(_d, _n)   _pcps_cfg_short_port_rsrc( &(_d)->cfg, (_n) )
 
#define _pcps_cfg_short_port_base(_c, _n)   ( _pcps_cfg_short_port_rsrc( (_c), (_n) ).base )
 
#define _pcps_short_port_base(_d, _n)   ( _pcps_short_port_rsrc( (_d), (_n) ).base )
 
#define _pcps_cfg_irq_num(_c)   ( (_c)->irq_num )
 
#define _pcps_irq_num(_d)   _pcps_cfg_irq_num( &(_d)->cfg )
 
#define _pcps_cfg_timeout_clk(_c)   ( (_c)->timeout_clk )
 
#define _pcps_timeout_clk(_d)   _pcps_cfg_timeout_clk( &(_d)->cfg )
 
#define _pcps_fw_rev_num(_d)   ( (_d)->cfg.fw_rev_num )
 
#define _pcps_features(_d)   ( (_d)->cfg.features )
 
#define _pcps_fw_id(_d)   ( (_d)->cfg.fw_id )
 
#define _pcps_sernum(_d)   ( (_d)->cfg.sernum )
 
#define _pcps_err_flags(_d)   ( (_d)->cfg.err_flags )
 
#define _pcps_chk_err_flags(_d, _msk)   ( _pcps_err_flags( _d ) & (_msk) )
 
#define _pcps_set_err_flags(_d, _msk)   ( _pcps_err_flags( _d ) |= (_msk) )
 
#define _pcps_clr_err_flags(_d, _msk)   ( _pcps_err_flags( _d ) &= ~(_msk) )
 
#define _pcps_has_feature(_d, _f)   ( ( (_d)->cfg.features & (_f) ) != 0 )
 Check whether a special feature is supported. More...
 
#define _pcps_has_ri_feature(_p_ri, _f)   ( ( (_p_ri)->features & (_f) ) != 0 )
 Check whether a special feature is supported according to RECEIVER_INFO. More...
 
#define _ri_addr(_p)   &(_p)->xdev_features.receiver_info
 
#define _xfeat_addr(_p)   &(_p)->xdev_features.xfeature_buffer
 
#define _tlv_info_addr(_p)   &(_p)->xdev_features.tlv_info
 
#define _tlv_feat_buffp(_p)   &(_p)->xdev_features.tlv_info.supp_tlv_feat
 
#define _pcps_can_set_time(_d)   _pcps_has_feature( (_d), PCPS_CAN_SET_TIME )
 
#define _pcps_has_serial(_d)   _pcps_has_feature( (_d), PCPS_HAS_SERIAL )
 
#define _pcps_has_sync_time(_d)   _pcps_has_feature( (_d), PCPS_HAS_SYNC_TIME )
 
#define _pcps_has_ident(_d)   _pcps_has_feature( (_d), PCPS_HAS_IDENT )
 
#define _pcps_has_utc_offs(_d)   _pcps_has_feature( (_d), PCPS_HAS_UTC_OFFS )
 
#define _pcps_has_hr_time(_d)   _pcps_has_feature( (_d), PCPS_HAS_HR_TIME )
 
#define _pcps_has_sernum(_d)   _pcps_has_feature( (_d), PCPS_HAS_SERNUM )
 
#define _pcps_has_cab_len(_d)   _pcps_has_feature( (_d), PCPS_HAS_CABLE_LEN )
 
#define _pcps_has_tzdl(_d)   _pcps_has_feature( (_d), PCPS_HAS_TZDL )
 
#define _pcps_has_pcps_tzdl(_d)   _pcps_has_feature( (_d), PCPS_HAS_PCPS_TZDL )
 
#define _pcps_has_tzcode(_d)   _pcps_has_feature( (_d), PCPS_HAS_TZCODE )
 
#define _pcps_has_tz(_d)
 
#define _pcps_has_event_time(_d)   _pcps_has_feature( (_d), PCPS_HAS_EVENT_TIME )
 
#define _pcps_has_receiver_info(_d)   _pcps_has_feature( (_d), PCPS_HAS_RECEIVER_INFO )
 
#define _pcps_can_clr_ucap_buff(_d)   _pcps_has_feature( (_d), PCPS_CAN_CLR_UCAP_BUFF )
 
#define _pcps_has_ucap(_d)   _pcps_has_feature( (_d), PCPS_HAS_UCAP )
 
#define _pcps_has_irig_tx(_d)   _pcps_has_feature( (_d), PCPS_HAS_IRIG_TX )
 
#define _pcps_has_serial_hs(_d)
 
#define _pcps_has_signal(_d)   ( _pcps_is_dcf( _d ) || _pcps_is_msf( _d ) || _pcps_is_wwvb( _d ) || _pcps_is_irig_rx( _d ) )
 
#define _pcps_has_mod(_d)   ( _pcps_is_dcf( _d ) || _pcps_is_msf( _d ) || _pcps_is_wwvb( _d ) )
 
#define _pcps_has_irig(_d)   ( _pcps_is_irig_rx( _d ) || _pcps_has_irig_tx( _d ) )
 
#define _pcps_has_irig_ctrl_bits(_d)   _pcps_has_feature( (_d), PCPS_HAS_IRIG_CTRL_BITS )
 
#define _pcps_has_irig_time(_d)   _pcps_has_feature( (_d), PCPS_HAS_IRIG_TIME )
 
#define _pcps_has_raw_irig_data(_d)   _pcps_has_feature( (_d), PCPS_HAS_RAW_IRIG_DATA )
 
#define _pcps_has_ref_offs(_d)   _pcps_is_irig_rx( _d )
 
#define _pcps_ref_offs_out_of_range(_n)   ( ( (_n) > MBG_REF_OFFS_MAX ) || ( (_n) < -MBG_REF_OFFS_MAX ) )
 
#define _pcps_has_opt_flags(_d)   _pcps_is_irig_rx( _d )
 
#define _pcps_has_gps_data_16(_d)   _pcps_has_feature( (_d), PCPS_HAS_GPS_DATA_16 )
 
#define _pcps_has_gps_data(_d)   ( _pcps_is_gps( _d ) || _pcps_has_gps_data_16( _d ) )
 
#define _pcps_has_synth(_d)   _pcps_has_feature( (_d), PCPS_HAS_SYNTH )
 
#define _pcps_has_generic_io(_d)   _pcps_has_feature( (_d), PCPS_HAS_GENERIC_IO )
 
#define _pcps_has_time_scale(_d)   _pcps_has_feature( (_d), PCPS_HAS_TIME_SCALE )
 
#define _pcps_has_utc_parm(_d)   _pcps_has_feature( (_d), PCPS_HAS_UTC_PARM )
 
#define _pcps_has_asic_version(_d)
 
#define _pcps_has_asic_features(_d)   _pcps_has_asic_version( _d )
 
#define _pcps_has_fast_hr_timestamp(_d)   _pcps_has_feature( (_d), PCPS_HAS_FAST_HR_TSTAMP )
 
#define _pcps_has_lan_intf(_d)   _pcps_has_feature( (_d), PCPS_HAS_LAN_INTF )
 
#define _pcps_has_ptp(_d)   _pcps_has_feature( (_d), PCPS_HAS_PTP )
 
#define _pcps_has_ri_ptp_unicast(_p_ri)   _pcps_has_ri_feature( (_p_ri), GPS_HAS_PTP_UNICAST )
 
#define _pcps_has_pzf(_d)   _pcps_has_feature( (_d), PCPS_HAS_PZF )
 
#define _pcps_has_corr_info(_d)   _pcps_has_pzf( _d )
 
#define _pcps_has_tr_distance(_d)   _pcps_has_pzf( _d )
 
#define _pcps_has_evt_log(_d)   _pcps_has_feature( (_d), PCPS_HAS_EVT_LOG )
 
#define _pcps_has_debug_status(_d)   _pcps_is_irig_rx( _d )
 
#define _pcps_has_stat_info(_d)   ( _pcps_is_gps( _d ) || _pcps_has_pzf( _d ) )
 
#define _pcps_has_stat_info_mode(_d)   _pcps_is_gps( _d )
 
#define _pcps_has_stat_info_svs(_d)   _pcps_is_gps( _d )
 
#define _pcps_has_ri_gpio(_p_ri)   _pcps_has_ri_feature( (_p_ri), GPS_HAS_GPIO )
 
#define _pcps_has_ri_xmr(_p_ri)
 
#define _pcps_incoming_tfom_ignored(_d)
 
#define _pcps_pci_cfg_err(_d)
 
#define _pcps_fw_has_20ms_bug(_d)
 
#define _pcps_time_set_unread(_t)   do { (_t)->sec = 0xFF; } while ( 0 )
 
#define _pcps_time_is_read(_t)   ( (uchar) (_t)->sec != 0xFF )
 
#define _mbg_swab_pcps_time_stamp_cycles(_p)
 
#define _mbg_swab_pcps_hr_time_cycles(_p)
 
#define _mbg_swab_mbg_time_info_hrt(_p)
 
#define _mbg_swab_mbg_time_info_tstamp(_p)
 
#define PCPS_IRQ_STAT_ENABLE_CALLED   0x01
 
#define PCPS_IRQ_STAT_ENABLED   0x02
 
#define PCPS_IRQ_STAT_UNSAFE   0x04
 
#define PCPS_IRQ_STATE_DANGER   ( PCPS_IRQ_STAT_ENABLED | PCPS_IRQ_STAT_UNSAFE )
 
#define PCPS_FW_STR_FMT   "%X.%02X"
 
#define _pcps_fw_rev_num_major(_v)   ( (_v) >> 8 )
 
#define _pcps_fw_rev_num_minor(_v)   ( (_v) & 0xFF )
 
#define MBG_DEV_NAME_FMT   "%s_%s"
 A string format specifier for MBG_DEV_NAME. More...
 
#define PCPS_EF_TIMEOUT   0x00000001
 Possible device initialization error flags. More...
 
#define PCPS_EF_INV_FW_ID   0x00000002
 invalid firmware ID More...
 
#define PCPS_EF_IO_INIT   0x00000004
 I/O interface not initialized. More...
 
#define PCPS_EF_IO_CFG   0x00000008
 I/O interface not configured. More...
 
#define PCPS_EF_IO_ENB   0x00000010
 I/O interface not enabled. More...
 
#define PCPS_EF_IO_RSRC_IO   0x00000020
 I/O resource not registered with resource manager. More...
 
#define PCPS_EF_IO_RSRC_MEM   0x00000040
 Memory resource not registered with resource manager. More...
 
#define PCPS_CAN_SET_TIME   ( 1UL << PCPS_BIT_CAN_SET_TIME )
 Feature bit masks for bus-level devices. More...
 
#define PCPS_HAS_SERIAL   ( 1UL << PCPS_BIT_HAS_SERIAL )
 see PCPS_BIT_HAS_SERIAL More...
 
#define PCPS_HAS_SYNC_TIME   ( 1UL << PCPS_BIT_HAS_SYNC_TIME )
 see PCPS_BIT_HAS_SYNC_TIME More...
 
#define PCPS_HAS_TZDL   ( 1UL << PCPS_BIT_HAS_TZDL )
 see PCPS_BIT_HAS_TZDL More...
 
#define PCPS_HAS_IDENT   ( 1UL << PCPS_BIT_HAS_IDENT )
 see PCPS_BIT_HAS_IDENT More...
 
#define PCPS_HAS_UTC_OFFS   ( 1UL << PCPS_BIT_HAS_UTC_OFFS )
 see PCPS_BIT_HAS_UTC_OFFS More...
 
#define PCPS_HAS_HR_TIME   ( 1UL << PCPS_BIT_HAS_HR_TIME )
 see PCPS_BIT_HAS_HR_TIME More...
 
#define PCPS_HAS_SERNUM   ( 1UL << PCPS_BIT_HAS_SERNUM )
 see PCPS_BIT_HAS_SERNUM More...
 
#define PCPS_HAS_TZCODE   ( 1UL << PCPS_BIT_HAS_TZCODE )
 see PCPS_BIT_HAS_TZCODE More...
 
#define PCPS_HAS_CABLE_LEN   ( 1UL << PCPS_BIT_HAS_CABLE_LEN )
 see PCPS_BIT_HAS_CABLE_LEN More...
 
#define PCPS_HAS_EVENT_TIME   ( 1UL << PCPS_BIT_HAS_EVENT_TIME )
 see PCPS_BIT_HAS_EVENT_TIME More...
 
#define PCPS_HAS_RECEIVER_INFO   ( 1UL << PCPS_BIT_HAS_RECEIVER_INFO )
 see PCPS_BIT_HAS_RECEIVER_INFO More...
 
#define PCPS_CAN_CLR_UCAP_BUFF   ( 1UL << PCPS_BIT_CAN_CLR_UCAP_BUFF )
 see PCPS_BIT_CAN_CLR_UCAP_BUFF More...
 
#define PCPS_HAS_PCPS_TZDL   ( 1UL << PCPS_BIT_HAS_PCPS_TZDL )
 see PCPS_BIT_HAS_PCPS_TZDL More...
 
#define PCPS_HAS_UCAP   ( 1UL << PCPS_BIT_HAS_UCAP )
 see PCPS_BIT_HAS_UCAP More...
 
#define PCPS_HAS_IRIG_TX   ( 1UL << PCPS_BIT_HAS_IRIG_TX )
 see PCPS_BIT_HAS_IRIG_TX More...
 
#define PCPS_HAS_GPS_DATA_16   ( 1UL << PCPS_BIT_HAS_GPS_DATA_16 )
 see PCPS_BIT_HAS_GPS_DATA_16 More...
 
#define PCPS_HAS_SYNTH   ( 1UL << PCPS_BIT_HAS_SYNTH )
 see PCPS_BIT_HAS_SYNTH More...
 
#define PCPS_HAS_GENERIC_IO   ( 1UL << PCPS_BIT_HAS_GENERIC_IO )
 see PCPS_BIT_HAS_GENERIC_IO More...
 
#define PCPS_HAS_TIME_SCALE   ( 1UL << PCPS_BIT_HAS_TIME_SCALE )
 see PCPS_BIT_HAS_TIME_SCALE More...
 
#define PCPS_HAS_UTC_PARM   ( 1UL << PCPS_BIT_HAS_UTC_PARM )
 see PCPS_BIT_HAS_UTC_PARM More...
 
#define PCPS_HAS_IRIG_CTRL_BITS   ( 1UL << PCPS_BIT_HAS_IRIG_CTRL_BITS )
 see PCPS_BIT_HAS_IRIG_CTRL_BITS More...
 
#define PCPS_HAS_LAN_INTF   ( 1UL << PCPS_BIT_HAS_LAN_INTF )
 see PCPS_BIT_HAS_LAN_INTF More...
 
#define PCPS_HAS_PTP   ( 1UL << PCPS_BIT_HAS_PTP )
 see PCPS_BIT_HAS_PTP More...
 
#define PCPS_HAS_IRIG_TIME   ( 1UL << PCPS_BIT_HAS_IRIG_TIME )
 see PCPS_BIT_HAS_IRIG_TIME More...
 
#define PCPS_HAS_FAST_HR_TSTAMP   ( 1UL << PCPS_BIT_HAS_FAST_HR_TSTAMP )
 see PCPS_BIT_HAS_FAST_HR_TSTAMP More...
 
#define PCPS_HAS_RAW_IRIG_DATA   ( 1UL << PCPS_BIT_HAS_RAW_IRIG_DATA )
 see PCPS_BIT_HAS_RAW_IRIG_DATA More...
 
#define PCPS_HAS_PZF   ( 1UL << PCPS_BIT_HAS_PZF )
 see PCPS_BIT_HAS_PZF More...
 
#define PCPS_HAS_EVT_LOG   ( 1UL << PCPS_BIT_HAS_EVT_LOG )
 see PCPS_BIT_HAS_EVT_LOG More...
 
#define PCPS_IS_GNSS   ( 1UL << PCPS_BIT_IS_GNSS )
 see PCPS_BIT_IS_GNSS More...
 

Typedefs

typedef uint8_t MBG_DBG_DATA
 
typedef uint16_t MBG_DBG_PORT
 
typedef char PCPS_CLOCK_NAME[10]
 
typedef uint16_t PCPS_DEV_ID
 
typedef uint16_t PCPS_REF_TYPE
 
typedef uint16_t PCPS_BUS_FLAGS
 
typedef uint16_t PCPS_SHORT_PORT_ADDR
 Legacy I/O address type, see PCPS_SHORT_PORT_RSRC. More...
 
typedef uint32_t PCPS_ERR_FLAGS
 see PCPS_ERR_FLAG_MASKS More...
 
typedef uint32_t PCPS_FEATURES
 see PCPS_FEATURE_MASKS More...
 
typedef uint16_t PCPS_BUS_NUM
 
typedef uint16_t PCPS_SLOT_NUM
 
typedef uint16_t PCPS_FW_REV_NUM
 firmware revision number, MSB major, LSB minor version More...
 
typedef uint32_t PCPS_IRQ_STAT_INFO
 
typedef char MBG_DEV_NAME[10+(16+1)+1]
 A string buffer for a unique device ID. More...
 

Enumerations

enum  PCPS_TYPES {
  PCPS_TYPE_PC31, PCPS_TYPE_PS31_OLD, PCPS_TYPE_PS31, PCPS_TYPE_PC32,
  PCPS_TYPE_PCI32, PCPS_TYPE_GPS167PC, PCPS_TYPE_GPS167PCI, PCPS_TYPE_PCI509,
  PCPS_TYPE_GPS168PCI, PCPS_TYPE_PCI510, PCPS_TYPE_GPS169PCI, PCPS_TYPE_TCR510PCI,
  PCPS_TYPE_TCR167PCI, PCPS_TYPE_GPS170PCI, PCPS_TYPE_PCI511, PCPS_TYPE_TCR511PCI,
  PCPS_TYPE_PEX511, PCPS_TYPE_TCR511PEX, PCPS_TYPE_GPS170PEX, PCPS_TYPE_USB5131,
  PCPS_TYPE_TCR51USB, PCPS_TYPE_MSF51USB, PCPS_TYPE_PTP270PEX, PCPS_TYPE_FRC511PEX,
  PCPS_TYPE_TCR170PEX, PCPS_TYPE_WWVB51USB, PCPS_TYPE_GPS180PEX, PCPS_TYPE_TCR180PEX,
  PCPS_TYPE_DCF600USB, PCPS_TYPE_PZF180PEX, PCPS_TYPE_TCR600USB, PCPS_TYPE_MSF600USB,
  PCPS_TYPE_WVB600USB, PCPS_TYPE_GLN180PEX, PCPS_TYPE_GPS180AMC, PCPS_TYPE_GNS181PEX,
  PCPS_TYPE_TCR180USB, N_PCPS_DEV_TYPE
}
 A list of known devices. More...
 
enum  PCPS_FEATURE_BITS {
  PCPS_BIT_CAN_SET_TIME, PCPS_BIT_HAS_SERIAL, PCPS_BIT_HAS_SYNC_TIME, PCPS_BIT_HAS_TZDL,
  PCPS_BIT_HAS_IDENT, PCPS_BIT_HAS_UTC_OFFS, PCPS_BIT_HAS_HR_TIME, PCPS_BIT_HAS_SERNUM,
  PCPS_BIT_HAS_TZCODE, PCPS_BIT_HAS_CABLE_LEN, PCPS_BIT_HAS_EVENT_TIME, PCPS_BIT_HAS_RECEIVER_INFO,
  PCPS_BIT_CAN_CLR_UCAP_BUFF, PCPS_BIT_HAS_PCPS_TZDL, PCPS_BIT_HAS_UCAP, PCPS_BIT_HAS_IRIG_TX,
  PCPS_BIT_HAS_GPS_DATA_16, PCPS_BIT_HAS_SYNTH, PCPS_BIT_HAS_GENERIC_IO, PCPS_BIT_HAS_TIME_SCALE,
  PCPS_BIT_HAS_UTC_PARM, PCPS_BIT_HAS_IRIG_CTRL_BITS, PCPS_BIT_HAS_LAN_INTF, PCPS_BIT_HAS_PTP,
  PCPS_BIT_HAS_IRIG_TIME, PCPS_BIT_HAS_FAST_HR_TSTAMP, PCPS_BIT_HAS_RAW_IRIG_DATA, PCPS_BIT_HAS_PZF,
  PCPS_BIT_HAS_EVT_LOG, PCPS_BIT_IS_GNSS, N_PCPS_FEATURE_BITS
}
 Feature bits for bus-level devices. More...
 
enum  DEV_FEAT_TYPES {
  DEV_FEAT_TYPE_BUILTIN, DEV_FEAT_TYPE_REF_TYPE, DEV_FEAT_TYPE_PCPS, DEV_FEAT_TYPE_RI,
  DEV_FEAT_TYPE_XFEAT, DEV_FEAT_TYPE_TLV_FEAT, N_DEV_FEAT_TYPES
}
 Codes used with IOCTL_DEV_FEAT_REQ::feat_type. More...
 

Functions

static __mbg_inline void setup_hr_time_cycles_from_timestamp_cycles (PCPS_HR_TIME_CYCLES *p_ht_c, const PCPS_TIME_STAMP_CYCLES *p_ts_c)
 

Macro Definition Documentation

◆ _mbg_swab_mbg_sys_time_cycles

#define _mbg_swab_mbg_sys_time_cycles (   _p)
Value:
do \
{ \
_mbg_swab_mbg_pc_cycles( &(_p)->cyc_before ); \
_mbg_swab_mbg_pc_cycles( &(_p)->cyc_after ); \
_mbg_swab_mbg_sys_time( &(_p)->sys_time ); \
} while ( 0 )

Definition at line 394 of file pcpsdev.h.

◆ _mbg_swab_mbg_time_info_hrt

#define _mbg_swab_mbg_time_info_hrt (   _p)
Value:
do \
{ \
_mbg_swab_pcps_hr_time_cycles( &(_p)->ref_hr_time_cycles ); \
_mbg_swab_mbg_sys_time_cycles( &(_p)->sys_time_cycles ); \
} while ( 0 )

Definition at line 1425 of file pcpsdev.h.

Referenced by mbg_get_time_info_hrt().

◆ _mbg_swab_mbg_time_info_tstamp

#define _mbg_swab_mbg_time_info_tstamp (   _p)
Value:
do \
{ \
_mbg_swab_pcps_time_stamp_cycles( &(_p)->ref_tstamp_cycles ); \
_mbg_swab_mbg_sys_time_cycles( &(_p)->sys_time_cycles ); \
} while ( 0 )

Definition at line 1452 of file pcpsdev.h.

Referenced by mbg_get_time_info_tstamp().

◆ _mbg_swab_pcps_hr_time_cycles

#define _mbg_swab_pcps_hr_time_cycles (   _p)
Value:
do \
{ \
_mbg_swab_mbg_pc_cycles( &(_p)->cycles ); \
_mbg_swab_pcps_hr_time( &(_p)->t ); \
} while ( 0 )

Definition at line 1399 of file pcpsdev.h.

Referenced by mbg_get_hr_time_cycles().

◆ _mbg_swab_pcps_time_stamp_cycles

#define _mbg_swab_pcps_time_stamp_cycles (   _p)
Value:
do \
{ \
_mbg_swab_mbg_pc_cycles( &(_p)->cycles ); \
_mbg_swab_pcps_time_stamp( &(_p)->tstamp ); \
} while ( 0 )

Definition at line 1376 of file pcpsdev.h.

Referenced by mbgclock_default_get_fast_hr_timestamp_cycles().

◆ _pcps_bus_flags

#define _pcps_bus_flags (   _d)    ( (_d)->type.bus_flags )

Definition at line 1071 of file pcpsdev.h.

◆ _pcps_bus_num

#define _pcps_bus_num (   _d)    ( (_d)->cfg.bus_num )

Definition at line 1102 of file pcpsdev.h.

◆ _pcps_can_clr_ucap_buff

#define _pcps_can_clr_ucap_buff (   _d)    _pcps_has_feature( (_d), PCPS_CAN_CLR_UCAP_BUFF )

Definition at line 1161 of file pcpsdev.h.

◆ _pcps_can_set_time

#define _pcps_can_set_time (   _d)    _pcps_has_feature( (_d), PCPS_CAN_SET_TIME )

Definition at line 1144 of file pcpsdev.h.

◆ _pcps_cfg_irq_num

#define _pcps_cfg_irq_num (   _c)    ( (_c)->irq_num )

Definition at line 1111 of file pcpsdev.h.

◆ _pcps_cfg_short_port_base

#define _pcps_cfg_short_port_base (   _c,
  _n 
)    ( _pcps_cfg_short_port_rsrc( (_c), (_n) ).base )

Definition at line 1108 of file pcpsdev.h.

◆ _pcps_cfg_short_port_rsrc

#define _pcps_cfg_short_port_rsrc (   _c,
  _n 
)    ( (_c)->port[_n] )

Definition at line 1105 of file pcpsdev.h.

◆ _pcps_cfg_timeout_clk

#define _pcps_cfg_timeout_clk (   _c)    ( (_c)->timeout_clk )

Definition at line 1114 of file pcpsdev.h.

◆ _pcps_chk_err_flags

#define _pcps_chk_err_flags (   _d,
  _msk 
)    ( _pcps_err_flags( _d ) & (_msk) )

Definition at line 1125 of file pcpsdev.h.

◆ _pcps_clr_err_flags

#define _pcps_clr_err_flags (   _d,
  _msk 
)    ( _pcps_err_flags( _d ) &= ~(_msk) )

Definition at line 1127 of file pcpsdev.h.

◆ _pcps_dev_id

#define _pcps_dev_id (   _d)    ( (_d)->type.dev_id )

Definition at line 1069 of file pcpsdev.h.

◆ _pcps_err_flags

#define _pcps_err_flags (   _d)    ( (_d)->cfg.err_flags )

Definition at line 1124 of file pcpsdev.h.

◆ _pcps_features

#define _pcps_features (   _d)    ( (_d)->cfg.features )

Definition at line 1118 of file pcpsdev.h.

◆ _pcps_fw_has_20ms_bug

#define _pcps_fw_has_20ms_bug (   _d)
Value:
( \
( _pcps_type_num( _d ) == PCPS_TYPE_GPS168PCI && _pcps_fw_rev_num( _d ) < 0x0102 ) || \
( _pcps_type_num( _d ) == PCPS_TYPE_GPS167PCI && _pcps_fw_rev_num( _d ) < 0x0420 ) \
)
#define _pcps_type_num(_d)
Definition: pcpsdev.h:1067
#define _pcps_fw_rev_num(_d)
Definition: pcpsdev.h:1117

Definition at line 1300 of file pcpsdev.h.

Referenced by mbg_get_show_dev_info().

◆ _pcps_fw_id

#define _pcps_fw_id (   _d)    ( (_d)->cfg.fw_id )

Definition at line 1119 of file pcpsdev.h.

◆ _pcps_fw_rev_num

#define _pcps_fw_rev_num (   _d)    ( (_d)->cfg.fw_rev_num )

Definition at line 1117 of file pcpsdev.h.

Referenced by mbg_get_show_dev_info().

◆ _pcps_fw_rev_num_major

#define _pcps_fw_rev_num_major (   _v)    ( (_v) >> 8 )

Definition at line 1483 of file pcpsdev.h.

Referenced by mbg_get_show_dev_info(), mbg_str_dev_name(), and report_access_mode().

◆ _pcps_fw_rev_num_minor

#define _pcps_fw_rev_num_minor (   _v)    ( (_v) & 0xFF )

Definition at line 1486 of file pcpsdev.h.

Referenced by mbg_get_show_dev_info(), mbg_str_dev_name(), and report_access_mode().

◆ _pcps_has_asic_features

#define _pcps_has_asic_features (   _d)    _pcps_has_asic_version( _d )

Definition at line 1222 of file pcpsdev.h.

◆ _pcps_has_asic_version

#define _pcps_has_asic_version (   _d)
Value:
#define _pcps_is_pci_mbgpex(_d)
Definition: pcpsdev.h:1098
#define _pcps_is_pci_asic(_d)
Definition: pcpsdev.h:1096
#define _pcps_is_pci_pex8311(_d)
Definition: pcpsdev.h:1097

Definition at line 1218 of file pcpsdev.h.

Referenced by mbg_get_show_dev_info().

◆ _pcps_has_cab_len

#define _pcps_has_cab_len (   _d)    _pcps_has_feature( (_d), PCPS_HAS_CABLE_LEN )

Definition at line 1151 of file pcpsdev.h.

Referenced by check_cmd_line().

◆ _pcps_has_corr_info

#define _pcps_has_corr_info (   _d)    _pcps_has_pzf( _d )

Definition at line 1234 of file pcpsdev.h.

◆ _pcps_has_debug_status

#define _pcps_has_debug_status (   _d)    _pcps_is_irig_rx( _d )

Definition at line 1240 of file pcpsdev.h.

◆ _pcps_has_event_time

#define _pcps_has_event_time (   _d)    _pcps_has_feature( (_d), PCPS_HAS_EVENT_TIME )

Definition at line 1159 of file pcpsdev.h.

Referenced by check_cmd_line(), and usage().

◆ _pcps_has_evt_log

#define _pcps_has_evt_log (   _d)    _pcps_has_feature( (_d), PCPS_HAS_EVT_LOG )

Definition at line 1238 of file pcpsdev.h.

◆ _pcps_has_fast_hr_timestamp

#define _pcps_has_fast_hr_timestamp (   _d)    _pcps_has_feature( (_d), PCPS_HAS_FAST_HR_TSTAMP )

Definition at line 1224 of file pcpsdev.h.

Referenced by show_time_and_status().

◆ _pcps_has_feature

#define _pcps_has_feature (   _d,
  _f 
)    ( ( (_d)->cfg.features & (_f) ) != 0 )

Check whether a special feature is supported.

Definition at line 1133 of file pcpsdev.h.

◆ _pcps_has_generic_io

#define _pcps_has_generic_io (   _d)    _pcps_has_feature( (_d), PCPS_HAS_GENERIC_IO )

Definition at line 1212 of file pcpsdev.h.

Referenced by do_mbgtcrcal().

◆ _pcps_has_gps_data

#define _pcps_has_gps_data (   _d)    ( _pcps_is_gps( _d ) || _pcps_has_gps_data_16( _d ) )

Definition at line 1207 of file pcpsdev.h.

Referenced by check_cmd_line(), and do_mbgstatus().

◆ _pcps_has_gps_data_16

#define _pcps_has_gps_data_16 (   _d)    _pcps_has_feature( (_d), PCPS_HAS_GPS_DATA_16 )

Definition at line 1205 of file pcpsdev.h.

◆ _pcps_has_hr_time

#define _pcps_has_hr_time (   _d)    _pcps_has_feature( (_d), PCPS_HAS_HR_TIME )

Definition at line 1149 of file pcpsdev.h.

Referenced by do_mbgsvctasks(), do_mbgxhrtime(), and show_time_and_status().

◆ _pcps_has_ident

#define _pcps_has_ident (   _d)    _pcps_has_feature( (_d), PCPS_HAS_IDENT )

Definition at line 1147 of file pcpsdev.h.

◆ _pcps_has_irig

#define _pcps_has_irig (   _d)    ( _pcps_is_irig_rx( _d ) || _pcps_has_irig_tx( _d ) )

Definition at line 1184 of file pcpsdev.h.

Referenced by do_mbgirigcfg().

◆ _pcps_has_irig_ctrl_bits

#define _pcps_has_irig_ctrl_bits (   _d)    _pcps_has_feature( (_d), PCPS_HAS_IRIG_CTRL_BITS )

Definition at line 1187 of file pcpsdev.h.

Referenced by do_mbgstatus().

◆ _pcps_has_irig_time

#define _pcps_has_irig_time (   _d)    _pcps_has_feature( (_d), PCPS_HAS_IRIG_TIME )

Definition at line 1190 of file pcpsdev.h.

Referenced by show_time_and_status().

◆ _pcps_has_irig_tx

#define _pcps_has_irig_tx (   _d)    _pcps_has_feature( (_d), PCPS_HAS_IRIG_TX )

Definition at line 1163 of file pcpsdev.h.

Referenced by chk_dev_tx(), and do_mbgirigcfg().

◆ _pcps_has_lan_intf

#define _pcps_has_lan_intf (   _d)    _pcps_has_feature( (_d), PCPS_HAS_LAN_INTF )

Definition at line 1226 of file pcpsdev.h.

Referenced by check_cmd_line().

◆ _pcps_has_mod

#define _pcps_has_mod (   _d)    ( _pcps_is_dcf( _d ) || _pcps_is_msf( _d ) || _pcps_is_wwvb( _d ) )

Definition at line 1181 of file pcpsdev.h.

◆ _pcps_has_opt_flags

#define _pcps_has_opt_flags (   _d)    _pcps_is_irig_rx( _d )

Definition at line 1202 of file pcpsdev.h.

Referenced by mbg_get_all_irig_rx_info(), and mbg_save_all_irig_rx_settings().

◆ _pcps_has_pcps_tzdl

#define _pcps_has_pcps_tzdl (   _d)    _pcps_has_feature( (_d), PCPS_HAS_PCPS_TZDL )

Definition at line 1153 of file pcpsdev.h.

◆ _pcps_has_ptp

#define _pcps_has_ptp (   _d)    _pcps_has_feature( (_d), PCPS_HAS_PTP )

Definition at line 1228 of file pcpsdev.h.

Referenced by check_cmd_line(), and do_mbgstatus().

◆ _pcps_has_pzf

#define _pcps_has_pzf (   _d)    _pcps_has_feature( (_d), PCPS_HAS_PZF )

Definition at line 1232 of file pcpsdev.h.

Referenced by show_signal(), and show_time_and_status().

◆ _pcps_has_raw_irig_data

#define _pcps_has_raw_irig_data (   _d)    _pcps_has_feature( (_d), PCPS_HAS_RAW_IRIG_DATA )

Definition at line 1193 of file pcpsdev.h.

◆ _pcps_has_receiver_info

#define _pcps_has_receiver_info (   _d)    _pcps_has_feature( (_d), PCPS_HAS_RECEIVER_INFO )

◆ _pcps_has_ref_offs

#define _pcps_has_ref_offs (   _d)    _pcps_is_irig_rx( _d )

◆ _pcps_has_ri_feature

#define _pcps_has_ri_feature (   _p_ri,
  _f 
)    ( ( (_p_ri)->features & (_f) ) != 0 )

Check whether a special feature is supported according to RECEIVER_INFO.

Definition at line 1136 of file pcpsdev.h.

◆ _pcps_has_ri_gpio

#define _pcps_has_ri_gpio (   _p_ri)    _pcps_has_ri_feature( (_p_ri), GPS_HAS_GPIO )

Definition at line 1248 of file pcpsdev.h.

◆ _pcps_has_ri_ptp_unicast

#define _pcps_has_ri_ptp_unicast (   _p_ri)    _pcps_has_ri_feature( (_p_ri), GPS_HAS_PTP_UNICAST )

Definition at line 1230 of file pcpsdev.h.

Referenced by mbg_get_ptp_uc_master_cfg_limits().

◆ _pcps_has_ri_xmr

#define _pcps_has_ri_xmr (   _p_ri)
Value:
_pcps_has_ri_feature( (_p_ri), GPS_HAS_XMRS_MULT_INSTC ) )
#define GPS_HAS_XMRS_MULT_INSTC
see GPS_FEAT_XMRS_MULT_INSTC
Definition: gpsdefs.h:2297
#define _pcps_has_ri_feature(_p_ri, _f)
Check whether a special feature is supported according to RECEIVER_INFO.
Definition: pcpsdev.h:1136
#define GPS_HAS_XMULTI_REF
see GPS_FEAT_XMULTI_REF
Definition: gpsdefs.h:2286

Definition at line 1251 of file pcpsdev.h.

◆ _pcps_has_serial

#define _pcps_has_serial (   _d)    _pcps_has_feature( (_d), PCPS_HAS_SERIAL )

Definition at line 1145 of file pcpsdev.h.

Referenced by mbg_get_serial_settings().

◆ _pcps_has_serial_hs

#define _pcps_has_serial_hs (   _d)
Value:

Definition at line 1167 of file pcpsdev.h.

Referenced by mbg_get_serial_settings().

◆ _pcps_has_sernum

#define _pcps_has_sernum (   _d)    _pcps_has_feature( (_d), PCPS_HAS_SERNUM )

Definition at line 1150 of file pcpsdev.h.

◆ _pcps_has_signal

#define _pcps_has_signal (   _d)    ( _pcps_is_dcf( _d ) || _pcps_is_msf( _d ) || _pcps_is_wwvb( _d ) || _pcps_is_irig_rx( _d ) )

Definition at line 1178 of file pcpsdev.h.

Referenced by show_time_and_status().

◆ _pcps_has_stat_info

#define _pcps_has_stat_info (   _d)    ( _pcps_is_gps( _d ) || _pcps_has_pzf( _d ) )

Definition at line 1242 of file pcpsdev.h.

Referenced by show_ext_stat_info().

◆ _pcps_has_stat_info_mode

#define _pcps_has_stat_info_mode (   _d)    _pcps_is_gps( _d )

Definition at line 1244 of file pcpsdev.h.

Referenced by show_ext_stat_info().

◆ _pcps_has_stat_info_svs

#define _pcps_has_stat_info_svs (   _d)    _pcps_is_gps( _d )

Definition at line 1246 of file pcpsdev.h.

Referenced by show_ext_stat_info().

◆ _pcps_has_sync_time

#define _pcps_has_sync_time (   _d)    _pcps_has_feature( (_d), PCPS_HAS_SYNC_TIME )

Definition at line 1146 of file pcpsdev.h.

◆ _pcps_has_synth

#define _pcps_has_synth (   _d)    _pcps_has_feature( (_d), PCPS_HAS_SYNTH )

Definition at line 1210 of file pcpsdev.h.

Referenced by check_cmd_line(), and show_enable_flags().

◆ _pcps_has_time_scale

#define _pcps_has_time_scale (   _d)    _pcps_has_feature( (_d), PCPS_HAS_TIME_SCALE )

Definition at line 1214 of file pcpsdev.h.

Referenced by check_cmd_line().

◆ _pcps_has_tr_distance

#define _pcps_has_tr_distance (   _d)    _pcps_has_pzf( _d )

Definition at line 1236 of file pcpsdev.h.

◆ _pcps_has_tz

#define _pcps_has_tz (   _d)
Value:
#define PCPS_HAS_TZDL
see PCPS_BIT_HAS_TZDL
Definition: pcpsdev.h:710
#define _pcps_has_feature(_d, _f)
Check whether a special feature is supported.
Definition: pcpsdev.h:1133
#define PCPS_HAS_PCPS_TZDL
see PCPS_BIT_HAS_PCPS_TZDL
Definition: pcpsdev.h:721
#define PCPS_HAS_TZCODE
see PCPS_BIT_HAS_TZCODE
Definition: pcpsdev.h:716

Definition at line 1155 of file pcpsdev.h.

◆ _pcps_has_tzcode

#define _pcps_has_tzcode (   _d)    _pcps_has_feature( (_d), PCPS_HAS_TZCODE )

Definition at line 1154 of file pcpsdev.h.

Referenced by set_timezone().

◆ _pcps_has_tzdl

#define _pcps_has_tzdl (   _d)    _pcps_has_feature( (_d), PCPS_HAS_TZDL )

Definition at line 1152 of file pcpsdev.h.

Referenced by check_cmd_line(), and set_timezone().

◆ _pcps_has_ucap

#define _pcps_has_ucap (   _d)    _pcps_has_feature( (_d), PCPS_HAS_UCAP )

Definition at line 1162 of file pcpsdev.h.

Referenced by do_mbggpscap().

◆ _pcps_has_utc_offs

#define _pcps_has_utc_offs (   _d)    _pcps_has_feature( (_d), PCPS_HAS_UTC_OFFS )

Definition at line 1148 of file pcpsdev.h.

◆ _pcps_has_utc_parm

#define _pcps_has_utc_parm (   _d)    _pcps_has_feature( (_d), PCPS_HAS_UTC_PARM )

Definition at line 1216 of file pcpsdev.h.

Referenced by do_mbgstatus().

◆ _pcps_incoming_tfom_ignored

#define _pcps_incoming_tfom_ignored (   _d)
Value:
( ( ( _pcps_type_num( _d ) == PCPS_TYPE_TCR167PCI ) && ( _pcps_fw_rev_num( _d ) <= 0x121 ) ) \
|| ( ( _pcps_type_num( _d ) == PCPS_TYPE_TCR170PEX ) && ( _pcps_fw_rev_num( _d ) <= 0x103 ) ) )
#define _pcps_type_num(_d)
Definition: pcpsdev.h:1067
#define _pcps_fw_rev_num(_d)
Definition: pcpsdev.h:1117

Definition at line 1269 of file pcpsdev.h.

◆ _pcps_irq_num

#define _pcps_irq_num (   _d)    _pcps_cfg_irq_num( &(_d)->cfg )

Definition at line 1112 of file pcpsdev.h.

Referenced by mbg_get_show_dev_info().

◆ _pcps_is_dcf

#define _pcps_is_dcf (   _d)    ( _pcps_ref_type( _d ) == PCPS_REF_DCF )

Definition at line 1075 of file pcpsdev.h.

◆ _pcps_is_frc

#define _pcps_is_frc (   _d)    ( _pcps_ref_type( _d ) == PCPS_REF_FRC )

Definition at line 1080 of file pcpsdev.h.

◆ _pcps_is_gnss

#define _pcps_is_gnss (   _d)    _pcps_has_feature( (_d), PCPS_IS_GNSS )

Definition at line 1081 of file pcpsdev.h.

Referenced by show_ext_stat_info().

◆ _pcps_is_gps

◆ _pcps_is_irig_rx

◆ _pcps_is_isa

#define _pcps_is_isa (   _d)    ( _pcps_bus_flags( _d ) & PCPS_BUS_ISA )

Definition at line 1086 of file pcpsdev.h.

◆ _pcps_is_lwr

#define _pcps_is_lwr (   _d)    ( _pcps_is_dcf( _d ) || _pcps_is_msf( _d ) || _pcps_is_wwvb( _d ) )

Definition at line 1083 of file pcpsdev.h.

Referenced by do_mbgsvctasks(), and show_time_and_status().

◆ _pcps_is_mca

#define _pcps_is_mca (   _d)    ( _pcps_bus_flags( _d ) & PCPS_BUS_MCA )

Definition at line 1087 of file pcpsdev.h.

◆ _pcps_is_msf

#define _pcps_is_msf (   _d)    ( _pcps_ref_type( _d ) == PCPS_REF_MSF )

Definition at line 1076 of file pcpsdev.h.

◆ _pcps_is_pci

#define _pcps_is_pci (   _d)    ( _pcps_bus_flags( _d ) & PCPS_BUS_PCI )

Definition at line 1088 of file pcpsdev.h.

◆ _pcps_is_pci_amcc

#define _pcps_is_pci_amcc (   _d)    ( _pcps_is_pci_s5920( _d ) || _pcps_is_pci_s5933( _d ) )

Definition at line 1095 of file pcpsdev.h.

◆ _pcps_is_pci_asic

#define _pcps_is_pci_asic (   _d)    ( _pcps_bus_flags( _d ) == PCPS_BUS_PCI_ASIC )

Definition at line 1096 of file pcpsdev.h.

◆ _pcps_is_pci_mbgpex

#define _pcps_is_pci_mbgpex (   _d)    ( _pcps_bus_flags( _d ) == PCPS_BUS_PCI_MBGPEX )

Definition at line 1098 of file pcpsdev.h.

◆ _pcps_is_pci_pex8311

#define _pcps_is_pci_pex8311 (   _d)    ( _pcps_bus_flags( _d ) == PCPS_BUS_PCI_PEX8311 )

Definition at line 1097 of file pcpsdev.h.

◆ _pcps_is_pci_s5920

#define _pcps_is_pci_s5920 (   _d)    ( _pcps_bus_flags( _d ) == PCPS_BUS_PCI_S5920 )

Definition at line 1094 of file pcpsdev.h.

◆ _pcps_is_pci_s5933

#define _pcps_is_pci_s5933 (   _d)    ( _pcps_bus_flags( _d ) == PCPS_BUS_PCI_S5933 )

Definition at line 1093 of file pcpsdev.h.

◆ _pcps_is_ptp

#define _pcps_is_ptp (   _d)    ( _pcps_ref_type( _d ) == PCPS_REF_PTP )

Definition at line 1079 of file pcpsdev.h.

◆ _pcps_is_usb

#define _pcps_is_usb (   _d)    ( _pcps_bus_flags( _d ) & PCPS_BUS_USB )

Definition at line 1089 of file pcpsdev.h.

Referenced by do_mbgsvctasks().

◆ _pcps_is_usb_v2

#define _pcps_is_usb_v2 (   _d)    ( _pcps_bus_flags( _d ) == PCPS_BUS_USB_V2 )

Definition at line 1092 of file pcpsdev.h.

◆ _pcps_is_wwvb

#define _pcps_is_wwvb (   _d)    ( _pcps_ref_type( _d ) == PCPS_REF_WWVB )

Definition at line 1077 of file pcpsdev.h.

◆ _pcps_pci_cfg_err

#define _pcps_pci_cfg_err (   _d)
Value:
( _pcps_is_pci( _d ) && _pcps_short_port_base( _d, 0 ) && \
( _pcps_short_port_base( _d, 1 ) == _pcps_short_port_base( _d, 0 ) ) )
#define _pcps_short_port_base(_d, _n)
Definition: pcpsdev.h:1109
#define _pcps_is_pci(_d)
Definition: pcpsdev.h:1088

Definition at line 1286 of file pcpsdev.h.

◆ _pcps_pex_irq_is_safe

#define _pcps_pex_irq_is_safe (   _curr_fw_ver,
  _req_fw_ver,
  _curr_asic_ver,
  _req_asic_ver_major,
  _req_asic_ver_minor 
)
Value:
( ( (_curr_fw_ver) >= (_req_fw_ver) ) && _pcps_asic_version_greater_equal( \
(_curr_asic_ver), (_req_asic_ver_major), (_req_asic_ver_minor ) ) \
)
#define _pcps_asic_version_greater_equal(_v, _v_major, _v_minor)
Check whether a version number is correct and matches a required minimum version. ...
Definition: pci_asic.h:354

Definition at line 961 of file pcpsdev.h.

Referenced by pcps_check_pex_irq_unsafe().

◆ _pcps_ref_offs_out_of_range

#define _pcps_ref_offs_out_of_range (   _n)    ( ( (_n) > MBG_REF_OFFS_MAX ) || ( (_n) < -MBG_REF_OFFS_MAX ) )

Definition at line 1199 of file pcpsdev.h.

Referenced by show_time_and_status().

◆ _pcps_ref_type

#define _pcps_ref_type (   _d)    ( (_d)->type.ref_type )

Definition at line 1070 of file pcpsdev.h.

Referenced by show_signal().

◆ _pcps_sernum

#define _pcps_sernum (   _d)    ( (_d)->cfg.sernum )

◆ _pcps_set_err_flags

#define _pcps_set_err_flags (   _d,
  _msk 
)    ( _pcps_err_flags( _d ) |= (_msk) )

Definition at line 1126 of file pcpsdev.h.

◆ _pcps_short_port_base

#define _pcps_short_port_base (   _d,
  _n 
)    ( _pcps_short_port_rsrc( (_d), (_n) ).base )

Definition at line 1109 of file pcpsdev.h.

Referenced by mbg_get_show_dev_info(), and pcps_port_str().

◆ _pcps_short_port_rsrc

#define _pcps_short_port_rsrc (   _d,
  _n 
)    _pcps_cfg_short_port_rsrc( &(_d)->cfg, (_n) )

Definition at line 1106 of file pcpsdev.h.

◆ _pcps_slot_num

#define _pcps_slot_num (   _d)    ( (_d)->cfg.slot_num )

Definition at line 1103 of file pcpsdev.h.

◆ _pcps_time_is_read

#define _pcps_time_is_read (   _t)    ( (uchar) (_t)->sec != 0xFF )

◆ _pcps_time_set_unread

#define _pcps_time_set_unread (   _t)    do { (_t)->sec = 0xFF; } while ( 0 )

Definition at line 1343 of file pcpsdev.h.

◆ _pcps_timeout_clk

#define _pcps_timeout_clk (   _d)    _pcps_cfg_timeout_clk( &(_d)->cfg )

Definition at line 1115 of file pcpsdev.h.

◆ _pcps_type_name

#define _pcps_type_name (   _d)    ( (_d)->type.name )

◆ _pcps_type_num

#define _pcps_type_num (   _d)    ( (_d)->type.num )

Definition at line 1067 of file pcpsdev.h.

◆ _ri_addr

#define _ri_addr (   _p)    &(_p)->xdev_features.receiver_info

◆ _tlv_feat_buffp

#define _tlv_feat_buffp (   _p)    &(_p)->xdev_features.tlv_info.supp_tlv_feat

Definition at line 1141 of file pcpsdev.h.

Referenced by check_receiver_info_and_features().

◆ _tlv_info_addr

#define _tlv_info_addr (   _p)    &(_p)->xdev_features.tlv_info

Definition at line 1140 of file pcpsdev.h.

Referenced by check_receiver_info_and_features(), and dump_tlv_info().

◆ _USE_DEV_MACROS

#define _USE_DEV_MACROS   1

Definition at line 1052 of file pcpsdev.h.

◆ _xfeat_addr

#define _xfeat_addr (   _p)    &(_p)->xdev_features.xfeature_buffer

Definition at line 1139 of file pcpsdev.h.

Referenced by check_receiver_info_and_features(), and dump_xfeature_buffer().

◆ MBG_DEV_NAME_FMT

◆ MBG_TGT_SUPP_MEM_ACC

#define MBG_TGT_SUPP_MEM_ACC   1

Definition at line 349 of file pcpsdev.h.

◆ N_PCPS_PORT_RSRC

#define N_PCPS_PORT_RSRC   2

The max. number of I/O port resources used by a clock.

Definition at line 555 of file pcpsdev.h.

Referenced by pcps_add_rsrc_io(), and pcps_probe_device().

◆ PCPS_CLOCK_NAME_SZ

#define PCPS_CLOCK_NAME_SZ   10

Definition at line 496 of file pcpsdev.h.

◆ PCPS_EF_INV_FW_ID

#define PCPS_EF_INV_FW_ID   0x00000002

invalid firmware ID

Definition at line 625 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_EF_IO_CFG

#define PCPS_EF_IO_CFG   0x00000008

I/O interface not configured.

Definition at line 627 of file pcpsdev.h.

◆ PCPS_EF_IO_ENB

#define PCPS_EF_IO_ENB   0x00000010

I/O interface not enabled.

Definition at line 628 of file pcpsdev.h.

Referenced by pcps_cleanup_device(), and pcps_probe_device().

◆ PCPS_EF_IO_INIT

#define PCPS_EF_IO_INIT   0x00000004

I/O interface not initialized.

Definition at line 626 of file pcpsdev.h.

Referenced by pcps_cleanup_device(), pcps_probe_device(), and report_ret_val().

◆ PCPS_EF_IO_RSRC_IO

#define PCPS_EF_IO_RSRC_IO   0x00000020

I/O resource not registered with resource manager.

Definition at line 629 of file pcpsdev.h.

Referenced by pcps_add_rsrc_io().

◆ PCPS_EF_IO_RSRC_MEM

#define PCPS_EF_IO_RSRC_MEM   0x00000040

Memory resource not registered with resource manager.

Definition at line 630 of file pcpsdev.h.

Referenced by pcps_add_rsrc_mem().

◆ PCPS_EF_TIMEOUT

#define PCPS_EF_TIMEOUT   0x00000001

Possible device initialization error flags.

Used with PCPS_DEV_CFG::err_flags

See also
PCPS_ERR_FLAGS

timeout occured

Definition at line 624 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_DCF600USB

#define PCPS_FEAT_DCF600USB   ( PCPS_FEAT_USB5131 )

Definition at line 903 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_FRC511PEX

#define PCPS_FEAT_FRC511PEX
Value:
#define PCPS_CAN_CLR_UCAP_BUFF
see PCPS_BIT_CAN_CLR_UCAP_BUFF
Definition: pcpsdev.h:720
#define PCPS_HAS_UCAP
see PCPS_BIT_HAS_UCAP
Definition: pcpsdev.h:722
#define PCPS_HAS_GPS_DATA_16
see PCPS_BIT_HAS_GPS_DATA_16
Definition: pcpsdev.h:725
#define PCPS_HAS_HR_TIME
see PCPS_BIT_HAS_HR_TIME
Definition: pcpsdev.h:713
#define PCPS_CAN_SET_TIME
Feature bit masks for bus-level devices.
Definition: pcpsdev.h:707
#define PCPS_HAS_SERNUM
see PCPS_BIT_HAS_SERNUM
Definition: pcpsdev.h:714
#define PCPS_HAS_RECEIVER_INFO
see PCPS_BIT_HAS_RECEIVER_INFO
Definition: pcpsdev.h:719

Definition at line 883 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_GLN180PEX

#define PCPS_FEAT_GLN180PEX   ( PCPS_FEAT_GPS180PEX | PCPS_IS_GNSS )

Definition at line 926 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_GNS181PEX

#define PCPS_FEAT_GNS181PEX   ( PCPS_FEAT_GLN180PEX )

Definition at line 930 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_GPS167PC

#define PCPS_FEAT_GPS167PC
Value:
#define PCPS_FEAT_LVL2
Definition: pcpsdev.h:790
#define PCPS_HAS_TZDL
see PCPS_BIT_HAS_TZDL
Definition: pcpsdev.h:710
#define PCPS_HAS_IDENT
see PCPS_BIT_HAS_IDENT
Definition: pcpsdev.h:711

Definition at line 807 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_GPS167PCI

#define PCPS_FEAT_GPS167PCI
Value:
#define PCPS_FEAT_LVL2
Definition: pcpsdev.h:790
#define PCPS_HAS_TZDL
see PCPS_BIT_HAS_TZDL
Definition: pcpsdev.h:710
#define PCPS_HAS_HR_TIME
see PCPS_BIT_HAS_HR_TIME
Definition: pcpsdev.h:713
#define PCPS_HAS_IDENT
see PCPS_BIT_HAS_IDENT
Definition: pcpsdev.h:711

Definition at line 811 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_GPS168PCI

#define PCPS_FEAT_GPS168PCI
Value:
#define PCPS_FEAT_LVL2
Definition: pcpsdev.h:790
#define PCPS_HAS_TZDL
see PCPS_BIT_HAS_TZDL
Definition: pcpsdev.h:710
#define PCPS_HAS_HR_TIME
see PCPS_BIT_HAS_HR_TIME
Definition: pcpsdev.h:713
#define PCPS_HAS_CABLE_LEN
see PCPS_BIT_HAS_CABLE_LEN
Definition: pcpsdev.h:717
#define PCPS_HAS_RECEIVER_INFO
see PCPS_BIT_HAS_RECEIVER_INFO
Definition: pcpsdev.h:719
#define PCPS_HAS_IDENT
see PCPS_BIT_HAS_IDENT
Definition: pcpsdev.h:711

Definition at line 816 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_GPS169PCI

#define PCPS_FEAT_GPS169PCI
Value:
#define PCPS_CAN_CLR_UCAP_BUFF
see PCPS_BIT_CAN_CLR_UCAP_BUFF
Definition: pcpsdev.h:720
#define PCPS_HAS_UCAP
see PCPS_BIT_HAS_UCAP
Definition: pcpsdev.h:722
#define PCPS_FEAT_GPS168PCI
Definition: pcpsdev.h:816

Definition at line 823 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_GPS170PCI

#define PCPS_FEAT_GPS170PCI
Value:
#define PCPS_HAS_GPS_DATA_16
see PCPS_BIT_HAS_GPS_DATA_16
Definition: pcpsdev.h:725
#define PCPS_FEAT_GPS169PCI
Definition: pcpsdev.h:823
#define PCPS_HAS_GENERIC_IO
see PCPS_BIT_HAS_GENERIC_IO
Definition: pcpsdev.h:727
#define PCPS_HAS_IRIG_TX
see PCPS_BIT_HAS_IRIG_TX
Definition: pcpsdev.h:723

Definition at line 827 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_GPS170PEX

#define PCPS_FEAT_GPS170PEX   ( PCPS_FEAT_GPS170PCI )

Definition at line 853 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_GPS180AMC

#define PCPS_FEAT_GPS180AMC   ( PCPS_FEAT_GPS180PEX )

Definition at line 928 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_GPS180PEX

#define PCPS_FEAT_GPS180PEX
Value:
#define PCPS_HAS_FAST_HR_TSTAMP
see PCPS_BIT_HAS_FAST_HR_TSTAMP
Definition: pcpsdev.h:735
#define PCPS_FEAT_GPS170PEX
Definition: pcpsdev.h:853
#define PCPS_HAS_IRIG_TX
see PCPS_BIT_HAS_IRIG_TX
Definition: pcpsdev.h:723

IRIG TX only supp. if GPS_HAS_IRIG_TX.

Definition at line 895 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_LVL2

#define PCPS_FEAT_LVL2
Value:
#define PCPS_CAN_SET_TIME
Feature bit masks for bus-level devices.
Definition: pcpsdev.h:707
#define PCPS_HAS_SERIAL
see PCPS_BIT_HAS_SERIAL
Definition: pcpsdev.h:708
#define PCPS_HAS_SYNC_TIME
see PCPS_BIT_HAS_SYNC_TIME
Definition: pcpsdev.h:709
#define PCPS_HAS_UTC_OFFS
see PCPS_BIT_HAS_UTC_OFFS
Definition: pcpsdev.h:712

Definition at line 790 of file pcpsdev.h.

◆ PCPS_FEAT_MSF51USB

#define PCPS_FEAT_MSF51USB
Value:
#define PCPS_HAS_HR_TIME
see PCPS_BIT_HAS_HR_TIME
Definition: pcpsdev.h:713
#define PCPS_CAN_SET_TIME
Feature bit masks for bus-level devices.
Definition: pcpsdev.h:707
#define PCPS_HAS_SERNUM
see PCPS_BIT_HAS_SERNUM
Definition: pcpsdev.h:714
#define PCPS_HAS_SYNC_TIME
see PCPS_BIT_HAS_SYNC_TIME
Definition: pcpsdev.h:709
#define PCPS_HAS_UTC_OFFS
see PCPS_BIT_HAS_UTC_OFFS
Definition: pcpsdev.h:712

Definition at line 868 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_MSF600USB

#define PCPS_FEAT_MSF600USB   ( PCPS_FEAT_MSF51USB )

Definition at line 922 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_PC31PS31

#define PCPS_FEAT_PC31PS31   0

Definition at line 786 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_PC32

#define PCPS_FEAT_PC32   ( PCPS_FEAT_LVL2 )

Definition at line 795 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_PCI32

#define PCPS_FEAT_PCI32   ( PCPS_FEAT_LVL2 )

Definition at line 797 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_PCI509

#define PCPS_FEAT_PCI509
Value:
#define PCPS_FEAT_LVL2
Definition: pcpsdev.h:790
#define PCPS_HAS_SERNUM
see PCPS_BIT_HAS_SERNUM
Definition: pcpsdev.h:714
#define PCPS_HAS_TZCODE
see PCPS_BIT_HAS_TZCODE
Definition: pcpsdev.h:716

Definition at line 799 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_PCI510

#define PCPS_FEAT_PCI510   ( PCPS_FEAT_PCI509 )

Definition at line 803 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_PCI511

#define PCPS_FEAT_PCI511   ( PCPS_FEAT_PCI510 )

Definition at line 805 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_PEX511

#define PCPS_FEAT_PEX511   ( PCPS_FEAT_PCI511 )

Definition at line 849 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_PTP270PEX

#define PCPS_FEAT_PTP270PEX
Value:
#define PCPS_CAN_CLR_UCAP_BUFF
see PCPS_BIT_CAN_CLR_UCAP_BUFF
Definition: pcpsdev.h:720
#define PCPS_HAS_UCAP
see PCPS_BIT_HAS_UCAP
Definition: pcpsdev.h:722
#define PCPS_HAS_GPS_DATA_16
see PCPS_BIT_HAS_GPS_DATA_16
Definition: pcpsdev.h:725
#define PCPS_HAS_HR_TIME
see PCPS_BIT_HAS_HR_TIME
Definition: pcpsdev.h:713
#define PCPS_CAN_SET_TIME
Feature bit masks for bus-level devices.
Definition: pcpsdev.h:707
#define PCPS_HAS_SERNUM
see PCPS_BIT_HAS_SERNUM
Definition: pcpsdev.h:714
#define PCPS_HAS_RECEIVER_INFO
see PCPS_BIT_HAS_RECEIVER_INFO
Definition: pcpsdev.h:719
#define PCPS_HAS_SYNC_TIME
see PCPS_BIT_HAS_SYNC_TIME
Definition: pcpsdev.h:709

Definition at line 874 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_PZF180PEX

#define PCPS_FEAT_PZF180PEX
Value:
#define PCPS_CAN_CLR_UCAP_BUFF
see PCPS_BIT_CAN_CLR_UCAP_BUFF
Definition: pcpsdev.h:720
#define PCPS_HAS_UCAP
see PCPS_BIT_HAS_UCAP
Definition: pcpsdev.h:722
#define PCPS_FEAT_LVL2
Definition: pcpsdev.h:790
#define PCPS_HAS_GPS_DATA_16
see PCPS_BIT_HAS_GPS_DATA_16
Definition: pcpsdev.h:725
#define PCPS_HAS_UTC_PARM
see PCPS_BIT_HAS_UTC_PARM
Definition: pcpsdev.h:729
#define PCPS_HAS_TZDL
see PCPS_BIT_HAS_TZDL
Definition: pcpsdev.h:710
#define PCPS_HAS_HR_TIME
see PCPS_BIT_HAS_HR_TIME
Definition: pcpsdev.h:713
#define PCPS_HAS_SERNUM
see PCPS_BIT_HAS_SERNUM
Definition: pcpsdev.h:714
#define PCPS_HAS_PZF
see PCPS_BIT_HAS_PZF
Definition: pcpsdev.h:737
#define PCPS_HAS_RECEIVER_INFO
see PCPS_BIT_HAS_RECEIVER_INFO
Definition: pcpsdev.h:719
#define PCPS_HAS_GENERIC_IO
see PCPS_BIT_HAS_GENERIC_IO
Definition: pcpsdev.h:727

Definition at line 905 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_TCR167PCI

#define PCPS_FEAT_TCR167PCI
Value:
#define PCPS_CAN_CLR_UCAP_BUFF
see PCPS_BIT_CAN_CLR_UCAP_BUFF
Definition: pcpsdev.h:720
#define PCPS_HAS_UCAP
see PCPS_BIT_HAS_UCAP
Definition: pcpsdev.h:722
#define PCPS_FEAT_LVL2
Definition: pcpsdev.h:790
#define PCPS_HAS_GPS_DATA_16
see PCPS_BIT_HAS_GPS_DATA_16
Definition: pcpsdev.h:725
#define PCPS_HAS_TZDL
see PCPS_BIT_HAS_TZDL
Definition: pcpsdev.h:710
#define PCPS_HAS_HR_TIME
see PCPS_BIT_HAS_HR_TIME
Definition: pcpsdev.h:713
#define PCPS_HAS_SERNUM
see PCPS_BIT_HAS_SERNUM
Definition: pcpsdev.h:714
#define PCPS_HAS_RECEIVER_INFO
see PCPS_BIT_HAS_RECEIVER_INFO
Definition: pcpsdev.h:719
#define PCPS_HAS_GENERIC_IO
see PCPS_BIT_HAS_GENERIC_IO
Definition: pcpsdev.h:727
#define PCPS_HAS_IRIG_TX
see PCPS_BIT_HAS_IRIG_TX
Definition: pcpsdev.h:723

Definition at line 835 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_TCR170PEX

#define PCPS_FEAT_TCR170PEX   ( PCPS_FEAT_TCR167PCI )

Definition at line 891 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_TCR180PEX

#define PCPS_FEAT_TCR180PEX
Value:
#define PCPS_HAS_FAST_HR_TSTAMP
see PCPS_BIT_HAS_FAST_HR_TSTAMP
Definition: pcpsdev.h:735
#define PCPS_FEAT_TCR170PEX
Definition: pcpsdev.h:891
#define PCPS_HAS_IRIG_TX
see PCPS_BIT_HAS_IRIG_TX
Definition: pcpsdev.h:723

IRIG TX only supp. if GPS_HAS_IRIG_TX.

Definition at line 899 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_TCR180USB

#define PCPS_FEAT_TCR180USB
Value:
| PCPS_CAN_CLR_UCAP_BUFF /* TODO ? */ \
| PCPS_HAS_UCAP /* TODO ? */ \
| PCPS_HAS_GENERIC_IO /* TODO ? */ )
#define PCPS_CAN_CLR_UCAP_BUFF
see PCPS_BIT_CAN_CLR_UCAP_BUFF
Definition: pcpsdev.h:720
#define PCPS_HAS_UCAP
see PCPS_BIT_HAS_UCAP
Definition: pcpsdev.h:722
#define PCPS_HAS_GPS_DATA_16
see PCPS_BIT_HAS_GPS_DATA_16
Definition: pcpsdev.h:725
#define PCPS_HAS_TZDL
see PCPS_BIT_HAS_TZDL
Definition: pcpsdev.h:710
#define PCPS_HAS_RECEIVER_INFO
see PCPS_BIT_HAS_RECEIVER_INFO
Definition: pcpsdev.h:719
#define PCPS_HAS_GENERIC_IO
see PCPS_BIT_HAS_GENERIC_IO
Definition: pcpsdev.h:727
#define PCPS_FEAT_TCR600USB
Definition: pcpsdev.h:917

IRIG TX only supp. if GPS_HAS_IRIG_TX.

Definition at line 932 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_TCR510PCI

#define PCPS_FEAT_TCR510PCI
Value:
#define PCPS_FEAT_LVL2
Definition: pcpsdev.h:790
#define PCPS_HAS_SERNUM
see PCPS_BIT_HAS_SERNUM
Definition: pcpsdev.h:714

Definition at line 832 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_TCR511PCI

#define PCPS_FEAT_TCR511PCI
Value:
#define PCPS_FEAT_TCR510PCI
Definition: pcpsdev.h:832
#define PCPS_HAS_HR_TIME
see PCPS_BIT_HAS_HR_TIME
Definition: pcpsdev.h:713

Definition at line 846 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_TCR511PEX

#define PCPS_FEAT_TCR511PEX   ( PCPS_FEAT_TCR511PCI )

Definition at line 851 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_TCR51USB

#define PCPS_FEAT_TCR51USB
Value:
#define PCPS_HAS_HR_TIME
see PCPS_BIT_HAS_HR_TIME
Definition: pcpsdev.h:713
#define PCPS_CAN_SET_TIME
Feature bit masks for bus-level devices.
Definition: pcpsdev.h:707
#define PCPS_HAS_SERNUM
see PCPS_BIT_HAS_SERNUM
Definition: pcpsdev.h:714
#define PCPS_HAS_SYNC_TIME
see PCPS_BIT_HAS_SYNC_TIME
Definition: pcpsdev.h:709
#define PCPS_HAS_UTC_OFFS
see PCPS_BIT_HAS_UTC_OFFS
Definition: pcpsdev.h:712

Definition at line 862 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_TCR600USB

#define PCPS_FEAT_TCR600USB
Value:
#define PCPS_HAS_RAW_IRIG_DATA
see PCPS_BIT_HAS_RAW_IRIG_DATA
Definition: pcpsdev.h:736
#define PCPS_FEAT_TCR51USB
Definition: pcpsdev.h:862
#define PCPS_HAS_IRIG_TIME
see PCPS_BIT_HAS_IRIG_TIME
Definition: pcpsdev.h:734
#define PCPS_HAS_IRIG_CTRL_BITS
see PCPS_BIT_HAS_IRIG_CTRL_BITS
Definition: pcpsdev.h:730

Definition at line 917 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_USB5131

#define PCPS_FEAT_USB5131
Value:
#define PCPS_HAS_HR_TIME
see PCPS_BIT_HAS_HR_TIME
Definition: pcpsdev.h:713
#define PCPS_CAN_SET_TIME
Feature bit masks for bus-level devices.
Definition: pcpsdev.h:707
#define PCPS_HAS_SERNUM
see PCPS_BIT_HAS_SERNUM
Definition: pcpsdev.h:714
#define PCPS_HAS_TZCODE
see PCPS_BIT_HAS_TZCODE
Definition: pcpsdev.h:716
#define PCPS_HAS_SYNC_TIME
see PCPS_BIT_HAS_SYNC_TIME
Definition: pcpsdev.h:709
#define PCPS_HAS_UTC_OFFS
see PCPS_BIT_HAS_UTC_OFFS
Definition: pcpsdev.h:712

Definition at line 855 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_WVB600USB

#define PCPS_FEAT_WVB600USB   ( PCPS_FEAT_WWVB51USB )

Definition at line 924 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FEAT_WWVB51USB

#define PCPS_FEAT_WWVB51USB   ( PCPS_FEAT_MSF51USB )

Definition at line 893 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ PCPS_FW_STR_FMT

#define PCPS_FW_STR_FMT   "%X.%02X"

Definition at line 1481 of file pcpsdev.h.

Referenced by mbg_get_show_dev_info(), mbg_str_dev_name(), and report_access_mode().

◆ REV_CAN_CLR_UCAP_BUFF_GPS167PCI

#define REV_CAN_CLR_UCAP_BUFF_GPS167PCI   0x0419

Definition at line 995 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_CAN_CLR_UCAP_BUFF_GPS168PCI

#define REV_CAN_CLR_UCAP_BUFF_GPS168PCI   0x0101

Definition at line 996 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_CAN_SET_TIME_PC31PS31

#define REV_CAN_SET_TIME_PC31PS31   0x0240

Definition at line 1028 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_GIVE_TIME_NOCLEAR_PC31PS31

#define REV_GIVE_TIME_NOCLEAR_PC31PS31   0x0300

Definition at line 1019 of file pcpsdev.h.

◆ REV_HAS_CABLE_LEN_GPS167PC

#define REV_HAS_CABLE_LEN_GPS167PC   0x0411

Definition at line 1001 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_CABLE_LEN_GPS167PCI

#define REV_HAS_CABLE_LEN_GPS167PCI   0x0411

Definition at line 1000 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_GPS_DATA_16_GPS169PCI

#define REV_HAS_GPS_DATA_16_GPS169PCI   0x0202

Definition at line 985 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_HR_TIME_GPS167PC

#define REV_HAS_HR_TIME_GPS167PC   0x0305

Definition at line 1004 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_HR_TIME_PCI511

#define REV_HAS_HR_TIME_PCI511   0x0103

Definition at line 1007 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_HR_TIME_PEX511

#define REV_HAS_HR_TIME_PEX511   0x0105

Definition at line 1006 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_HR_TIME_TCR510PCI

#define REV_HAS_HR_TIME_TCR510PCI   0x0200

Definition at line 1005 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_IRIG_CTRL_BITS_TCR511PCI

#define REV_HAS_IRIG_CTRL_BITS_TCR511PCI   0x0107

Definition at line 979 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_IRIG_CTRL_BITS_TCR511PEX

#define REV_HAS_IRIG_CTRL_BITS_TCR511PEX   0x0107

Definition at line 978 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_IRIG_CTRL_BITS_TCR51USB

#define REV_HAS_IRIG_CTRL_BITS_TCR51USB   0x0106

Definition at line 980 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_IRIG_TIME_TCR511PCI

#define REV_HAS_IRIG_TIME_TCR511PCI   0x0109

Definition at line 974 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_IRIG_TIME_TCR511PEX

#define REV_HAS_IRIG_TIME_TCR511PEX   0x0109

Definition at line 973 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_IRIG_TIME_TCR51USB

#define REV_HAS_IRIG_TIME_TCR51USB   0x0106

Definition at line 975 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_IRQ_FIX_MINOR_GPS170PEX

#define REV_HAS_IRQ_FIX_MINOR_GPS170PEX   0x0104

Definition at line 956 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_IRQ_FIX_MINOR_PEX511

#define REV_HAS_IRQ_FIX_MINOR_PEX511   0x0106

Definition at line 954 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_IRQ_FIX_MINOR_TCR511PEX

#define REV_HAS_IRQ_FIX_MINOR_TCR511PEX   0x0105

Definition at line 955 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_RAW_IRIG_DATA_TCR511PCI

#define REV_HAS_RAW_IRIG_DATA_TCR511PCI   0x0111

Definition at line 969 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_RAW_IRIG_DATA_TCR511PEX

#define REV_HAS_RAW_IRIG_DATA_TCR511PEX   0x0111

Definition at line 968 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_RAW_IRIG_DATA_TCR51USB

#define REV_HAS_RAW_IRIG_DATA_TCR51USB   0x0106

Definition at line 970 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_SERIAL_HS_PCI509

#define REV_HAS_SERIAL_HS_PCI509   0x0104

Definition at line 988 of file pcpsdev.h.

◆ REV_HAS_SERIAL_PC31PS31

#define REV_HAS_SERIAL_PC31PS31   0x0300

Definition at line 1016 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_SYNC_TIME_PC31PS31

#define REV_HAS_SYNC_TIME_PC31PS31   0x0300

Definition at line 1013 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_UCAP_GPS167PCI

#define REV_HAS_UCAP_GPS167PCI   0x0421

Definition at line 991 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_UCAP_GPS168PCI

#define REV_HAS_UCAP_GPS168PCI   0x0104

Definition at line 992 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_HAS_UTC_OFFS_PC31PS31

#define REV_HAS_UTC_OFFS_PC31PS31   0x0300

Definition at line 1010 of file pcpsdev.h.

Referenced by pcps_probe_device().

◆ REV_PCPS_IFTM_PC31PS31

#define REV_PCPS_IFTM_PC31PS31   0x0300

Definition at line 1025 of file pcpsdev.h.

◆ REV_PCPS_LS_ANN_PC31PS31

#define REV_PCPS_LS_ANN_PC31PS31   0x0300

Definition at line 1022 of file pcpsdev.h.

Typedef Documentation

◆ MBG_DBG_DATA

Definition at line 369 of file pcpsdev.h.

◆ MBG_DBG_PORT

Definition at line 370 of file pcpsdev.h.

◆ MBG_DEV_NAME

typedef char MBG_DEV_NAME[10+( 16+1)+1]

A string buffer for a unique device ID.

The unique ID is made up of the device model name and its serial number, i.e. [model_name]_[serial_number] E.g.: "GPS170PCI_028210040670"

See also
snprint_dev_name
MBG_DEV_NAME_FMT

Definition at line 1524 of file pcpsdev.h.

◆ PCPS_BUS_FLAGS

Definition at line 502 of file pcpsdev.h.

◆ PCPS_BUS_NUM

Definition at line 580 of file pcpsdev.h.

◆ PCPS_CLOCK_NAME

typedef char PCPS_CLOCK_NAME[10]

Definition at line 498 of file pcpsdev.h.

◆ PCPS_DEV_ID

Definition at line 500 of file pcpsdev.h.

◆ PCPS_ERR_FLAGS

typedef uint32_t PCPS_ERR_FLAGS

see PCPS_ERR_FLAG_MASKS

Definition at line 578 of file pcpsdev.h.

◆ PCPS_FEATURES

typedef uint32_t PCPS_FEATURES

see PCPS_FEATURE_MASKS

Definition at line 579 of file pcpsdev.h.

◆ PCPS_FW_REV_NUM

firmware revision number, MSB major, LSB minor version

Definition at line 582 of file pcpsdev.h.

◆ PCPS_REF_TYPE

Definition at line 501 of file pcpsdev.h.

◆ PCPS_SHORT_PORT_ADDR

Legacy I/O address type, see PCPS_SHORT_PORT_RSRC.

Definition at line 527 of file pcpsdev.h.

◆ PCPS_SLOT_NUM

Definition at line 581 of file pcpsdev.h.

Enumeration Type Documentation

◆ DEV_FEAT_TYPES

Codes used with IOCTL_DEV_FEAT_REQ::feat_type.

Enumerator
DEV_FEAT_TYPE_BUILTIN 

feat_num field contains one of the GPS_BUILTIN_FEATURE_BITS

DEV_FEAT_TYPE_REF_TYPE 

feat_num field contains one of the PCPS_REF_TYPES

DEV_FEAT_TYPE_PCPS 

feat_num field contains one of the PCPS_FEATURE_BITS

DEV_FEAT_TYPE_RI 

feat_num field contains one of the GPS_FEATURE_BITS

DEV_FEAT_TYPE_XFEAT 

feat_num field contains one of the MBG_XFEATURE_BITS

DEV_FEAT_TYPE_TLV_FEAT 

feat_num field contains one of the MBG_TLV_FEAT_TYPES

N_DEV_FEAT_TYPES 

Definition at line 1311 of file pcpsdev.h.

◆ PCPS_TYPES

enum PCPS_TYPES

A list of known devices.

Enumerator
PCPS_TYPE_PC31 
PCPS_TYPE_PS31_OLD 
PCPS_TYPE_PS31 
PCPS_TYPE_PC32 
PCPS_TYPE_PCI32 
PCPS_TYPE_GPS167PC 
PCPS_TYPE_GPS167PCI 
PCPS_TYPE_PCI509 
PCPS_TYPE_GPS168PCI 
PCPS_TYPE_PCI510 
PCPS_TYPE_GPS169PCI 
PCPS_TYPE_TCR510PCI 
PCPS_TYPE_TCR167PCI 
PCPS_TYPE_GPS170PCI 
PCPS_TYPE_PCI511 
PCPS_TYPE_TCR511PCI 
PCPS_TYPE_PEX511 
PCPS_TYPE_TCR511PEX 
PCPS_TYPE_GPS170PEX 
PCPS_TYPE_USB5131 
PCPS_TYPE_TCR51USB 
PCPS_TYPE_MSF51USB 
PCPS_TYPE_PTP270PEX 
PCPS_TYPE_FRC511PEX 
PCPS_TYPE_TCR170PEX 
PCPS_TYPE_WWVB51USB 
PCPS_TYPE_GPS180PEX 
PCPS_TYPE_TCR180PEX 
PCPS_TYPE_DCF600USB 
PCPS_TYPE_PZF180PEX 
PCPS_TYPE_TCR600USB 
PCPS_TYPE_MSF600USB 
PCPS_TYPE_WVB600USB 
PCPS_TYPE_GLN180PEX 
PCPS_TYPE_GPS180AMC 
PCPS_TYPE_GNS181PEX 
PCPS_TYPE_TCR180USB 
N_PCPS_DEV_TYPE 

Definition at line 453 of file pcpsdev.h.

Function Documentation

◆ setup_hr_time_cycles_from_timestamp_cycles()

static __mbg_inline void setup_hr_time_cycles_from_timestamp_cycles ( PCPS_HR_TIME_CYCLES p_ht_c,
const PCPS_TIME_STAMP_CYCLES p_ts_c 
)
static