Victor (and others):

I have completed my proposed patch to add some additional functionality to
rtf's with respect to querying their sizes/fills.  Attached is the patch
.tar.gz (along with a readme).  If this mailing list filters out
attachments, you can also download the patch at:

http://www.rtlab.org/patches/rtlinux-3.1_rtf_sizes_patch.tar.gz


Patch Synopsis:

RTF Get Sizes/Free/et al patch.. for the released version of rt-linux v3.1


RT-Linux Version:

rtlinux-3.1 (as distrubuted to the commmunity at large)


Author:

Calin A. Culianu ([EMAIL PROTECTED])


Description:

This patch is a proof of concept/feature request for the rt-linux team at
fsmlabs.  I (and maybe some other people?) thought it would be useful if
an RTF were queryable from the kernel/userland with respect to buffer
size, current length, and bytes free.  As such, three functions, two
ioctls, and 1 configure option were added.

Files modified were:

scripts/config.in   -- added the configure option
CONFIG_RTF_EXTRA_QUERYABLE
doc/Configure.helpa -- added a description of the above option
include/rtl_fifo.h  -- added function prototypes and some IOCTL constants
fifos/rtl_fifo.c    -- added 3 functions: rtf_free(), rtf_bufsize(), and
                       rtf_length().  Also added two ioctls in the
                       rtf_ioctl() function (IOCTL_RTF_GET_BUFSIZE and
                       IOCTL_RTF_GET_FREE).

The code I added is small and reasonably well commented.  I tried to
stick to the style of the existing code.  I have tested this functionality
both from userland and kernel space and everything should be fine.  I
also wrote the 3 functions to be SMP-safe (via judicious use of spin
locks).
This is also in conformance with existing code.

Please let me know if the patch is accepted, and thank you for your time!

-Calin

Patch rtlinux v3.1 to support some additional rtf funcs

Reply via email to