[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <04ac8ca2-a54d-48e0-8dc2-e1640aedcb59@wdc.com>
Date: Tue, 3 Feb 2026 11:46:13 +0000
From: Johannes Thumshirn <Johannes.Thumshirn@....com>
To: Xuan Zhuo <xuanzhuo@...ux.alibaba.com>
CC: Alexander Graf <graf@...zon.com>, Jason Wang <jasowang@...hat.com>,
Eugenio Pérez <eperezma@...hat.com>, "open list:VIRTIO
CORE" <virtualization@...ts.linux.dev>, open list
<linux-kernel@...r.kernel.org>, "Michael S . Tsirkin" <mst@...hat.com>
Subject: Re: [PATCH v3] virtio_ring: Add READ_ONCE annotations for
device-writable fields
On 2/3/26 9:29 AM, Xuan Zhuo wrote:
>> +/*
>> + * Accessors for device-writable fields in virtio rings.
>> + * These fields are concurrently written by the device and read by the driver.
>> + * Use READ_ONCE() to prevent compiler optimizations, document the
>> + * intentional data race and prevent KCSAN warnings.
>> + */
>> +static inline u16 vring_read_split_used_idx(const struct vring_virtqueue *vq)
> "inline" is not recommended in *.c files.
>
> Ohters LGTM.
>
> Thanks.
Is it?
johannes@neo:~/src/linux (master)$ git grep -E "\bstatic inline\b"
{arch,drivers,fs,mm}/**.c | wc -l
18295
That's new to me, sorry. But if there's consensus I can re-send the
patch without inline.
Powered by blists - more mailing lists