Changeset b3bbcdf1 in rtems


Ignore:
Timestamp:
Sep 5, 2008, 2:42:48 PM (11 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Branches:
4.10, 4.11, 4.9, master
Children:
94130db
Parents:
e0487ed
Message:

Convert to "bool".

Location:
c/src/lib/libbsp/powerpc/gen5200/i2c
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/powerpc/gen5200/i2c/i2c.c

    re0487ed rb3bbcdf1  
    4141i2c_transfer_poll_done_func(uint32_t         arg)
    4242{
    43     rtems_boolean *poll_done_flag = (rtems_boolean *)arg;
    44     *poll_done_flag = 1;
     43    bool *poll_done_flag = (bool *)arg;
     44    *poll_done_flag = true;
    4545}
    4646
     
    9999i2c_transfer_wait_poll(i2c_bus_number bus, i2c_message *msg, int nmsg)
    100100{
    101     volatile rtems_boolean poll_done_flag;
     101    volatile bool poll_done_flag;
    102102    rtems_status_code sc;
    103     poll_done_flag = 0;
     103    poll_done_flag = false;
    104104    sc = i2c_transfer(bus, nmsg, msg, i2c_transfer_poll_done_func,
    105105                      (uint32_t)&poll_done_flag);
    106106    if (sc != RTEMS_SUCCESSFUL)
    107107        return sc;
    108     while (poll_done_flag == 0)
     108    while (poll_done_flag == false)
    109109    {
    110110        i2c_poll(bus);
  • c/src/lib/libbsp/powerpc/gen5200/i2c/i2cdrv.c

    re0487ed rb3bbcdf1  
    8787
    8888/* MBus I2C bus controller busy flag */
    89 static volatile rtems_boolean mbus_busy;
     89static volatile bool mbus_busy;
    9090
    9191/* MBus I2C bus controller descriptor */
     
    113113    rtems_interrupt_disable(level);
    114114    tqueue_tail = (tqueue_tail + 1) % tqueue_size;
    115     mbus_busy = 0;
     115    mbus_busy = false;
    116116    rtems_interrupt_enable(level);
    117117    i2cdrv_unload();
     
    131131    if (!mbus_busy && (tqueue_head != tqueue_tail))
    132132    {
    133         mbus_busy = 1;
     133        mbus_busy = true;
    134134        rtems_interrupt_enable(level);
    135135        qel = tqueue + tqueue_tail;
     
    220220    int i;
    221221    rtems_status_code sc;
    222     mbus_busy = 0;
     222    mbus_busy = false;
    223223    tqueue_tail = tqueue_head = 0;
    224224    tqueue_size = 32;
Note: See TracChangeset for help on using the changeset viewer.