summaryrefslogtreecommitdiff
path: root/drivers/scsi/libfc/fc_disc.c
diff options
context:
space:
mode:
authorHannes Reinecke <hare@suse.de>2016-10-18 11:01:42 +0300
committerMartin K. Petersen <martin.petersen@oracle.com>2016-11-09 01:29:55 +0300
commit2580064b5ec6dc9efa475298b276ab21f5cc287d (patch)
tree70331d1a31c5160aef6eb4d529e344a579166496 /drivers/scsi/libfc/fc_disc.c
parent558b88fe6dd88a16563a4d72b674947b8130a550 (diff)
downloadlinux-2580064b5ec6dc9efa475298b276ab21f5cc287d.tar.xz
scsi: libfc: Replace ->rport_create callback with function call
The ->rport_create callback only ever had a single implementation, so we can as well call it directly and drop the callback. Signed-off-by: Hannes Reinecke <hare@suse.com> Acked-by: Johannes Thumshirn <jth@kernel.org> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/libfc/fc_disc.c')
-rw-r--r--drivers/scsi/libfc/fc_disc.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/scsi/libfc/fc_disc.c b/drivers/scsi/libfc/fc_disc.c
index e5ffeab9f670..305dd8541963 100644
--- a/drivers/scsi/libfc/fc_disc.c
+++ b/drivers/scsi/libfc/fc_disc.c
@@ -454,7 +454,7 @@ static int fc_disc_gpn_ft_parse(struct fc_disc *disc, void *buf, size_t len)
if (ids.port_id != lport->port_id &&
ids.port_name != lport->wwpn) {
- rdata = lport->tt.rport_create(lport, ids.port_id);
+ rdata = fc_rport_create(lport, ids.port_id);
if (rdata) {
rdata->ids.port_name = ids.port_name;
rdata->disc_id = disc->disc_id;
@@ -624,8 +624,7 @@ static void fc_disc_gpn_id_resp(struct fc_seq *sp, struct fc_frame *fp,
mutex_unlock(&rdata->rp_mutex);
lport->tt.rport_logoff(rdata);
mutex_lock(&lport->disc.disc_mutex);
- new_rdata = lport->tt.rport_create(lport,
- rdata->ids.port_id);
+ new_rdata = fc_rport_create(lport, rdata->ids.port_id);
mutex_unlock(&lport->disc.disc_mutex);
if (new_rdata) {
new_rdata->disc_id = disc->disc_id;
@@ -690,7 +689,7 @@ static int fc_disc_single(struct fc_lport *lport, struct fc_disc_port *dp)
{
struct fc_rport_priv *rdata;
- rdata = lport->tt.rport_create(lport, dp->port_id);
+ rdata = fc_rport_create(lport, dp->port_id);
if (!rdata)
return -ENOMEM;
rdata->disc_id = 0;