#1419 closed defect (fixed)

IMFS stat st_dev and st_rdev wrong

Reported by: Chris Johns Owned by: Chris Johns
Priority: normal Milestone: 4.10
Component: fs Version: unknown
Severity: normal Keywords:
Cc: Blocked By:
Blocking:

Description

The IMFS code does:

case IMFS_DEVICE:

io = &the_jnode->info.device;
buf->st_dev = rtems_filesystem_make_dev_t( io->major, io->minor );
break;

to fill in the node, how-ever the SUS states[1]:

dev_t st_dev Device ID of device containing file.
dev_t st_rdev Device ID (if file is character or block special).

This can be seen with the BSD ls command where the nodes are not display correctly. Changing the IMFS to support rdev will break code which is wrong and should be fixed. The MSDOS file system has this code:

vol->dev = stat_buf.st_dev;

I have changed the IMFS to also fill in the st_redev field, but what is the device number for the IMFS itself ?

[1]

http://www.opengroup.org/onlinepubs/009695399/basedefs/sys/stat.h.html

Change History (3)

comment:1 Changed on 05/14/10 at 10:05:16 by Chris Johns

Owner: changed from Joel Sherrill to Chris Johns
Status: newassigned

comment:2 Changed on 05/15/10 at 05:30:50 by Chris Johns

Resolution: fixed
Status: assignedclosed

comment:3 Changed on 05/15/10 at 05:31:21 by Chris Johns

Closed.

Note: See TracTickets for help on using tickets.