login
Login
/
Register
Search
Search this site:
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2007
»
October
»
24
Re: [PATCH -mm 09/11] call blk_queue_segment_boundary in __scsi_alloc_queue
view
thread
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From: Jens Axboe
Subject:
Re: [PATCH -mm 09/11] call blk_queue_segment_boundary in __scsi_alloc_queue
Date: Wednesday, October 24, 2007 - 7:28 am
On Wed, Oct 24 2007, FUJITA Tomonori wrote:
quoted text
> On Wed, 24 Oct 2007 07:39:16 -0400 > Jeff Garzik <jeff@garzik.org> wrote: > > > FUJITA Tomonori wrote: > > > request_queue and device struct must have the same value of a segment > > > size limit. This patch adds blk_queue_segment_boundary in > > > __scsi_alloc_queue so LLDs don't need to call both > > > blk_queue_segment_boundary and set_dma_max_seg_size. A LLD can change > > > the default value (64KB) can call device_dma_parameters accessors like > > > pci_set_dma_max_seg_size when allocating scsi_host. > > > > > > Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> > > > --- > > > drivers/scsi/scsi_lib.c | 3 +++ > > > 1 files changed, 3 insertions(+), 0 deletions(-) > > > > > > diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c > > > index 61fdaf0..23a30ab 100644 > > > --- a/drivers/scsi/scsi_lib.c > > > +++ b/drivers/scsi/scsi_lib.c > > > @@ -1645,6 +1645,7 @@ struct request_queue *__scsi_alloc_queue(struct Scsi_Host *shost, > > > request_fn_proc *request_fn) > > > { > > > struct request_queue *q; > > > + struct device *dev = shost->shost_gendev.parent; > > > > > > q = blk_init_queue(request_fn, NULL); > > > if (!q) > > > @@ -1673,6 +1674,8 @@ struct request_queue *__scsi_alloc_queue(struct Scsi_Host *shost, > > > blk_queue_bounce_limit(q, scsi_calculate_bounce_limit(shost)); > > > blk_queue_segment_boundary(q, shost->dma_boundary); > > > > > > + blk_queue_max_segment_size(q, dma_get_max_seg_size(dev)); > > > + > > > > it would be nice to have something more general that's useable in > > drivers/block/sx8.c (for example), something like > > > > static inline void > > dev_blk_associate(struct device *dev, request_queue *q) > > { > > blk_queue_max_segment_size(q, > > dma_get_max_seg_size(dev)); > > } > > > > still, I will ACK the above patch (#9) in case you wish that to become a > > future cleanup, or others dislike this suggestion > > Yeah, I thought about something like that. But I can't find many > non-scsi drivers (ide, sx8, mmc/card/, anymore?) doing dma and having > the restrictions so I just call blk_queue_max_segment_size here. > > Either is ok with me. I'll modify the patch if Jens prefers such > function. Jens?
If there's a use for it, sure. -- Jens Axboe -
unsubscribe notice
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html
Please read the FAQ at
http://www.tux.org/lkml/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
[PATCH -mm 0/11] fix iommu sg merging problem
, FUJITA Tomonori
, (Wed Oct 24, 3:47 am)
[PATCH -mm 01/11] add device_dma_parameters structure
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
[PATCH -mm 02/11] PCI: add device_dma_parameters support
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
[PATCH -mm 03/11] x86: make pci-gart iommu respect the seg ...
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
[PATCH -mm 04/11] ppc: make iommu respect the segment size ...
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
[PATCH -mm 05/11] IA64: make sba_iommu respect the segment ...
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
[PATCH -mm 06/11] alpha: make pci_iommu respect the segmen ...
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
[PATCH -mm 07/11] sparc64: make iommu respect the segment ...
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
[PATCH -mm 08/11] parisc: make iommu respect the segment s ...
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
[PATCH -mm 09/11] call blk_queue_segment_boundary in __scs ...
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
[PATCH -mm 10/11] sata_inic162x: use pci_set_dma_max_seg_size
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
[PATCH -mm 11/11] aacraid: use pci_set_dma_max_seg_size
, FUJITA Tomonori
, (Wed Oct 24, 3:48 am)
Re: [PATCH -mm 11/11] aacraid: use pci_set_dma_max_seg_size
, Jeff Garzik
, (Wed Oct 24, 4:31 am)
Re: [PATCH -mm 01/11] add device_dma_parameters structure
, Jeff Garzik
, (Wed Oct 24, 4:33 am)
Re: [PATCH -mm 02/11] PCI: add device_dma_parameters support
, Jeff Garzik
, (Wed Oct 24, 4:34 am)
Re: [PATCH -mm 08/11] parisc: make iommu respect the segme ...
, Jeff Garzik
, (Wed Oct 24, 4:35 am)
Re: [PATCH -mm 11/11] aacraid: use pci_set_dma_max_seg_size
, FUJITA Tomonori
, (Wed Oct 24, 4:35 am)
Re: [PATCH -mm 09/11] call blk_queue_segment_boundary in _ ...
, Jeff Garzik
, (Wed Oct 24, 4:39 am)
Re: [PATCH -mm 10/11] sata_inic162x: use pci_set_dma_max_s ...
, Jeff Garzik
, (Wed Oct 24, 4:39 am)
Re: [PATCH -mm 0/11] fix iommu sg merging problem
, Jeff Garzik
, (Wed Oct 24, 4:40 am)
Re: [PATCH -mm 0/11] fix iommu sg merging problem
, Jens Axboe
, (Wed Oct 24, 6:24 am)
RE: [PATCH -mm 11/11] aacraid: use pci_set_dma_max_seg_size
, Salyzyn, Mark
, (Wed Oct 24, 6:34 am)
RE: [PATCH -mm 11/11] aacraid: use pci_set_dma_max_seg_size
, Salyzyn, Mark
, (Wed Oct 24, 6:34 am)
Re: [PATCH -mm 02/11] PCI: add device_dma_parameters support
, FUJITA Tomonori
, (Wed Oct 24, 6:41 am)
Re: [PATCH -mm 09/11] call blk_queue_segment_boundary in _ ...
, FUJITA Tomonori
, (Wed Oct 24, 7:15 am)
Re: [PATCH -mm 09/11] call blk_queue_segment_boundary in ...
, Jens Axboe
, (Wed Oct 24, 7:28 am)
Re: [PATCH -mm 0/11] fix iommu sg merging problem
, FUJITA Tomonori
, (Wed Oct 24, 7:32 am)
Re: [PATCH -mm 09/11] call blk_queue_segment_boundary in _ ...
, Jeff Garzik
, (Wed Oct 24, 7:34 am)
Re: [PATCH -mm 09/11] call blk_queue_segment_boundary in ...
, FUJITA Tomonori
, (Wed Oct 24, 7:36 am)
RE: [PATCH -mm 11/11] aacraid: use pci_set_dma_max_seg_size
, FUJITA Tomonori
, (Wed Oct 24, 9:21 am)
RE: [PATCH -mm 11/11] aacraid: use pci_set_dma_max_seg_size
, Salyzyn, Mark
, (Wed Oct 24, 9:25 am)
Navigation
Create content
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Dave Jones
Re: OT: character encodings (was: Linux 2.6.20-rc4)
Greg Kroah-Hartman
[PATCH 17/36] sysdev: detect multiple driver registrations
Sam Ravnborg
Re: [PATCH] kbuild: fix make V=1
Nick Piggin
Re: [PATCH 0/24] make atomic_read() behave consistently across all architectures
Greg Kroah-Hartman
[PATCH 16/36] driver core: cpu: fix section mismatch in cpu.c:store_online
git
:
Stephen R. van den Berg
Re: [RFC] origin link for cherry-pick and revert
Junio C Hamano
Re: [PATCH 1/2] Teach git-describe to display distances from tags.
Johannes Schindelin
Re: [PATCH 2/2] git-svn: support fetch with autocrlf on
fantasy1215
Will tortoisesvn conflict with tortoisegit?
Junio C Hamano
Re: [PATCH 6/6] Teach core object handling functions about gitlinks
linux-netdev
:
Jarek Poplawski
Re: [PATCH] flush_work_sync vs. flush_scheduled_work Re: [PATCH] PHYLIB: IRQ event...
Lennert Buytenhek
Re: Distributed Switch Architecture(DSA)
Daniel Schaffrath
Re: tcp bw in 2.6
Guo-Fu Tseng
Re: jme: UDP checksum error, and lots of them
Gerrit Renker
[PATCH 37/37] dccp: Debugging functions for feature negotiation
openbsd-misc
:
Claudio Jeker
Re: Vlan Tag on Vlan Tag (l2tunneling)
Josh Grosse
ssh/sshd challenge-response seems to have stopped working in -current
Pieter Verberne
File collision while using pkg_add
Tomas Bodzar
bsd: uvm_mapent_alloc: out of static map entries
Community First Financial
Teacher A+ Loan
git-commits-head
:
Linux Kernel Mailing List
ath9k: Added get_survey callback in order to get channel noise
Linux Kernel Mailing List
tracing: protect reader of cmdline output
Linux Kernel Mailing List
kconfig: recalc symbol value before showing search results
Linux Kernel Mailing List
[ARM] 5185/1: Fix spi num_chipselect for lubbock
Linux Kernel Mailing List
swsusp: provide users with a hint about the no_console_suspend option
Colocation donated by:
Syndicate