aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/char/vmlogrdr.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/s390/char/vmlogrdr.c')
-rw-r--r--drivers/s390/char/vmlogrdr.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/s390/char/vmlogrdr.c b/drivers/s390/char/vmlogrdr.c
index e8487347e4d4..2c2428cc05d8 100644
--- a/drivers/s390/char/vmlogrdr.c
+++ b/drivers/s390/char/vmlogrdr.c
@@ -762,10 +762,10 @@ static int vmlogrdr_register_device(struct vmlogrdr_priv_t *priv)
762 device_unregister(dev); 762 device_unregister(dev);
763 return ret; 763 return ret;
764 } 764 }
765 priv->class_device = device_create(vmlogrdr_class, dev, 765 priv->class_device = device_create_drvdata(vmlogrdr_class, dev,
766 MKDEV(vmlogrdr_major, 766 MKDEV(vmlogrdr_major,
767 priv->minor_num), 767 priv->minor_num),
768 "%s", dev->bus_id); 768 priv, "%s", dev->bus_id);
769 if (IS_ERR(priv->class_device)) { 769 if (IS_ERR(priv->class_device)) {
770 ret = PTR_ERR(priv->class_device); 770 ret = PTR_ERR(priv->class_device);
771 priv->class_device=NULL; 771 priv->class_device=NULL;
@@ -773,7 +773,6 @@ static int vmlogrdr_register_device(struct vmlogrdr_priv_t *priv)
773 device_unregister(dev); 773 device_unregister(dev);
774 return ret; 774 return ret;
775 } 775 }
776 dev->driver_data = priv;
777 priv->device = dev; 776 priv->device = dev;
778 return 0; 777 return 0;
779} 778}