lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAHp75Ve46P=TYk0pzHFsYXjkKX92K2=NO5Krqy2uo_7HG=DWCA@mail.gmail.com>
Date:   Tue, 7 Apr 2020 00:57:43 +0300
From:   Andy Shevchenko <andy.shevchenko@...il.com>
To:     "Michael S. Tsirkin" <mst@...hat.com>
Cc:     Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Andy Shevchenko <andy@...radead.org>,
        Darren Hart <dvhart@...radead.org>,
        Vadim Pasternak <vadimp@...lanox.com>,
        Platform Driver <platform-driver-x86@...r.kernel.org>
Subject: Re: [PATCH v5 12/12] mellanox: switch to virtio_legacy_init/size

On Tue, Apr 7, 2020 at 12:35 AM Michael S. Tsirkin <mst@...hat.com> wrote:
>
> These are used for legacy ring format, switch to APIs that make this
> explicit.
>

Acked-by: Andy Shevchenko <andy.shevchenko@...il.com>

> Signed-off-by: Michael S. Tsirkin <mst@...hat.com>
> ---
>
> maintainers, pls ack merging this through virtio tree due to dependency
> on previous patches in the patchset.

Here you are!

>
>  drivers/platform/mellanox/mlxbf-tmfifo.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/platform/mellanox/mlxbf-tmfifo.c b/drivers/platform/mellanox/mlxbf-tmfifo.c
> index 5739a9669b29..f42b1fb713f1 100644
> --- a/drivers/platform/mellanox/mlxbf-tmfifo.c
> +++ b/drivers/platform/mellanox/mlxbf-tmfifo.c
> @@ -214,7 +214,7 @@ static void mlxbf_tmfifo_free_vrings(struct mlxbf_tmfifo *fifo,
>         for (i = 0; i < ARRAY_SIZE(tm_vdev->vrings); i++) {
>                 vring = &tm_vdev->vrings[i];
>                 if (vring->va) {
> -                       size = vring_size(vring->num, vring->align);
> +                       size = vring_legacy_size(vring->num, vring->align);
>                         dma_free_coherent(tm_vdev->vdev.dev.parent, size,
>                                           vring->va, vring->dma);
>                         vring->va = NULL;
> @@ -245,7 +245,7 @@ static int mlxbf_tmfifo_alloc_vrings(struct mlxbf_tmfifo *fifo,
>                 vring->vdev_id = tm_vdev->vdev.id.device;
>                 dev = &tm_vdev->vdev.dev;
>
> -               size = vring_size(vring->num, vring->align);
> +               size = vring_legacy_size(vring->num, vring->align);
>                 va = dma_alloc_coherent(dev->parent, size, &dma, GFP_KERNEL);
>                 if (!va) {
>                         mlxbf_tmfifo_free_vrings(fifo, tm_vdev);
> @@ -935,7 +935,7 @@ static int mlxbf_tmfifo_virtio_find_vqs(struct virtio_device *vdev,
>                 vring = &tm_vdev->vrings[i];
>
>                 /* zero vring */
> -               size = vring_size(vring->num, vring->align);
> +               size = vring_legacy_size(vring->num, vring->align);
>                 memset(vring->va, 0, size);
>                 vq = vring_new_virtqueue(i, vring->num, vring->align, vdev,
>                                          false, false, vring->va,
> --
> MST
>


-- 
With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