From mboxrd@z Thu Jan 1 00:00:00 1970 From: Boris Brezillon Subject: Re: [PATCH] mtd: use dev_of_node helper in mtd_get_of_node Date: Fri, 31 Mar 2017 11:49:50 +0200 Message-ID: <20170331114950.726c9cb7@bbrezillon> References: <20170331091148.19816-1-zajec5@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8BIT Return-path: In-Reply-To: <20170331091148.19816-1-zajec5-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> Sender: devicetree-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: =?UTF-8?B?UmFmYcWCIE1pxYJlY2tp?= Cc: David Woodhouse , Brian Norris , Marek Vasut , Richard Weinberger , Cyrille Pitchen , linux-mtd-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org, devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, =?UTF-8?B?UmFm?= =?UTF-8?B?YcWCIE1pxYJlY2tp?= List-Id: devicetree@vger.kernel.org On Fri, 31 Mar 2017 11:11:48 +0200 Rafał Miłecki wrote: > From: Rafał Miłecki > > This allows better compile-time optimizations with CONFIG_OF disabled. > > Signed-off-by: Rafał Miłecki Not sure we care about such micro-optimizations, but it shouldn't hurst so, Acked-by: Boris Brezillon > --- > include/linux/mtd/mtd.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h > index eebdc63cf6af..f8db5b2e4028 100644 > --- a/include/linux/mtd/mtd.h > +++ b/include/linux/mtd/mtd.h > @@ -393,7 +393,7 @@ static inline void mtd_set_of_node(struct mtd_info *mtd, > > static inline struct device_node *mtd_get_of_node(struct mtd_info *mtd) > { > - return mtd->dev.of_node; > + return dev_of_node(&mtd->dev); > } > > static inline int mtd_oobavail(struct mtd_info *mtd, struct mtd_oob_ops *ops) -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html