All of lore.kernel.org
 help / color / mirror / Atom feed
* [KJ][Patch] make storage class first in pwc-kiara.h
@ 2006-02-17 11:00 Darren Jenkins\
  2006-02-17 11:09 ` [KJ][Patch] Make storage class first in machine_kexec.c Darren Jenkins\
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: Darren Jenkins\ @ 2006-02-17 11:00 UTC (permalink / raw)
  To: kernel-janitors

[-- Attachment #1: Type: text/plain, Size: 830 bytes --]

G'day list

ICC complains about : Remark #82: Storage Class is not First.

http://linuxicc.sourceforge.net/

@ line 40 & 41 of pwc-kiara.h.

The patch below re-orders the modifiers to make extern before const.

Signed-off-by: Darren Jenkins <darrenrjenkins@gmail.com>

--- linux-2.6.16-rc3/drivers/usb/media/pwc/pwc-kiara.h.orig	2006-02-17 21:47:21.000000000 +1100
+++ linux-2.6.16-rc3/drivers/usb/media/pwc/pwc-kiara.h	2006-02-17 21:47:30.000000000 +1100
@@ -37,8 +37,8 @@ struct Kiara_table_entry
 	unsigned char mode[12];		/* precomputed mode settings for cam */
 };
 
-const extern struct Kiara_table_entry Kiara_table[PSZ_MAX][6][4];
-const extern unsigned int KiaraRomTable[8][2][16][8];
+extern const struct Kiara_table_entry Kiara_table[PSZ_MAX][6][4];
+extern const unsigned int KiaraRomTable[8][2][16][8];
 
 #endif
 



[-- Attachment #2: Type: text/plain, Size: 168 bytes --]

_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

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

* [KJ][Patch] Make storage class first in machine_kexec.c
  2006-02-17 11:00 [KJ][Patch] make storage class first in pwc-kiara.h Darren Jenkins\
@ 2006-02-17 11:09 ` Darren Jenkins\
  2006-02-17 11:43 ` [KJ][Patch] make storage class first in pwc-timon.h Darren Jenkins\
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: Darren Jenkins\ @ 2006-02-17 11:09 UTC (permalink / raw)
  To: kernel-janitors

[-- Attachment #1: Type: text/plain, Size: 906 bytes --]

G'day list,

from http://linuxicc.sourceforge.net/

ICC complains about :Storage Class is not First

@ line 136 & 138 of machine_kexec.c

The patch below just alters the order of the modifiers to make extern
first.

Signed-off-by: Darren Jenkins <darrenrjenkins@gmail.com>

--- linux-2.6.16-rc3/arch/i386/kernel/machine_kexec.c.orig	2006-02-17 22:02:14.000000000 +1100
+++ linux-2.6.16-rc3/arch/i386/kernel/machine_kexec.c	2006-02-17 22:07:00.000000000 +1100
@@ -133,9 +133,9 @@ typedef asmlinkage NORET_TYPE void (*rel
 					unsigned long start_address,
 					unsigned int has_pae) ATTRIB_NORET;
 
-const extern unsigned char relocate_new_kernel[];
+extern const unsigned char relocate_new_kernel[];
 extern void relocate_new_kernel_end(void);
-const extern unsigned int relocate_new_kernel_size;
+extern const unsigned int relocate_new_kernel_size;
 
 /*
  * A architecture hook called to validate the



[-- Attachment #2: Type: text/plain, Size: 168 bytes --]

_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

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

* [KJ][Patch] make storage class first in pwc-timon.h
  2006-02-17 11:00 [KJ][Patch] make storage class first in pwc-kiara.h Darren Jenkins\
  2006-02-17 11:09 ` [KJ][Patch] Make storage class first in machine_kexec.c Darren Jenkins\
@ 2006-02-17 11:43 ` Darren Jenkins\
  2006-02-17 12:13 ` [KJ][Patch] make storage class first in nfs4proc.c Darren Jenkins\
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: Darren Jenkins\ @ 2006-02-17 11:43 UTC (permalink / raw)
  To: kernel-janitors

[-- Attachment #1: Type: text/plain, Size: 822 bytes --]

G'day list

from http://linuxicc.sourceforge.net/

ICC complains about : Storage Class is not First

@ line 55 & 56 of pwc-timon.h

This patch just re-orders the modifiers to ensure extern is first

Signed-off-by: Darren Jenkins <darrenrjenkins@gmail.com>

--- linux-2.6.16-rc3/drivers/usb/media/pwc/pwc-timon.h.orig	2006-02-17 22:29:16.000000000 +1100
+++ linux-2.6.16-rc3/drivers/usb/media/pwc/pwc-timon.h	2006-02-17 22:29:50.000000000 +1100
@@ -52,8 +52,8 @@ struct Timon_table_entry
 	unsigned char mode[13];		/* precomputed mode settings for cam */
 };
 
-const extern struct Timon_table_entry Timon_table[PSZ_MAX][6][4];
-const extern unsigned int TimonRomTable [16][2][16][8];
+extern const struct Timon_table_entry Timon_table[PSZ_MAX][6][4];
+extern const unsigned int TimonRomTable [16][2][16][8];
 
 
 #endif



[-- Attachment #2: Type: text/plain, Size: 168 bytes --]

_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

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

* [KJ][Patch] make storage class first in nfs4proc.c
  2006-02-17 11:00 [KJ][Patch] make storage class first in pwc-kiara.h Darren Jenkins\
  2006-02-17 11:09 ` [KJ][Patch] Make storage class first in machine_kexec.c Darren Jenkins\
  2006-02-17 11:43 ` [KJ][Patch] make storage class first in pwc-timon.h Darren Jenkins\
@ 2006-02-17 12:13 ` Darren Jenkins\
  2006-02-17 16:12 ` [KJ][Patch] make storage class first in pwc-kiara.h Randy.Dunlap
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: Darren Jenkins\ @ 2006-02-17 12:13 UTC (permalink / raw)
  To: kernel-janitors

[-- Attachment #1: Type: text/plain, Size: 747 bytes --]

G'day list

from http://linuxicc.sourceforge.net/

ICC complains about : Storage Class is not First

@ line 2961 of nfs4proc.c

The patch below just re-orders the modifiers so static is first.

Signed-off-by: Darren Jenkins <darrenrjenkins@gmail.com>

--- linux-2.6.16-rc3/fs/nfs/nfs4proc.c.orig	2006-02-17 23:03:04.000000000 +1100
+++ linux-2.6.16-rc3/fs/nfs/nfs4proc.c	2006-02-17 23:03:51.000000000 +1100
@@ -2958,7 +2958,7 @@ static void nfs4_delegreturn_release(voi
 	kfree(calldata);
 }
 
-const static struct rpc_call_ops nfs4_delegreturn_ops = {
+static const struct rpc_call_ops nfs4_delegreturn_ops = {
 	.rpc_call_prepare = nfs4_delegreturn_prepare,
 	.rpc_call_done = nfs4_delegreturn_done,
 	.rpc_release = nfs4_delegreturn_release,



[-- Attachment #2: Type: text/plain, Size: 168 bytes --]

_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

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

* Re: [KJ][Patch] make storage class first in pwc-kiara.h
  2006-02-17 11:00 [KJ][Patch] make storage class first in pwc-kiara.h Darren Jenkins\
                   ` (2 preceding siblings ...)
  2006-02-17 12:13 ` [KJ][Patch] make storage class first in nfs4proc.c Darren Jenkins\
@ 2006-02-17 16:12 ` Randy.Dunlap
  2006-02-17 16:41 ` Adrian Bunk
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: Randy.Dunlap @ 2006-02-17 16:12 UTC (permalink / raw)
  To: kernel-janitors

[-- Attachment #1: Type: TEXT/PLAIN, Size: 1015 bytes --]

On Fri, 17 Feb 2006, Darren Jenkins\ wrote:

> G'day list
>
> ICC complains about : Remark #82: Storage Class is not First.
>
> http://linuxicc.sourceforge.net/
>
> @ line 40 & 41 of pwc-kiara.h.
>
> The patch below re-orders the modifiers to make extern before const.

Is that a C-language standard requirement?
IOW, that would be a reason to make such a change.

> Signed-off-by: Darren Jenkins <darrenrjenkins@gmail.com>
>
> --- linux-2.6.16-rc3/drivers/usb/media/pwc/pwc-kiara.h.orig	2006-02-17 21:47:21.000000000 +1100
> +++ linux-2.6.16-rc3/drivers/usb/media/pwc/pwc-kiara.h	2006-02-17 21:47:30.000000000 +1100
> @@ -37,8 +37,8 @@ struct Kiara_table_entry
>  	unsigned char mode[12];		/* precomputed mode settings for cam */
>  };
>
> -const extern struct Kiara_table_entry Kiara_table[PSZ_MAX][6][4];
> -const extern unsigned int KiaraRomTable[8][2][16][8];
> +extern const struct Kiara_table_entry Kiara_table[PSZ_MAX][6][4];
> +extern const unsigned int KiaraRomTable[8][2][16][8];
>
>  #endif

-- 
~Randy

[-- Attachment #2: Type: text/plain, Size: 168 bytes --]

_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

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

* Re: [KJ][Patch] make storage class first in pwc-kiara.h
  2006-02-17 11:00 [KJ][Patch] make storage class first in pwc-kiara.h Darren Jenkins\
                   ` (3 preceding siblings ...)
  2006-02-17 16:12 ` [KJ][Patch] make storage class first in pwc-kiara.h Randy.Dunlap
@ 2006-02-17 16:41 ` Adrian Bunk
  2006-02-17 16:47 ` Randy.Dunlap
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: Adrian Bunk @ 2006-02-17 16:41 UTC (permalink / raw)
  To: kernel-janitors

[-- Attachment #1: Type: text/plain, Size: 813 bytes --]

On Fri, Feb 17, 2006 at 08:12:51AM -0800, Randy.Dunlap wrote:
> On Fri, 17 Feb 2006, Darren Jenkins\ wrote:
> 
> > G'day list
> >
> > ICC complains about : Remark #82: Storage Class is not First.
> >
> > http://linuxicc.sourceforge.net/
> >
> > @ line 40 & 41 of pwc-kiara.h.
> >
> > The patch below re-orders the modifiers to make extern before const.
> 
> Is that a C-language standard requirement?
> IOW, that would be a reason to make such a change.
>...

It's a coding style issue - different orders of the modifiers only cause 
confusion.

> ~Randy

cu
Adrian

-- 

       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed


[-- Attachment #2: Type: text/plain, Size: 168 bytes --]

_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

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

* Re: [KJ][Patch] make storage class first in pwc-kiara.h
  2006-02-17 11:00 [KJ][Patch] make storage class first in pwc-kiara.h Darren Jenkins\
                   ` (4 preceding siblings ...)
  2006-02-17 16:41 ` Adrian Bunk
@ 2006-02-17 16:47 ` Randy.Dunlap
  2006-02-18  3:46 ` Darren Jenkins\
  2006-02-18  4:58 ` Randy.Dunlap
  7 siblings, 0 replies; 9+ messages in thread
From: Randy.Dunlap @ 2006-02-17 16:47 UTC (permalink / raw)
  To: kernel-janitors

[-- Attachment #1: Type: TEXT/PLAIN, Size: 689 bytes --]

On Fri, 17 Feb 2006, Adrian Bunk wrote:

> On Fri, Feb 17, 2006 at 08:12:51AM -0800, Randy.Dunlap wrote:
> > On Fri, 17 Feb 2006, Darren Jenkins\ wrote:
> >
> > > G'day list
> > >
> > > ICC complains about : Remark #82: Storage Class is not First.
> > >
> > > http://linuxicc.sourceforge.net/
> > >
> > > @ line 40 & 41 of pwc-kiara.h.
> > >
> > > The patch below re-orders the modifiers to make extern before const.
> >
> > Is that a C-language standard requirement?
> > IOW, that would be a reason to make such a change.
> >...
>
> It's a coding style issue - different orders of the modifiers only cause
> confusion.

Maybe, but that wasn't his justification for the patch.

-- 
~Randy

[-- Attachment #2: Type: text/plain, Size: 168 bytes --]

_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

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

* Re: [KJ][Patch] make storage class first in pwc-kiara.h
  2006-02-17 11:00 [KJ][Patch] make storage class first in pwc-kiara.h Darren Jenkins\
                   ` (5 preceding siblings ...)
  2006-02-17 16:47 ` Randy.Dunlap
@ 2006-02-18  3:46 ` Darren Jenkins\
  2006-02-18  4:58 ` Randy.Dunlap
  7 siblings, 0 replies; 9+ messages in thread
From: Darren Jenkins\ @ 2006-02-18  3:46 UTC (permalink / raw)
  To: kernel-janitors

[-- Attachment #1: Type: text/plain, Size: 2042 bytes --]

On Fri, 2006-02-17 at 08:12 -0800, Randy.Dunlap wrote:
> On Fri, 17 Feb 2006, Darren Jenkins\ wrote:
> 
> > G'day list
> >
> > ICC complains about : Remark #82: Storage Class is not First.
> >
> > http://linuxicc.sourceforge.net/
> >
> > @ line 40 & 41 of pwc-kiara.h.
> >
> > The patch below re-orders the modifiers to make extern before const.
> 
> Is that a C-language standard requirement?
> IOW, that would be a reason to make such a change.

OK I don't have a copy of the standard, but after a hunt through the
draft copy I was pointed to earlier 
(http://wwwold.dkuug.dk/jtc1/sc22/open/n2794/)
I found this under the grammar section.
(page 400)

(6.7) declaration-specifiers:

declaration-specifiers:
         storage-class-specifier declaration-specifiersopt
         type-specifier declaration-specifiersopt
         type-qualifier declaration-specifiersopt
         function-specifier declaration-specifiersopt

Which shows (surprisingly) that it isn't a C-standard requirement. 
(Damn I thought it was)

So I guess It is only a coding style issue.

Not putting the storage class specifier first: 
is confusing; 
dilutes the logical meaning of the specifier; 
is only used in 4 files (looking at ICC warnings);
generates warnings on ICC;
is safe to re-order in non-pointer declarations.

So I guess for these reasons the patches should be applied.

> 
> > Signed-off-by: Darren Jenkins <darrenrjenkins@gmail.com>
> >
> > --- linux-2.6.16-rc3/drivers/usb/media/pwc/pwc-kiara.h.orig	2006-02-17 21:47:21.000000000 +1100
> > +++ linux-2.6.16-rc3/drivers/usb/media/pwc/pwc-kiara.h	2006-02-17 21:47:30.000000000 +1100
> > @@ -37,8 +37,8 @@ struct Kiara_table_entry
> >  	unsigned char mode[12];		/* precomputed mode settings for cam */
> >  };
> >
> > -const extern struct Kiara_table_entry Kiara_table[PSZ_MAX][6][4];
> > -const extern unsigned int KiaraRomTable[8][2][16][8];
> > +extern const struct Kiara_table_entry Kiara_table[PSZ_MAX][6][4];
> > +extern const unsigned int KiaraRomTable[8][2][16][8];
> >
> >  #endif
> 


[-- Attachment #2: Type: text/plain, Size: 168 bytes --]

_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

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

* Re: [KJ][Patch] make storage class first in pwc-kiara.h
  2006-02-17 11:00 [KJ][Patch] make storage class first in pwc-kiara.h Darren Jenkins\
                   ` (6 preceding siblings ...)
  2006-02-18  3:46 ` Darren Jenkins\
@ 2006-02-18  4:58 ` Randy.Dunlap
  7 siblings, 0 replies; 9+ messages in thread
From: Randy.Dunlap @ 2006-02-18  4:58 UTC (permalink / raw)
  To: kernel-janitors

[-- Attachment #1: Type: text/plain, Size: 1557 bytes --]

On Sat, 18 Feb 2006 14:46:14 +1100 Darren Jenkins\\ wrote:

> On Fri, 2006-02-17 at 08:12 -0800, Randy.Dunlap wrote:
> > On Fri, 17 Feb 2006, Darren Jenkins\ wrote:
> > 
> > > G'day list
> > >
> > > ICC complains about : Remark #82: Storage Class is not First.
> > >
> > > http://linuxicc.sourceforge.net/
> > >
> > > @ line 40 & 41 of pwc-kiara.h.
> > >
> > > The patch below re-orders the modifiers to make extern before const.
> > 
> > Is that a C-language standard requirement?
> > IOW, that would be a reason to make such a change.
> 
> OK I don't have a copy of the standard, but after a hunt through the
> draft copy I was pointed to earlier 
> (http://wwwold.dkuug.dk/jtc1/sc22/open/n2794/)
> I found this under the grammar section.
> (page 400)
> 
> (6.7) declaration-specifiers:
> 
> declaration-specifiers:
>          storage-class-specifier declaration-specifiersopt
>          type-specifier declaration-specifiersopt
>          type-qualifier declaration-specifiersopt
>          function-specifier declaration-specifiersopt
> 
> Which shows (surprisingly) that it isn't a C-standard requirement. 
> (Damn I thought it was)
> 
> So I guess It is only a coding style issue.
> 
> Not putting the storage class specifier first: 
> is confusing; 
> dilutes the logical meaning of the specifier; 
> is only used in 4 files (looking at ICC warnings);
> generates warnings on ICC;
> is safe to re-order in non-pointer declarations.
> 
> So I guess for these reasons the patches should be applied.

OK, thank you for doing that.

---
~Randy

[-- Attachment #2: Type: text/plain, Size: 168 bytes --]

_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

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

end of thread, other threads:[~2006-02-18  4:58 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-02-17 11:00 [KJ][Patch] make storage class first in pwc-kiara.h Darren Jenkins\
2006-02-17 11:09 ` [KJ][Patch] Make storage class first in machine_kexec.c Darren Jenkins\
2006-02-17 11:43 ` [KJ][Patch] make storage class first in pwc-timon.h Darren Jenkins\
2006-02-17 12:13 ` [KJ][Patch] make storage class first in nfs4proc.c Darren Jenkins\
2006-02-17 16:12 ` [KJ][Patch] make storage class first in pwc-kiara.h Randy.Dunlap
2006-02-17 16:41 ` Adrian Bunk
2006-02-17 16:47 ` Randy.Dunlap
2006-02-18  3:46 ` Darren Jenkins\
2006-02-18  4:58 ` Randy.Dunlap

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.