> -----Original Message----- > From: Wood Scott-B07421 > Sent: Tuesday, September 14, 2010 0:28 AM > To: Zang Roy-R61911 > Cc: Geert Uytterhoeven; linux-...@lists.infradead.org; Wood Scott-B07421; > dedeki...@gmail.com; Lan Chunhe-B25806; linuxppc-...@ozlabs.org; a...@linux- > foundation.org; dw...@infradead.org; Gala Kumar-B11780 > Subject: Re: [PATCH v2 3/3][MTD] P4080/mtd: Fix the freescale lbc issue with > 36bit mode > > On Mon, 13 Sep 2010 00:22:10 -0700 > "Zang Roy-R61911" <r61...@freescale.com> wrote: > > > > > > > > -----Original Message----- > > > From: geert.uytterhoe...@gmail.com [mailto:geert.uytterhoe...@gmail.com] > On > > > Behalf Of Geert Uytterhoeven > > > Sent: Thursday, September 09, 2010 19:06 PM > > > To: Zang Roy-R61911 > > > Cc: linux-...@lists.infradead.org; Wood Scott-B07421; dedeki...@gmail.com; > Lan > > > Chunhe-B25806; linuxppc-...@ozlabs.org; a...@linux-foundation.org; > > > dw...@infradead.org; Gala Kumar-B11780 > > > Subject: Re: [PATCH v2 3/3][MTD] P4080/mtd: Fix the freescale lbc issue > with > > > 36bit mode > > > > > > On Thu, Sep 9, 2010 at 12:20, Roy Zang <tie-fei.z...@freescale.com> wrote: > > > > From: Lan Chunhe-B25806 <b25...@freescale.com> > > > > > > > > When system uses 36bit physical address, res.start is 36bit > > > > physical address. But the function of in_be32 returns 32bit > > > > physical address. Then both of them compared each other is > > > > wrong. So by converting the address of res.start into > > > > the right format fixes this issue. > > > > > > > /** > > > > + * fsl_lbc_addr - convert the base address > > > > + * @addr_base: base address of the memory bank > > > > + * > > > > + * This function converts a base address of lbc into the right format > for > > > the BR > > > > + * registers. If the SOC has eLBC then it returns 32bit physical > address > > > else > > > > + * it returns 34bit physical address for local bus(Example: MPC8641). > > > > + */ > > > > +unsigned int fsl_lbc_addr(phys_addr_t addr_base) > > > ^^^^^^^^^^^^ > > > Shouldn't this be u32 or __be32, for consistency with the actual > > > comparisons below? > > __be32 is better. > > I disagree, the return from this function is native-endian. It should > be u32. But the return of this value is ONLY used for br comparing. It is big endia. Thanks. Roy
_______________________________________________ Linuxppc-dev mailing list Linuxppc-dev@lists.ozlabs.org https://lists.ozlabs.org/listinfo/linuxppc-dev