| 324 | } |
| 325 | |
| 326 | static int _sys_ptmx_init(void) |
| 327 | { |
| 328 | rt_err_t rc; |
| 329 | rt_device_t sysptmx_rtdev = &sysptmx; |
| 330 | |
| 331 | /* setup system level device */ |
| 332 | sysptmx_rtdev->type = RT_Device_Class_Char; |
| 333 | sysptmx_rtdev->ops = RT_NULL; |
| 334 | rc = rt_device_register(sysptmx_rtdev, "ptmx", RT_DEVICE_FLAG_DYNAMIC); |
| 335 | if (rc == RT_EOK) |
| 336 | { |
| 337 | sysptmx_rtdev->readlink = &sysptmx_readlink; |
| 338 | sysptmx_rtdev->fops = &sysptmx_file_ops; |
| 339 | } |
| 340 | return rc; |
| 341 | } |
| 342 | INIT_DEVICE_EXPORT(_sys_ptmx_init); |
nothing calls this directly
no test coverage detected