Re: [PATCH v2 06/20] fsnotify: remove redundant arguments to handle_event()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Apr 17, 2018 at 7:33 PM, Jan Kara <jack@xxxxxxx> wrote:
> On Thu 05-04-18 16:18:07, Amir Goldstein wrote:
>> inode_mark and vfsmount_mark arguments are passed to handle_event()
>> operation as function arguments as well as on iter_info struct.
>> The difference is that iter_info struct may contain marks that should
>> not be handled and are represented as NULL arguments to inode_mark or
>> vfsmount_mark.
>>
>> Instead of passing the inode_mark and vfsmount_mark arguments, add
>> a type_mask member to iter_info struct to indicate which marks should
>> be handled, versus marks that should only be kept alive during user
>> wait.
>>
>> This change is going to be used for passing more mark types
>> with handle_event() (i.e. super block marks).
>>
>> Signed-off-by: Amir Goldstein <amir73il@xxxxxxxxx>
>
> Again only nit here:
>
>> @@ -212,6 +210,35 @@ enum fsnotify_obj_type {
>>  #define FSNOTIFY_OBJ_TYPE_VFSMOUNT_FL        (1U << FSNOTIFY_OBJ_TYPE_VFSMOUNT)
>>  #define FSNOTIFY_OBJ_ALL_TYPES_MASK  ((1U << FSNOTIFY_OBJ_TYPE_MAX) - 1)
>>
>> +struct fsnotify_iter_info {
>> +     struct fsnotify_mark *inode_mark;
>> +     struct fsnotify_mark *vfsmount_mark;
>> +     unsigned int type_mask;
>> +     int srcu_idx;
>> +};
>
> I'd rename 'type_mask' to something more expressing the fact that these are
> marks we currently report to - 'report_mask'?
>

OK. For lack of a better name.

Thanks,
Amir.



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux