diff --git a/arch/rgmp/src/rgmp.c b/arch/rgmp/src/rgmp.c index 40bbed971e..104591752d 100644 --- a/arch/rgmp/src/rgmp.c +++ b/arch/rgmp/src/rgmp.c @@ -56,7 +56,10 @@ int nest_irq = 0; -// the default time is 10ms +// The default time is 10ms +// REVISIT: tick time is given by CONFIG_USEC_PER_TICK. MSEC_PER_TICK may +// be zero. + #ifdef MSEC_PER_TICK const unsigned int rtos_tick_time = MSEC_PER_TICK; #else diff --git a/drivers/net/slip.c b/drivers/net/slip.c index 8b6af8d62d..07fac24fc3 100644 --- a/drivers/net/slip.c +++ b/drivers/net/slip.c @@ -1,7 +1,7 @@ /**************************************************************************** * drivers/net/slip.c * - * Copyright (C) 2011-2012, 2015 Gregory Nutt. All rights reserved. + * Copyright (C) 2011-2012, 2015-2016 Gregory Nutt. All rights reserved. * Author: Gregory Nutt * * Reference: RFC 1055 @@ -485,8 +485,8 @@ static void slip_txtask(int argc, FAR char *argv[]) /* Has a half second elapsed since the last timer poll? */ now_ticks = clock_systimer(); - hsec = (unsigned int)(now_ticks - start_ticks) / TICK_PER_HSEC; - if (hsec) + hsec = (unsigned int)((now_ticks - start_ticks) / TICK_PER_HSEC); + if (hsec > 0) { /* Yes, perform the timer poll */