Changeset d949482 in rtems


Ignore:
Timestamp:
Nov 12, 2009, 4:34:24 PM (10 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Branches:
4.10, 4.11, master
Children:
d093934
Parents:
b27799c
Message:

2009-11-12 Ralf Corsépius <ralf.corsepius@…>

  • libchip/ide/ata.c (rtems_ata_initialize): Avoid implicit cast to uint16_t.
Location:
c/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • c/src/ChangeLog

    rb27799c rd949482  
    112009-11-12      Ralf Corsépius <ralf.corsepius@rtems.org>
    22
     3        * libchip/ide/ata.c (rtems_ata_initialize): Avoid implicit cast to uint16_t.
    34        * libchip/ide/ata.c (ata_non_data_request): Change arg from int to
    45        uint32_t (16bit ints are too small).
  • c/src/libchip/ide/ata.c

    rb27799c rd949482  
    14061406            ATA_DEV_INFO(ctrl_minor, dev).sectors =
    14071407                CF_LE_W(buffer[ATA_IDENT_WORD_NUM_OF_CURR_LOG_SECS]);
    1408             ATA_DEV_INFO(ctrl_minor, dev).lba_sectors =
    1409                 (CF_LE_W(buffer[ATA_IDENT_WORD_NUM_OF_USR_SECS1]) << 16) +
    1410                  CF_LE_W(buffer[ATA_IDENT_WORD_NUM_OF_USR_SECS0]);
     1408            ATA_DEV_INFO(ctrl_minor, dev).lba_sectors =
     1409                CF_LE_W(buffer[ATA_IDENT_WORD_NUM_OF_USR_SECS1]);
     1410            ATA_DEV_INFO(ctrl_minor, dev).lba_sectors <<= 16;
     1411            ATA_DEV_INFO(ctrl_minor, dev).lba_sectors += CF_LE_W(buffer[ATA_IDENT_WORD_NUM_OF_USR_SECS0]);
    14111412            ATA_DEV_INFO(ctrl_minor, dev).lba_avaible =
    14121413                (CF_LE_W(buffer[ATA_IDENT_WORD_CAPABILITIES]) >> 9) & 0x1;
Note: See TracChangeset for help on using the changeset viewer.