net/iavf: fix mbuf leak
[dpdk.git] / drivers / net / hinic / base / hinic_pmd_cfg.c
index 2d25dc9..837734f 100644 (file)
@@ -112,6 +112,7 @@ static void hinic_parse_pub_res_cap(struct service_cap *cap,
        cap->host_id = dev_cap->host_id;
        cap->ep_id = dev_cap->ep_id;
        cap->max_cos_id = dev_cap->max_cos_id;
+       cap->valid_cos_bitmap = dev_cap->valid_cos_bitmap;
        cap->er_id = dev_cap->er_id;
        cap->port_id = dev_cap->port_id;
 
@@ -134,9 +135,11 @@ static void hinic_parse_pub_res_cap(struct service_cap *cap,
        cap->host_oq_id_mask_val = dev_cap->host_oq_id_mask_val;
 
        PMD_DRV_LOG(INFO, "Get public resource capability:");
-       PMD_DRV_LOG(INFO, "host_id: 0x%x, ep_id: 0x%x, intr_type: 0x%x, max_cos_id: 0x%x, er_id: 0x%x, port_id: 0x%x",
+       PMD_DRV_LOG(INFO, "host_id: 0x%x, ep_id: 0x%x, intr_type: 0x%x, "
+                   "max_cos_id: 0x%x, cos_bitmap: 0x%x, er_id: 0x%x, port_id: 0x%x",
                    cap->host_id, cap->ep_id, cap->intr_chip_en,
-                   cap->max_cos_id, cap->er_id, cap->port_id);
+                   cap->max_cos_id, cap->valid_cos_bitmap, cap->er_id,
+                   cap->port_id);
        PMD_DRV_LOG(INFO, "host_total_function: 0x%x, host_oq_id_mask_val: 0x%x, max_vf: 0x%x",
                    cap->host_total_function, cap->host_oq_id_mask_val,
                    cap->max_vf);
@@ -179,7 +182,7 @@ static int get_cap_from_fw(struct hinic_hwdev *dev, enum func_type type)
        if (err || dev_cap.mgmt_msg_head.status || !out_len) {
                PMD_DRV_LOG(ERR, "Get capability from FW failed, err: %d, status: %d, out_len: %d",
                        err, dev_cap.mgmt_msg_head.status, out_len);
-               return -EFAULT;
+               return -EIO;
        }
 
        parse_dev_cap(dev, &dev_cap, type);
@@ -201,7 +204,7 @@ static int get_cap_from_pf(struct hinic_hwdev *dev, enum func_type type)
        if (err || dev_cap.mgmt_msg_head.status || !out_len) {
                PMD_DRV_LOG(ERR, "Get capability from PF failed, err: %d, status: %d, out_len: %d",
                                err, dev_cap.mgmt_msg_head.status, out_len);
-               return -EFAULT;
+               return -EIO;
        }
 
        parse_dev_cap(dev, &dev_cap, type);