Re: [PATCH] [6/21] Remove unchecked_isa_dma in advansys.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Nov 16, 2008 at 11:56:21AM -0500, James Bottomley wrote:
> On Sun, 2008-11-16 at 00:11 +0100, Andi Kleen wrote:
> > That patch is a little more complicated than the others. advansys
> > was the only ISA driver who actually passed ->cmnd to the firmware.
> > So I implemented a simple own bounce buffer scheme for this case.
> > Also did sense_buffer bouncing in the driver while I was at it;
> > which means it doesn't require the mid layer to do this anymore.
> > 
> > - allocate hostdata with GFP_DMA separately for the ISA case
> > - Tell block layer explicitely to bounce for ISA case
> > - remove unchecked_isa_dma
> > 
> > Untested due to lack of hardware
> > 
> > v2: use dma api for all allocations
> 
> Just a minute:  this is another driver where you allocate coherent
> memory for the host structure but fail to use it for I/O as far as I can
> tell.
> 
> What's going on here?  If this is just a ploy to get GFP_DMA memory,
> then this isn't the way to do it.  Firstly, it doesn't seem to be needed

It's just that the structure was in GFP_DMA before due to unchecked_isa_dma
so I wanted to do a equivalent convertion

> and secondly, coherent memory is hard (or impossible) to manufacture on
> certain platforms.  You should only use it for DMA mailboxes and other
> register exchanges between the device and main memory ... expanding its
> use is asking for resource exhaustion.

It's not expanding it, in fact it lowers it because they allocate
less in GFP_DMA now than with unchecked_isa_dma (e.g. no more commands
and sense buffers)

-Andi

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

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux