Re: BUG in copy_page_to_iter() when iscsi sets ENABLE_CLUSTERING

2018-12-07 Thread Christoph Hellwig
roceed. > > BACKGROUND > > Recently Christoph Hellwig sent an email to driver maintainers for > drivers that set ".use_clustering" to DISABLE_CLUSTERING in their SCSI > Host templates, asking if the setting could be changed to > ENABLE_CLUSTERING. > >

[PATCH 09/10] gdth: remove interrupt coalescing support

2018-12-06 Thread Christoph Hellwig
This code has been under a never defined ifdef since the beginning of time (or at least history), and has just bitrotted. Nuke it. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth.c | 151 1 file changed, 12 insertions(+), 139 deletions

[PATCH 04/10] gdth: remove ISA and EISA support

2018-12-06 Thread Christoph Hellwig
The non-PCI code has bitrotted for quite a while and will just oops on load because it passes a NULL pointer to the PCI DMA routines. Lets kill it for good - if someone really wants to use one of these cards I'll help mentoring them to write a proper driver glue. Signed-off-by: Christoph Hellwig

[PATCH 03/10] gdth: remove gdth_{alloc,free}_ioctl

2018-12-06 Thread Christoph Hellwig
under a spinlock with irqs disabled. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth.c | 7 ++-- drivers/scsi/gdth_proc.c | 71 drivers/scsi/gdth_proc.h | 3 -- 3 files changed, 25 insertions(+), 56 deletions(-) diff --git a/drivers/scsi

[PATCH 02/10] gdth: reuse dma coherent allocation in gdth_show_info

2018-12-06 Thread Christoph Hellwig
gdth_show_info currently allocs and frees a dma buffer four times, which isn't very efficient. Reuse a single allocation instead. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth_proc.c | 20 +--- 1 file changed, 5 insertions(+), 15 deletions(-) diff --git a/drivers/scsi

[PATCH 01/10] gdth: refactor ioc_general

2018-12-06 Thread Christoph Hellwig
This function is a huge mess with duplicated error handling. Split out a few useful helpers and use goto labels to untangle the error handling and no-data ioctl handling. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth.c | 244 +++- 1 file changed

[PATCH 10/10] gdth: use generic DMA API

2018-12-06 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Also switch to dma_map_single from pci_map_page in one case where this makes the code simpler. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth.c | 59 +++- drivers/scsi/gdth_proc.c | 4

[PATCH 07/10] gdth: remove dead dma statistics code

2018-12-06 Thread Christoph Hellwig
This code can't be built into the kernel without editing the source file and is not generall useful. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth.c | 18 -- drivers/scsi/gdth_proc.c | 8 2 files changed, 26 deletions(-) diff --git a/drivers/scsi/gdth.c

[PATCH 08/10] gdth: remove dead code under #ifdef GDTH_IOCTL_PROC

2018-12-06 Thread Christoph Hellwig
This can't ever be compiled into the kernel, so remove it. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth_ioctl.h | 89 --- drivers/scsi/gdth_proc.c | 18 2 files changed, 107 deletions(-) diff --git a/drivers/scsi/gdth_ioctl.h b/drivers

[PATCH 05/10] gdth: remove direct serial port access

2018-12-06 Thread Christoph Hellwig
Remove never compile in support for sending debug traces straight to the serial port using direct port access. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth.c | 70 - 1 file changed, 70 deletions(-) diff --git a/drivers/scsi/gdth.c b/drivers

[PATCH 06/10] gdth: remove dead rtc code

2018-12-06 Thread Christoph Hellwig
This code has been under the never defined GDTH_RTC ifdef forever, nuke it. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth.c | 32 1 file changed, 32 deletions(-) diff --git a/drivers/scsi/gdth.c b/drivers/scsi/gdth.c index e8121b80233c..63d704301875

various fixups for gdth

2018-12-06 Thread Christoph Hellwig
Cleans up various oddities found during a code audit, and drops the legacy ISA support which hasn't had a chance to actually work for a long time.

Re: DISABLE_CLUSTERING in scsi drivers

