-----Original Message-----
> Date: Tue,  3 Apr 2018 20:35:08 +0530
> From: Pavan Nikhilesh <pbhagavat...@caviumnetworks.com>
> To: jerin.ja...@caviumnetworks.com, santosh.shu...@caviumnetworks.com,
>  erik.g.carri...@intel.com
> Cc: dev@dpdk.org, Pavan Nikhilesh <pbhagavat...@caviumnetworks.com>
> Subject: [dpdk-dev] [PATCH v3 06/12] event/octeontx: add multiproducer
>  timer arm and cancel
> X-Mailer: git-send-email 2.16.3
> 
> Signed-off-by: Pavan Nikhilesh <pbhagavat...@caviumnetworks.com>
> ---
> +static inline int16_t
> +timr_bkt_get_rem(struct tim_mem_bucket *bktp)
> +{
> +     return __atomic_load_n((int16_t *)&bktp->chunk_remainder,
> +                     __ATOMIC_ACQUIRE);
> +}
> +
> +static inline void
> +timr_bkt_set_rem(struct tim_mem_bucket *bktp, uint16_t v)
> +{
> +     __atomic_store_n((int16_t *)&bktp->chunk_remainder, v,

typecast is not required for  __atomic_* gcc atomic builtins functions.

> +                     __ATOMIC_RELEASE);
> +}
> +
> +static inline void
> +timr_bkt_sub_rem(struct tim_mem_bucket *bktp, uint16_t v)
> +{
> +     __atomic_fetch_sub((int16_t *)&bktp->chunk_remainder, v,
> +                     __ATOMIC_RELEASE);
> +}
> +
> +{
> +
> +/* Multi producer functions. */
> +static inline int
> +timvf_add_entry_mp(struct timvf_ring * const timr, const uint32_t rel_bkt,
> +             struct rte_event_timer * const tim,
> +             const struct tim_mem_entry * const pent)
> +{
> +     uint8_t lock_cnt;
> +     int16_t rem;
> +     uint64_t lock_sema;
> +     struct tim_mem_bucket *bkt;
> +     struct tim_mem_entry *chunk;
> +
> +__retry:
> +     bkt = timvf_get_target_bucket(timr, rel_bkt);
> +     /* Bucket related checks. */
> +     /*Get Bucket sema*/
> +     lock_sema = timr_bkt_fetch_sema_lock(bkt);
> +     if (unlikely(timr_bkt_get_shbt(lock_sema))) {
> +             timr_bkt_dec_lock(bkt);
> +             goto __retry;
> +     }
> +
> +     RTE_SET_USED(lock_cnt);

lock_cnt not been used. Remove it.

With above changes:
Acked-by: Jerin Jacob <jerin.ja...@caviumnetworks.com>


Reply via email to