All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] direct IO: respect backing device max IO size
@ 2018-07-28 19:17 stockhausen
  2018-07-28 22:22 ` Jens Axboe
  0 siblings, 1 reply; 3+ messages in thread
From: stockhausen @ 2018-07-28 19:17 UTC (permalink / raw)
  To: linux-block

[-- Attachment #1: Type: text/plain, Size: 1225 bytes --]

Running older FusionIO cards with newer linux kernels turns out to be
a headache. First of all their driver is a mix of open sources and
proprietary object parts. Second we get only support for kernels up
to ~4.0. Trying to get this to work with 4.9 longterm was successful
but 4.14 renders the driver totally useless.

Searching the reason for lost data it turned out that the driver has 
a hard 1024K or 257 page IO limit and silently drops any request that 
is too large. Of course this might be a driver only problem but at 
least it discloses the real source of a bad chain reaction.

blkdev_direct_IO() sets the maximum allowed IO size to BIO_MAX_PAGES.
With 225311a4 ("mm: test code to write THP to swap device as a whole")
its value changed from 256 to 512. Indepedant of its value the choice
is arbitrary and can be driver agnostic as long as breakdown of bios
happens later on.

We already have sufficent info about backing device properties and 
can packetize the IO into sane values to avoid hassle later on. If
bdi->io_pages is set and lower than BIO_MAX_PAGES reduce the package
size appropriately.

Ths patch consists of two parts. The first is only a cosmetic change
to avoid double coding in the second one.

[-- Attachment #2: InterScan_Disclaimer.txt --]
[-- Type: text/plain, Size: 1608 bytes --]

****************************************************************************
Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte
Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail
irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und
vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte
Weitergabe dieser Mail ist nicht gestattet.

Über das Internet versandte E-Mails können unter fremden Namen erstellt oder
manipuliert werden. Deshalb ist diese als E-Mail verschickte Nachricht keine
rechtsverbindliche Willenserklärung.

Collogia AG
Ubierring 11
D-50678 Köln

Vorstand:
Kadir Akin
Dr. Michael Höhnerbach

Vorsitzender des Aufsichtsrates:
Hans Kristian Langva

Registergericht: Amtsgericht Köln
Registernummer: HRB 52 497

This e-mail may contain confidential and/or privileged information. If you
are not the intended recipient (or have received this e-mail in error)
please notify the sender immediately and destroy this e-mail. Any
unauthorized copying, disclosure or distribution of the material in this
e-mail is strictly forbidden.

e-mails sent over the internet may have been written under a wrong name or
been manipulated. That is why this message sent as an e-mail is not a
legally binding declaration of intention.

Collogia AG
Ubierring 11
D-50678 Köln

executive board:
Kadir Akin
Dr. Michael Höhnerbach

President of the supervisory board:
Hans Kristian Langva

Registry office: district court Cologne
Register number: HRB 52 497

****************************************************************************

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

* Re: [PATCH 0/2] direct IO: respect backing device max IO size
  2018-07-28 19:17 [PATCH 0/2] direct IO: respect backing device max IO size stockhausen
@ 2018-07-28 22:22 ` Jens Axboe
  2018-07-28 22:31   ` AW: " Markus Stockhausen
  0 siblings, 1 reply; 3+ messages in thread
From: Jens Axboe @ 2018-07-28 22:22 UTC (permalink / raw)
  To: stockhausen, linux-block

On 7/28/18 1:17 PM, stockhausen@collogia.de wrote:
> Running older FusionIO cards with newer linux kernels turns out to be
> a headache. First of all their driver is a mix of open sources and
> proprietary object parts. Second we get only support for kernels up
> to ~4.0. Trying to get this to work with 4.9 longterm was successful
> but 4.14 renders the driver totally useless.
> 
> Searching the reason for lost data it turned out that the driver has 
> a hard 1024K or 257 page IO limit and silently drops any request that 
> is too large. Of course this might be a driver only problem but at 
> least it discloses the real source of a bad chain reaction.
> 
> blkdev_direct_IO() sets the maximum allowed IO size to BIO_MAX_PAGES.
> With 225311a4 ("mm: test code to write THP to swap device as a whole")
> its value changed from 256 to 512. Indepedant of its value the choice
> is arbitrary and can be driver agnostic as long as breakdown of bios
> happens later on.
> 
> We already have sufficent info about backing device properties and 
> can packetize the IO into sane values to avoid hassle later on. If
> bdi->io_pages is set and lower than BIO_MAX_PAGES reduce the package
> size appropriately.
> 
> Ths patch consists of two parts. The first is only a cosmetic change
> to avoid double coding in the second one.

Sounds to me like the fusion driver isn't calling split like it is
supposed to. That's what you get when it's unmaintained for years.
Add a:

	blk_queue_split(queue, &bio);

to kblock.c:kfio_make_request() and see if that helps.

-- 
Jens Axboe

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

* AW: [PATCH 0/2] direct IO: respect backing device max IO size
  2018-07-28 22:22 ` Jens Axboe
