RE: [PATCH 04/39] megaraid_sas: 32 bit descriptor fire cmd optimization

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> -----Original Message-----
> From: Hannes Reinecke [mailto:hare@xxxxxxxx]
> Sent: Monday, February 06, 2017 3:54 PM
> To: Shivasharan S; linux-scsi@xxxxxxxxxxxxxxx
> Cc: martin.petersen@xxxxxxxxxx; thenzl@xxxxxxxxxx;
> jejb@xxxxxxxxxxxxxxxxxx; kashyap.desai@xxxxxxxxxxxx;
> sumit.saxena@xxxxxxxxxxxx
> Subject: Re: [PATCH 04/39] megaraid_sas: 32 bit descriptor fire cmd
> optimization
>
> On 02/06/2017 10:59 AM, Shivasharan S wrote:
> > No functional change. Code refactor.
> > megasas_fire_cmd_fusion can always use 32 bit descriptor write for
ventura.
> No need to pass extra flag.
> > Only IOC INIT required 64 bit Descriptor write.
> >
> > Signed-off-by: Shivasharan S <shivasharan.srikanteshwara@xxxxxxxxxxxx>
> > Signed-off-by: Kashyap Desai <kashyap.desai@xxxxxxxxxxxx>
> > ---
> >  drivers/scsi/megaraid/megaraid_sas_fusion.c | 65
> > +++++++++++++++--------------
> >  1 file changed, 33 insertions(+), 32 deletions(-)
> >
> [ .. ]
> > @@ -897,7 +893,14 @@ megasas_ioc_init_fusion(struct megasas_instance
> *instance)
> >  			break;
> >  	}
> >
> > -	megasas_fire_cmd_fusion(instance, &req_desc, false);
> > +	/* For Ventura also IOC INIT required 64 bit Descriptor write. */
> > +	spin_lock_irqsave(&instance->hba_lock, flags);
> > +	writel(le32_to_cpu(req_desc.u.low),
> > +	       &instance->reg_set->inbound_low_queue_port);
> > +	writel(le32_to_cpu(req_desc.u.high),
> > +	       &instance->reg_set->inbound_high_queue_port);
> > +	mmiowb();
> > +	spin_unlock_irqrestore(&instance->hba_lock, flags);
> >
> >  	wait_and_poll(instance, cmd, MFI_POLL_TIMEOUT_SECS);
> >
> You are missing the 64 bit writeq improvements here.

We have to use writeq() with additional checks " #if defined(writeq) &&
defined(CONFIG_64BIT)" as some arch still wants two PCI write as they do
not have writeq() support.
Since this is a one-time IOC INIT operation we should be good to keep
simple code avoiding writeq() usage.
>
> Cheers,
>
> Hannes
> --
> Dr. Hannes Reinecke		               zSeries & Storage
> hare@xxxxxxxx			               +49 911 74053 688
> SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg
> GF: F. Imendörffer, J. Smithard, D. Upmanyu, G. Norton HRB 21284 (AG
> Nürnberg)




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux