Janosch Reinking created an issue: 
https://gitlab.rtems.org/rtems/rtos/rtems/-/issues/5402



## Summary

When initializing a single block device with `rtems_nvdisk_initialize()`, the 
device is mounted at `/dev/nvda`. For any further device, the base name 
(`/dev/nvda`) should have its last letter incremented by the device index (i.e. 
`/dev/nvdb`, ...). However, instead of incrementing the last letter, the 
function increments the null-terminator. This results in corrupted device names.

```cpp
char     name[] = RTEMS_NVDISK_DEVICE_BASE_NAME "a";
uint32_t device;
uint32_t blocks = 0;

name [sizeof(RTEMS_NVDISK_DEVICE_BASE_NAME)] += i;
```

-- 
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/issues/5402
You're receiving this email because of your account on gitlab.rtems.org.


_______________________________________________
bugs mailing list
[email protected]
http://lists.rtems.org/mailman/listinfo/bugs

Reply via email to