mbox series

[0/3] btrfs: Enumerate and export exclusive operations

Message ID 20200727220451.30680-1-rgoldwyn@suse.de (mailing list archive)
Headers show
Series btrfs: Enumerate and export exclusive operations | expand

Message

Goldwyn Rodrigues July 27, 2020, 10:04 p.m. UTC
This would enable our tools to specify precisely which operation is
running on why starting an exclusive operation failed. The series also
adds a sysfs_notify() to alert userspace when the state changes, so
userspace can perform select() on it to get notified of the change.
This would enable us to enqueue a command which will wait for current
exclusive operation to complete before issuing the next exclusive
operation. This has been done synchronously as opposed to a background
process, or else error collection (if any) will become a nightmare.

This third patch further expands the balance information such as the
state and the current statistics. I am hoping that it could be used to
move the logic of guessing/managing the right ioctls out of the kernel
and into the tools. However, if you feel that it is inappropriate, the
patch can be ignored.

For backward compatibility, the tools ignore if the sys file is not
present. Would you prefer an error if "--enqueue" option is issued on an
older kernel?

Regards,