[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAKWSiC5-Oqwf0TEndxbNZqCp2Z+kxq95MebDfNRNJ0fN5fWnKw@mail.gmail.com>
Date: Thu, 22 May 2025 01:17:06 +0530
From: Siddarth Gundu <siddarthsgml@...il.com>
To: Alex Elder <elder@...e.org>
Cc: idryomov@...il.com, dongsheng.yang@...ystack.cn, axboe@...nel.dk,
ceph-devel@...r.kernel.org, linux-block@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] rbd: replace strcpy() with strscpy()
On Tue, May 20, 2025 at 10:14 PM Alex Elder <elder@...e.org> wrote:
> I personally think the typedef here is the appropriate. But
> it's really up to Ilya whether he likes this approach. Get
> his input before you do more.
right, understood.
> There's a basic question about whether this is a useful
> abstraction. It's used for "lock cookies" but do they
> serve a broader purpose?
>
> The other part of my suggestion was to define functions that
> provide an API. For example:
>
> static inline rbd_cookie_t rbd_cookie_set(rbd_cookie_t cookie, u64 id);
> static inline u64 rbd_cookie_get(rbd_cookie_t cookie);
I see, I will try implementing such functions. Because of
using typedef I made minimal code changes.
Thanks for the detailed input
> Anyway, before I say any more let's see if Ilya even wants
> to go in this direction. Your original proposal was OK, I
> just thought specifying the length might be safer.
Alright, I'll wait for feedback before making
any changes.
Thanks for taking time to review the patch
--
With Gratitude
Siddarth Gundu
Powered by blists - more mailing lists