diff --git a/drivers/s390/block/scm_drv.c b/drivers/s390/block/scm_drv.c index 349966f6fc529cf1ed695fed4abaf6f6465c2398..9fa0a908607b013ce3ef0981a323d3b4e9043bde 100644 --- a/drivers/s390/block/scm_drv.c +++ b/drivers/s390/block/scm_drv.c @@ -52,8 +52,8 @@ static int scm_remove(struct scm_device *scmdev) { struct scm_blk_dev *bdev = dev_get_drvdata(&scmdev->dev); - dev_set_drvdata(&scmdev->dev, NULL); scm_blk_dev_cleanup(bdev); + dev_set_drvdata(&scmdev->dev, NULL); kfree(bdev); return 0;