public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH -tip] x86: i8259.c fix style problems
@ 2009-01-04 11:03 Jaswinder Singh Rajput
  2009-01-07 18:36 ` Maciej W. Rozycki
  0 siblings, 1 reply; 3+ messages in thread
From: Jaswinder Singh Rajput @ 2009-01-04 11:03 UTC (permalink / raw)
  To: Ingo Molnar, x86 maintainers, LKML

Impact: cleanup, fix style problems, more readable

Fixes style problems:
WARNING: Use #include <linux/acpi.h> instead of <asm/acpi.h>
WARNING: Use #include <linux/io.h> instead of <asm/io.h>
WARNING: Use #include <linux/delay.h> instead of <asm/delay.h>
ERROR: code indent should use tabs where possible

total: 1 errors, 3 warnings

Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com>
---
 arch/x86/kernel/i8259.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/x86/kernel/i8259.c b/arch/x86/kernel/i8259.c
index 4b8a53d..11d5093 100644
--- a/arch/x86/kernel/i8259.c
+++ b/arch/x86/kernel/i8259.c
@@ -11,15 +11,15 @@
 #include <linux/kernel_stat.h>
 #include <linux/sysdev.h>
 #include <linux/bitops.h>
+#include <linux/acpi.h>
+#include <linux/io.h>
+#include <linux/delay.h>
 
-#include <asm/acpi.h>
 #include <asm/atomic.h>
 #include <asm/system.h>
-#include <asm/io.h>
 #include <asm/timer.h>
 #include <asm/hw_irq.h>
 #include <asm/pgtable.h>
-#include <asm/delay.h>
 #include <asm/desc.h>
 #include <asm/apic.h>
 #include <asm/arch_hooks.h>
@@ -323,7 +323,7 @@ void init_8259A(int auto_eoi)
 	outb_pic(0x11, PIC_MASTER_CMD);	/* ICW1: select 8259A-1 init */
 
 	/* ICW2: 8259A-1 IR0-7 mapped to 0x30-0x37 on x86-64,
-	                       to 0x20-0x27 on i386 */
+	   to 0x20-0x27 on i386 */
 	outb_pic(IRQ0_VECTOR, PIC_MASTER_IMR);
 
 	/* 8259A-1 (the master) has a slave on IR2 */
-- 
1.5.5.1




^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH -tip] x86: i8259.c fix style problems
  2009-01-04 11:03 [PATCH -tip] x86: i8259.c fix style problems Jaswinder Singh Rajput
@ 2009-01-07 18:36 ` Maciej W. Rozycki
  2009-01-07 18:56   ` Ingo Molnar
  0 siblings, 1 reply; 3+ messages in thread
From: Maciej W. Rozycki @ 2009-01-07 18:36 UTC (permalink / raw)
  To: Jaswinder Singh Rajput; +Cc: Ingo Molnar, x86 maintainers, LKML

On Sun, 4 Jan 2009, Jaswinder Singh Rajput wrote:

> @@ -11,15 +11,15 @@
>  #include <linux/kernel_stat.h>
>  #include <linux/sysdev.h>
>  #include <linux/bitops.h>
> +#include <linux/acpi.h>
> +#include <linux/io.h>
> +#include <linux/delay.h>
>  
> -#include <asm/acpi.h>
>  #include <asm/atomic.h>
>  #include <asm/system.h>
> -#include <asm/io.h>
>  #include <asm/timer.h>
>  #include <asm/hw_irq.h>
>  #include <asm/pgtable.h>
> -#include <asm/delay.h>
>  #include <asm/desc.h>
>  #include <asm/apic.h>
>  #include <asm/arch_hooks.h>

 My feeling is this hunk and the following one should be submitted as 
separate patches.

> @@ -323,7 +323,7 @@ void init_8259A(int auto_eoi)
>  	outb_pic(0x11, PIC_MASTER_CMD);	/* ICW1: select 8259A-1 init */
>  
>  	/* ICW2: 8259A-1 IR0-7 mapped to 0x30-0x37 on x86-64,
> -	                       to 0x20-0x27 on i386 */
> +	   to 0x20-0x27 on i386 */
>  	outb_pic(IRQ0_VECTOR, PIC_MASTER_IMR);
>  
>  	/* 8259A-1 (the master) has a slave on IR2 */

 I think the original formatting is more readable; I would align the two 
'to's vertically even.  You can fix the comment to adhere to the Linux 
coding standard though and the whitespace "problem" will vanish 
automagically.

  Maciej

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH -tip] x86: i8259.c fix style problems
  2009-01-07 18:36 ` Maciej W. Rozycki
@ 2009-01-07 18:56   ` Ingo Molnar
  0 siblings, 0 replies; 3+ messages in thread
From: Ingo Molnar @ 2009-01-07 18:56 UTC (permalink / raw)
  To: Maciej W. Rozycki; +Cc: Jaswinder Singh Rajput, x86 maintainers, LKML


* Maciej W. Rozycki <macro@linux-mips.org> wrote:

> > @@ -323,7 +323,7 @@ void init_8259A(int auto_eoi)
> >  	outb_pic(0x11, PIC_MASTER_CMD);	/* ICW1: select 8259A-1 init */
> >  
> >  	/* ICW2: 8259A-1 IR0-7 mapped to 0x30-0x37 on x86-64,
> > -	                       to 0x20-0x27 on i386 */
> > +	   to 0x20-0x27 on i386 */
> >  	outb_pic(IRQ0_VECTOR, PIC_MASTER_IMR);
> >  
> >  	/* 8259A-1 (the master) has a slave on IR2 */
> 
>  I think the original formatting is more readable; I would align the two 
> 'to's vertically even.  You can fix the comment to adhere to the Linux 
> coding standard though and the whitespace "problem" will vanish 
> automagically.

yep, this should be:

  	/*
	 * ICW2: 8259A-1 IR0-7 mapped to:
	 *
	 * - 0x20-0x27 on 32-bit
	 * - 0x30-0x37 on 64-bit
	 */

	Ingo

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-01-07 18:56 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-04 11:03 [PATCH -tip] x86: i8259.c fix style problems Jaswinder Singh Rajput
2009-01-07 18:36 ` Maciej W. Rozycki
2009-01-07 18:56   ` Ingo Molnar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox