usb-mtp: Add support for inotify based file monitoring
authorBandan Das <bsd@redhat.com>
Mon, 23 Nov 2015 21:37:04 +0000 (16:37 -0500)
committerGerd Hoffmann <kraxel@redhat.com>
Tue, 15 Dec 2015 08:26:10 +0000 (09:26 +0100)
commit8e3e3897ce6d9e927053229ab0672f079c9c1501
tree479ddf0f9b247b65a8ccbc449837f29d06c349a7
parentb3c4d4250f571c2c739699be563f764eae1e6f52
usb-mtp: Add support for inotify based file monitoring

For now, we use inotify watches to track only a small number of
events, namely, add, delete and modify. Note that for delete, the kernel
already deactivates the watch for us and we just need to
take care of modifying our internal state.

inotify is a linux only mechanism.

Suggested-by: Gerd Hoffman <kraxel@redhat.com>
Signed-off-by: Bandan Das <bsd@redhat.com>
Message-id: 1448314625-3855-4-git-send-email-bsd@redhat.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
hw/usb/dev-mtp.c
trace-events