[En-Nut-Discussion] irqreg.h files duplicated

Ernst Stippl ernst at stippl.org
Fri Jan 4 10:22:10 CET 2008


Hi!

During some digging inside Nut/OS files I found that irqreg.h files have
(near) duplicates within the "nut/include/ directory structure:

D:\DRV-NUT\ethernut_4.4.0\nut>dir /s irqreg*.h
 Volume in Drive D: is DATAPART1
 Volumeserialnumber: DEA9-33E3

 Directory D:\DRV-NUT\ethernut_4.4.0\nut\include\arch\arm
06.09.2007  20:46             6.211 irqreg.h                  newer as (5)

 Directory D:\DRV-NUT\ethernut_4.4.0\nut\include\arch\avr
08.02.2006  16:20             4.754 irqreg.h                  newer as (4)

 Directory D:\DRV-NUT\ethernut_4.4.0\nut\include\arch\h8300h
26.07.2005  19:35             3.876 irqreg.h                  same as  (3)

 Directory D:\DRV-NUT\ethernut_4.4.0\nut\include\arch\m68k
26.07.2005  19:35             3.964 irqreg.h                  same as  (1)

 Directory D:\DRV-NUT\ethernut_4.4.0\nut\include\arch\unix   newer as (2)
26.01.2006  16:34             2.486 irqreg.h

 Directory D:\DRV-NUT\ethernut_4.4.0\nut\include\dev
05.01.2006  17:53             5.974 irqreg.h         
05.04.2005  18:52             2.717 irqreg_arm.h            (5)
07.10.2005  22:52             3.531 irqreg_avr.h            (4)
16.03.2004  17:48             3.806 irqreg_h8.h             (3)
16.03.2004  17:48             3.896 irqreg_m68k.h           (1)
07.04.2005  13:31             2.240 irqreg_unix.h           (2)
               6 Files    ,         22.164 Bytes

     Summary:
              11 Files,         43.455 Bytes

D:\DRV-NUT\ethernut_4.4.0\nut>

By "same as" I mean functionally equivalent, log/copyright comments may
differ.
By "newer as" I mean functionally extended, i.e. more definitions etc.

A "grep" shows that all ".c" files include "<dev/irqreg.h>"
And another series of greps show only dev/irqreg.h includes the
"arch/xxx/irqreg.h" files based on the CPU architecture:

D:\DRV-NUT\ETHERN~1.0\nut>grep -d+ -i+ arm/irqreg.h *.c

D:\DRV-NUT\ETHERN~1.0\nut>grep -d+ -i+ arm/irqreg.h *.h
File INCLUDE\DEV\IRQREG.H:
#include <arch/arm/irqreg.h>

D:\DRV-NUT\ETHERN~1.0\nut>grep -d+ -i+ avr/irqreg.h *.c

D:\DRV-NUT\ETHERN~1.0\nut>grep -d+ -i+ avr/irqreg.h *.h
File INCLUDE\DEV\IRQREG.H:
#include <arch/avr/irqreg.h>

D:\DRV-NUT\ETHERN~1.0\nut>grep -d+ -i+ unix/irqreg.h *.c

D:\DRV-NUT\ETHERN~1.0\nut>grep -d+ -i+ unix/irqreg.h *.h
File INCLUDE\DEV\IRQREG.H:
#include <arch/unix/irqreg.h>

D:\DRV-NUT\ETHERN~1.0\nut>grep -d+ -i+ h8300h/irqreg.h *.c

D:\DRV-NUT\ETHERN~1.0\nut>grep -d+ -i+ h8300h/irqreg.h *.h
File INCLUDE\DEV\IRQREG.H:
#include <arch/h8300h/irqreg.h>

D:\DRV-NUT\ETHERN~1.0\nut>grep -d+ -i+ m68k/irqreg.h *.c

D:\DRV-NUT\ETHERN~1.0\nut>grep -d+ -i+ m68k/irqreg.h *.h
File INCLUDE\DEV\IRQREG.H:
#include <arch/m68k/irqreg.h>

D:\DRV-NUT\ETHERN~1.0\nut>


Question: why are the irqreg_xxxxx.h versions within "\nut\include\dev"
still there? Shouldn't they get removed?

Regards
Ernst




More information about the En-Nut-Discussion mailing list