Fix minor spacing problems from 1017 and 1018

This commit is contained in:
Gregory Nutt
2020-05-09 14:08:44 -06:00
committed by Abdelatif Guettouche
parent 3ac629bdfb
commit fbbf1dffaf
5 changed files with 20 additions and 35 deletions
+2 -2
View File
@@ -37,7 +37,7 @@ SYSCALL_LOOKUP(sched_setparam, 2)
SYSCALL_LOOKUP(sched_setscheduler, 3)
SYSCALL_LOOKUP(sched_unlock, 0)
SYSCALL_LOOKUP(sched_yield, 0)
SYSCALL_LOOKUP(nxsched_get_stackinfo, 2)
SYSCALL_LOOKUP(nxsched_get_stackinfo, 2)
#ifdef CONFIG_SMP
SYSCALL_LOOKUP(sched_getaffinity, 3)
@@ -256,7 +256,7 @@ SYSCALL_LOOKUP(telldir, 1)
#if CONFIG_NFILE_STREAMS > 0
SYSCALL_LOOKUP(fs_fdopen, 3)
SYSCALL_LOOKUP(nxsched_get_streams, 0)
SYSCALL_LOOKUP(nxsched_get_streams, 0)
#endif
#ifdef CONFIG_NET_SENDFILE
+2 -2
View File
@@ -373,7 +373,7 @@ bool nxsched_add_readytorun(FAR struct tcb_s *rtrtcb);
bool nxsched_remove_readytorun(FAR struct tcb_s *rtrtcb);
bool nxsched_add_prioritized(FAR struct tcb_s *tcb, DSEG dq_queue_t *list);
void nxsched_merge_prioritized(FAR dq_queue_t *list1, FAR dq_queue_t *list2,
uint8_t task_state);
uint8_t task_state);
bool nxsched_merge_pending(void);
void nxsched_add_blocked(FAR struct tcb_s *btcb, tstate_t task_state);
void nxsched_remove_blocked(FAR struct tcb_s *btcb);
@@ -415,7 +415,7 @@ int nxsched_reset_sporadic(FAR struct tcb_s *tcb);
int nxsched_resume_sporadic(FAR struct tcb_s *tcb);
int nxsched_suspend_sporadic(FAR struct tcb_s *tcb);
uint32_t nxsched_process_sporadic(FAR struct tcb_s *tcb, uint32_t ticks,
bool noswitches);
bool noswitches);
void nxsched_sporadic_lowpriority(FAR struct tcb_s *tcb);
#endif
+2 -2
View File
@@ -274,8 +274,8 @@ bool nxsched_merge_pending(void)
*/
nxsched_merge_prioritized((FAR dq_queue_t *)&g_pendingtasks,
(FAR dq_queue_t *)&g_readytorun,
TSTATE_TASK_READYTORUN);
(FAR dq_queue_t *)&g_readytorun,
TSTATE_TASK_READYTORUN);
}
errout_with_lock:
+1 -1
View File
@@ -61,7 +61,7 @@
****************************************************************************/
void nxsched_merge_prioritized(FAR dq_queue_t *list1, FAR dq_queue_t *list2,
uint8_t task_state)
uint8_t task_state)
{
dq_queue_t clone;
FAR struct tcb_s *tcb1;
+13 -28
View File
@@ -1,35 +1,20 @@
/****************************************************************************
* sched/sched/sched_roundrobin.c
*
* Copyright (C) 2007, 2009, 2014-2016 Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership. The
* ASF licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the
* License. You may obtain a copy of the License at
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* http://www.apache.org/licenses/LICENSE-2.0
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
* 3. Neither the name NuttX nor the names of its contributors may be
* used to endorse or promote products derived from this software
* without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
* COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
* OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
* AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*
****************************************************************************/
@@ -97,7 +82,7 @@
****************************************************************************/
uint32_t nxsched_process_roundrobin(FAR struct tcb_s *tcb, uint32_t ticks,
bool noswitches)
bool noswitches)
{
uint32_t ret;
int decr;