blob: 5faad17118b4360b59b6c7456be6a08b96f47c96 [file] [log] [blame]
Vineet Gupta3be80aa2013-01-18 15:12:17 +05301/*
2 * Copyright (C) 2004, 2007-2010, 2011-2012 Synopsys, Inc. (www.synopsys.com)
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation.
7 */
8
9#ifndef __ASM_LINKAGE_H
10#define __ASM_LINKAGE_H
11
12#ifdef __ASSEMBLY__
13
Chen Gang9df62f02014-01-12 09:59:13 +080014#define ASM_NL ` /* use '`' to mark new line in macro */
15
Vineet Gupta8b5850f2013-01-18 15:12:25 +053016/* annotation for data we want in DCCM - if enabled in .config */
17.macro ARCFP_DATA nm
18#ifdef CONFIG_ARC_HAS_DCCM
19 .section .data.arcfp
20#else
21 .section .data
22#endif
23 .global \nm
24.endm
25
26/* annotation for data we want in DCCM - if enabled in .config */
27.macro ARCFP_CODE
28#ifdef CONFIG_ARC_HAS_ICCM
29 .section .text.arcfp, "ax",@progbits
30#else
31 .section .text, "ax",@progbits
32#endif
33.endm
34
35#else /* !__ASSEMBLY__ */
36
37#ifdef CONFIG_ARC_HAS_ICCM
38#define __arcfp_code __attribute__((__section__(".text.arcfp")))
39#else
40#define __arcfp_code __attribute__((__section__(".text")))
41#endif
42
43#ifdef CONFIG_ARC_HAS_DCCM
44#define __arcfp_data __attribute__((__section__(".data.arcfp")))
45#else
46#define __arcfp_data __attribute__((__section__(".data")))
47#endif
48
Vineet Gupta3be80aa2013-01-18 15:12:17 +053049#endif /* __ASSEMBLY__ */
50
51#endif