RE: Adding IO engine

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

 



The concept of "file" can represent a special device and driver unknown to the system, and get_file_size() and/or setup() are usually the first APIs that fio should call where the device will be initialized and set its max size so that fio can know the device "file" capacity.  Such device has to be initialized prior to IO (DMA) buffer allocation/free that is specific only to that device.   There isn't any other fio plugin APIs that precede iomem_alloc, and I think iomem_alloc/free were added specifically to support that special device.

How is that a misconception?


-----Original Message-----
From: fio-owner@xxxxxxxxxxxxxxx [mailto:fio-owner@xxxxxxxxxxxxxxx] On Behalf Of Andrey Kuzmin
Sent: Monday, April 10, 2017 12:44 PM
To: Deyoung Hong (dhong) <dhong@xxxxxxxxxx>
Cc: fio@xxxxxxxxxxxxxxx
Subject: Re: Adding IO engine

On Mon, Apr 10, 2017 at 8:45 PM, Deyoung Hong (dhong) <dhong@xxxxxxxxxx> wrote:
> Hi Jens,
>
> I have a couple basic questions:
>
> 1)  If I want to submit a new IO engine with fio and it has a dependency on an external library, how does that work when fio is compiled?  Please also point me to info how to submit a new IO engine to be packaged with fio?
>
> 2)  I've seen cases where the ->iomem_alloc() function (i.e. for a custom IO engine) is invoked first by fio before ->get_file_size() or ->setup().  This causes an issue since IO memory allocation can have dependency on certain initialization (for the custom IO engine) that is done in ->get_file_size().   I just wonder if that's an fio bug or how it should be?

It sounds more like a misconception re iomem_{alloc,free} API. It is
about buffers I/O goes to/from, not files. As an example (and the root
cause behind the API proposal), I wanted to be able to allocate
buffers in DMAable memory as my engine required that to interact with
hardware directly.

Being unrelated to files by design, buffer initialization occurs way
before file setup as it did in fio before iomem_* API was introduced.

Regards,
Andrey



>   My current work around is to check in ->iomem_alloc() each time and do initializion first if has not.
>
> Thanks,
> Deyoung
>
> --
> To unsubscribe from this list: send the line "unsubscribe fio" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe fio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html
��.n��������+%������w��{.n�������^n�r������&��z�ޗ�zf���h���~����������_��+v���)ߣ�

[Index of Archives]     [Linux Kernel]     [Linux SCSI]     [Linux IDE]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux