Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

xen/dmabuf: switch gntdev-dmabuf to use INVALID_GRANT_REF

Instead of using a private macro for an invalid grant reference use
the common one.

Signed-off-by: Juergen Gross <jgross@suse.com>
Reviewed-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Signed-off-by: Juergen Gross <jgross@suse.com>

+2 -11
+2 -11
drivers/xen/gntdev-dmabuf.c
··· 24 24 25 25 MODULE_IMPORT_NS(DMA_BUF); 26 26 27 - #ifndef GRANT_INVALID_REF 28 - /* 29 - * Note on usage of grant reference 0 as invalid grant reference: 30 - * grant reference 0 is valid, but never exposed to a driver, 31 - * because of the fact it is already in use/reserved by the PV console. 32 - */ 33 - #define GRANT_INVALID_REF 0 34 - #endif 35 - 36 27 struct gntdev_dmabuf { 37 28 struct gntdev_dmabuf_priv *priv; 38 29 struct dma_buf *dmabuf; ··· 523 532 int i; 524 533 525 534 for (i = 0; i < count; i++) 526 - if (refs[i] != GRANT_INVALID_REF) 535 + if (refs[i] != INVALID_GRANT_REF) 527 536 gnttab_end_foreign_access(refs[i], 0UL); 528 537 } 529 538 ··· 558 567 gntdev_dmabuf->nr_pages = count; 559 568 560 569 for (i = 0; i < count; i++) 561 - gntdev_dmabuf->u.imp.refs[i] = GRANT_INVALID_REF; 570 + gntdev_dmabuf->u.imp.refs[i] = INVALID_GRANT_REF; 562 571 563 572 return gntdev_dmabuf; 564 573