Lines Matching defs:length
28 size_t length;
76 long semihosting_file_read(long file_handle, size_t *length, uintptr_t buffer)
81 if ((length == NULL) || (buffer == (uintptr_t)NULL)) {
87 read_block.length = *length;
91 if (result == *length) {
93 } else if (result < *length) {
94 *length -= result;
101 long semihosting_file_write(long file_handle, size_t *length,
107 if ((length == NULL) || (buffer == (uintptr_t)NULL)) {
113 write_block.length = *length;
118 *length = result;
162 long length;
171 /* Find the length of the file */
172 length = semihosting_file_length(file_handle);
174 return (semihosting_file_close(file_handle) != 0) ? -1 : length;
182 size_t length;
197 /* Find the actual length of the file */
198 length = semihosting_file_length(file_handle);
199 if (length == (size_t)(-1)) {
204 if (length > buf_size) {
213 ret = semihosting_file_read(file_handle, &length, buf);
217 ret = (long)length;