[PATCH 0/2] bsg: ring buffer interface

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

 



This patchset adds a generic ring buffer interface and converts bsg to
use it.

The scsi target infrastructure invented its own mmap ring buffer
interface. It seems that kevent would use a slightly different ring
buffer interface. I think it would be nice to have common ring buffer
code rather than inventing another ring buffer interface for bsg.

I use a modified version of kevent's user interface
(sys_kevent_commit, sys_kevent_wait, etc). So we can send and receive
sg_io_v4 structures to/from kernel via new system calls while kevent
only receives ukevent structures from kernel.

kevent dropped the mmap ring buffer at take 23. The current version
uses a ring buffer that isn't shared between kernel and user space
(kernel simply does copy_from_user/to_user from/to a ring buffer in
user space). This is mainly because the mmap ring buffer leads to lots
of unswappable memory (and processes can create it freely). I adopted
the current kevent scheme because we could have tons of bsg devices
(means lots of unswappable memory). sg_io_v4 structures are larger than 
ukevent structures so we need to see the performance.

The patchset is for discussion not for inclusion. I'd like to remove
the scsi target's ring buffer code but the generic ring buffer scheme
might be over-designed stuff. Simple ring buffer interfaces like
producer/consumer pointers might be good enough for the block layer
and scsi-ml stuff. Or we could duplicate various ring buffer code
since the code is small.

It's against Jens' bsg tree and it's only lightly tested.
-
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