static int stream_set_speed(BlockJob *job, int64_t value)

{

    StreamBlockJob *s = container_of(job, StreamBlockJob, common);



    if (value < 0) {

        return -EINVAL;

    }

    ratelimit_set_speed(&s->limit, value / BDRV_SECTOR_SIZE);

    return 0;

}

static int stream_set_speed(BlockJob *job, int64_t value)

{

    StreamBlockJob *s = container_of(job, StreamBlockJob, common);



    if (value < 0) {

        return -EINVAL;

    }

    ratelimit_set_speed(&s->limit, value / BDRV_SECTOR_SIZE);

    return 0;

}

static int FUNC_0(BlockJob *VAR_0, int64_t VAR_1)

{

    StreamBlockJob *s = container_of(VAR_0, StreamBlockJob, common);



    if (VAR_1 < 0) {

        return -EINVAL;

    }

    ratelimit_set_speed(&s->limit, VAR_1 / BDRV_SECTOR_SIZE);

    return 0;

}

static int FUNC_0(BlockJob *VAR_0, int64_t VAR_1)
{ StreamBlockJob *s = container_of(VAR_0, StreamBlockJob, common); if (VAR_1 < 0) { return -EINVAL; } ratelimit_set_speed(&s->limit, VAR_1 / BDRV_SECTOR_SIZE); return 0; }