[PATCH RFC 51/51] ARM: 7805/1: mm: change max*pfn to include the physical offset of memory

Russell King - ARM Linux linux at arm.linux.org.uk
Tue Aug 6 04:51:23 EDT 2013


On Mon, Aug 05, 2013 at 10:15:11PM -0500, Rob Herring wrote:
> On Thu, Aug 1, 2013 at 5:25 PM, Santosh Shilimkar
> <santosh.shilimkar at ti.com> wrote:
> > +/* The ARM override for dma_max_pfn() */
> > +static inline unsigned long dma_max_pfn(struct device *dev)
> > +{
> > +       return PHYS_PFN_OFFSET + dma_to_pfn(dev, *dev->dma_mask);
> 
> Do we need to handle dev == NULL case?

No, look at where it's used and the code it's replacing.  You'll find
that its callsites handle the dev = NULL case.



More information about the linux-arm-kernel mailing list