From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-yb0-f194.google.com ([209.85.213.194]:39920 "EHLO mail-yb0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751552AbeFWHmq (ORCPT ); Sat, 23 Jun 2018 03:42:46 -0400 Received: by mail-yb0-f194.google.com with SMTP id i2-v6so3383614ybg.6 for ; Sat, 23 Jun 2018 00:42:46 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20180622164442.brczirdbvtpiflpk@quack2.suse.cz> References: <20180611133628.e35npuuv425n2425@quack2.suse.cz> <20180611160311.dsehobeuvwiq2j6c@quack2.suse.cz> <20180613132107.pto3j7ujt2wacgii@quack2.suse.cz> <20180622164442.brczirdbvtpiflpk@quack2.suse.cz> From: Amir Goldstein Date: Sat, 23 Jun 2018 10:42:45 +0300 Message-ID: Subject: Re: [GIT PULL] Fsnotify cleanups To: Jan Kara Cc: linux-fsdevel Content-Type: text/plain; charset="UTF-8" Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Fri, Jun 22, 2018 at 7:44 PM, Jan Kara wrote: > On Thu 14-06-18 01:17:38, Amir Goldstein wrote: >> On Wed, Jun 13, 2018 at 4:56 PM, Amir Goldstein wrote: >> > On Wed, Jun 13, 2018 at 4:21 PM, Jan Kara wrote: >> >> >> Going through patches: >> >> >> >> Regarding "fsnotify: use abstract fsnotify_obj_t * instead of **connp >> >> argument" - I agree "struct fsnotify_mark_connector __rcu *" is quite >> >> verbose but given how things evolved I don't think "fsnotify_obj_t" is a >> >> great name. How about "fsnotify_connp_t" and keep parameter names as >> >> "connp" instead of renaming them to "obj"? Because abstraction (like >> >> pretending this is some kind of object when it is actually just a pointer) >> >> that does not actually abstract anything is just obfuscation... So let's be >> >> direct and admit this is just a shortcut name for connector pointer. >> >> >> > >> > I though you'd say that and I agree. >> > will rework after pull request. >> >> Two places I couldn't resist keeping 'obj': >> 1. connector->obj >> 2. fsnotify_obj_{inode,mount} >> >> The first one because conn->connp is horrible. >> The second one because most call sites pass conn->obj as argument. >> >> Force pushed result to fsnotify-cleanup. >> >> See if you find it acceptable. > > Thanks. I like the patches. Just one suggestion for improvement: > Maybe we could call fsnotify_obj_inode() fsnotify_conn_inode() > and let it take connector as an argument. Everybody does conn->obj anyway > unnecessarily. Similarly for mount. And then fsnotify_connector_mask() > could be fsnotify_conn_mask() for consistency? Sure. > > fsnotify_connector_inode() (or mount) is already a bit too long for my > taste ;). Mine as well. > > If you update this, please post the patches to fsdevel with me on CC so > that we have an official posting and I'll pick them up to my tree. > Will do. Thanks, Amir.