ble completions")
Signed-off-by: Dan Carpenter
---
include/scsi/scsi_cmnd.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/scsi/scsi_cmnd.h b/include/scsi/scsi_cmnd.h
index 3de905e205ce..d85e6befa26b 100644
--- a/include/scsi/scsi_cmnd.h
+++ b/include/scsi/scsi_cm
If "interface" is NULL then we can't release it and trying to will only
lead to an Oops.
Fixes: aea71a024914 ("[SCSI] bnx2fc: Introduce interface structure for each
vlan interface")
Signed-off-by: Dan Carpenter
---
drivers/scsi/bnx2fc/bnx2fc_fcoe.c | 2 +-
1 file change
On Mon, Oct 22, 2018 at 08:25:49AM +0100, James Bottomley wrote:
> On Mon, 2018-10-22 at 09:50 +0300, Dan Carpenter wrote:
> > There was a merge problem and we accidentally removed the "nrport"
> > initialization.
> >
> > Fixes: 77c5bf5647b5 ("Merge br
There was a merge problem and we accidentally removed the "nrport"
initialization.
Fixes: 77c5bf5647b5 ("Merge branch 'misc' into for-next")
Signed-off-by: Dan Carpenter
---
drivers/scsi/lpfc/lpfc_debugfs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git
On Fri, Oct 19, 2018 at 12:19:09PM +0300, Dan Carpenter wrote:
> We only want the value to be zero or one.
>
> It's not a big deal, but say we passed set value to INT_MIN, then
> disable_enclosure_messages_show() would return that 12 bytes of "buf"
> are initialized bu
sge_count = (u32)sg_dma_len(sgl);
1619 hw_sgl++;
1620 }
1621 }
1622 submit:
1623 spin_lock_irqsave(>queue_lock, flags);
regards,
dan carpenter
ak warning when that happens.
Fixes: 77266186397c ("scsi: myrs: Add Mylex RAID controller (SCSI interface)")
Signed-off-by: Dan Carpenter
---
drivers/scsi/myrs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/scsi/myrs.c b/drivers/scsi/myrs.c
index 07e5a3
If both processors are absent then it's supposed to print that, but
instead we print that just the second processor is absent.
Fixes: 77266186397c ("scsi: myrs: Add Mylex RAID controller (SCSI interface)")
Signed-off-by: Dan Carpenter
---
drivers/scsi/myrs.c | 4 ++--
1 file
The || was supposed to be |. The original code just sets ->result to 1.
Fixes: 77266186397c ("scsi: myrs: Add Mylex RAID controller (SCSI interface)")
Signed-off-by: Dan Carpenter
---
drivers/scsi/myrs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/
We shouldn't allow negative thresholds. I don't know what it would do
but it can't be good.
Fixes: 8b4673ba3a1b ("scsi: qla2xxx: Add support for ZIO6 interrupt threshold")
Signed-off-by: Dan Carpenter
diff --git a/drivers/scsi/qla2xxx/qla_attr.c b/drivers/scsi/qla2xxx/qla_at
Hi Anil,
I love your patch! Perhaps something to improve:
url:
https://github.com/0day-ci/linux/commits/Himanshu-Madhani/qla2xxx-Add-FC-NVMe-Target-support/20180916-090108
base: https://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi.git for-next
smatch warnings:
We should first do the le16_to_cpu endian conversion and then apply
the FCP_CMD_LENGTH_MASK mask.
Fixes: 5f35509db179 ("qla2xxx: Terminate exchange if corrupted")
Signed-off-by: Dan Carpenter
---
I just happened to spot this when I was reviewing something unrelated.
I don't have th
ags*/0, _data->sg_dmat) != 0) {
6461 goto error_exit;
6462 }
regards,
dan carpenter
The problem is that ->reset_state is a u8 but it can be set to -1 or -2
in aac_tmf_callback() and the error handling in aac_eh_target_reset()
relies on it to be signed.
Fixes: 0d643ff3c353 ("scsi: aacraid: use aac_tmf_callback for reset fib")
Signed-off-by: Dan Carpenter
diff --
Smatch complains about this code:
drivers/scsi/lpfc/lpfc_scsi.c:1053 lpfc_get_scsi_buf_s4()
warn: variable dereferenced before check 'lpfc_cmd' (see line 1039)
Fortunately the NULL check isn't required so I have removed it.
Signed-off-by: Dan Carpenter
diff --git a/drivers/scsi/lpfc
We accidentally return success instead of -ENOMEM on this error path.
Fixes: 2908d778ab3e ("[SCSI] aic94xx: new driver")
Signed-off-by: Dan Carpenter
---
v2: return -ENOMEM instead of -ENODEV
diff --git a/drivers/scsi/aic94xx/aic94xx_init.c
b/drivers/scsi/aic94xx/aic94xx_in
On Wed, Aug 08, 2018 at 03:16:57PM +0100, John Garry wrote:
> On 08/08/2018 12:56, Dan Carpenter wrote:
> > We accidentally return success instead of -ENODEV on this error path.
>
> Sorry to nitpick, but - as I see - the only way for
> sas_domain_attach_transport() to fail
We accidentally return success instead of -ENODEV on this error path.
Fixes: 2908d778ab3e ("[SCSI] aic94xx: new driver")
Signed-off-by: Dan Carpenter
diff --git a/drivers/scsi/aic94xx/aic94xx_init.c
b/drivers/scsi/aic94xx/aic94xx_init.c
index 80e5b283fd81..cb8191afc1dc 100644
---
sp->free(sp);
2646 }
2647 e->u.iosb.sp = sp;
Dereference without checking
2648 qla2x00_post_work(vha, e);
2649 }
regards,
dan carpenter
F_RES;
1859 goto reject;
1860 }
regards,
dan carpenter
n't change runtime, but this is the more idiomatic way to do it and
makes the static checker happy.
Signed-off-by: Dan Carpenter
diff --git a/drivers/scsi/qedi/qedi_main.c b/drivers/scsi/qedi/qedi_main.c
index cf274a79e77a..682f3ce31014 100644
--- a/drivers/scsi/qedi/qedi_main.c
+++ b/drivers/scsi/q
Hi Mike,
Thank you for the patch! Perhaps something to improve:
url:
https://github.com/0day-ci/linux/commits/Mike-Christie/tcmu-fix-hung-netlink-requests-during-restarts/20180622-115832
smatch warnings:
drivers/target/target_core_user.c:301 tcmu_genl_cmd_done() warn: KERN_* level
not at
ings?
>
Or we could silence a lot of them by adding "qla8044_rd_reg_indirect 2"
to the smatch_data/kernel.ignore_uninitialized_param file.
regards,
dan carpenter
;target[index].ipv6_addr.byte);
899 else
900 snprintf(tgt->ip_addr, IPV4_LEN, "%pI4\n",
901 block->target[index].ipv4_addr.byte);
902 }
regards,
dan carpenter
goto bye;
2023
regards,
dan carpenter
m not 100% sure if correct.
Looks good to me.
Reviewed-by: Dan Carpenter <dan.carpen...@oracle.com>
regards,
dan carpenter
reset() doesn't take NULL pointers, it's just going to
crash.
268
269 return 0;
270 }
regards,
dan carpenter
If we had more than 32 megaraid cards then it would cause memory
corruption. That's not likely, of course, but it's handy to enforce it
and make the static checker happy.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/megaraid.c b/drivers/scsi/megaraid.c
cwdev_iter),
> + NULL);
> if (!entry)
> return -ENOENT;
> return 0;
regards,
dan carpenter
e so it's not
going to overflow unless there is a firmware bug.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
---
v2: rebase, and re-write commit message
diff --git a/drivers/scsi/cxgbi/cxgb4i/cxgb4i.c
b/drivers/scsi/cxgbi/cxgb4i/cxgb4i.c
index 406e94312d4e..beb146b7c17c 100644
---
On Wed, Mar 28, 2018 at 09:14:25PM +0530, Varun Prakash wrote:
> On Wed, Mar 21, 2018 at 09:12:00PM -0400, Martin K. Petersen wrote:
> >
> > Varun: Please look at this. Thanks!
> >
> > > What happened to this one?
> > >
> > > regards,
> >
Here is another use after free if we reset the card. The adpt_hba_reset()
function frees "pHba" on error.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/dpt_i2o.c b/drivers/scsi/dpt_i2o.c
index 3c667b23a801..359e0acfbc7c 100644
--- a/driver
Yeah. You're right. Thanks for catching that.
regards,
dan carpenter
The scsi_host_put() function frees "pHba" and then we dereference it on
the next line when we do "scsi_host_put(pHba->host);".
Fixes: 38e09e3bb056 ("scsi: dpt_i2o: stop using scsi_unregister")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff -
What happened to this one?
regards,
dan carpenter
On Wed, Nov 29, 2017 at 02:42:20PM +0300, Dan Carpenter wrote:
> The story is that Smatch marks skb->data as untrusted and so it
> complains about this code:
>
> drivers/scsi/cxgbi/cxgb4i/cxgb4i.c:2111 t4_uld_rx_handler(
ctxp->oxid);
918 else
919 lpfc_nvmet_sol_fcp_issue_abort(phba, ctxp, ctxp->sid,
920 ctxp->oxid);
921 spin_unlock_irqrestore(>ctxlock, flags);
922 }
regards,
dan carpenter
04e81ee95e155e9043132#n751
>
> static inline struct crypto_tfm *crypto_shash_tfm(struct crypto_shash *tfm)
> {
> return >base;
> }
Yes. It's not a dereference, it's just doing pointer math to get the
address.
regards,
dan carpenter
We accidentally used a logical || instead of a | so these bit masks are
off.
Fixes: 8a8606895947 ("scsi: myrs: Add Mylex RAID controller (SCSI interface)")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/myrs.c b/drivers/scsi/myrs.c
in
This code causes a static checker because we have an upper bound on
"value" but not a lower bound. In other words "value" can be s32min-2.
It's harmless but really it should just be bool.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/
On 64 bit CPUs there is a memory corruption bug on probe(). It should
be a u32 pointer instead of an unsigned long pointer or we write past
the end of the setupdata[] array.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
Reviewed-by: Hannes Reinecke <h...@suse.com>
---
I w
uf);
2244 if (status == DAC960_V2_NormalCompletion) {
2245 myrs_log_event(cs, cs->event_buf);
2246 cs->next_evseq++;
And I guess this is where we set cs->next_evseq.
2247 interval = 1;
2248 }
2249 }
regards,
dan carpenter
My static checker complains about an out of bounds read:
drivers/message/fusion/mptctl.c:2786 mptctl_hp_targetinfo()
error: buffer overflow 'hd->sel_timeout' 255 <= u32max.
It's true that we probably should have a bounds check here.
Signed-off-by: Dan Carpenter <dan.carpen...@o
We wanted to exit the loop with "div" set to zero, but instead, if we
don't hit the break then "div" is -1 when we finish the loop. It leads
to an array underflow a few lines later.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi
We should set the error code if fc_remote_port_add() fails.
Fixes: daf0cd445a21 ("scsi: storvsc: Add support for FC rport.")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/storvsc_drv.c b/drivers/scsi/storvsc_drv.c
index 3b3d1d050cac..40f
^^^
But there is an unchecked NULL dereference here.
131 break;
132 case SRB_LOGOUT_CMD:
regards,
dan carpenter
qla25xx_free_rsp_que(vha, rsp);
^^^
603
604 return ret;
regards,
dan carpenter
regards,
dan carpenter
SY flag to prevent double completions.
971 * The nvme rport is getting unregistered and there is
regards,
dan carpenter
400 * days;
3682 if (secs < 0) {
Not possible.
3683 days = days - 1;
3684 secs = secs + 86400;
3685 }
3686 j = days / 146097;
regards,
dan carpenter
arning
message. Let's address it by adding a sanity check to make sure "opc"
is within bounds.
Fixes: bbc02c7e9d34 ("cxgb4: Add register, message, and FW definitions")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/cxgbi/cxgb4i/cxgb4
the question is we're adding an option called "msi_enable" which is
used to disable MSI interrupts "if it does not work properly". Why is
the current code not working properly?
Is there a crash or a performance issue? What does the bug in the
current code look like from a user perspective? Can you send us a dmesg
from a failing system?
regards,
dan carpenter
tiful, but I can't actually apply
this patch? Which tree is this written against? I'm using linux-next.
regards,
dan carpenter
nfo(>dev, for a start.
I know that the other prints don't use this, but we could use it one
time then slowly add more users until more are using dev_info() than
pr_info() and then someone will decide to clean up the old users.
regards,
dan carpenter
The error message dereferences "rqb_entry" so we need to print it first
and then free the buffer.
Fixes: 6c621a2229b0 ("scsi: lpfc: Separate NVMET RQ buffer posting from IO
resources SGL/iocbq/context")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff
[ Ha ha. The kbuild-bot automatically inserts complimentary things that
"I love your patch." In fact, I have not looked at your patch at all,
I'm just forwarding this email from a robot after glancing at the
code. - dan carpenter ]
Hi Anil,
I love your patch! Perhaps
We added a new error path here but we forgot to drop the lock first
before returning.
Fixes: 0d44374c1aae ("tcmu: fix double se_cmd completion")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/target/target_core_user.c
b/drivers/target/target_c
"udev->nl_reply_supported" is an int but on 64 bit arches we are writing
8 bytes of data to it so it corrupts four bytes beyond the end of the
struct.
Fixes: b849b4567549 ("target: Add netlink command reply supported option for
each device")
Signed-off-by: Dan Carpenter &l
pr_info() has a KERN_INFO already so the second KERN_INFO isn't needed.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/mpt3sas/mpt3sas_scsih.c
b/drivers/scsi/mpt3sas/mpt3sas_scsih.c
index 3a9438a1704e..b258f210120a 100644
--- a/drivers/scsi/m
NVMe PCIe device related events
generated from firmware.")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/mpt3sas/mpt3sas_scsih.c
b/drivers/scsi/mpt3sas/mpt3sas_scsih.c
index 3a9438a1704e..93b45e618edb 100644
--- a/drivers/scsi/mpt3sas/mpt3sas_scsih
a 4 byte array, but it's clearly not. You're
saying it's supposed to be a single dword array but why??? Is there
something special and mandatory stored in the first 4 bytes? Why can't
it just be a zero size array?
It would help if there were at least a comment or something.
regards,
dan carpenter
device->scsi3addr[] is an array, not a pointer, so it can't be NULL.
I've removed the check.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c
index 287e5eb0723f..b0aa5dc1d54c 100644
--- a/drivers/scsi/hpsa.c
+++ b/drivers/sc
e the specially allocated buffer of
1465 * contiguous memory.
1466 */
1467 prp_page = (__le64 *)mpt3sas_base_get_pcie_sgl(ioc, smid);
1468 prp_page_phys = (__le64 *)mpt3sas_base_get_pcie_sgl_dma(ioc,
smid);
1469
regards,
dan carpenter
Argh... My script chose a stupid subject. Sorry for not catching that.
regards,
dan carpenter
On Wed, Oct 18, 2017 at 12:52:49AM +0300, Dan Carpenter wrote:
> Hey,
>
> This code is older than git is so it probably doesn't matter. But just
> for laughs does anyone know what
data->init_level++;
4819
regards,
dan carpenter
The ! has higher precedence than the & operation. I've added
parenthesis so this works as intended.
Fixes: 952c303b329c ("scsi: lpfc: Ensure io aborts interlocked with the
target.")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/lpfc/l
t;bna: integer overflow bug in debugfs").
Fixes: ab2a9ba189e8 ("[SCSI] bfa: add debugfs support")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/bfa/bfad_debugfs.c b/drivers/scsi/bfa/bfad_debugfs.c
index 8dcd8c70c7ee..05f523971348 100644
--
spin_unlock_irq(shost->host_lock);
6199 vport->fc_rscn_id_list[vport->fc_rscn_id_cnt++] = pcmd;
^^^^^^^
But here we don't check here. It feels like we should be checking on
this path as well.
6200 /* Indicate we are done walking fc_rscn_id_list on this vport */
6201 vport->fc_rscn_flush = 0;
regards,
dan carpenter
bsg-lib for SMP
passthrough")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
---
I'm not totally sure about the .status thing. This is a static checker
fix.
diff --git a/drivers/scsi/mpt3sas/mpt3sas_transport.c
b/drivers/scsi/mpt3sas/mpt3sas_transport.c
index d3940c5d
_total += size;
But ->alloc_total is not used anywhere.
I don't see a buffer overflow here.
regards,
dan carpenter
w region-based flash-part accesses.")
Reported-by: shqking <shqk...@gmail.com>
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
---
v2: Add stable and the URL for bugzila
diff --git a/drivers/scsi/qla2xxx/qla_attr.c b/drivers/scsi/qla2xxx/qla_attr.c
index 75c4b312645e..9ce28c4f9812
On Wed, Aug 30, 2017 at 08:28:52PM +0800, shqking wrote:
> Hi,
>
> Glad to see it is fixed.
>
> Can I apply for a CVE ID for this bug?
>
We don't handle that on this list. You'd need to ask on
oss-secur...@lists.openwall.com.
regards,
dan carpenter
rs. So we would get memory corruption and likely
a crash when we call ha->isp_ops->write_optrom() and ->read_optrom().
Only root can trigger this bug.
Fixes: b7cc176c9eb3 ("[SCSI] qla2xxx: Allow region-based flash-part accesses.")
Reported-by: shqking <shqk...@gmail.com
The > here should be >= or we end up reading one element beyond the end
of the qedi->itt_map[] array. The qedi->itt_map[] array is allocated in
qedi_alloc_itt().
Fixes: ace7f46ba5fd ("scsi: qedi: Add QLogic FastLinQ offload iSCSI driver
framework.")
Signed-off-by: Dan
mutex_lock(_tgt_mutex);
1553 list_del(>vha_tgt.qla_tgt->tgt_list_entry);\
The patch adds a new dereference.
1554 mutex_unlock(_tgt_mutex);
1555
regards,
dan carpenter
^
We added a new unchecked dereference.
2011 spin_unlock_irq(shost->host_lock);
2012
regards,
dan carpenter
The parentheses are in the wrong place so we specify the length as
"sizeof(this_device->device_id) < 0" which is zero.
Fixes: 988b87edd231 ("scsi: hpsa: Ignore errors for unsupported LV_DEVICE_ID
VPD page")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
If "val" is SG_MAX_QUEUE then we are one element beyond the end of the
"rinfo" array so the > should be >=.
Fixes: 109bade9c625 ("scsi: sg: use standard lists for sg_requests")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/d
{
If i is negative then it's less than OS_FM_TAB_MAX so we read before
the start of the STp->header_cache->dat_fm_tab.fm_tab_ent[] array.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
---
There is a second static checker warning that I didn't know how to
address:
drivers/scs
Calling list_del() on the iterator pointer in list_for_each_entry() will
cause an oops. We need to user the _safe() version for that.
Fixes: c73d02f63c16 ("tcmu: Add fifo type waiter list support to avoid
starvation")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff
It would be simple enough to write it like you say, but it probably
should be done by someone who is able to test it.
regards,
dan carpenter
pport"). The relevant section is "Also fix up a name truncation
problem". Can someone review this code and figure out the right thing
to do?
Fixes: b836439faf04 ("aacraid: 4KB sector support")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/
"qd.id" comes directly from the copy_from_user() on the line before so
we should verify that it's within bounds.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
---
This bug predates git.
diff --git a/drivers/scsi/aacraid/aachba.c b/drivers/scsi/aacraid/aachba.c
in
On Fri, Jul 14, 2017 at 11:01:11AM +0200, Johannes Thumshirn wrote:
> On Fri, Jul 14, 2017 at 10:46:03AM +0300, Dan Carpenter wrote:
> >761 case SG_DXFER_FROM_DEV:
> >762 if (hp->dxfer_len < 0)
> > ^^^
xfer_len and I noticed that the
documentation for hp->resid is wrong. It says:
int resid; /* [o] dxfer_len - actual_transferred */
My guess is that resid stands for Response ID but I'm not positive.
regards,
dan carpenter
We shouldn't be writing over the "ret" variable. It means we return
ERR_PTR(0) which is NULL and it results in a NULL dereference in the
caller.
Fixes: ace7f46ba5fd ("scsi: qedi: Add QLogic FastLinQ offload iSCSI driver
framework.")
Signed-off-by: Dan Carpenter <dan.carp
an error
pointer.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/libfc/fc_disc.c b/drivers/scsi/libfc/fc_disc.c
index fd501f8dbb11..8660f923ace0 100644
--- a/drivers/scsi/libfc/fc_disc.c
+++ b/drivers/scsi/libfc/fc_disc.c
@@ -573,7 +573,7 @@ stati
There are "req->num_outstanding_cmds" elements in the
req->outstanding_cmds[] array so the > here should be >=.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/qla2xxx/qla_target.c
b/drivers/scsi/qla2xxx/qla_target.c
index 6e479
On Tue, Feb 07, 2017 at 02:27:09PM +0100, walter harms wrote:
>
>
> Am 07.02.2017 14:01, schrieb Dan Carpenter:
> > The problem here is this:
> >
> > sprintf(host_buf, "qedi_ofld%d", qedi->shost->host_no);
> >
> > host_buf is 16 charac
If lpfc_nvmet_unsol_fcp_issue_abort() fails then we accidentally
increment "tgtp->xmt_abort_rsp_error" and then two lines later we
increment it a second time.
Fixes: 547077a44b3b ("scsi: lpfc: Adding additional stats counters for nvme.")
Signed-off-by: Dan Carpenter &l
We're calling spin_lock_irq() multiple times, the problem is that on the
first spin_unlock_irq() then we will re-enable IRQs and we don't want
that.
Fixes: 966bb5b71196 ("scsi: lpfc: Break up IO ctx list into a separate get and
put list")
Signed-off-by: Dan Carpenter <dan.carpen.
The copy_from/to_user() functions return the number of bytes remaining
to be copied but we had intended to return -EFAULT here.
Fixes: bc88ac47d5cb ("scsi: cxlflash: Support AFU debug")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/cxlflash/
On Fri, Jun 23, 2017 at 04:25:27PM +0100, John Garry wrote:
> On 23/06/2017 16:15, Dan Carpenter wrote:
> > phy->phy_type is a u64. We only ever use the first two bits so it's a
> > bit over kill perhaps.
>
> Hi Dan,
>
> Right, u64 is unneeded and u32 would
nintentionally clear the high 32 bits as well.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/scsi/hisi_sas/hisi_sas.h b/drivers/scsi/hisi_sas/hisi_sas.h
index 4fc23087a939..b23245aeab74 100644
--- a/drivers/scsi/hisi_sas/hisi_sas.h
+++ b/drivers/scsi/hisi_sas
If bnx2i_map_ep_dbell_regs() then we accidentally return NULL instead
of an error pointer. It results in a NULL dereference in
iscsi_if_ep_connect().
Fixes: cf4e6363859d ("[SCSI] bnx2i: Add bnx2i iSCSI driver.")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --gi
> + mutex_unlock(_config_mutex);
> > +
> > if (rc)
> > - goto out_free;
> > + goto out_destroy;
> >
> > - mutex_unlock(_config_mutex);
> > return 0;
> >
> if you do that, why not
> if (!rc) return 0;
Gar... No. Please don't get creative with the last if statement.
regards,
dan carpenter
I'm fine with this version...
regards,
dan carpenter
^
This is the same as "return 0;" and I guess it's supposed to be a
success return? But it would look more clear if we changed it to return
a literal instead of rc.
2297 }
2298
2299 out_nodev:
2300 rtnl_unlock();
regards,
dan carpenter
s to spaghetti code and it's confusing. Please
never do this again.
The original is correct and the new code is bad rubbish code.
regards,
dan carpenter
On Fri, May 26, 2017 at 11:11:37AM +0100, Colin King wrote:
> From: Colin Ian King <colin.k...@canonical.com>
>
> Trivial fix to spelling mistake in debugfs message
>
Are you using a tool to find all these spelling mistakes?
regards,
dan carpenter
This should be CC'd to qlogic-storage-upstr...@qlogic.com as well.
regards,
dan carpenter
On Sun, May 07, 2017 at 10:30:20PM +0100, Colin King wrote:
> From: Colin Ian King <colin.k...@canonical.com>
>
> iscsi_lookup_endpoint can potentially return null and in 9 out of
NMAP_THREE, k);
721
722 if (cfg->afu)
But the existing code assumed it could be NULL. Presumably it can't?
723 stop_afu(cfg);
724
regards,
dan carpenter
1 - 100 of 407 matches
Mail list logo