linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* possible bug using async_xor() call in ops_run_post_xor()
@ 2008-07-25 18:45 tirumalareddy marri
  2008-07-25 19:47 ` Dan Williams
  0 siblings, 1 reply; 3+ messages in thread
From: tirumalareddy marri @ 2008-07-25 18:45 UTC (permalink / raw)
  To: linux-raid; +Cc: Dan Williams

I am looking at async_xor() usage and found that if async_xor() returns null because of  device->device_prep_dma_xor() <async_xor.c> failed to get slot. This might cause failure of stripe creation . Which would cause data corruption in RAID-5 at high data rates.
OR
Data integrity is guaranteed because ops_complete_write() will not be called in the event of  device->device_prep_dma_xor() failed to get slot and returned NULL ? 
Thanks,
Marri
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: possible bug using async_xor() call in ops_run_post_xor()
  2008-07-25 18:45 tirumalareddy marri
@ 2008-07-25 19:47 ` Dan Williams
  0 siblings, 0 replies; 3+ messages in thread
From: Dan Williams @ 2008-07-25 19:47 UTC (permalink / raw)
  To: tirumalareddy marri; +Cc: linux-raid

On Fri, Jul 25, 2008 at 11:45 AM, tirumalareddy marri
<tirumalareddymarri@yahoo.com> wrote:
> I am looking at async_xor() usage and found that if async_xor() returns null because of  device->device_prep_dma_xor() <async_xor.c> failed to get slot. This might cause failure of stripe creation . Which would cause data corruption in RAID-5 at high data rates.
> OR
> Data integrity is guaranteed because ops_complete_write() will not be called in the event of  device->device_prep_dma_xor() failed to get slot and returned NULL ?

Hi Marri,

ops_complete_write will be called regardless of whether NULL is
returned.  If async_xor returns NULL it simply indicates to the caller
that the operation was completed synchronously.  In current mainline
async_xor will poll for a descriptor so the driver must take care to
ensure forward progress.

--
Dan

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: possible bug using async_xor() call in ops_run_post_xor()
@ 2008-07-27 23:19 tirumalareddy marri
  0 siblings, 0 replies; 3+ messages in thread
From: tirumalareddy marri @ 2008-07-27 23:19 UTC (permalink / raw)
  To: linux-raid

Dan,
  You right. async_xor() wait for (tx != NULL).
Thanks,
Marri

----- Original Message ----
From: Dan Williams <dan.j.williams@intel.com>
To: tirumalareddy marri <tirumalareddymarri@yahoo.com>
Cc: linux-raid@vger.kernel.org
Sent: Friday, July 25, 2008 12:47:27 PM
Subject: Re: possible bug using async_xor() call in ops_run_post_xor()

On Fri, Jul 25, 2008 at 11:45 AM, tirumalareddy marri
<tirumalareddymarri@yahoo.com> wrote:
> I am looking at async_xor() usage and found that if async_xor() returns null because of  device->device_prep_dma_xor() <async_xor.c> failed to get slot. This might cause failure of stripe creation . Which would cause data corruption in RAID-5 at high data rates.
> OR
> Data integrity is guaranteed because ops_complete_write() will not be called in the event of  device->device_prep_dma_xor() failed to get slot and returned NULL ?

Hi Marri,

ops_complete_write will be called regardless of whether NULL is
returned.  If async_xor returns NULL it simply indicates to the caller
that the operation was completed synchronously.  In current mainline
async_xor will poll for a descriptor so the driver must take care to
ensure forward progress.

--
Dan
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2008-07-27 23:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-27 23:19 possible bug using async_xor() call in ops_run_post_xor() tirumalareddy marri
  -- strict thread matches above, loose matches on Subject: below --
2008-07-25 18:45 tirumalareddy marri
2008-07-25 19:47 ` Dan Williams

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).