--- zzzz-none-000/linux-3.10.107/drivers/s390/scsi/zfcp_unit.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/drivers/s390/scsi/zfcp_unit.c 2021-02-04 17:41:59.000000000 +0000 @@ -21,7 +21,7 @@ void zfcp_unit_scsi_scan(struct zfcp_unit *unit) { struct fc_rport *rport = unit->port->rport; - unsigned int lun; + u64 lun; lun = scsilun_to_int((struct scsi_lun *) &unit->fcp_lun); @@ -145,6 +145,7 @@ unit->fcp_lun = fcp_lun; unit->dev.parent = &port->dev; unit->dev.release = zfcp_unit_release; + unit->dev.groups = zfcp_unit_attr_groups; INIT_WORK(&unit->scsi_work, zfcp_unit_scsi_scan_work); if (dev_set_name(&unit->dev, "0x%016llx", @@ -160,12 +161,6 @@ goto out; } - if (sysfs_create_group(&unit->dev.kobj, &zfcp_sysfs_unit_attrs)) { - device_unregister(&unit->dev); - retval = -EINVAL; - goto out; - } - atomic_inc(&port->units); /* under zfcp_sysfs_port_units_mutex ! */ write_lock_irq(&port->unit_list_lock); @@ -193,7 +188,7 @@ { struct Scsi_Host *shost; struct zfcp_port *port; - unsigned int lun; + u64 lun; lun = scsilun_to_int((struct scsi_lun *) &unit->fcp_lun); port = unit->port; @@ -254,7 +249,7 @@ put_device(&unit->dev); - zfcp_device_unregister(&unit->dev, &zfcp_sysfs_unit_attrs); + device_unregister(&unit->dev); return 0; }