linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: linux@arm.linux.org.uk (Russell King - ARM Linux)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 7/8] S3C2412: move io-init to SoC specific files
Date: Tue, 17 Jan 2012 21:50:24 +0000	[thread overview]
Message-ID: <20120117215024.GY1068@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <201201172216.06542.heiko@sntech.de>

On Tue, Jan 17, 2012 at 10:16:06PM +0100, Heiko St?bner wrote:
> @@ -103,15 +83,6 @@ static struct map_desc s3c_iodesc[] __initdata = {
>  
>  /* read cpu identificaiton code */
>  
> -static unsigned long s3c24xx_read_idcode_v5(void)
> -{
> -#if defined(CONFIG_CPU_S3C2412) || defined(CONFIG_CPU_S3C2413)
> -	return __raw_readl(S3C2412_GSTATUS1);
> -#else
> -	return 1UL;	/* don't look like an 2400 */
> -#endif
> -}
> -
>  static unsigned long s3c24xx_read_idcode_v4(void)
>  {
>  	return __raw_readl(S3C2410_GSTATUS1);
> @@ -123,11 +94,7 @@ void __init s3c24xx_init_io(struct map_desc *mach_desc, int size)
>  	iotable_init(mach_desc, size);
>  	iotable_init(s3c_iodesc, ARRAY_SIZE(s3c_iodesc));
>  
> -	if (cpu_architecture() >= CPU_ARCH_ARMv5) {
> -		samsung_cpu_id = s3c24xx_read_idcode_v5();
> -	} else {
> -		samsung_cpu_id = s3c24xx_read_idcode_v4();
> -	}
> +	samsung_cpu_id = s3c24xx_read_idcode_v4();

I really don't like seeing patches which do this kind of thing:

patch 1: move A
patch 2: move B
patch 3: move C and delete D which A,B,C all depend on

It means that if, for whatever reason, patch 2 has to be reverted or
removed, you also have to revert patch 3.  Rather than this:

patch 1: move A
patch 2: move B
patch 3: move C
patch 4: delete D which A,B,C all depend on

This makes each 'move' patches _totally_ independent of each other, and
of the delete D patch, and makes the interdependencies of the patches
easier to express and understand.

Note that you didn't say you deleted D, which the others rely upon, in
the patch commentry:

> Move s3c2412 specific code from s3c24xx_init_io to s3c2412.c
> and make the s3c2412.h header obsolete.

  reply	other threads:[~2012-01-17 21:50 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-01-17 21:10 [PATCH v2 0/8] S3C24XX: remove global plat/s3c24??.h SoC-headers Heiko Stübner
2012-01-17 21:11 ` [PATCH 1/8] S3C24XX: Remove extern declaration of clk_msysclk Heiko Stübner
2012-01-17 21:12 ` [PATCH 2/8] S3C24XX: move common S3C2443 clock definitions to clock.h Heiko Stübner
2012-01-17 21:12 ` [PATCH 3/8] S3C2410: move s3c2410_baseclk_add " Heiko Stübner
2012-01-17 21:13 ` [PATCH 4/8] S3C2416: move io-init to SoC specific files Heiko Stübner
2012-01-17 21:43   ` Russell King - ARM Linux
2012-01-17 22:23     ` Heiko Stübner
2012-01-17 21:14 ` [PATCH 5/8] S3C2443: " Heiko Stübner
2012-01-17 21:15 ` [PATCH 6/8] S3C2440: " Heiko Stübner
2012-01-17 21:16 ` [PATCH 7/8] S3C2412: " Heiko Stübner
2012-01-17 21:50   ` Russell King - ARM Linux [this message]
2012-01-17 21:16 ` [PATCH 8/8] S3C2410: " Heiko Stübner
2012-01-17 21:58 ` [PATCH v2 0/8] S3C24XX: remove global plat/s3c24??.h SoC-headers Russell King - ARM Linux
  -- strict thread matches above, loose matches on Subject: below --
2012-01-06 23:22 [PATCH " Heiko Stübner
2012-01-06 23:28 ` [PATCH 7/8] S3C2412: move io-init to SoC specific files Heiko Stübner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20120117215024.GY1068@n2100.arm.linux.org.uk \
    --to=linux@arm.linux.org.uk \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).