Changeset 8cb2882 in rtems


Ignore:
Timestamp:
Oct 31, 2013, 2:00:20 PM (6 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, master
Children:
7eb6444d
Parents:
16829460
git-author:
Sebastian Huber <sebastian.huber@…> (10/31/13 14:00:20)
git-committer:
Sebastian Huber <sebastian.huber@…> (11/04/13 14:22:48)
Message:

Filesystem: Add kernel event filter handler

This handler is necessary to implement the KQUEUE(2) system calls.

Add <sys/event.h> from FreeBSD 8.4.

Location:
cpukit
Files:
2 added
4 edited

Legend:

Unmodified
Added
Removed
  • cpukit/Makefile.am

    r16829460 r8cb2882  
    5151
    5252include_sys_HEADERS += libcsupport/include/sys/ioccom.h
     53include_sys_HEADERS += libcsupport/include/sys/event.h
    5354include_sys_HEADERS += libcsupport/include/sys/filio.h
    5455include_sys_HEADERS += libcsupport/include/sys/ioctl.h
  • cpukit/libcsupport/include/rtems/libio.h

    r16829460 r8cb2882  
    4141extern "C" {
    4242#endif
     43
     44struct knote;
    4345
    4446/**
     
    959961
    960962/**
     963 * @brief Kernel event filter support.
     964 *
     965 * @param[in, out] iop The IO pointer.
     966 * @param[in] kn The kernel event note.
     967 *
     968 * @retval 0 Successful operation.
     969 * @retval error An error occurred.  This is usually EINVAL.
     970 *
     971 * @see rtems_filesystem_default_kqfilter().
     972 */
     973typedef int (*rtems_filesystem_kqfilter_t)(
     974  rtems_libio_t *iop,
     975  struct knote *kn
     976);
     977
     978/**
    961979 * @brief File system node operations table.
    962980 */
     
    974992  rtems_filesystem_fcntl_t fcntl_h;
    975993  rtems_filesystem_poll_t poll_h;
     994  rtems_filesystem_kqfilter_t kqfilter_h;
    976995};
    977996
     
    11571176  rtems_libio_t *iop,
    11581177  int events
     1178);
     1179
     1180/**
     1181 * @brief Default kernel event filter handler.
     1182 *
     1183 * @retval EINVAL Always.
     1184 *
     1185 * @see rtems_filesystem_kqfilter_t.
     1186 */
     1187int rtems_filesystem_default_kqfilter(
     1188  rtems_libio_t *iop,
     1189  struct knote *kn
    11591190);
    11601191
  • cpukit/libfs/Makefile.am

    r16829460 r8cb2882  
    3434    src/defaults/default_ftruncate_directory.c \
    3535    src/defaults/default_handlers.c src/defaults/default_ops.c
     36libdefaultfs_a_SOURCES += src/defaults/default_kqfilter.c
    3637libdefaultfs_a_SOURCES += src/defaults/default_poll.c
    3738
  • cpukit/preinstall.am

    r16829460 r8cb2882  
    6969PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/ioccom.h
    7070
     71$(PROJECT_INCLUDE)/sys/event.h: libcsupport/include/sys/event.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
     72        $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/event.h
     73PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/event.h
     74
    7175$(PROJECT_INCLUDE)/sys/filio.h: libcsupport/include/sys/filio.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
    7276        $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/filio.h
Note: See TracChangeset for help on using the changeset viewer.