#1449 closed defect (fixed)
Incorrect implementation of rtems_disk_next() function of libblock library.
Reported by: | Oleg | Owned by: | Chris Johns |
---|---|---|---|
Priority: | lowest | Milestone: | 4.10 |
Component: | lib/block | Version: | 4.10 |
Severity: | trivial | Keywords: | |
Cc: | chrisj@…, nbkolchin@…, sebastian.huber@…, Oleg.Kravtsov@… | Blocked By: | |
Blocking: |
Description
As far as I can see rtems_disk_next() function defined in cpukit/libblock/src/diskdevs.c file assumes that dev_t is a signed integer, which is not good because dev_t should be treated as an abstract type.
rtems_disk_next() function assumes that we know how major and minor numerbs are packed (major is in MSB, and minor in LSB). This not good from portability point of view.
I would recommend to use macro rtems_filesystem_incr_dev_t(dev, amont) for such operations.
Also it woule be nice to use NODEV constant instead of -1 in cases when we start search.
Any opinion?
Attachments (1)
Change History (12)
comment:1 Changed on 10/08/09 at 17:02:07 by Oleg
Cc: | Oleg added |
---|
comment:2 Changed on 10/16/09 at 08:20:10 by Sebastian Huber
Cc: | Sebastian Huber added |
---|
Changed on 10/26/09 at 13:22:41 by Oleg
Attachment: | rtems_disk_next.c added |
---|
comment:3 Changed on 10/26/09 at 13:24:35 by Oleg
Summary: | The function rtems_filesystem_incr_dev_t(dev_t dev, uint32_t amout) is missing → Incorrect implementation of rtems_disk_next() function of libblock library. |
---|
comment:4 Changed on 11/02/09 at 08:52:37 by Oleg
Cc: | Nickolay Semyonov-Kolchin added |
---|
comment:5 Changed on 11/20/09 at 08:55:12 by Sebastian Huber
Cc: | Chris Johns added |
---|
comment:6 Changed on 12/04/09 at 18:03:39 by Joel Sherrill
Owner: | changed from Joel Sherrill to Chris Johns |
---|
comment:7 Changed on 05/14/10 at 03:31:07 by Chris Johns
attachments.ispatch: | 0 → 1 |
---|
comment:8 Changed on 05/14/10 at 03:31:55 by Chris Johns
attachments.ispatch: | 1 → 0 |
---|
comment:9 Changed on 05/15/10 at 07:04:47 by Chris Johns
Status: | new → assigned |
---|
comment:10 Changed on 05/17/10 at 07:08:43 by Sebastian Huber
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Fixed in CVS.
comment:11 Changed on 10/10/17 at 06:49:52 by Sebastian Huber
Component: | score → lib/block |
---|
Note: See
TracTickets for help on using
tickets.
Proposed implementation of rtems_disk_next() function