mtd: remove driver-core BUS_ID_SIZE

Kay Sievers kay.sievers at vrfy.org
Fri May 29 09:25:59 EDT 2009


On Fri, May 29, 2009 at 15:21, David Woodhouse <dwmw2 at infradead.org> wrote:
> This might work better. Nemoto-san, can you test and confirm?

Looks good to me.

> diff --git a/drivers/mtd/nand/txx9ndfmc.c b/drivers/mtd/nand/txx9ndfmc.c

>                if (plat->ch_mask != 1) {
> +                       char *devname = dev_name(&dev->dev);
>                        txx9_priv->cs = i;
> +                       txx9_priv->mtdname = kmalloc(strlen(devname) + 3,
> +                                                    GFP_KERNEL);

kasprintf() might be nicer here?

Thanks,
Kay


More information about the linux-mtd mailing list