From mboxrd@z Thu Jan 1 00:00:00 1970 From: Arnd Bergmann Subject: Re: [PATCH 3/9] ARM: versatile: add DT based PCI detection Date: Tue, 30 Dec 2014 22:37:01 +0100 Message-ID: <13417872.31IhE1RbAx@wuerfel> References: <1419967718-26909-1-git-send-email-robherring2@gmail.com> <1419967718-26909-4-git-send-email-robherring2@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Return-path: In-Reply-To: <1419967718-26909-4-git-send-email-robherring2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> Sender: devicetree-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org Cc: Rob Herring , devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Peter Maydell , Russell King , Rob Herring , Linus Walleij , arm-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org, Bjorn Helgaas List-Id: devicetree@vger.kernel.org On Tuesday 30 December 2014 13:28:32 Rob Herring wrote: > From: Rob Herring > > Disable the Versatile PCI DT node when no PCI backplane is detected. This > will prevent the Versatile PCI driver from probing when PCI is not > populated. Can you explain why the check is done in platform code instead of the PCI driver probe function itself? > + /* Check if PCI backplane is detected */ > + val = __raw_readl(base + VERSATILE_SYS_PCICTL_OFFSET); > + if (val & 1) > + goto err; Using __raw_readl prevents this from working with big-endian kernels, so just use readl here. Arnd -- 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