Hi Paolo,

On Thu, 01 Feb 2024 13:01:51 +0100
Paolo Abeni <pab...@redhat.com> wrote:

[...]
> >  
> > +static int qmc_hdlc_xlate_slot_map(struct qmc_hdlc *qmc_hdlc,
> > +                              u32 slot_map, struct qmc_chan_ts_info 
> > *ts_info)
> > +{
> > +   DECLARE_BITMAP(ts_mask_avail, 64);
> > +   DECLARE_BITMAP(ts_mask, 64);
> > +   DECLARE_BITMAP(map, 64);
> > +   u32 array32[2];
> > +
> > +   /* Tx and Rx available masks must be identical */
> > +   if (ts_info->rx_ts_mask_avail != ts_info->tx_ts_mask_avail) {
> > +           dev_err(qmc_hdlc->dev, "tx and rx available timeslots mismatch 
> > (0x%llx, 0x%llx)\n",
> > +                   ts_info->rx_ts_mask_avail, ts_info->tx_ts_mask_avail);
> > +           return -EINVAL;
> > +   }
> > +
> > +   bitmap_from_arr64(ts_mask_avail, &ts_info->rx_ts_mask_avail, 64);
> > +   array32[0] = slot_map;
> > +   array32[1] = 0;
> > +   bitmap_from_arr32(map, array32, 64);  
> 
> What about using bitmap_from_u64 everywhere ?

Yes indeed.
Will be updated in the next series iteration.

Thanks for this review.
Best regards,
Hervé

Reply via email to