Thanks for the comments, Yunsheng,
>>
>> +static int aq_nic_update_link_status(struct aq_nic_s *self)
>> +{
>> + int err = self->aq_hw_ops.hw_get_link_status(self->aq_hw);
>> +
>> + if (err < 0)
>> + return -1;
> why not just return err?
Agreed, that could be improved.
>> + if (self->link_status.mbps != self->aq_hw->aq_link_status.mbps)
>> + pr_info("%s: link change old %d new %d\n",
>> + AQ_CFG_DRV_NAME, self->link_status.mbps,
>> + self->aq_hw->aq_link_status.mbps);
> You has ndev in struct aq_nic_s *self, why not use netdev_*?
We are planning to introduce a generic rework commit separately and use netif_*
set of macro's through all the driver's code.
--
BR, Igor