[PATCH] qla2xxx: Fix use-after-free issues in qla2xxx_qpair_sp_free_dma()

2019-04-10 Thread Bart Van Assche
The current order for freeing memory is as follows: - struct crc_context itself. - struct crc_context member pointers. Change the freeing order into the following: - struct crc_context member pointers. - struct crc_context itself. Detected by Coverity. Untested. Cc: Himanshu Madhani Cc: Giridh

Re: [PATCH] nvme,scsi: display FC-NVMe port roles

2019-04-10 Thread James Smart
On 4/10/2019 7:16 AM, Hannes Reinecke wrote: Currently the FC-NVMe driver is leverating the SCSI FC transport class to access the remote ports. Which means that all FC-NVMe remote ports will be visible to the fc transport layer, but due to missing definitions the port roles will always be 'unk

Re: [PATCH][V2] scsi: cxgbi: remove redundant __kfree_skb call on skb and free cst->atid

2019-04-10 Thread Dan Carpenter
On Wed, Apr 10, 2019 at 04:54:31PM +0100, Colin King wrote: > From: Colin Ian King > > The error return path via label rel_resource checks for a non-null > skb before free'ing it. However, skb is always null at this exit > path, so the null check and the free are redundant and can be removed. >

Re: [PATCH 2/2] qla2xxx: Fix N2N link up hang

2019-04-10 Thread Bart Van Assche
On Tue, 2019-04-09 at 22:29 -0700, Himanshu Madhani wrote: > From: Quinn Tran > > Prevent driver from endless loop or hang in the case of > NPort ID change. > > Following stack trace is seen > > Feb 12 08:21:17 localhost kernel: Call Trace: > Feb 12 08:21:17 localhost kernel: ? Please include

Re: [PATCH 1/2] qla2xxx: Fix device staying in blocked state

2019-04-10 Thread Bart Van Assche
On Tue, 2019-04-09 at 22:29 -0700, Himanshu Madhani wrote: > From: Quinn Tran > > This patch fixes issue reported by some of the customers, > who discvored that after some event in SAN if the devices ^ discovered?

Re: [PATCHv2] scsi: core: set result when the command cannot be dispatched

2019-04-10 Thread Bart Van Assche
On Tue, 2019-04-09 at 17:02 -0700, Jaesoo Lee wrote: > When SCSI blk-mq is enabled, there is a bug in handling errors in > scsi_queue_rq. > Specifically, the bug is not setting result field of scsi_request correctly > when > the dispatch of the command has been failed. Since the upper layer code

[PATCH][V2] scsi: cxgbi: remove redundant __kfree_skb call on skb and free cst->atid

2019-04-10 Thread Colin King
From: Colin Ian King The error return path via label rel_resource checks for a non-null skb before free'ing it. However, skb is always null at this exit path, so the null check and the free are redundant and can be removed. Removing this allows the original goto's to rel_resource to be cleaned u

Re: [PATCH 0/2] Limit number of hw queues by nr_cpu_ids for virtio-blk and virtio-scsi

2019-04-10 Thread Jens Axboe
On 3/27/19 4:36 AM, Dongli Zhang wrote: > When tag_set->nr_maps is 1, the block layer limits the number of hw queues > by nr_cpu_ids. No matter how many hw queues are use by > virtio-blk/virtio-scsi, as they both have (tag_set->nr_maps == 1), they > can use at most nr_cpu_ids hw queues. > > In add

[PATCH] nvme,scsi: display FC-NVMe port roles

2019-04-10 Thread Hannes Reinecke
Currently the FC-NVMe driver is leverating the SCSI FC transport class to access the remote ports. Which means that all FC-NVMe remote ports will be visible to the fc transport layer, but due to missing definitions the port roles will always be 'unknown'. This patch adds the missing definitions to

Re: [PATCH 2/2] scsi: virtio_scsi: limit number of hw queues by nr_cpu_ids

2019-04-10 Thread Stefan Hajnoczi
On Wed, Mar 27, 2019 at 06:36:35PM +0800, Dongli Zhang wrote: > When tag_set->nr_maps is 1, the block layer limits the number of hw queues > by nr_cpu_ids. No matter how many hw queues are used by virtio-scsi, as it > has (tag_set->nr_maps == 1), it can use at most nr_cpu_ids hw queues. > > In add

Re: [PATCH 1/2] virtio-blk: limit number of hw queues by nr_cpu_ids

2019-04-10 Thread Stefan Hajnoczi
On Wed, Mar 27, 2019 at 06:36:34PM +0800, Dongli Zhang wrote: > When tag_set->nr_maps is 1, the block layer limits the number of hw queues > by nr_cpu_ids. No matter how many hw queues are used by virtio-blk, as it > has (tag_set->nr_maps == 1), it can use at most nr_cpu_ids hw queues. > > In addi

Re: [PATCH 07/10] zfcp: implicitly refresh port-data diagnostics when reading SysFS

2019-04-10 Thread Benjamin Block
On Tue, Apr 09, 2019 at 06:50:50PM +0200, Benjamin Block wrote: > This patch adds implicit updates to the SysFS entries that read the > diagnostic data stored in the "caching buffer" for Exchange Port Data. > > An update is triggered once the buffer is older than ZFCP_DIAG_MAX_AGE > milliseconds (

Re: [PATCH] scsi: smartpqi: Reporting unhandled SCSI errors

2019-04-10 Thread Erwan Velu
Hi there ! Any reactions to this one ? I didn't got a single comment. Cheers, Erwan, Le jeu. 21 mars 2019 à 10:49, Erwan Velu a écrit : > > When a HARDWARE_ERROR is triggered for asc=0x3e, the actual code is only > considering the case where ascq=0x1. > > Following the http://www.t10.org/lists/a

RE: [PATCH 4/4] lib/hexdump.c: Allow multiple groups to be separated by lines '|'

2019-04-10 Thread Alastair D'Silva
> -Original Message- > From: David Laight > Sent: Wednesday, 10 April 2019 6:45 PM > To: 'Alastair D'Silva' ; alast...@d-silva.org > Cc: Jani Nikula ; Joonas Lahtinen > ; Rodrigo Vivi ; > David Airlie ; Daniel Vetter ; Karsten Keil > ; Jassi Brar ; Tom Lendacky > ; David S. Miller ; > Jose

Re: [PATCH 4/4] lib/hexdump.c: Allow multiple groups to be separated by lines '|'

2019-04-10 Thread Sergey Senozhatsky
On (04/10/19 13:17), Alastair D'Silva wrote: > With the wider display format, it can become hard to identify how many > bytes into the line you are looking at. > > The patch adds new flags to hex_dump_to_buffer() and print_hex_dump() to > print vertical lines to separate every N groups of bytes. >

RE: [PATCH 4/4] lib/hexdump.c: Allow multiple groups to be separated by lines '|'

2019-04-10 Thread David Laight
From: Alastair D'Silva > Sent: 10 April 2019 04:17 > With the wider display format, it can become hard to identify how many > bytes into the line you are looking at. > > The patch adds new flags to hex_dump_to_buffer() and print_hex_dump() to > print vertical lines to separate every N groups of by