[PATCH 18/19] scsi: hisi_sas: replace kfree with scsi_host_put

2017-08-10 Thread John Garry
Instances of kfree(shost) should be replaced with scsi_host_put(). In addition, a missing scsi_host_put() is added for error path in hisi_sas_shost_alloc_pci() and v3 driver removal. Signed-off-by: Pan Bian # For main.c changes Signed-off-by: John Garry

[PATCH 18/19] scsi: hisi_sas: replace kfree with scsi_host_put

2017-08-10 Thread John Garry
Instances of kfree(shost) should be replaced with scsi_host_put(). In addition, a missing scsi_host_put() is added for error path in hisi_sas_shost_alloc_pci() and v3 driver removal. Signed-off-by: Pan Bian # For main.c changes Signed-off-by: John Garry ---

Re: scsi: hisi_sas: replace kfree with scsi_host_put

2017-08-08 Thread PanBian
On Tue, Aug 08, 2017 at 03:56:22PM +0100, John Garry wrote: > On 08/08/2017 12:37, Pan Bian wrote: > >Return value of scsi_host_alloc() should be released with > >scsi_host_put() rather than kfree(). > > > >Signed-off-by: Pan Bian > > We also have a kfree(shost) in newly

Re: scsi: hisi_sas: replace kfree with scsi_host_put

2017-08-08 Thread PanBian
On Tue, Aug 08, 2017 at 03:56:22PM +0100, John Garry wrote: > On 08/08/2017 12:37, Pan Bian wrote: > >Return value of scsi_host_alloc() should be released with > >scsi_host_put() rather than kfree(). > > > >Signed-off-by: Pan Bian > > We also have a kfree(shost) in newly added pci-based v3

Re: scsi: hisi_sas: replace kfree with scsi_host_put

2017-08-08 Thread John Garry
On 08/08/2017 12:37, Pan Bian wrote: Return value of scsi_host_alloc() should be released with scsi_host_put() rather than kfree(). Signed-off-by: Pan Bian We also have a kfree(shost) in newly added pci-based v3 driver which would need replacing for consistency. But,

Re: scsi: hisi_sas: replace kfree with scsi_host_put

2017-08-08 Thread John Garry
On 08/08/2017 12:37, Pan Bian wrote: Return value of scsi_host_alloc() should be released with scsi_host_put() rather than kfree(). Signed-off-by: Pan Bian We also have a kfree(shost) in newly added pci-based v3 driver which would need replacing for consistency. But, apart from that, we

scsi: hisi_sas: replace kfree with scsi_host_put

2017-08-08 Thread Pan Bian
Return value of scsi_host_alloc() should be released with scsi_host_put() rather than kfree(). Signed-off-by: Pan Bian --- drivers/scsi/hisi_sas/hisi_sas_main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/hisi_sas/hisi_sas_main.c

scsi: hisi_sas: replace kfree with scsi_host_put

2017-08-08 Thread Pan Bian
Return value of scsi_host_alloc() should be released with scsi_host_put() rather than kfree(). Signed-off-by: Pan Bian --- drivers/scsi/hisi_sas/hisi_sas_main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/hisi_sas/hisi_sas_main.c