[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20131217104617.GE19810@lee--X1>
Date: Tue, 17 Dec 2013 10:46:17 +0000
From: Lee Jones <lee.jones@...aro.org>
To: Angus Clark <angus.clark@...com>
Cc: Brian Norris <computersforpeace@...il.com>,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
dwmw2@...radead.org, linus.walleij@...aro.org,
linux-mtd@...ts.infradead.org
Subject: Re: [PATCH v3 11/36] mtd: st_spi_fsm: Search for preferred FSM
message sequence configurations
> >> +/* Search for preferred configuration based on available flags */
> >> +static struct seq_rw_config *
> >> +stfsm_search_seq_rw_configs(struct stfsm *fsm,
> >> + struct seq_rw_config cfgs[])
> >> +{
> >> + struct seq_rw_config *config;
> >> + int flags = fsm->info->flags;
> >> +
> >> + for (config = cfgs; cfgs->cmd != 0; config++)
> >
> > This becomes an infinite loop if you can't find a matching config. You
> > probably meant 'config->cmd != 0':
>
> I will leave Lee to defend himself on this one ;-)
No defence necessary, I think Brian's correct.
NB: You might want to take a look at the 'dirty' implementation too. ;)
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists