Block protocol: add user endpoint to IOCTL request
I/O control requests now come with the endpoint of the user process that initiated the ioctl(2) call. It is stored in a new BDEV_USER field, which is an alias for BDEV_FLAGS. The contents of this field are to be used only in highly specific situations. It should be preserved (not replaced!) by services that forward IOCTL requests, and may be set to NONE for service-initiated IOCTL requests. Change-Id: I68a01b9ce43eca00e61b985a9cf87f55ba683de4
This commit is contained in:
@@ -60,6 +60,7 @@ static int driver_open(int which)
|
||||
msg.BDEV_MINOR = driver[which].minor;
|
||||
msg.BDEV_REQUEST = DIOCGETP;
|
||||
msg.BDEV_GRANT = gid;
|
||||
msg.BDEV_USER = NONE;
|
||||
msg.BDEV_ID = 0;
|
||||
|
||||
r = sendrec(driver[which].endpt, &msg);
|
||||
|
||||
Reference in New Issue
Block a user