static device_t* _cast_device(const oe_device_t* device)
{
    device_t* ret = NULL;
    device_t* fs = (device_t*)device;

    if (fs == NULL || fs->magic != FS_MAGIC)
        goto done;

    ret = fs;

done:
    return ret;
}
static device_t* _cast_device(const oe_device_t* device)
{
    device_t* ret = NULL;
    device_t* fs = (device_t*)device;

    if (fs == NULL || fs->magic != FS_MAGIC)
        goto done;

    ret = fs;

done:
    return ret;
}