summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorBrandon Low <lostlogic@rockbox.org>2007-10-28 19:19:54 +0000
committerBrandon Low <lostlogic@rockbox.org>2007-10-28 19:19:54 +0000
commit94b133ad332da292f1a78dbede4c96356cc7861f (patch)
tree86a7a2e24b44a1d9edd905fda742a6a0316be984 /apps
parenta8eeff0feefec4b1eec34980d45c87ac544d1778 (diff)
downloadrockbox-94b133ad332da292f1a78dbede4c96356cc7861f.tar.gz
rockbox-94b133ad332da292f1a78dbede4c96356cc7861f.zip
Comment improvements
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15350 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r--apps/buffering.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/apps/buffering.c b/apps/buffering.c
index 0fd0c4c520..dd08b6ce78 100644
--- a/apps/buffering.c
+++ b/apps/buffering.c
@@ -212,9 +212,12 @@ buf_ridx == buf_widx means the buffer is empty.
212/* Add a new handle to the linked list and return it. It will have become the 212/* Add a new handle to the linked list and return it. It will have become the
213 new current handle. 213 new current handle.
214 data_size must contain the size of what will be in the handle. 214 data_size must contain the size of what will be in the handle.
215 On return, it's the size available for the handle.
216 can_wrap tells us whether this type of data may wrap on buffer 215 can_wrap tells us whether this type of data may wrap on buffer
217 alloc_all tells us if we must immediately be able to allocate data_size 216 alloc_all tells us if we must immediately be able to allocate data_size
217 returns a valid memory handle if all conditions for allocation are met.
218 NULL if there memory_handle itself cannot be allocated or if the
219 data_size cannot be allocated and alloc_all is set. This function
220 has no side effects if NULL is returned.
218 */ 221 */
219static struct memory_handle *add_handle(size_t data_size, const bool can_wrap, 222static struct memory_handle *add_handle(size_t data_size, const bool can_wrap,
220 const bool alloc_all) 223 const bool alloc_all)
@@ -578,6 +581,10 @@ static ssize_t buffer_handle(int handle_id)
578 h->filerem -= rc; 581 h->filerem -= rc;
579 582
580 /* Stop buffering if new queue events have arrived */ 583 /* Stop buffering if new queue events have arrived */
584 /* FIXME: This may sleep, if it does it will untrigger the
585 * cpu boost for this thread. If the codec's low data
586 * situation was very short lived that could leave us filling
587 * w/o boost */
581 if (yield_codec()) 588 if (yield_codec())
582 break; 589 break;
583 } 590 }