cq->ctrl = vnic_dev_get_res(vdev, RES_TYPE_CQ, index);
if (!cq->ctrl) {
- pr_err("Failed to hook CQ[%d] resource\n", index);
+ pr_err("Failed to hook CQ[%u] resource\n", index);
return -EINVAL;
}
- snprintf(res_name, sizeof(res_name), "%d-cq-%d", instance++, index);
+ snprintf(res_name, sizeof(res_name), "%d-cq-%u", instance++, index);
err = vnic_dev_alloc_desc_ring(vdev, &cq->ring, desc_count, desc_size,
socket_id, res_name);
if (err)
if (!vdev->stats) {
snprintf((char *)name, sizeof(name),
- "vnic_stats-%d", instance++);
+ "vnic_stats-%u", instance++);
vdev->stats = vdev->alloc_consistent(vdev->priv,
sizeof(struct vnic_stats), &vdev->stats_pa, (u8 *)name);
if (!vdev->stats)
}
if (!vnic_dev_in_reset(vdev)) {
snprintf((char *)name, sizeof(name),
- "vnic_notify-%d", instance++);
+ "vnic_notify-%u", instance++);
notify_addr = vdev->alloc_consistent(vdev->priv,
sizeof(struct vnic_devcmd_notify),
¬ify_pa, (u8 *)name);
tlv_size = filter_size + action_size +
2*sizeof(struct filter_tlv);
snprintf((char *)z_name, sizeof(z_name),
- "vnic_clsf_%d", unique_id++);
+ "vnic_clsf_%u", unique_id++);
tlv_va = vdev->alloc_consistent(vdev->priv,
tlv_size, &tlv_pa, (u8 *)z_name);
if (!tlv_va)
rq->ctrl = vnic_dev_get_res(vdev, RES_TYPE_RQ, index);
if (!rq->ctrl) {
- pr_err("Failed to hook RQ[%d] resource\n", index);
+ pr_err("Failed to hook RQ[%u] resource\n", index);
return -EINVAL;
}
vnic_rq_disable(rq);
- snprintf(res_name, sizeof(res_name), "%d-rq-%d", instance++, index);
+ snprintf(res_name, sizeof(res_name), "%d-rq-%u", instance++, index);
rc = vnic_dev_alloc_desc_ring(vdev, &rq->ring, desc_count, desc_size,
rq->socket_id, res_name);
return rc;
char res_name[NAME_MAX];
static int instance;
- snprintf(res_name, sizeof(res_name), "%d-wq-%d", instance++, wq->index);
+ snprintf(res_name, sizeof(res_name), "%d-wq-%u", instance++, wq->index);
return vnic_dev_alloc_desc_ring(vdev, &wq->ring, desc_count, desc_size,
wq->socket_id, res_name);
}