RE: [PATCH] OMAP: fix gpmc nand setup when no timings supplied

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> -----Original Message-----
> From: linux-omap-owner@xxxxxxxxxxxxxxx [mailto:linux-omap-
> owner@xxxxxxxxxxxxxxx] On Behalf Of Mike Rapoport
> Sent: 2010-04-22 10:50
> To: linux-omap@xxxxxxxxxxxxxxx
> Cc: Tony Lindgren; Mike Rapoport
> Subject: Re: [PATCH] OMAP: fix gpmc nand setup when no timings supplied
> 
> Any comments on this?
> 
> Mike Rapoport wrote:
> > The gpmc nand infrastructure crashes when there no timing structure
> > supplied in the omap_nand_platform_data. Adding check for
> > gpmc_nand_data->gpmc_t pointer validity resolves the crash and allows to
> > continue nand initialization without modifying gpmc timings.
> >
> > Signed-off-by: Mike Rapoport <mike@xxxxxxxxxxxxxx>
> > ---
> >  arch/arm/mach-omap2/gpmc-nand.c |    5 +++++
> >  1 files changed, 5 insertions(+), 0 deletions(-)
> >
> > diff --git a/arch/arm/mach-omap2/gpmc-nand.c b/arch/arm/mach-omap2/gpmc-
> nand.c
> > index 64d74f0..3629da3 100644
> > --- a/arch/arm/mach-omap2/gpmc-nand.c
> > +++ b/arch/arm/mach-omap2/gpmc-nand.c
> > @@ -83,6 +83,11 @@ static int gpmc_nand_setup(void)
> >  {
> >  	struct device *dev = &gpmc_nand_device.dev;
> >
> > +	if (!gpmc_nand_data->gpmc_t) {
> > +		dev_info(dev, "Keeping gpmc timings\n");
> > +		return 0;
> > +	}
[Ghorai] This is the only time its setup the gpmc timings for NAND. And it should return as error.

> > +
> >  	/* Set timings in GPMC */
> >  	if (omap2_nand_gpmc_retime() < 0) {
> >  		dev_err(dev, "Unable to set gpmc timings\n");
> 
> 
> --
> Sincerely yours,
> Mike.
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux