Questions tagged [ioctl]

ioctl (Input Output ConTroL) is a system call for device-specific I/O operations and other operations which cannot be expressed by regular system calls and it provides an interface through which an application can communicate directly with a device driver(or any other global kernel space variables). Applications can use the standard control codes or device-specific control codes to perform direct input and output operations.

691 questions
0
votes
1 answer

NDIS OID query from user mode

Writing NDIS 5.1 driver for WinXPe. In addition to normal NDIS send/receive functionality, driver also needs to make some discrete IO values available to user processes, presumably via a set of custom OIDs. Info on web indicates…
Frank Natoli
  • 153
  • 1
  • 1
  • 12
-1
votes
1 answer

ioctl() call list for iOS

Quickie: where (in which header files) can I find the declarations of the parameters of the ioctl() call on iOS? I've already looked at ioctl.h and the first-level includes it imports, but I'm not sure whether they're the only place to search…
anon
-1
votes
1 answer

ioctl() for socket programming in C

I am using ioctl() to read the number of characters in my buffer in a socket program. However at times, when populating of the buffer is delayed, it is misinterpreted by ioctl() as the end of the message. How can this be avoided if i were to use…
Manoj Kumar
  • 135
  • 1
  • 3
  • 13
-1
votes
1 answer

Oracle Datapump impdp Inappropriate ioctl for device

i had an error while exporting my schema and then import it into a new database. My Exporting System is an Oracle Linux 7 with 19c Database and the importing system is Oracle Linux 8 with 21c XE. When i import the schema with impdp i receive the…
Ivan1986
  • 19
  • 4
-1
votes
1 answer

Devices networking on C++

I have the need to access the network interfaces on my device. I have the below code that does that but I am missing the ones that are active but with no IP address associated to them. Any idea on how programmatically I could gather the information…
abdeldiaz
  • 11
  • 1
  • 4
-1
votes
2 answers

How can a volume exist on more than one physical disk?

Here they say that calling DeviceIoControl with IOCTL_VOLUME_GET_VOLUME_DISK_EXTENTS control code, "retrieves the physical location of a specified volume on one or more disks." But from my 25 years of using compuers I know that a physical disk can…
Marus Gradinaru
  • 2,824
  • 1
  • 26
  • 55
-1
votes
1 answer

One ioctl not being executed in kernel module

I wrote a kernel module demonstrating on how ioctl works. #include #include #include #include #include #include #include int…
md.jamal
  • 4,067
  • 8
  • 45
  • 108
-1
votes
1 answer

(Linux Style) Ioctl code, Hard to understand

I'm using infini** chip. In their Basic Code, every [XXX_ioctl].c code It has below code at upper parts. (XXX means the driver I want to use. ) typedef void (*PFUNCTION)(void); #define FUNCTION_COUNT 5 struct IoctlInterface { uint8_t count; …
-1
votes
1 answer

Call to ioctl() results in errno indicating "Bad address"

I'm getting the following error: wlan_config_vap_priv_int vap lan0 cmd cpauth val 0(0) error: Bad address Which is from the print in wlan_config_vap_priv_int. Does anyone know what might be causing the "Bad address" error? From why does ioctl…
Jobs
  • 3,317
  • 6
  • 26
  • 52
-1
votes
1 answer

How can I use ioctl with second parameter setting 0xFACE to call a specific function?

I'm a student of DLUT. Recently I read the code of the telex project. While I am reading code, i met st->client_conn = ioctl( fake_listen_sock, 0xFACE, &s_st ); code link- line: 331 I think ioctl is used to call the function "fake_accept_ioctl".…
loot
  • 1
-1
votes
2 answers

How does ioctl exactly exactly work and how to make it work properly for dvd readings?

I've done the following code to test the use of ioctl and I'm pretty confused about the results. int main(void) { int id; dvd_struct s; id=open("/dev/dvd",O_RDONLY); ioctl(id,DVD_READ_STRUCT,&s); …
user2638180
  • 1,013
  • 16
  • 37
-1
votes
1 answer

C program: How to copy linked list to dynamic array?

Let say I have a structure of disk_info with members devname & devno. And I have created linked list of the same. Now I want to convert this linked list to contiguous memory so as to easily pass the data to kernel through ioctl. And at the kernel…
Nikita Kodkani
  • 165
  • 1
  • 2
  • 11
-1
votes
2 answers

In general How to find out whether client has assigned static Ip or it is dhcp client

I have retrieved IP, subnet and broadcast using ioctl() system call. can anyone help me to find out whether client is static or dhcp?? I am asking about in general and using system call. it is all about client instead of interface.
Ravi Bhushan
  • 253
  • 3
  • 17
-1
votes
2 answers

how to return mac address using ioctl only 4 hex instead 6 hex

I have the following code:(compiled as shared library) #include #include #include typedef int (*ioctl_t)(int, unsigned long int, char *); int ioctl(int d, unsigned long int request, char *argp) { int out; …
-2
votes
1 answer

slcand error : Inappropriate ioctl for device

I want to use can interface with slcand, but I have a problem. To link can device(canable) with slcand, I make symbolic link with udev-rule SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTR{product}=="canable gs_usb",…
1 2 3
46
47