@@ -174,7 +174,6 @@ static int vp_request_msix_vectors(struct virtio_device *vdev, int nvectors,
174
174
static struct virtqueue * vp_setup_vq (struct virtio_device * vdev , unsigned int index ,
175
175
void (* callback )(struct virtqueue * vq ),
176
176
const char * name ,
177
- u32 size ,
178
177
bool ctx ,
179
178
u16 msix_vec )
180
179
{
@@ -187,7 +186,7 @@ static struct virtqueue *vp_setup_vq(struct virtio_device *vdev, unsigned int in
187
186
if (!info )
188
187
return ERR_PTR (- ENOMEM );
189
188
190
- vq = vp_dev -> setup_vq (vp_dev , info , index , callback , name , size , ctx ,
189
+ vq = vp_dev -> setup_vq (vp_dev , info , index , callback , name , ctx ,
191
190
msix_vec );
192
191
if (IS_ERR (vq ))
193
192
goto out_info ;
@@ -284,7 +283,7 @@ void vp_del_vqs(struct virtio_device *vdev)
284
283
285
284
static int vp_find_vqs_msix (struct virtio_device * vdev , unsigned int nvqs ,
286
285
struct virtqueue * vqs [], vq_callback_t * callbacks [],
287
- const char * const names [], u32 sizes [], bool per_vq_vectors ,
286
+ const char * const names [], bool per_vq_vectors ,
288
287
const bool * ctx ,
289
288
struct irq_affinity * desc )
290
289
{
@@ -327,8 +326,8 @@ static int vp_find_vqs_msix(struct virtio_device *vdev, unsigned int nvqs,
327
326
else
328
327
msix_vec = VP_MSIX_VQ_VECTOR ;
329
328
vqs [i ] = vp_setup_vq (vdev , queue_idx ++ , callbacks [i ], names [i ],
330
- sizes ? sizes [i ] : 0 ,
331
- ctx ? ctx [ i ] : false, msix_vec );
329
+ ctx ? ctx [i ] : false ,
330
+ msix_vec );
332
331
if (IS_ERR (vqs [i ])) {
333
332
err = PTR_ERR (vqs [i ]);
334
333
goto error_find ;
@@ -358,7 +357,7 @@ static int vp_find_vqs_msix(struct virtio_device *vdev, unsigned int nvqs,
358
357
359
358
static int vp_find_vqs_intx (struct virtio_device * vdev , unsigned int nvqs ,
360
359
struct virtqueue * vqs [], vq_callback_t * callbacks [],
361
- const char * const names [], u32 sizes [], const bool * ctx )
360
+ const char * const names [], const bool * ctx )
362
361
{
363
362
struct virtio_pci_device * vp_dev = to_vp_device (vdev );
364
363
int i , err , queue_idx = 0 ;
@@ -380,7 +379,6 @@ static int vp_find_vqs_intx(struct virtio_device *vdev, unsigned int nvqs,
380
379
continue ;
381
380
}
382
381
vqs [i ] = vp_setup_vq (vdev , queue_idx ++ , callbacks [i ], names [i ],
383
- sizes ? sizes [i ] : 0 ,
384
382
ctx ? ctx [i ] : false,
385
383
VIRTIO_MSI_NO_VECTOR );
386
384
if (IS_ERR (vqs [i ])) {
@@ -404,15 +402,15 @@ int vp_find_vqs(struct virtio_device *vdev, unsigned int nvqs,
404
402
int err ;
405
403
406
404
/* Try MSI-X with one vector per queue. */
407
- err = vp_find_vqs_msix (vdev , nvqs , vqs , callbacks , names , sizes , true, ctx , desc );
405
+ err = vp_find_vqs_msix (vdev , nvqs , vqs , callbacks , names , true, ctx , desc );
408
406
if (!err )
409
407
return 0 ;
410
408
/* Fallback: MSI-X with one vector for config, one shared for queues. */
411
- err = vp_find_vqs_msix (vdev , nvqs , vqs , callbacks , names , sizes , false, ctx , desc );
409
+ err = vp_find_vqs_msix (vdev , nvqs , vqs , callbacks , names , false, ctx , desc );
412
410
if (!err )
413
411
return 0 ;
414
412
/* Finally fall back to regular interrupts. */
415
- return vp_find_vqs_intx (vdev , nvqs , vqs , callbacks , names , sizes , ctx );
413
+ return vp_find_vqs_intx (vdev , nvqs , vqs , callbacks , names , ctx );
416
414
}
417
415
418
416
const char * vp_bus_name (struct virtio_device * vdev )
0 commit comments