@@ -169,11 +169,11 @@ struct elfloader_output {
169
169
};
170
170
171
171
/**
172
- * \brief Allocate a new segment
173
- * \param input The output object
174
- * \param type Type of segment
175
- * \param size Size of segment in bytes
176
- * \return A pointer to the start of the segment.
172
+ * \brief Allocate a new segment
173
+ * \param output The output object
174
+ * \param type Type of segment
175
+ * \param size Size of segment in bytes
176
+ * \return A pointer to the start of the segment.
177
177
*
178
178
* The returned address doesn't need to correspond to any real memory,
179
179
* since it's only used for calculating the relocations.
@@ -182,39 +182,39 @@ void *elfloader_allocate_segment(struct elfloader_output *output,
182
182
unsigned int type , int size );
183
183
184
184
/**
185
- * \brief Start writing to a new segment
186
- * \param input The output object
187
- * \param type Type of segment
188
- * \param addr Address of segment from elfloader_allocate_segment
189
- * \param size Size of segment in bytes
190
- * \return Returns ELFLOADER_OK if successful, otherwise an error code
185
+ * \brief Start writing to a new segment
186
+ * \param output The output object
187
+ * \param type Type of segment
188
+ * \param addr Address of segment from elfloader_allocate_segment
189
+ * \param size Size of segment in bytes
190
+ * \return Returns ELFLOADER_OK if successful, otherwise an error code
191
191
*
192
192
*/
193
193
int elfloader_start_segment (struct elfloader_output * output ,
194
194
unsigned int type , void * addr , int size );
195
195
196
196
/**
197
- * \brief Mark end of segment
198
- * \param input The output object
199
- * \return Zero if successful
197
+ * \brief Mark end of segment
198
+ * \param output The output object
199
+ * \return Zero if successful
200
200
*/
201
201
int elfloader_end_segment (struct elfloader_output * output );
202
202
203
203
/**
204
- * \brief Write data to a segment
205
- * \param input The output object
206
- * \param buf Data to be written
207
- * \param len Length of data
208
- * \return The number of bytes actually written, or negative if failed.
204
+ * \brief Write data to a segment
205
+ * \param output The output object
206
+ * \param buf Data to be written
207
+ * \param len Length of data
208
+ * \return The number of bytes actually written, or negative if failed.
209
209
*/
210
210
int elfloader_write_segment (struct elfloader_output * output , const char * buf ,
211
211
unsigned int len );
212
212
213
213
/**
214
- * \brief Get the current offset in the file where the next data will
215
- * be written.
216
- * \param input The output object
217
- * \return The current offset.
214
+ * \brief Get the current offset in the file where the next data will
215
+ * be written.
216
+ * \param output The output object
217
+ * \return The current offset.
218
218
*/
219
219
unsigned int elfloader_segment_offset (struct elfloader_output * output );
220
220
@@ -255,8 +255,8 @@ void elfloader_init(void);
255
255
256
256
/**
257
257
* \brief Load and relocate an ELF file.
258
- * \param input Input object defining how to read from the ELF file
259
- * \param output Output object defining how to create and write to seegments.
258
+ * \param input_fd Input object defining how to read from the ELF file
259
+ * \param output Output object defining how to create and write to seegments.
260
260
* \return ELFLOADER_OK if loading and relocation worked.
261
261
* Otherwise an error value.
262
262
*
0 commit comments