Re: mtip32xx: add a status field to struct mtip_cmd

2017-04-21 Thread Jens Axboe
On 04/21/2017 08:37 AM, Christoph Hellwig wrote: > On Fri, Apr 21, 2017 at 08:14:03AM -0600, Jens Axboe wrote: >> From: Jens Axboe >> Subject: [PATCH] mtip32xx: fix dereference of stack garbage >> >> We need to get the command payload from the request before >> we attempt to dereference it. >> >>

Re: mtip32xx: add a status field to struct mtip_cmd

2017-04-21 Thread Christoph Hellwig
On Fri, Apr 21, 2017 at 08:14:03AM -0600, Jens Axboe wrote: > From: Jens Axboe > Subject: [PATCH] mtip32xx: fix dereference of stack garbage > > We need to get the command payload from the request before > we attempt to dereference it. > > Fixes: 4dda4735c581 ("mtip32xx: add a status field to st

Re: mtip32xx: add a status field to struct mtip_cmd

2017-04-21 Thread Jens Axboe
On 04/21/2017 08:06 AM, Colin Ian King wrote: > Hi, > > CoverityScan found an issue with the following part of the patch: > > - if (likely(!reserv)) > - blk_mq_complete_request(rq, -ENODEV); > - else if (test_bit(MTIP_PF_IC_ACTIVE_BIT, &dd->port->flags)) { > + if (

re: mtip32xx: add a status field to struct mtip_cmd

2017-04-21 Thread Colin Ian King
Hi, CoverityScan found an issue with the following part of the patch: - if (likely(!reserv)) - blk_mq_complete_request(rq, -ENODEV); - else if (test_bit(MTIP_PF_IC_ACTIVE_BIT, &dd->port->flags)) { + if (likely(!reserv)) { + cmd->status = -ENODEV; +