GVM User Suite
User tools for the GVM open source project.
|
#include <utils/device.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/stat.h>
#include <unistd.h>
Go to the source code of this file.
Functions | |
uint8_t | device_exists (const char *device_name) |
Does a device file exist? More... | |
int32_t | get_major (const char *device) |
Gets the device major id from /proc/devices. More... | |
int32_t | get_param (const char *filename, const char *parameter) |
Gets a parameter from a driver param file. More... | |
uint8_t device_exists | ( | const char * | device_name | ) |
Does a device file exist?
Definition at line 30 of file device.c.
int32_t get_major | ( | const char * | device | ) |
Gets the device major id from /proc/devices.
Invalid Device - In the case of an invalid device being passed it will return -1.
Device List Not Found - Device list is not found, this can occur on unsupported operating systems.
Definition at line 42 of file device.c.
int32_t get_param | ( | const char * | filename, |
const char * | parameter | ||
) |
Gets a parameter from a driver param file.
Definition at line 71 of file device.c.