Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S936601AbcLTRo0 (ORCPT ); Tue, 20 Dec 2016 12:44:26 -0500 Received: from smtp.eu.citrix.com ([185.25.65.24]:20963 "EHLO SMTP.EU.CITRIX.COM" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S935444AbcLTRoX (ORCPT ); Tue, 20 Dec 2016 12:44:23 -0500 X-IronPort-AV: E=Sophos;i="5.33,379,1477958400"; d="scan'208";a="37175799" Date: Tue, 20 Dec 2016 17:44:06 +0000 From: Roger Pau =?iso-8859-1?Q?Monn=E9?= To: Konrad Rzeszutek Wilk CC: Geliang Tang , , Subject: Re: [PATCH] xen/blkback: use rb_entry() Message-ID: <20161220174406.uewt5mhniwtznran@dhcp-3-221.uk.xensource.com> References: <20161220164703.GL10069@char.us.oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20161220164703.GL10069@char.us.oracle.com> User-Agent: NeoMutt/20161126 (1.7.1) X-ClientProxiedBy: AMSPEX02CAS01.citrite.net (10.69.22.112) To AMSPEX02CL02.citrite.net (10.69.22.126) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 564 Lines: 15 On Tue, Dec 20, 2016 at 11:47:03AM -0500, Konrad Rzeszutek Wilk wrote: > On Tue, Dec 20, 2016 at 10:02:19PM +0800, Geliang Tang wrote: > > To make the code clearer, use rb_entry() instead of container_of() to > > deal with rbtree. > > That is OK but I think 'container_of' is more clear. > > Roger, thoughts? I think so, container_of is a global macro that's widely used and everyone knows, rb_entry OTOH it's not and it's use doesn't really simply the code at all. I'm not really opposed, but it seems kind of a pointless change (not that it's wrong). Roger.