提交 3126b45d 编写于 作者: B bernard.xiong@gmail.com

Remove divide instructions.

git-svn-id: https://rt-thread.googlecode.com/svn/trunk@1477 bbd45198-f89e-11dd-88c7-29a3b14d5316
上级 0513333a
......@@ -1398,7 +1398,7 @@ rt_err_t rt_mb_send_wait (rt_mailbox_t mb, rt_uint32_t value, rt_int32_t timeout
mb->msg_pool[mb->in_offset] = value;
/* increase input offset */
++ mb->in_offset;
mb->in_offset %= mb->size;
if (mb->in_offset > mb->size) mb->in_offset = 0;
/* increase message entry */
mb->entry ++;
......@@ -1529,7 +1529,7 @@ rt_err_t rt_mb_recv (rt_mailbox_t mb, rt_uint32_t* value, rt_int32_t timeout)
/* increase output offset */
++mb->out_offset;
mb->out_offset %= mb->size;
if (mb->out_offset > mb->size) mb->out_offset = 0;
/* decrease message entry */
mb->entry --;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册