On 04/21/2015 04:55 PM, Andy Shevchenko wrote: >> +static unsigned char rb4xx_nand_read_byte(struct mtd_info *mtd) >> +{ >> + struct nand_chip *chip = mtd->priv; >> + struct rb4xx_nand_info *info = chip->priv; >> + unsigned char data = 0; >> + int ret; >> + >> + ret = rb4xx_cpld_read(info->spi_dev, &data, 1); >> + if (ret) { >> + pr_err("rb4xx_nand: read data failed, error %d\n", ret); > > Is it possible to use dev_err() here and in other places?
Not having much luck with this... for some reason the mtd_info struct passed in doesn't have a name on its device, and I'm not sure why. It doesn't match the mtd_info structs created from the partitions either. Can anyone shed some light on this? >> +static int rb4xx_cpld_probe(struct spi_device *spi) >> +{ >> + struct rb4xx_cpld *cpld; >> + struct rb4xx_cpld_platform_data *pdata; >> + int ret; >> + >> + pdata = dev_get_platdata(&spi->dev); > > Hmm... do we have helper in SPI framework to do that? Not that I can see. I'll fix things according to your other comments. -- Bert Vermeulen b...@biot.com email/xmpp -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/