[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RFC] hw/net/vmxnet3: allow VMXNET3_MAX_MTU itself as a value
From: |
P J P |
Subject: |
Re: [RFC] hw/net/vmxnet3: allow VMXNET3_MAX_MTU itself as a value |
Date: |
Thu, 25 Aug 2022 07:12:57 +0000 (UTC) |
On Wednesday, 24 August, 2022, 04:46:21 pm IST, Fiona Ebner
<f.ebner@proxmox.com> wrote:
>Reported by one of our users running into the failing assert():
>https://forum.proxmox.com/threads/114011/#post-492916
>
>- assert(VMXNET3_MIN_MTU <= s->mtu && s->mtu < VMXNET3_MAX_MTU);
>+ assert(VMXNET3_MIN_MTU <= s->mtu && s->mtu <= VMXNET3_MAX_MTU);
> VMW_CFPRN("MTU is %u", s->mtu);
>
* I wonder if setting s->mtu == buffer_upper_limit may lead to an out-of-bounds
access issue?
* IIUC, VMXNET3_MAX_MTU OR s->mtu does not seem to be used to allocate and/or
access packet buffer(s)
so above check might work, but still it does not seem clean, ie. it may lead
to some confusion.
* Nonetheless, Jason has acked it, so that's good.
Thank you.
---
-P J P
http://feedmug.com