* [PATCH] io_uring: fix a typo in comment
@ 2022-06-29 14:43 korantwork
2022-06-29 14:46 ` Jens Axboe
0 siblings, 1 reply; 3+ messages in thread
From: korantwork @ 2022-06-29 14:43 UTC (permalink / raw)
To: axboe, asml.silence; +Cc: io-uring, linux-kernel, Xinghui Li
From: Xinghui Li <[email protected]>
fix a typo in comment in io_allocate_scq_urings.
sane -> same.
Signed-off-by: Xinghui Li <[email protected]>
---
fs/io_uring.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/io_uring.c b/fs/io_uring.c
index d3ee4fc532fa..af17adf3fa79 100644
--- a/fs/io_uring.c
+++ b/fs/io_uring.c
@@ -12284,7 +12284,7 @@ static __cold int io_allocate_scq_urings(struct io_ring_ctx *ctx,
struct io_rings *rings;
size_t size, sq_array_offset;
- /* make sure these are sane, as we already accounted them */
+ /* make sure these are same, as we already accounted them */
ctx->sq_entries = p->sq_entries;
ctx->cq_entries = p->cq_entries;
--
2.36.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] io_uring: fix a typo in comment
2022-06-29 14:43 [PATCH] io_uring: fix a typo in comment korantwork
@ 2022-06-29 14:46 ` Jens Axboe
2022-06-30 2:28 ` Xinghui Li
0 siblings, 1 reply; 3+ messages in thread
From: Jens Axboe @ 2022-06-29 14:46 UTC (permalink / raw)
To: korantwork, asml.silence; +Cc: io-uring, linux-kernel, Xinghui Li
On 6/29/22 8:43 AM, [email protected] wrote:
> From: Xinghui Li <[email protected]>
>
> fix a typo in comment in io_allocate_scq_urings.
> sane -> same.
>
> Signed-off-by: Xinghui Li <[email protected]>
> ---
> fs/io_uring.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/io_uring.c b/fs/io_uring.c
> index d3ee4fc532fa..af17adf3fa79 100644
> --- a/fs/io_uring.c
> +++ b/fs/io_uring.c
> @@ -12284,7 +12284,7 @@ static __cold int io_allocate_scq_urings(struct io_ring_ctx *ctx,
> struct io_rings *rings;
> size_t size, sq_array_offset;
>
> - /* make sure these are sane, as we already accounted them */
> + /* make sure these are same, as we already accounted them */
> ctx->sq_entries = p->sq_entries;
> ctx->cq_entries = p->cq_entries;
That's not really a typo, though I can see why you'd think so. It's
trying to say that we need to ensure that the ctx entries are sane,
as they have already been accounted. This means that if we teardown
past this point, they need to be assigned (eg sane) so that we undo
that accounting appropriately.
--
Jens Axboe
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] io_uring: fix a typo in comment
2022-06-29 14:46 ` Jens Axboe
@ 2022-06-30 2:28 ` Xinghui Li
0 siblings, 0 replies; 3+ messages in thread
From: Xinghui Li @ 2022-06-30 2:28 UTC (permalink / raw)
To: Jens Axboe, asml.silence; +Cc: io-uring, linux-kernel, Xinghui Li
On 2022/6/29 22:46,“Jens Axboe”<[email protected]> wrote:
>
> On 6/29/22 8:43 AM, [email protected] wrote:
> > From: Xinghui Li <[email protected]>
> >
> > fix a typo in comment in io_allocate_scq_urings.
> > sane -> same.
> >
> > Signed-off-by: Xinghui Li <[email protected]>
> > ---
> > fs/io_uring.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/fs/io_uring.c b/fs/io_uring.c
> > index d3ee4fc532fa..af17adf3fa79 100644
> > --- a/fs/io_uring.c
> > +++ b/fs/io_uring.c
> > @@ -12284,7 +12284,7 @@ static __cold int io_allocate_scq_urings(struct io_ring_ctx *ctx,
> > struct io_rings *rings;
> > size_t size, sq_array_offset;
> >
> > - /* make sure these are sane, as we already accounted them */
> > + /* make sure these are same, as we already accounted them */
> > ctx->sq_entries = p->sq_entries;
> > ctx->cq_entries = p->cq_entries;
> That's not really a typo, though I can see why you'd think so. It's
> trying to say that we need to ensure that the ctx entries are sane,
> as they have already been accounted. This means that if we teardown
> past this point, they need to be assigned (eg sane) so that we undo
> that accounting appropriately.
Thanks a lot for your reply and I am sorry about wasting your effort. I will try to submit some valuable patches. : - )
--
Xinghui Li
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-06-30 2:29 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-06-29 14:43 [PATCH] io_uring: fix a typo in comment korantwork
2022-06-29 14:46 ` Jens Axboe
2022-06-30 2:28 ` Xinghui Li
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox