Merge branch 'master' into upstream-fixes
[powerpc.git] / drivers / s390 / block / dasd_genhd.c
index 61ffde7..4c272b7 100644 (file)
@@ -11,7 +11,6 @@
  *
  */
 
-#include <linux/config.h>
 #include <linux/interrupt.h>
 #include <linux/fs.h>
 #include <linux/blkpg.h>
@@ -85,9 +84,9 @@ void
 dasd_gendisk_free(struct dasd_device *device)
 {
        del_gendisk(device->gdp);
-       device->gdp->queue = 0;
+       device->gdp->queue = NULL;
        put_disk(device->gdp);
-       device->gdp = 0;
+       device->gdp = NULL;
 }
 
 /*
@@ -137,7 +136,7 @@ dasd_destroy_partitions(struct dasd_device * device)
         * device->bdev to lower the offline open_count limit again.
         */
        bdev = device->bdev;
-       device->bdev = 0;
+       device->bdev = NULL;
 
        /*
         * See fs/partition/check.c:delete_partition
@@ -146,7 +145,7 @@ dasd_destroy_partitions(struct dasd_device * device)
         */
        memset(&bpart, 0, sizeof(struct blkpg_partition));
        memset(&barg, 0, sizeof(struct blkpg_ioctl_arg));
-       barg.data = &bpart;
+       barg.data = (void __user *) &bpart;
        barg.op = BLKPG_DEL_PARTITION;
        for (bpart.pno = device->gdp->minors - 1; bpart.pno > 0; bpart.pno--)
                ioctl_by_bdev(bdev, BLKPG, (unsigned long) &barg);