From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tony Lindgren Subject: Re: [PATCH] pinctrl: when claiming hog, skip maps not served by same device Date: Fri, 12 May 2017 07:03:19 -0700 Message-ID: <20170512140319.GD3489@atomide.com> References: <20170511200211.20985-1-nikita.yoush@cogentembedded.com> <20170511214444.GB3489@atomide.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from muru.com ([72.249.23.125]:47334 "EHLO muru.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756316AbdELODY (ORCPT ); Fri, 12 May 2017 10:03:24 -0400 Content-Disposition: inline In-Reply-To: Sender: linux-gpio-owner@vger.kernel.org List-Id: linux-gpio@vger.kernel.org To: Nikita Yushchenko Cc: Linus Walleij , Andy Shevchenko , Jon Hunter , Masahiro Yamada , Bjorn Andersson , Mika Westerberg , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Chris Healy , Jeff.White@zii.aero * Nikita Yushchenko [170512 01:22]: > >> + /* > >> + * If pctldev is not null, we are claiming hog for it, > >> + * that means, setting that is served by pctldev by itself. > >> + * > >> + * Thus we must skip map that is for this device but is served > >> + * by other device. > >> + */ > >> + if (pctldev && > >> + strcmp(dev_name(pctldev->dev), map->ctrl_dev_name)) > >> + continue; > >> > >> ret = add_setting(p, pctldev, map); > >> /* > >> -- > > > > Maybe add a comment saying pctldev is NULL in the regular case > > and only exists in the hog case? > > Isn't comment above saying exactly that? Yes it is, you're right :) Tony