diff mbox

[1/1] mtd: s3c2410: Move plat/regs-nand.h to drivers/mtd

Message ID 1388466690-16435-1-git-send-email-sachin.kamat@linaro.org (mailing list archive)
State New, archived
Headers show

Commit Message

Sachin Kamat Dec. 31, 2013, 5:11 a.m. UTC
plat/regs-nand.h is used only by s3c2410 nand driver.
Move this file to the drivers folder to remove platform
dependency.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
---
 drivers/mtd/nand/s3c2410.c                         |    2 +-
 .../plat/regs-nand.h => drivers/mtd/nand/s3c2410.h |   11 ++++-------
 2 files changed, 5 insertions(+), 8 deletions(-)
 rename arch/arm/plat-samsung/include/plat/regs-nand.h => drivers/mtd/nand/s3c2410.h (96%)

Comments

Jingoo Han Dec. 31, 2013, 6:47 a.m. UTC | #1
On Tuesday, December 31, 2013 2:12 PM, Sachin Kamat wrote:
> 
> plat/regs-nand.h is used only by s3c2410 nand driver.
> Move this file to the drivers folder to remove platform
> dependency.
> 
> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>

Reviewed-by: Jingoo Han <jg1.han@samsung.com>

However, how about consolidating this header into 's3c2410.c'?
This comment also applies to the patch "ata: pata_samsung_cf: Move
plat/regs-ata.h to drivers/ata".

Best regards,
Jingoo Han

> ---
>  drivers/mtd/nand/s3c2410.c                         |    2 +-
>  .../plat/regs-nand.h => drivers/mtd/nand/s3c2410.h |   11 ++++-------
>  2 files changed, 5 insertions(+), 8 deletions(-)
>  rename arch/arm/plat-samsung/include/plat/regs-nand.h => drivers/mtd/nand/s3c2410.h (96%)
> 
> diff --git a/drivers/mtd/nand/s3c2410.c b/drivers/mtd/nand/s3c2410.c
> index d65cbe903d40..83fb4feb7556 100644
> --- a/drivers/mtd/nand/s3c2410.c
> +++ b/drivers/mtd/nand/s3c2410.c
> @@ -46,8 +46,8 @@
>  #include <linux/mtd/nand_ecc.h>
>  #include <linux/mtd/partitions.h>
> 
> -#include <plat/regs-nand.h>
>  #include <linux/platform_data/mtd-nand-s3c2410.h>
> +#include "s3c2410.h"
> 
>  /* new oob placement block for use with hardware ecc generation
>   */
> diff --git a/arch/arm/plat-samsung/include/plat/regs-nand.h b/drivers/mtd/nand/s3c2410.h
> similarity index 96%
> rename from arch/arm/plat-samsung/include/plat/regs-nand.h
> rename to drivers/mtd/nand/s3c2410.h
> index 238efea7b9e4..f3b82d7053a0 100644
> --- a/arch/arm/plat-samsung/include/plat/regs-nand.h
> +++ b/drivers/mtd/nand/s3c2410.h
> @@ -1,5 +1,4 @@
> -/* arch/arm/mach-s3c2410/include/mach/regs-nand.h
> - *
> +/*
>   * Copyright (c) 2004-2005 Simtec Electronics <linux@simtec.co.uk>
>   *	http://www.simtec.co.uk/products/SWLINUX/
>   *
> @@ -10,8 +9,8 @@
>   * S3C2410 NAND register definitions
>  */
> 
> -#ifndef __ASM_ARM_REGS_NAND
> -#define __ASM_ARM_REGS_NAND
> +#ifndef __S3C2410_NAND_H
> +#define __S3C2410_NAND_H
> 
> 
>  #define S3C2410_NFREG(x) (x)
> @@ -117,7 +116,5 @@
>  #define S3C2412_NFECCERR_MULTIBIT	(2)
>  #define S3C2412_NFECCERR_ECCAREA	(3)
> 
> -
> -
> -#endif /* __ASM_ARM_REGS_NAND */
> +#endif /* __S3C2410_NAND_H */
> 
> --
> 1.7.9.5
> 
> --

--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Sachin Kamat Dec. 31, 2013, 6:51 a.m. UTC | #2
Hi Jingoo,

On 31 December 2013 12:17, Jingoo Han <jg1.han@samsung.com> wrote:
> On Tuesday, December 31, 2013 2:12 PM, Sachin Kamat wrote:
>>
>> plat/regs-nand.h is used only by s3c2410 nand driver.
>> Move this file to the drivers folder to remove platform
>> dependency.
>>
>> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
>
> Reviewed-by: Jingoo Han <jg1.han@samsung.com>

Thanks.

> However, how about consolidating this header into 's3c2410.c'?
> This comment also applies to the patch "ata: pata_samsung_cf: Move
> plat/regs-ata.h to drivers/ata".

That was an option. However considering the size of the header files, I chose to
keep them separate. Either way is fine with me though.
Sachin Kamat Jan. 2, 2014, 5:02 a.m. UTC | #3
On 31 December 2013 10:41, Sachin Kamat <sachin.kamat@linaro.org> wrote:
> plat/regs-nand.h is used only by s3c2410 nand driver.
> Move this file to the drivers folder to remove platform
> dependency.
>
> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>

Please ignore this patch. Sent an updated version.
diff mbox

Patch

diff --git a/drivers/mtd/nand/s3c2410.c b/drivers/mtd/nand/s3c2410.c
index d65cbe903d40..83fb4feb7556 100644
--- a/drivers/mtd/nand/s3c2410.c
+++ b/drivers/mtd/nand/s3c2410.c
@@ -46,8 +46,8 @@ 
 #include <linux/mtd/nand_ecc.h>
 #include <linux/mtd/partitions.h>
 
-#include <plat/regs-nand.h>
 #include <linux/platform_data/mtd-nand-s3c2410.h>
+#include "s3c2410.h"
 
 /* new oob placement block for use with hardware ecc generation
  */
diff --git a/arch/arm/plat-samsung/include/plat/regs-nand.h b/drivers/mtd/nand/s3c2410.h
similarity index 96%
rename from arch/arm/plat-samsung/include/plat/regs-nand.h
rename to drivers/mtd/nand/s3c2410.h
index 238efea7b9e4..f3b82d7053a0 100644
--- a/arch/arm/plat-samsung/include/plat/regs-nand.h
+++ b/drivers/mtd/nand/s3c2410.h
@@ -1,5 +1,4 @@ 
-/* arch/arm/mach-s3c2410/include/mach/regs-nand.h
- *
+/*
  * Copyright (c) 2004-2005 Simtec Electronics <linux@simtec.co.uk>
  *	http://www.simtec.co.uk/products/SWLINUX/
  *
@@ -10,8 +9,8 @@ 
  * S3C2410 NAND register definitions
 */
 
-#ifndef __ASM_ARM_REGS_NAND
-#define __ASM_ARM_REGS_NAND
+#ifndef __S3C2410_NAND_H
+#define __S3C2410_NAND_H
 
 
 #define S3C2410_NFREG(x) (x)
@@ -117,7 +116,5 @@ 
 #define S3C2412_NFECCERR_MULTIBIT	(2)
 #define S3C2412_NFECCERR_ECCAREA	(3)
 
-
-
-#endif /* __ASM_ARM_REGS_NAND */
+#endif /* __S3C2410_NAND_H */