2005-04-17 02:20:36 +04:00
/ *
* vmlinux. l d s . S - - m a s t e r l i n k e r s c r i p t f o r m 6 8 k n o m m u a r c h
*
2006-06-26 10:33:05 +04:00
* ( C) C o p y r i g h t 2 0 0 2 - 2 0 0 6 , G r e g U n g e r e r < g e r g @snapgear.com>
2005-04-17 02:20:36 +04:00
*
2006-06-28 10:44:14 +04:00
* This l i n k e r s c r i p t i s e q u i p e d t o b u i l d e i t h e r R O M l o a d e d o r R A M
* run k e r n e l s .
2005-04-17 02:20:36 +04:00
* /
# include < a s m - g e n e r i c / v m l i n u x . l d s . h >
# if d e f i n e d ( C O N F I G _ R A M K E R N E L )
2006-06-26 10:33:05 +04:00
# define R A M _ S T A R T C O N F I G _ K E R N E L B A S E
# define R A M _ L E N G T H ( C O N F I G _ R A M B A S E + C O N F I G _ R A M S I Z E - C O N F I G _ K E R N E L B A S E )
2005-04-17 02:20:36 +04:00
# define T E X T r a m
# define D A T A r a m
# define I N I T r a m
# define B S S r a m
# endif
# if d e f i n e d ( C O N F I G _ R O M K E R N E L ) | | d e f i n e d ( C O N F I G _ H I M E M K E R N E L )
2006-06-26 10:33:05 +04:00
# define R A M _ S T A R T C O N F I G _ R A M B A S E
# define R A M _ L E N G T H C O N F I G _ R A M S I Z E
2006-06-28 10:44:14 +04:00
# define R O M V E C _ S T A R T C O N F I G _ R O M V E C
# define R O M V E C _ L E N G T H C O N F I G _ R O M V E C S I Z E
# define R O M _ S T A R T C O N F I G _ R O M S T A R T
# define R O M _ L E N G T H C O N F I G _ R O M S I Z E
2005-04-17 02:20:36 +04:00
# define T E X T r o m
# define D A T A r a m
# define I N I T r a m
# define B S S r a m
# endif
# ifndef D A T A _ A D D R
# define D A T A _ A D D R
# endif
OUTPUT_ A R C H ( m 6 8 k )
ENTRY( _ s t a r t )
MEMORY {
ram : O R I G I N = R A M _ S T A R T , L E N G T H = R A M _ L E N G T H
# ifdef R O M _ S T A R T
romvec : O R I G I N = R O M V E C _ S T A R T , L E N G T H = R O M V E C _ L E N G T H
rom : O R I G I N = R O M _ S T A R T , L E N G T H = R O M _ L E N G T H
# endif
}
jiffies = j i f f i e s _ 6 4 + 4 ;
SECTIONS {
# ifdef R O M V E C _ S T A R T
. = ROMVEC_ S T A R T ;
.romvec : {
_ _ rom_ s t a r t = . ;
_ romvec = . ;
* ( .data .initvect )
} > romvec
# endif
.text : {
2006-12-07 04:14:04 +03:00
_ text = . ;
2005-04-17 02:20:36 +04:00
_ stext = . ;
2007-05-13 02:31:33 +04:00
TEXT_ T E X T
2005-04-17 02:20:36 +04:00
SCHED_ T E X T
* ( .text .lock )
. = ALIGN( 1 6 ) ; /* Exception table */
_ _ start_ _ _ e x _ t a b l e = . ;
* ( _ _ ex_ t a b l e )
_ _ stop_ _ _ e x _ t a b l e = . ;
* ( .rodata ) * ( .rodata . * )
* ( _ _ vermagic) / * K e r n e l v e r s i o n m a g i c * /
* ( .rodata1 )
* ( .rodata .str1 .1 )
/* Kernel symbol table: Normal symbols */
. = ALIGN( 4 ) ;
_ _ start_ _ _ k s y m t a b = . ;
* ( _ _ ksymtab)
_ _ stop_ _ _ k s y m t a b = . ;
/* Kernel symbol table: GPL-only symbols */
_ _ start_ _ _ k s y m t a b _ g p l = . ;
* ( _ _ ksymtab_ g p l )
_ _ stop_ _ _ k s y m t a b _ g p l = . ;
2007-02-07 04:45:43 +03:00
/* Kernel symbol table: Normal unused symbols */
_ _ start_ _ _ k s y m t a b _ u n u s e d = . ;
* ( _ _ ksymtab_ u n u s e d )
_ _ stop_ _ _ k s y m t a b _ u n u s e d = . ;
/* Kernel symbol table: GPL-only unused symbols */
_ _ start_ _ _ k s y m t a b _ u n u s e d _ g p l = . ;
* ( _ _ ksymtab_ u n u s e d _ g p l )
_ _ stop_ _ _ k s y m t a b _ u n u s e d _ g p l = . ;
2006-03-21 00:17:13 +03:00
/* Kernel symbol table: GPL-future symbols */
_ _ start_ _ _ k s y m t a b _ g p l _ f u t u r e = . ;
* ( _ _ ksymtab_ g p l _ f u t u r e )
_ _ stop_ _ _ k s y m t a b _ g p l _ f u t u r e = . ;
2005-04-17 02:20:36 +04:00
/* Kernel symbol table: Normal symbols */
_ _ start_ _ _ k c r c t a b = . ;
* ( _ _ kcrctab)
_ _ stop_ _ _ k c r c t a b = . ;
/* Kernel symbol table: GPL-only symbols */
_ _ start_ _ _ k c r c t a b _ g p l = . ;
* ( _ _ kcrctab_ g p l )
_ _ stop_ _ _ k c r c t a b _ g p l = . ;
2006-03-21 00:17:13 +03:00
/* Kernel symbol table: GPL-future symbols */
_ _ start_ _ _ k c r c t a b _ g p l _ f u t u r e = . ;
* ( _ _ kcrctab_ g p l _ f u t u r e )
_ _ stop_ _ _ k c r c t a b _ g p l _ f u t u r e = . ;
2005-04-17 02:20:36 +04:00
/* Kernel symbol table: strings */
* ( _ _ ksymtab_ s t r i n g s )
/* Built-in module parameters */
2005-11-07 07:09:50 +03:00
. = ALIGN( 4 ) ;
2005-04-17 02:20:36 +04:00
_ _ start_ _ _ p a r a m = . ;
* ( _ _ param)
_ _ stop_ _ _ p a r a m = . ;
. = ALIGN( 4 ) ;
_ etext = . ;
} > TEXT
.data DATA_ADDR : {
. = ALIGN( 4 ) ;
_ sdata = . ;
2007-05-17 15:38:44 +04:00
DATA_ D A T A
2005-04-17 02:20:36 +04:00
. = ALIGN( 8 1 9 2 ) ;
* ( .data .init_task )
_ edata = . ;
} > DATA
.init : {
. = ALIGN( 4 0 9 6 ) ;
_ _ init_ b e g i n = . ;
_ sinittext = . ;
* ( .init .text )
_ einittext = . ;
* ( .init .data )
. = ALIGN( 1 6 ) ;
_ _ setup_ s t a r t = . ;
* ( .init .setup )
_ _ setup_ e n d = . ;
_ _ initcall_ s t a r t = . ;
2006-10-27 22:41:44 +04:00
INITCALLS
2005-04-17 02:20:36 +04:00
_ _ initcall_ e n d = . ;
_ _ con_ i n i t c a l l _ s t a r t = . ;
* ( .con_initcall .init )
_ _ con_ i n i t c a l l _ e n d = . ;
_ _ security_ i n i t c a l l _ s t a r t = . ;
* ( .security_initcall .init )
_ _ security_ i n i t c a l l _ e n d = . ;
2007-02-10 12:44:44 +03:00
# ifdef C O N F I G _ B L K _ D E V _ I N I T R D
2005-04-17 02:20:36 +04:00
. = ALIGN( 4 ) ;
_ _ initramfs_ s t a r t = . ;
* ( .init .ramfs )
_ _ initramfs_ e n d = . ;
2007-02-10 12:44:44 +03:00
# endif
2005-04-17 02:20:36 +04:00
. = ALIGN( 4 0 9 6 ) ;
_ _ init_ e n d = . ;
} > INIT
/ DISCARD/ : {
* ( .exit .text )
* ( .exit .data )
* ( .exitcall .exit )
}
.bss : {
. = ALIGN( 4 ) ;
_ sbss = . ;
* ( .bss )
* ( COMMON)
. = ALIGN( 4 ) ;
_ ebss = . ;
} > BSS
}