block: pass block dev not num to read/write/erase()

This will allow the implementation to make use of data in the block_dev
structure beyond the base device number. This will be useful so that eMMC
block devices can encompass the HW partition ID rather than treating this
out-of-band. Equally, the existence of the priv field is crying out for
this patch to exist.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
diff --git a/common/fb_mmc.c b/common/fb_mmc.c
index b480e76..6e742da 100644
--- a/common/fb_mmc.c
+++ b/common/fb_mmc.c
@@ -58,7 +58,7 @@
 	block_dev_desc_t *dev_desc = sparse->dev_desc;
 	int ret;
 
-	ret = dev_desc->block_write(dev_desc->dev, offset, size, data);
+	ret = dev_desc->block_write(dev_desc, offset, size, data);
 	if (!ret)
 		return -EIO;
 
@@ -84,8 +84,7 @@
 
 	puts("Flashing Raw Image\n");
 
-	blks = dev_desc->block_write(dev_desc->dev, info->start, blkcnt,
-				     buffer);
+	blks = dev_desc->block_write(dev_desc, info->start, blkcnt, buffer);
 	if (blks != blkcnt) {
 		error("failed writing to device %d\n", dev_desc->dev);
 		fastboot_fail(response_str, "failed writing to device");
@@ -206,7 +205,7 @@
 	printf("Erasing blocks " LBAFU " to " LBAFU " due to alignment\n",
 	       blks_start, blks_start + blks_size);
 
-	blks = dev_desc->block_erase(dev_desc->dev, blks_start, blks_size);
+	blks = dev_desc->block_erase(dev_desc, blks_start, blks_size);
 	if (blks != blks_size) {
 		error("failed erasing from device %d", dev_desc->dev);
 		fastboot_fail(response_str, "failed erasing from device");