* Coding style cleanup, pointed out by Andreas.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26815 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler
2008-08-05 13:57:14 +00:00
parent 79f556e5a6
commit c569fd76b4
+18 -15
View File
@@ -1,5 +1,5 @@
/* /*
* Copyright 2004-2007, Haiku. All rights reserved. * Copyright 2004-2008, Haiku. All rights reserved.
* Distributed under the terms of the MIT License. * Distributed under the terms of the MIT License.
* *
* Authors: * Authors:
@@ -14,7 +14,7 @@
static struct { static struct {
uint32 what; uint32 what;
int32 priority; int32 priority;
} gWhatPriorityArray[] = { } sWhatPriorityArray[] = {
// highest priority first // highest priority first
{B_MIDI_PROCESSING, 0x78}, {B_MIDI_PROCESSING, 0x78},
{B_AUDIO_RECORDING | B_AUDIO_PLAYBACK, 0x73}, {B_AUDIO_RECORDING | B_AUDIO_PLAYBACK, 0x73},
@@ -30,28 +30,31 @@ static struct {
{(uint32)-1, -1} {(uint32)-1, -1}
}; };
int32
suggest_thread_priority(uint32 what, int32 period, bigtime_t jitter, bigtime_t length) int32
suggest_thread_priority(uint32 what, int32 period, bigtime_t jitter,
bigtime_t length)
{ {
int i; int i;
int32 priority = what == B_DEFAULT_MEDIA_PRIORITY ? 0x0a : 0; int32 priority = what == B_DEFAULT_MEDIA_PRIORITY ? 0x0a : 0;
// default priority // default priority
for (i = 0; gWhatPriorityArray[i].what != (uint32)-1; i ++) { for (i = 0; sWhatPriorityArray[i].what != (uint32)-1; i ++) {
if ((what & gWhatPriorityArray[i].what) != 0) { if ((what & sWhatPriorityArray[i].what) != 0) {
priority = gWhatPriorityArray[i].priority; priority = sWhatPriorityArray[i].priority;
break; break;
} }
} }
return priority; return priority;
} }
bigtime_t
estimate_max_scheduling_latency(thread_id th) bigtime_t
estimate_max_scheduling_latency(thread_id thread)
{ {
if (th == -1) if (thread == -1)
th = find_thread(NULL); thread = find_thread(NULL);
return 0; return 0;
} }