2018-11-25 Thread Christoph Hellwig
On Thu, Nov 22, 2018 at 10:11:33AM +1300, Michael Schmitz wrote: > Christoph, > for Atari SCSI, commands can only be merged if the physical addresses > of all buffers are contiguous (limitation of the Falcon DMA engine). > Documentation/scsi/scsi_mid_low_api.tx does not spell out whether that > is

Re: DISABLE_CLUSTERING in scsi drivers

2018-11-25 Thread Christoph Hellwig
On Thu, Nov 22, 2018 at 09:02:13AM +1100, Finn Thain wrote: > > you in the To list maintain or wrote SCSI drivers that set the > > DISABLE_CLUSTERING flag, which basically disable merges of any > > bio segments. We already have the actual max_segment size limit > > to say which length a segment

Re: DISABLE_CLUSTERING in scsi drivers

2018-11-25 Thread Christoph Hellwig
On Fri, Nov 23, 2018 at 09:09:49AM +0100, Juergen Gross wrote: > On 21/11/2018 10:41, Christoph Hellwig wrote: > > Hi all, > > > > you in the To list maintain or wrote SCSI drivers that set the > > DISABLE_CLUSTERING flag, which basically disable merges of any > &g

Re: [PATCH 3/3] target: replace fabric_ops.name with fabric_alias

2018-11-25 Thread Christoph Hellwig
fabric_alias and fallback to target/$fabric vs > .fabric_name comparison if .fabric_alias isn't initialised. > iscsi_target_mod is the only fabric module to set .fabric_alias . All > other fabric modules rely on .fabric_name matching and can drop the > duplicate string. Looks fine: Reviewed-by: Christoph Hellwig

Re: [PATCH 2/3] target: drop unnecessary get_fabric_name() accessor from fabric_ops

2018-11-25 Thread Christoph Hellwig
Looks good, Reviewed-by: Christoph Hellwig

Re: [PATCH 1/3] target: drop unused pi_prot_format attribute storage

2018-11-25 Thread Christoph Hellwig
e write-only, and drop the always zero > se_dev_attrib.pi_prot_format storage. Looks good, Reviewed-by: Christoph Hellwig

Re: [PATCH] target: drop unnecessary get_fabric_name() accessor from fabric_ops

2018-11-22 Thread Christoph Hellwig
On Thu, Nov 22, 2018 at 03:16:23PM +0100, David Disseldorp wrote: > All fabrics return a const string. In all cases *except* iSCSI the > get_fabric_name() string matches fabric_ops.name. > > Both fabric_ops.get_fabric_name() and fabric_ops.name are user facing, > with the former being used for

DISABLE_CLUSTERING in scsi drivers

2018-11-21 Thread Christoph Hellwig
Hi all, you in the To list maintain or wrote SCSI drivers that set the DISABLE_CLUSTERING flag, which basically disable merges of any bio segments. We already have the actual max_segment size limit to say which length a segment should have, independent of merged or originally created, so this

Re: [PATCH v5] target: add emulate_pr backstore attr to toggle PR support

2018-11-21 Thread Christoph Hellwig
Looks good, Reviewed-by: Christoph Hellwig

Re: [PATCH v3 2/4] target: don't assume t10_wwn.vendor is null terminated

2018-11-20 Thread Christoph Hellwig
This could use a little more explanation, the code doesn't just add a little if but also changes the existing case. Also where can't it be null currently?

Re: [PATCH v3 1/4] target: use consistent left-aligned ASCII INQUIRY data

2018-11-20 Thread Christoph Hellwig
Looks good, Reviewed-by: Christoph Hellwig

[PATCH v3] aha1542: convert to DMA mapping API

2018-11-10 Thread Christoph Hellwig
aha1542 is one of the last users of the legacy isa_*_to_bus APIs, which also isn't portable enough. Convert it to the proper DMA mapping API. Thanks to Ondrej Zary for testing and finding and fixing a crucial bug. Signed-off-by: Christoph Hellwig --- Changes since v2: - fix another sizeof

