dma_addr_t hp_addr, tp_addr;
enum htt_srng_ring_type htt_ring_type;
enum htt_srng_ring_id htt_ring_id;
- int ret = 0;
+ int ret;
skb = ath11k_htc_alloc_skb(ab, len);
if (!skb)
hp_addr = ath11k_hal_srng_get_hp_addr(ab, srng);
tp_addr = ath11k_hal_srng_get_tp_addr(ab, srng);
- if (ath11k_dp_tx_get_ring_id_type(ab, mac_id, ring_id,
- ring_type, &htt_ring_type,
- &htt_ring_id))
+ ret = ath11k_dp_tx_get_ring_id_type(ab, mac_id, ring_id,
+ ring_type, &htt_ring_type,
+ &htt_ring_id);
+ if (ret)
goto err_free;
skb_put(skb, len);
HAL_ADDR_MSB_REG_SHIFT;
ret = ath11k_hal_srng_get_entrysize(ring_type);
- if (ret < 0) {
- ret = -EINVAL;
+ if (ret < 0)
goto err_free;
- }
ring_entry_sz = ret;
int len = sizeof(*cmd);
enum htt_srng_ring_type htt_ring_type;
enum htt_srng_ring_id htt_ring_id;
- int ret = 0;
+ int ret;
skb = ath11k_htc_alloc_skb(ab, len);
if (!skb)
memset(¶ms, 0, sizeof(params));
ath11k_hal_srng_get_params(ab, srng, ¶ms);
- if (ath11k_dp_tx_get_ring_id_type(ab, mac_id, ring_id,
- ring_type, &htt_ring_type,
- &htt_ring_id))
+ ret = ath11k_dp_tx_get_ring_id_type(ab, mac_id, ring_id,
+ ring_type, &htt_ring_type,
+ &htt_ring_id);
+ if (ret)
goto err_free;
skb_put(skb, len);