Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965335AbbFJUkb (ORCPT ); Wed, 10 Jun 2015 16:40:31 -0400 Received: from mail-wg0-f66.google.com ([74.125.82.66]:34939 "EHLO mail-wg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S965259AbbFJUkO (ORCPT ); Wed, 10 Jun 2015 16:40:14 -0400 From: Frans Klaver To: Brian Norris Cc: Frans Klaver , David Woodhouse , linux-kernel@vger.kernel.org, linux-mtd@lists.infradead.org Subject: [PATCH v2 60/60] staging: mt29f_spinand: show parent device in sysfs Date: Wed, 10 Jun 2015 22:39:14 +0200 Message-Id: <1433968754-10651-61-git-send-email-fransklaver@gmail.com> X-Mailer: git-send-email 2.4.0 In-Reply-To: <1433968754-10651-1-git-send-email-fransklaver@gmail.com> References: <1433968754-10651-1-git-send-email-fransklaver@gmail.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1152 Lines: 33 Fix a bug where mtd parent device symlinks aren't shown in sysfs. While at it, take advantage of the default owner and name values set by mtdcore. Signed-off-by: Frans Klaver Acked-by: Greg Kroah-Hartman --- drivers/staging/mt29f_spinand/mt29f_spinand.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/staging/mt29f_spinand/mt29f_spinand.c b/drivers/staging/mt29f_spinand/mt29f_spinand.c index 7285c64..c066ee0 100644 --- a/drivers/staging/mt29f_spinand/mt29f_spinand.c +++ b/drivers/staging/mt29f_spinand/mt29f_spinand.c @@ -912,8 +912,7 @@ static int spinand_probe(struct spi_device *spi_nand) dev_set_drvdata(&spi_nand->dev, mtd); mtd->priv = chip; - mtd->name = dev_name(&spi_nand->dev); - mtd->owner = THIS_MODULE; + mtd->dev.parent = &spi_nand->dev; mtd->oobsize = 64; if (nand_scan(mtd, 1)) -- 2.4.0 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/