X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=drivers%2Fevent%2Focteontx2%2Fotx2_tim_evdev.h;h=dac642e0e1dbf8a1afcdd591887e8c2da2916658;hb=53548ad3007b732e964dfa9217cf5471862cbf15;hp=e9cefea9fc7213c617efec107be947d5dab66a80;hpb=25b401c8b6405b7d788bc5602cbeb3ee463ff322;p=dpdk.git diff --git a/drivers/event/octeontx2/otx2_tim_evdev.h b/drivers/event/octeontx2/otx2_tim_evdev.h index e9cefea9fc..dac642e0e1 100644 --- a/drivers/event/octeontx2/otx2_tim_evdev.h +++ b/drivers/event/octeontx2/otx2_tim_evdev.h @@ -5,8 +5,8 @@ #ifndef __OTX2_TIM_EVDEV_H__ #define __OTX2_TIM_EVDEV_H__ +#include #include -#include #include #include "otx2_dev.h" @@ -70,7 +70,7 @@ #define OTX2_TIM_MAX_BURST (RTE_CACHE_LINE_SIZE / \ OTX2_TIM_CHUNK_ALIGNMENT) #define OTX2_TIM_NB_CHUNK_SLOTS(sz) (((sz) / OTX2_TIM_CHUNK_ALIGNMENT) - 1) -#define OTX2_TIM_MIN_CHUNK_SLOTS (0x1) +#define OTX2_TIM_MIN_CHUNK_SLOTS (0x8) #define OTX2_TIM_MAX_CHUNK_SLOTS (0x1FFE) #define OTX2_TIM_MIN_TMO_TKS (256) @@ -177,6 +177,32 @@ tim_priv_get(void) return mz->addr; } +#ifdef RTE_ARCH_ARM64 +static inline uint64_t +tim_cntvct(void) +{ + return __rte_arm64_cntvct(); +} + +static inline uint64_t +tim_cntfrq(void) +{ + return __rte_arm64_cntfrq(); +} +#else +static inline uint64_t +tim_cntvct(void) +{ + return 0; +} + +static inline uint64_t +tim_cntfrq(void) +{ + return 0; +} +#endif + #define TIM_ARM_FASTPATH_MODES \ FP(sp, 0, 0, 0, OTX2_TIM_ENA_DFB | OTX2_TIM_SP) \ FP(mp, 0, 0, 1, OTX2_TIM_ENA_DFB | OTX2_TIM_MP) \ @@ -218,7 +244,7 @@ uint16_t otx2_tim_timer_cancel_burst( int otx2_tim_caps_get(const struct rte_eventdev *dev, uint64_t flags, uint32_t *caps, - const struct rte_event_timer_adapter_ops **ops); + const struct event_timer_adapter_ops **ops); void otx2_tim_init(struct rte_pci_device *pci_dev, struct otx2_dev *cmn_dev); void otx2_tim_fini(void);