Re: [PATCH] aha1542: convert to DMA mapping API

2018-11-10 Thread Christoph Hellwig
> > @@ -826,7 +881,8 @@ static int aha1542_dev_reset(struct scsi_cmnd *cmd) > > > > aha1542->aha1542_last_mbo_used = mbo; > > > > - any2scsi(mb[mbo].ccbptr, isa_virt_to_bus([mbo])); /* This gets > > trashed for some reason */ > > + /* This gets trashed for some reason */ > > +

Re: [PATCH 4/4] gdth: use generic DMA API

2018-11-09 Thread Christoph Hellwig
On Fri, Oct 19, 2018 at 09:42:28AM +1100, Finn Thain wrote: > On Thu, 18 Oct 2018, Christoph Hellwig wrote: > > > Switch from the legacy PCI DMA API to the generic DMA API. Also switch > > to dma_map_single from pci_map_page in one case where this makes the code > > simp

Re: [PATCH 2/4] gdth: reuse dma coherent allocation in gdth_show_info

2018-11-09 Thread Christoph Hellwig
> > > > -buf = gdth_ioctl_alloc(ha, GDTH_SCRATCH, FALSE, ); > > if (!buf) > > goto stop_output; > > I think this !buf test is redundant. Thanks, fixed.

Re: [PATCH 1/4] gdth: refactor ioc_general

