libudev-enumerate.c revision bf7ad0ea662e747701cc66cdd1b33d22b6836cdf
/*
* libudev - interface to udev device information
*
* Copyright (C) 2008 Kay Sievers <kay.sievers@vrfy.org>
*
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
#include <dirent.h>
#include "libudev.h"
#include "libudev-private.h"
struct udev_enumerate {
int refcount;
struct list_head devices_list;
};
{
if (udev_enumerate == NULL)
return NULL;
return udev_enumerate;
}
{
if (udev_enumerate == NULL)
return;
if (udev_enumerate->refcount > 0)
return;
}
{
if (udev_enumerate == NULL)
return NULL;
}
struct list_head *device_list)
{
char path[UTIL_PATH_SIZE];
return -1;
char syspath[UTIL_PATH_SIZE];
continue;
}
return 0;
}
struct list_head *device_list)
{
char path[UTIL_PATH_SIZE];
return -1;
continue;
}
return 0;
}
{
static const char *delay_device_list[] = {
};
int i;
for (i = 0; delay_device_list[i] != NULL; i++) {
return 1;
}
}
return 0;
}
/**
* udev_enumerate_new_from_subsystems:
* @udev: udev library context
* @subsystem: the subsystem to enumerate
*
* Returns: an enumeration context
**/
{
struct udev_enumerate *udev_enumerate;
char base[UTIL_PATH_SIZE];
return NULL;
if (udev_enumerate == NULL)
return NULL;
} else {
}
/* sort delayed devices to the end of the list */
}
return udev_enumerate;
}