Skip to content

Commit e1d2dbe

Browse files
philmdrth7680
authored andcommitted
exec/memory_ldst_phys: Sort declarations
To ease the file review, sort the declarations by the size of the access (8, 16, 32). Simple code movement, no logical change. Signed-off-by: Philippe Mathieu-Daudé <[email protected]> Message-Id: <[email protected]> Signed-off-by: Richard Henderson <[email protected]>
1 parent 0a73d7a commit e1d2dbe

File tree

1 file changed

+36
-36
lines changed

1 file changed

+36
-36
lines changed

include/exec/memory_ldst_phys.h.inc

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,12 @@
2020
*/
2121

2222
#ifdef TARGET_ENDIANNESS
23+
static inline uint32_t glue(lduw_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
24+
{
25+
return glue(address_space_lduw, SUFFIX)(ARG1, addr,
26+
MEMTXATTRS_UNSPECIFIED, NULL);
27+
}
28+
2329
static inline uint32_t glue(ldl_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
2430
{
2531
return glue(address_space_ldl, SUFFIX)(ARG1, addr,
@@ -32,10 +38,10 @@ static inline uint64_t glue(ldq_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
3238
MEMTXATTRS_UNSPECIFIED, NULL);
3339
}
3440

35-
static inline uint32_t glue(lduw_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
41+
static inline void glue(stw_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
3642
{
37-
return glue(address_space_lduw, SUFFIX)(ARG1, addr,
38-
MEMTXATTRS_UNSPECIFIED, NULL);
43+
glue(address_space_stw, SUFFIX)(ARG1, addr, val,
44+
MEMTXATTRS_UNSPECIFIED, NULL);
3945
}
4046

4147
static inline void glue(stl_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
@@ -44,18 +50,30 @@ static inline void glue(stl_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
4450
MEMTXATTRS_UNSPECIFIED, NULL);
4551
}
4652

47-
static inline void glue(stw_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
48-
{
49-
glue(address_space_stw, SUFFIX)(ARG1, addr, val,
50-
MEMTXATTRS_UNSPECIFIED, NULL);
51-
}
52-
5353
static inline void glue(stq_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint64_t val)
5454
{
5555
glue(address_space_stq, SUFFIX)(ARG1, addr, val,
5656
MEMTXATTRS_UNSPECIFIED, NULL);
5757
}
5858
#else
59+
static inline uint32_t glue(ldub_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
60+
{
61+
return glue(address_space_ldub, SUFFIX)(ARG1, addr,
62+
MEMTXATTRS_UNSPECIFIED, NULL);
63+
}
64+
65+
static inline uint32_t glue(lduw_le_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
66+
{
67+
return glue(address_space_lduw_le, SUFFIX)(ARG1, addr,
68+
MEMTXATTRS_UNSPECIFIED, NULL);
69+
}
70+
71+
static inline uint32_t glue(lduw_be_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
72+
{
73+
return glue(address_space_lduw_be, SUFFIX)(ARG1, addr,
74+
MEMTXATTRS_UNSPECIFIED, NULL);
75+
}
76+
5977
static inline uint32_t glue(ldl_le_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
6078
{
6179
return glue(address_space_ldl_le, SUFFIX)(ARG1, addr,
@@ -80,22 +98,22 @@ static inline uint64_t glue(ldq_be_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
8098
MEMTXATTRS_UNSPECIFIED, NULL);
8199
}
82100

83-
static inline uint32_t glue(ldub_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
101+
static inline void glue(stb_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
84102
{
85-
return glue(address_space_ldub, SUFFIX)(ARG1, addr,
86-
MEMTXATTRS_UNSPECIFIED, NULL);
103+
glue(address_space_stb, SUFFIX)(ARG1, addr, val,
104+
MEMTXATTRS_UNSPECIFIED, NULL);
87105
}
88106

89-
static inline uint32_t glue(lduw_le_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
107+
static inline void glue(stw_le_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
90108
{
91-
return glue(address_space_lduw_le, SUFFIX)(ARG1, addr,
92-
MEMTXATTRS_UNSPECIFIED, NULL);
109+
glue(address_space_stw_le, SUFFIX)(ARG1, addr, val,
110+
MEMTXATTRS_UNSPECIFIED, NULL);
93111
}
94112

95-
static inline uint32_t glue(lduw_be_phys, SUFFIX)(ARG1_DECL, hwaddr addr)
113+
static inline void glue(stw_be_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
96114
{
97-
return glue(address_space_lduw_be, SUFFIX)(ARG1, addr,
98-
MEMTXATTRS_UNSPECIFIED, NULL);
115+
glue(address_space_stw_be, SUFFIX)(ARG1, addr, val,
116+
MEMTXATTRS_UNSPECIFIED, NULL);
99117
}
100118

101119
static inline void glue(stl_le_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
@@ -110,24 +128,6 @@ static inline void glue(stl_be_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t va
110128
MEMTXATTRS_UNSPECIFIED, NULL);
111129
}
112130

113-
static inline void glue(stb_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
114-
{
115-
glue(address_space_stb, SUFFIX)(ARG1, addr, val,
116-
MEMTXATTRS_UNSPECIFIED, NULL);
117-
}
118-
119-
static inline void glue(stw_le_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
120-
{
121-
glue(address_space_stw_le, SUFFIX)(ARG1, addr, val,
122-
MEMTXATTRS_UNSPECIFIED, NULL);
123-
}
124-
125-
static inline void glue(stw_be_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val)
126-
{
127-
glue(address_space_stw_be, SUFFIX)(ARG1, addr, val,
128-
MEMTXATTRS_UNSPECIFIED, NULL);
129-
}
130-
131131
static inline void glue(stq_le_phys, SUFFIX)(ARG1_DECL, hwaddr addr, uint64_t val)
132132
{
133133
glue(address_space_stq_le, SUFFIX)(ARG1, addr, val,

0 commit comments

Comments
 (0)