2018-11-09 Thread Christoph Hellwig
> > + switch (gen.command.OpCode) { > > + case GDT_IOCTL: > > + gen.command.u.ioctl.p_param = paddr; > > + break; > > + case CACHESERVICE: > > + gdth_ioc_cacheservice(ha, , paddr); > > + break; > > + case SCSIRAWSERVICE: > > +

[PATCH 2/3] wd719x: use per-command private data

2018-11-09 Thread Christoph Hellwig
-by: Christoph Hellwig --- drivers/scsi/wd719x.c | 98 +++ drivers/scsi/wd719x.h | 1 - 2 files changed, 42 insertions(+), 57 deletions(-) diff --git a/drivers/scsi/wd719x.c b/drivers/scsi/wd719x.c index 7b05bbcfb186..b73e7f24a1c4 100644 --- a/drivers/scsi

[PATCH 3/3] wd719x: always use generic DMA API

2018-11-09 Thread Christoph Hellwig
The wd719x driver currently uses a mix of the legacy PCI DMA and the generic DMA APIs. Switch it over to the generic DMA API entirely. Signed-off-by: Christoph Hellwig --- drivers/scsi/wd719x.c | 32 +--- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git

[PATCH 1/3] wd719x: there should be no active SCBs on removal

2018-11-09 Thread Christoph Hellwig
So warn on that case instead of trying to free them, which would be fatal in case we actuall had active ones. Signed-off-by: Christoph Hellwig --- drivers/scsi/wd719x.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/wd719x.c b/drivers/scsi/wd719x.c index

dma related cleanups for wd719x v2

2018-11-09 Thread Christoph Hellwig
Various dma relates cleanups Changes since v1: - include important fixes from Ondrej

[PATCH] aha1542: convert to DMA mapping API

2018-11-09 Thread Christoph Hellwig
aha1542 is one of the last users of the legacy isa_*_to_bus APIs, which also isn't portable enough. Convert it to the proper DMA mapping API. Thanks to Ondrej Zary for testing and finding and fixing a crucial bug. Signed-off-by: Christoph Hellwig Tested-by: Ondrej Zary --- drivers/scsi

Re: [PATCH 5/5] qla2xxx: use lower_32_bits and upper_32_bits instead of reinventing them

2018-10-26 Thread Christoph Hellwig
On Thu, Oct 18, 2018 at 09:43:25PM -0700, Bart Van Assche wrote: > Hi Christoph, > > Have you considered to use put_unaligned_le64() instead of storing the > lower and upper 32 bits separately? I really don't want to touch this old driver all that much, just get rid of the buggy existing

Submit Proposals to the 2019 Linux Storage and Filesystems Conference!

2018-10-25 Thread Christoph Hellwig
, and submission instructions. View the Vault '19 Call for Participation: https://www.usenix.org/conference/vault19/call-for-participation We look forward to receiving your proposals! Christoph Hellwig Erik Riedel Ric Wheeler, Red Hat vault19cha...@usenix.org

Re: [PATCH] bsg: convert to use blk-mq

2018-10-24 Thread Christoph Hellwig
On Mon, Oct 22, 2018 at 03:23:30AM -0600, Jens Axboe wrote: > JFYI, I also reordered the series to make it correct. You can apply > this one: > > http://git.kernel.dk/cgit/linux-block/commit/?h=mq-conversions=2b2ffa16193e9a69a076595ed64429b8cc9b42aa > > before the bsg patch, and it should be

use dma_set_mask and dma_set_mask_and_coherent

2018-10-18 Thread Christoph Hellwig
Various SCSI drivers that otherwise use the generic DMA API still use pci_set_dma_mask, so switch them over to dma_set_mask and dma_set_mask_and_coherent.

[PATCH 03/12] dpt_i2o: use dma_set_mask

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Also move the dma_get_required_mask check before actually setting the dma mask, so that we don't end up with inconsistent settings in corner cases. Signed-off-by: Christoph Hellwig --- drivers/scsi

[PATCH 12/12] sym53c8xx: use dma_set_mask

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Signed-off-by: Christoph Hellwig --- drivers/scsi/sym53c8xx_2/sym_glue.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/sym53c8xx_2/sym_glue.c b/drivers/scsi

[PATCH 01/12] arcmsr: use dma_set_mask

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Signed-off-by: Christoph Hellwig --- drivers/scsi/arcmsr/arcmsr_hba.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/scsi/arcmsr/arcmsr_hba.c b/drivers/scsi/arcmsr

[PATCH 02/12] bfa: use dma_set_mask_and_coherent

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Switch it over to the better generic DMA API helper and also ensure we set the coherent mask as well in the resume path. Signed-off-by: Christoph Hellwig --- drivers/scsi/bfa/bfad.c | 18

[PATCH 11/12] stex: use dma_set_mask_and_coherent

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Switch it over to the better generic DMA API. Signed-off-by: Christoph Hellwig --- drivers/scsi/stex.c | 17 +++-- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/drivers/scsi

[PATCH 10/12] mvumi: use dma_set_mask

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Signed-off-by: Christoph Hellwig --- drivers/scsi/mvumi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/mvumi.c b/drivers/scsi/mvumi.c index 2458974d1af6..3d2d026d1ccf

[PATCH 05/12] hisi_sas: use dma_set_mask_and_coherent

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Switch it over to the better generic DMA API. Signed-off-by: Christoph Hellwig --- drivers/scsi/hisi_sas/hisi_sas_v3_hw.c | 13 + 1 file changed, 5 insertions(+), 8 deletions(-) diff --git

[PATCH 08/12] iscsi: use dma_set_mask_and_coherent

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Switch it over to the better generic DMA API. Signed-off-by: Christoph Hellwig --- drivers/scsi/isci/init.c | 19 --- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git a/drivers

[PATCH 06/12] hptiop: use dma_set_mask

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Signed-off-by: Christoph Hellwig --- drivers/scsi/hptiop.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/scsi/hptiop.c b/drivers/scsi/hptiop.c index 2fad7f03aa02

[PATCH 04/12] esas2r: use dma_set_mask_and_coherent

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Also move the dma_get_required_mask check before actually setting the dma mask, so that we don't end up with inconsistent settings in corner cases. Signed-off-by: Christoph Hellwig --- drivers/scsi/esas2r

[PATCH 09/12] lpfc: use dma_set_mask_and_coherent

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Switch it over to the better generic DMA API. Signed-off-by: Christoph Hellwig --- drivers/scsi/lpfc/lpfc_init.c | 34 ++ 1 file changed, 10 insertions(+), 24 deletions

[PATCH 07/12] initio: use dma_set_mask

2018-10-18 Thread Christoph Hellwig
The driver currently uses pci_set_dma_mask despite otherwise using the generic DMA API. Signed-off-by: Christoph Hellwig --- drivers/scsi/initio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/scsi/initio.c b/drivers/scsi/initio.c index 7a91cf3ff173..0a8d786c84ed

[PATCH 3/4] gdth: remove gdth_{alloc,free}_ioctl

2018-10-18 Thread Christoph Hellwig
under a spinlock with irqs disabled. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth.c | 7 ++-- drivers/scsi/gdth_proc.c | 71 drivers/scsi/gdth_proc.h | 3 -- 3 files changed, 25 insertions(+), 56 deletions(-) diff --git a/drivers/scsi

[PATCH 4/4] gdth: use generic DMA API

2018-10-18 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Also switch to dma_map_single from pci_map_page in one case where this makes the code simpler. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth.c | 111 +++ drivers/scsi/gdth_proc.c | 4

[PATCH 1/4] gdth: refactor ioc_general

2018-10-18 Thread Christoph Hellwig
This function is a huge mess with duplicated error handling. Split out a few useful helpers and use goto labels to untangle the error handling and no-data ioctl handling. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth.c | 247 +++- 1 file changed

dma related cleanups for gdth

2018-10-18 Thread Christoph Hellwig
Cleans up various oddities found during a code audit.

[PATCH 2/4] gdth: reuse dma coherent allocation in gdth_show_info

2018-10-18 Thread Christoph Hellwig
gdth_show_info currently allocs and frees a dma buffer four times, which isn't very efficient. Reuse a single allocation instead. Signed-off-by: Christoph Hellwig --- drivers/scsi/gdth_proc.c | 18 +- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/drivers/scsi

dma related cleanups for pmcraid

2018-10-18 Thread Christoph Hellwig
Cleans up various oddities found during a code audit.

[PATCH 3/3] pmcraid: use generic DMA API

2018-10-18 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig --- drivers/scsi/pmcraid.c | 79 +++--- 1 file changed, 36 insertions(+), 43 deletions(-) diff --git a/drivers/scsi/pmcraid.c b/drivers/scsi/pmcraid.c index

[PATCH 1/3] pmcraid: simplify pmcraid_cancel_all a bit

2018-10-18 Thread Christoph Hellwig
No need for a local cmd_done variable, and pass boolean values as bool type instead of u32. Signed-off-by: Christoph Hellwig --- drivers/scsi/pmcraid.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/drivers/scsi/pmcraid.c b/drivers/scsi/pmcraid.c index

[PATCH 2/3] pmcraid: don't allocate a dma coherent buffer for sense data

2018-10-18 Thread Christoph Hellwig
We can just dma map the sense buffer passed with the scsi command, and that gets us out of the nasty business of doing dma coherent allocations from irq context. Signed-off-by: Christoph Hellwig --- drivers/scsi/pmcraid.c | 24 1 file changed, 8 insertions(+), 16

[PATCH 5/5] qla2xxx: use lower_32_bits and upper_32_bits instead of reinventing them

2018-10-18 Thread Christoph Hellwig
This also moves the optimization for builds with 32-bit dma_addr_t to the compiler (where it belongs) instead of opencoding it based on incorrect assumptions. Signed-off-by: Christoph Hellwig --- drivers/scsi/qla2xxx/qla_target.c | 8 drivers/scsi/qla2xxx/qla_target.h | 8 2

[PATCH 4/5] qla1280: properly handle 64-bit DMA

2018-10-18 Thread Christoph Hellwig
CONFIG_HIGHMEM is not in fact an indicator for > 32-bit dma addressing Given that the driver is a bit weird and wants a compile time selection switch to checking CONFIG_ARCH_DMA_ADDR_T_64BIT instead. Signed-off-by: Christoph Hellwig --- drivers/scsi/qla1280.c | 5 + 1 file changed

fix up a few drivers for 64-bit dma addresses

2018-10-18 Thread Christoph Hellwig
Some drivers make very odd decisions on when to use support for 64-bit addressing. Fix this up a bit.

[PATCH 2/5] ips: properly handle 64-bit DMA

2018-10-18 Thread Christoph Hellwig
CONFIG_HIGHMEM64 is only one (and these days unusual) way to indicate that > 32-bit dma address are possible. Replace it with a check of the dma_addr_t size. Signed-off-by: Christoph Hellwig --- drivers/scsi/ips.c | 2 +- drivers/scsi/ips.h | 6 -- 2 files changed, 1 insertion(+)

[PATCH 1/5] ips: use lower_32_bits and upper_32_bits instead of reinventing them

2018-10-18 Thread Christoph Hellwig
Signed-off-by: Christoph Hellwig --- drivers/scsi/ips.c | 6 +++--- drivers/scsi/ips.h | 3 --- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/drivers/scsi/ips.c b/drivers/scsi/ips.c index ee8a1ecd58fd..679321e96a86 100644 --- a/drivers/scsi/ips.c +++ b/drivers/scsi/ips.c

[PATCH 3/5] qla1280: use lower_32_bits and upper_32_bits instead of reinventing them

2018-10-18 Thread Christoph Hellwig
This also moves the optimization for builds with 32-bit dma_addr_t to the compiler (where it belongs) instead of opencoding it. Signed-off-by: Christoph Hellwig --- drivers/scsi/qla1280.c | 47 ++ 1 file changed, 20 insertions(+), 27 deletions(-) diff

[PATCH 2/3] wd719x: use per-command private data

2018-10-18 Thread Christoph Hellwig
Add the SCB onto the scsi command allocation and use dma streaming mappings for it only when in use. This avoid possibly calling dma_alloc_coherent under a lock or even in irq context, while also making the code simpler. Signed-off-by: Christoph Hellwig --- drivers/scsi/wd719x.c | 95

[PATCH 3/3] wd719x: always use generic DMA API

2018-10-18 Thread Christoph Hellwig
The wd719x driver currently uses a mix of the legacy PCI DMA and the generic DMA APIs. Switch it over to the generic DMA API entirely. Signed-off-by: Christoph Hellwig --- drivers/scsi/wd719x.c | 32 +--- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git

[PATCH 1/3] wd719x: there should be no active SCBs on removal

2018-10-18 Thread Christoph Hellwig
So warn on that case instead of trying to free them, which would be fatal in case we actuall had active ones. Signed-off-by: Christoph Hellwig --- drivers/scsi/wd719x.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/wd719x.c b/drivers/scsi/wd719x.c index

dma related cleanups for wd719x

2018-10-18 Thread Christoph Hellwig
Hi Ondrej, can you look over this series, which cleans up a few dma-related bits in the wd719x driver?

Re: aacraid: latest driver results in Host adapter abort request. / Outstanding commands on (0,0,0,0):

2018-10-17 Thread Christoph Hellwig
On Tue, Oct 16, 2018 at 07:33:53PM +0200, Stefan Priebe - Profihost AG wrote: > Hi David, > > can you give as any hint? We're running aroud 120 Adaptec Controllers > and i don't want to replace them all... 4.15 had a fair amount of aacraid changes. You can't bisect them by any chance?

Re: [PATCH] ib_srp: Remove WARN_ON in srp_terminate_io()

2018-10-17 Thread Christoph Hellwig
> diff --git a/drivers/nvme/host/fc.c b/drivers/nvme/host/fc.c > index e52b9d3c0bd6..c777b36ba62a 100644 > --- a/drivers/nvme/host/fc.c > +++ b/drivers/nvme/host/fc.c > @@ -483,6 +483,8 @@ nvme_fc_signal_discovery_scan(struct nvme_fc_lport *lport, > char hostaddr[FCNVME_TRADDR_LENGTH];/*

[PATCH 21/28] qla1280: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/qla1280.c | 26 +- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/drivers/scsi/qla1280.c b/drivers/scsi/qla1280

[PATCH 24/28] snic: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/snic/snic_disc.c | 7 --- drivers/scsi/snic/snic_io.c | 25 + drivers/scsi/snic/snic_main.c | 24

[PATCH 26/28] smartpqi: fully convert to the generic DMA API

2018-10-14 Thread Christoph Hellwig
The driver is currently using an odd mix of legacy PCI DMA API and generic DMA API calls, switch it over to the generic API entirely. Signed-off-by: Christoph Hellwig Tested-by: Don Brace Acked-by: Don Brace Reviewed-by: Johannes Thumshirn --- drivers/scsi/smartpqi/smartpqi_init.c | 100

[PATCH 28/28] mesh: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/mesh.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/scsi/mesh.c b/drivers/scsi/mesh.c index 82e01dbe90af

[PATCH 27/28] ips: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/ips.c | 80 -- 1 file changed, 41 insertions(+), 39 deletions(-) diff --git a/drivers/scsi/ips.c b/drivers

[PATCH 23/28] qla4xxx: fully convert to the generic DMA API

2018-10-14 Thread Christoph Hellwig
The driver is currently using an odd mix of legacy PCI DMA API and generic DMA API calls, switch it over to the generic API entirely. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/qla4xxx/ql4_os.c | 25 - 1 file changed, 8 insertions

[PATCH 22/28] qla2xxx: fully convert to the generic DMA API

2018-10-14 Thread Christoph Hellwig
The driver is currently using an odd mix of legacy PCI DMA API and generic DMA API calls, switch it over to the generic API entirely. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/qla2xxx/qla_target.c | 8 drivers/scsi/qla2xxx/tcm_qla2xxx.c | 2

[PATCH 25/28] vmw_pscsi: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/vmw_pvscsi.c | 77 +++ 1 file changed, 38 insertions(+), 39 deletions(-) diff --git a/drivers/scsi/vmw_pvscsi.c b

[PATCH 08/28] be2iscsi: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/be2iscsi/be_cmds.c | 10 ++--- drivers/scsi/be2iscsi/be_iscsi.c | 13 +++--- drivers/scsi/be2iscsi/be_main.c | 72

[PATCH 17/28] nsp32: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/nsp32.c | 18 ++ 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/drivers/scsi/nsp32.c b/drivers/scsi/nsp32.c index

[PATCH 12/28] megaraid_mbox: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/megaraid/megaraid_mbox.c | 51 +-- 1 file changed, 25 insertions(+), 26 deletions(-) diff --git a/drivers/scsi/megaraid

[PATCH 13/28] megaraid_sas: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/megaraid/megaraid_sas_base.c | 150 ++-- drivers/scsi/megaraid/megaraid_sas_fusion.c | 16 +-- 2 files changed, 83 insertions(+), 83

[PATCH 14/28] mpt3sas: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Also simplify setting the DMA mask a bit. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/mpt3sas/mpt3sas_base.c | 67 drivers/scsi/mpt3sas/mpt3sas_ctl.c | 34

[PATCH 19/28] qedf: fully convert to the generic DMA API

2018-10-14 Thread Christoph Hellwig
The driver is currently using an odd mix of legacy PCI DMA API and generic DMA API calls, switch it over to the generic API entirely. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/qedf/qedf_main.c | 8 1 file changed, 4 insertions(+), 4 deletions

[PATCH 09/28] csiostor: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/csiostor/csio_init.c | 7 ++- drivers/scsi/csiostor/csio_lnode.c | 6 +++--- drivers/scsi/csiostor/csio_scsi.c | 12 ++-- drivers/scsi

[PATCH 11/28] hpsa: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Tested-by: Don Brace Acked-by: Don Brace Reviewed-by: Johannes Thumshirn --- drivers/scsi/hpsa.c | 136 ++-- 1 file changed, 69 insertions(+), 67 deletions

[PATCH 03/28] 3w-xxx: fully convert to the generic DMA API

2018-10-14 Thread Christoph Hellwig
The driver is currently using an odd mix of legacy PCI DMA API and generic DMA API calls, switch it over to the generic API entirely. Signed-off-by: Christoph Hellwig Acked-by: Adam Radford Reviewed-by: Johannes Thumshirn --- drivers/scsi/3w-.c | 20 ++-- drivers/scsi/3w

[PATCH 07/28] atp870u: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/atp870u.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/atp870u.c b/drivers/scsi/atp870u.c index 8996d2329e11

[PATCH 01/28] aic94xx: fully convert to the generic DMA API

2018-10-14 Thread Christoph Hellwig
The driver is currently using an odd mix of legacy PCI DMA API and generic DMA API calls, switch it over to the generic API entirely. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/aic94xx/aic94xx_init.c | 9 ++ drivers/scsi/aic94xx/aic94xx_task.c | 46

[PATCH 04/28] 3w-sas: fully convert to the generic DMA API

2018-10-14 Thread Christoph Hellwig
The driver is currently using an odd mix of legacy PCI DMA API and generic DMA API calls, switch it over to the generic API entirely. Signed-off-by: Christoph Hellwig Acked-by: Adam Radford Reviewed-by: Johannes Thumshirn --- drivers/scsi/3w-sas.c | 38

[PATCH 06/28] a100u2w: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/a100u2w.c | 20 +--- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/drivers/scsi/a100u2w.c b/drivers/scsi/a100u2w.c index

[PATCH 18/28] pm8001: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn Reviewed-by: Jack Wang --- drivers/scsi/pm8001/pm8001_hwi.c | 22 +++--- drivers/scsi/pm8001/pm8001_init.c | 28 +--- drivers

[PATCH 05/28] BusLogic: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/BusLogic.c | 36 +++- 1 file changed, 19 insertions(+), 17 deletions(-) diff --git a/drivers/scsi/BusLogic.c b/drivers

[PATCH 15/28] mvumi: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Also reuse an existing helper (after fixing the error return) to set the DMA mask instead of having three copies of the code. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/mvumi.c | 89

[PATCH 02/28] 3w-9xxx: fully convert to the generic DMA API

2018-10-14 Thread Christoph Hellwig
The driver is currently using an odd mix of legacy PCI DMA API and generic DMA API calls, switch it over to the generic API entirely. Signed-off-by: Christoph Hellwig Acked-by: Adam Radford Reviewed-by: Johannes Thumshirn --- drivers/scsi/3w-9xxx.c | 50

[PATCH 16/28] mvsas: fully convert to the generic DMA API

2018-10-14 Thread Christoph Hellwig
The driver is currently using an odd mix of legacy PCI DMA API and generic DMA API calls, switch it over to the generic API entirely. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/mvsas/mv_init.c | 21 +++-- drivers/scsi/mvsas/mv_sas.c | 12

[PATCH 10/28] fnic: switch to generic DMA API

2018-10-14 Thread Christoph Hellwig
Switch from the legacy PCI DMA API to the generic DMA API. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/fnic/fnic_fcs.c | 41 +++ drivers/scsi/fnic/fnic_main.c | 19 ++-- drivers/scsi/fnic/fnic_scsi.c | 38

[PATCH 20/28] qedi: fully convert to the generic DMA API

2018-10-14 Thread Christoph Hellwig
The driver is currently using an odd mix of legacy PCI DMA API and generic DMA API calls, switch it over to the generic API entirely. Signed-off-by: Christoph Hellwig Reviewed-by: Johannes Thumshirn --- drivers/scsi/qedi/qedi_main.c | 8 1 file changed, 4 insertions(+), 4 deletions

switch most scsi drivers to the generic DMA API v2

2018-10-14 Thread Christoph Hellwig
A lot of SCSI drivers still use the legacy PCI DMA API. While a few of them have various oddities that should be deal with separately, most of them can be very trivially converted over. Two interesting things to look out for: - pci_(z)alloc_consistent forced GFP_ATOMIC allocations, which is a

Re: [PATCH 02/19] megaraid_sas: Add support for FW snap dump

2018-10-14 Thread Christoph Hellwig
> + > + instance->snapdump_prop = > + pci_alloc_consistent(pdev, > + sizeof(struct > MR_SNAPDUMP_PROPERTIES), > + >snapdump_prop_h); No new calls to the PCI DMA API please. Please

  1   2   3   4   5   6   7   8   9   10   >