lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130801171144.GB13747@jonmason-lab>
Date:	Thu, 1 Aug 2013 10:11:45 -0700
From:	Jon Mason <jon.mason@...el.com>
To:	"Jiang, Dave" <dave.jiang@...el.com>
Cc:	Brice Goglin <Brice.Goglin@...ia.fr>, Dan Williams <djbw@...com>,
	"Koul, Vinod" <vinod.koul@...el.com>,
	LKML <linux-kernel@...r.kernel.org>
Subject: Re: ioatdma: add ioat_raid_enabled module parameter

On Wed, Jul 31, 2013 at 03:14:07PM -0700, Jiang, Dave wrote:
> I'm ok with enabling this for people that just want to use DMA and not
> RAID. 

I might be crazy, but I'd be in favor of disabling the RAID offload by
default on non-Atom platforms.

Thanks,
Jon

> 
> Acked-by: Dave Jiang <dave.jiang@...el.com>
> 
> On Thu, 2013-08-01 at 00:05 +0200, Brice Goglin wrote:
> > ioatdma: add ioat_raid_enabled module parameter
> > 
> > Commit f26df1a1 added a 64-byte alignment requirement for legacy
> > operations to work around a silicon errata when mixing legacy and
> > RAID descriptors.
> > Passing ioat_raid_enabled=0 now disables RAID offload entirely in
> > the ioatdma driver so that legacy operations (memcpy, etc.) can
> > work without alignment restrictions anymore.
> > 
> > Signed-off-by: Brice Goglin <Brice.Goglin@...ia.fr>
> > ---
> >  drivers/dma/ioat/dma_v3.c |    9 +++++++--
> >  1 file changed, 7 insertions(+), 2 deletions(-)
> > 
> > Index: b/drivers/dma/ioat/dma_v3.c
> > ===================================================================
> > --- a/drivers/dma/ioat/dma_v3.c	2013-07-31 23:06:24.163810000 +0200
> > +++ b/drivers/dma/ioat/dma_v3.c	2013-07-31 23:47:54.246719841 +0200
> > @@ -67,6 +67,11 @@
> >  #include "dma.h"
> >  #include "dma_v2.h"
> >  
> > +static int ioat_raid_enabled = 1;
> > +module_param(ioat_raid_enabled, int, 0444);
> > +MODULE_PARM_DESC(ioat_raid_enabled,
> > +		 "control support of RAID offload (default: 1)");
> > +
> >  /* ioat hardware assumes at least two sources for raid operations */
> >  #define src_cnt_to_sw(x) ((x) + 2)
> >  #define src_cnt_to_hw(x) ((x) - 2)
> > @@ -1775,7 +1780,7 @@ int ioat3_dma_probe(struct ioatdma_devic
> >  	dma->device_alloc_chan_resources = ioat2_alloc_chan_resources;
> >  	dma->device_free_chan_resources = ioat2_free_chan_resources;
> >  
> > -	if (is_xeon_cb32(pdev))
> > +	if (is_xeon_cb32(pdev) && ioat_raid_enabled)
> >  		dma->copy_align = 6;
> >  
> >  	dma_cap_set(DMA_INTERRUPT, dma->cap_mask);
> > @@ -1783,7 +1788,7 @@ int ioat3_dma_probe(struct ioatdma_devic
> >  
> >  	device->cap = readl(device->reg_base + IOAT_DMA_CAP_OFFSET);
> >  
> > -	if (is_bwd_noraid(pdev))
> > +	if (!ioat_raid_enabled || is_bwd_noraid(pdev))
> >  		device->cap &= ~(IOAT_CAP_XOR | IOAT_CAP_PQ | IOAT_CAP_RAID16SS);
> >  
> >  	/* dca is incompatible with raid operations */
> > 
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