From: Christoph Hellwig Date: Mon, 28 Sep 2015 15:35:14 +0200 Subject: [Cluster-devel] [PATCH 02/23] usb-gadget: use per-attribute show and store methods In-Reply-To: <20150927155053.GD16364@saruman.tx.rr.com> References: <1443189000-13398-1-git-send-email-hch@lst.de> <1443189000-13398-3-git-send-email-hch@lst.de> <20150927155053.GD16364@saruman.tx.rr.com> Message-ID: <20150928133514.GB30453@lst.de> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit On Sun, Sep 27, 2015 at 10:50:53AM -0500, Felipe Balbi wrote: > this (and the other helper below) could be macros just fine. They could, but they shouldn't. Inlines are always preferable over function-like macros. > Are you 100% compiler > will *always* inline these helpers. With gcc you can't ever be sure - but if it doesn't inline a trivial pointer arithmetic we'll see breakage in various other places, including the file system fast path which uses this pattern all over.