On Thu, Feb 18, 2021 at 8:56 AM Joel Sherrill <j...@rtems.org> wrote:
>
> Hi
>
> There are a lot of Coverity issues related to device drivers which call 
> mkdir("/dev") and ignore the return value. My first thought was that they 
> should have (void) added since /dev could have been created by an earlier 
> driver.
>
> Then it occurred to me that libcsupport/src/base_fs.c includes mkdir("/dev") 
> and a fatal error if it cannot create it.
>
> Doesn't this mean that every call to mkdir("/dev") in a BSP or device driver 
> is redundant? They should be removed since the base FS contents are always in 
> place before any device drivers are called.
>
> Thoughts?
>

Seems reasonable. You could probably add an assert that /dev exists.

> --joel
> _______________________________________________
> devel mailing list
> devel@rtems.org
> http://lists.rtems.org/mailman/listinfo/devel
_______________________________________________
devel mailing list
devel@rtems.org
http://lists.rtems.org/mailman/listinfo/devel

Reply via email to