@ 2018-07-28 22:31   ` Markus Stockhausen
  0 siblings, 0 replies; 3+ messages in thread
From: Markus Stockhausen @ 2018-07-28 22:31 UTC (permalink / raw)
  To: Jens Axboe, linux-block

[-- Attachment #1: Type: text/plain, Size: 2065 bytes --]

> Von: Jens Axboe [axboe@kernel.dk]
> Gesendet: Sonntag, 29. Juli 2018 00:22
> An: Markus Stockhausen; linux-block@vger.kernel.org
> Betreff: Re: [PATCH 0/2] direct IO: respect backing device max IO size
> 
> On 7/28/18 1:17 PM, stockhausen@collogia.de wrote:
> > Running older FusionIO cards with newer linux kernels turns out to be
> > a headache. First of all their driver is a mix of open sources and
> > proprietary object parts. Second we get only support for kernels up
> > to ~4.0. Trying to get this to work with 4.9 longterm was successful
> > but 4.14 renders the driver totally useless.
> >
> > Searching the reason for lost data it turned out that the driver has
> > a hard 1024K or 257 page IO limit and silently drops any request that
> > is too large. Of course this might be a driver only problem but at
> > least it discloses the real source of a bad chain reaction.
> >
> > blkdev_direct_IO() sets the maximum allowed IO size to BIO_MAX_PAGES.
> > With 225311a4 ("mm: test code to write THP to swap device as a whole")
> > its value changed from 256 to 512. Indepedant of its value the choice
> > is arbitrary and can be driver agnostic as long as breakdown of bios
> > happens later on.
> >
> > We already have sufficent info about backing device properties and
> > can packetize the IO into sane values to avoid hassle later on. If
> > bdi->io_pages is set and lower than BIO_MAX_PAGES reduce the package
> > size appropriately.
> >
> > Ths patch consists of two parts. The first is only a cosmetic change
> > to avoid double coding in the second one.
> 
> Sounds to me like the fusion driver isn't calling split like it is
> supposed to. That's what you get when it's unmaintained for years.
> Add a:
> 
>         blk_queue_split(queue, &bio);
> 
> to kblock.c:kfio_make_request() and see if that helps.
> --
> Jens Axboe

I guess You know the driver and got my only by a few minutes.
Was just comparing iomemory 3.2.x with 4.3.x. And tadaaa: New
driver has a split.

Thanks a lot.

Markus


=

[-- Attachment #2: InterScan_Disclaimer.txt --]
[-- Type: text/plain, Size: 1608 bytes --]

****************************************************************************
Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte
Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail
irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und
vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte
Weitergabe dieser Mail ist nicht gestattet.

Über das Internet versandte E-Mails können unter fremden Namen erstellt oder
manipuliert werden. Deshalb ist diese als E-Mail verschickte Nachricht keine
rechtsverbindliche Willenserklärung.

Collogia AG
Ubierring 11
D-50678 Köln

Vorstand:
Kadir Akin
Dr. Michael Höhnerbach

Vorsitzender des Aufsichtsrates:
Hans Kristian Langva

Registergericht: Amtsgericht Köln
Registernummer: HRB 52 497

This e-mail may contain confidential and/or privileged information. If you
are not the intended recipient (or have received this e-mail in error)
please notify the sender immediately and destroy this e-mail. Any
unauthorized copying, disclosure or distribution of the material in this
e-mail is strictly forbidden.

e-mails sent over the internet may have been written under a wrong name or
been manipulated. That is why this message sent as an e-mail is not a
legally binding declaration of intention.

Collogia AG
Ubierring 11
D-50678 Köln

executive board:
Kadir Akin
Dr. Michael Höhnerbach

President of the supervisory board:
Hans Kristian Langva

Registry office: district court Cologne
Register number: HRB 52 497

****************************************************************************

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

end of thread, other threads:[~2018-07-28 23:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-28 19:17 [PATCH 0/2] direct IO: respect backing device max IO size stockhausen
2018-07-28 22:22 ` Jens Axboe
2018-07-28 22:31   ` AW: " Markus Stockhausen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.