Fix NULL dereference in umem.c

Fix NULL dereference in umem.c

Signed-off-by: Neil Brown <neilb@suse.de>
Tested-by: Dave Chinner <dgc@sgi.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by Neil Brown and committed by Linus Torvalds 794e64d5 76832d84

+2 -1
+2 -1
drivers/block/umem.c
··· 484 page->idx++; 485 if (page->idx >= bio->bi_vcnt) { 486 page->bio = bio->bi_next; 487 - page->idx = page->bio->bi_idx; 488 } 489 490 pci_unmap_page(card->dev, desc->data_dma_handle,
··· 484 page->idx++; 485 if (page->idx >= bio->bi_vcnt) { 486 page->bio = bio->bi_next; 487 + if (page->bio) 488 + page->idx = page->bio->bi_idx; 489 } 490 491 pci_unmap_page(card->dev, desc->data_dma_handle,