linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: James Bottomley <James.Bottomley@SteelEye.com>
To: Andrew Morton <akpm@osdl.org>
Cc: linux-scsi@vger.kernel.org
Subject: Re: ips.c warnings
Date: Sun, 16 Oct 2005 17:44:48 -0500	[thread overview]
Message-ID: <1129502688.9388.1.camel@mulgrave> (raw)
In-Reply-To: <20051016140817.4de1cc19.akpm@osdl.org>

On Sun, 2005-10-16 at 14:08 -0700, Andrew Morton wrote:
> drivers/scsi/ips.c: In function `ips_scmd_buf_write':
> drivers/scsi/ips.c:3665: warning: null argument where non-null required (arg 1)
> drivers/scsi/ips.c: In function `ips_scmd_buf_read':
> drivers/scsi/ips.c:3697: warning: null argument where non-null required (arg 2)
> drivers/scsi/ips.c: In function `ips_register_scsi':
> 
> Due to
> 
>                         memcpy(IPS_SG_ADDRESS(&sg[i]), &cdata[xfer_cnt],
>                                min_cnt);
> 
> I guess the compiler is saying that if IPS_SG_ADDRESS indeed evaluates to
> NULL (as it is designed to do), we have an oops.

That's weird ... the compiler can't possibly be in a position to make
that judgement call.  We have lots of places where we return null if
something goes wrong and the kernel oopses.  The compiler certainly
isn't warning about all of them.

James



  reply	other threads:[~2005-10-16 22:44 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-10-16 21:08 ips.c warnings Andrew Morton
2005-10-16 22:44 ` James Bottomley [this message]
2005-10-16 22:57   ` Andrew Morton
2005-10-16 23:11     ` James Bottomley
2005-10-16 23:24       ` Andrew Morton
  -- strict thread matches above, loose matches on Subject: below --
2005-10-20 16:59 Jack Hammer
2005-10-20 17:05 ` Matthew Wilcox
2005-10-20 17:25 Hammer, Jack
2005-10-20 17:29 ` Christoph Hellwig
2005-10-20 17:54   ` James Bottomley
2005-10-20 17:33 IpsLinux
2005-10-20 17:38 Salyzyn, Mark
2005-10-20 17:39 ` Christoph Hellwig
2005-10-20 17:59 IpsLinux

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1129502688.9388.1.camel@mulgrave \
    --to=james.bottomley@steeleye.com \
    --cc=akpm@osdl.org \
    --cc=linux-scsi@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).