From nobody Mon Apr 13 12:01:13 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 30A47C742A7 for ; Tue, 7 Mar 2023 20:39:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230122AbjCGUjN (ORCPT ); Tue, 7 Mar 2023 15:39:13 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59922 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230110AbjCGUjI (ORCPT ); Tue, 7 Mar 2023 15:39:08 -0500 Received: from gnuweeb.org (gnuweeb.org [51.81.211.47]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BC52D97FD4; Tue, 7 Mar 2023 12:39:06 -0800 (PST) Received: from localhost.localdomain (unknown [182.253.183.169]) by gnuweeb.org (Postfix) with ESMTPSA id 0E7467E3C0; Tue, 7 Mar 2023 20:39:03 +0000 (UTC) X-GW-Data: lPqxHiMPbJw1wb7CM9QUryAGzr0yq5atzVDdxTR0iA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gnuweeb.org; s=default; t=1678221546; bh=Mp/rhC8HIg+j7inL/6xYeQll6B81fY9c8V1MheagYO0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Q3+HBuyqNpRf7N/ZrB56nQ1bmLN/VsgZ6aPzZHMukxR3xjgEHB9cDMcDBZagHCDGD klH41erNqp0897Ja5Kz94Ib/Vk7YIX7jlURUcxNARHdDjvXUF9D4as5DDebu5olOAM YE+MnCAMxZQEaGT2Mm7V2wzt7u8jVw7n9aqWkKXZR4n8pUBQ+jD25bjlkR3i2epe/V qnJx7BOhMjzZgO0TUFX90M09J5l95MRqdOwymOr1408RLKK0jgaHXMsyLXM9xq3Kta u8D0F2em8kQe9Ac8qDC4GtVxhOBduBGnk0JvXgp33rRxFn8LHdiT13xFmimymLxzvS nex/jJS57MSEg== From: Ammar Faizi To: Jens Axboe Cc: Pavel Begunkov , io-uring Mailing List , Linux Kernel Mailing List , Ammar Faizi , Dylan Yudaken Subject: [PATCH liburing v1 1/3] io_uring-udp: Fix the wrong `inet_ntop()` argument Date: Wed, 8 Mar 2023 03:38:28 +0700 Message-Id: <20230307203830.612939-2-ammarfaizi2@gnuweeb.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230307203830.612939-1-ammarfaizi2@gnuweeb.org> References: <20230307203830.612939-1-ammarfaizi2@gnuweeb.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" The verbose output shows the wrong IP address. The second argument of inet_ntop() should be a pointer to the binary representation of the IP address. Fix it. Reported-by: @mczka # A GitHub user Cc: Dylan Yudaken Closes: https://github.com/axboe/liburing/pull/815 Fixes: https://github.com/axboe/liburing/issues/814 Fixes: 61d472b51e761e61c ("add an example for a UDP server") Signed-off-by: Ammar Faizi --- examples/io_uring-udp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/io_uring-udp.c b/examples/io_uring-udp.c index a07c3e2a6f20cd17..b81a5e7c47afd9c8 100644 --- a/examples/io_uring-udp.c +++ b/examples/io_uring-udp.c @@ -275,7 +275,7 @@ static int process_cqe_recv(struct ctx *ctx, struct io_= uring_cqe *cqe, const char *name; struct sockaddr_in *addr =3D io_uring_recvmsg_name(o); =20 - name =3D inet_ntop(ctx->af, addr, buff, sizeof(buff)); + name =3D inet_ntop(ctx->af, &addr->sin_addr, buff, sizeof(buff)); if (!name) name =3D ""; fprintf(stderr, "received %u bytes %d from %s:%d\n", --=20 Ammar Faizi From nobody Mon Apr 13 12:01:13 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 26B40C678D5 for ; Tue, 7 Mar 2023 20:39:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230178AbjCGUjP (ORCPT ); Tue, 7 Mar 2023 15:39:15 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59926 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230131AbjCGUjK (ORCPT ); Tue, 7 Mar 2023 15:39:10 -0500 Received: from gnuweeb.org (gnuweeb.org [51.81.211.47]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 834369E313; Tue, 7 Mar 2023 12:39:09 -0800 (PST) Received: from localhost.localdomain (unknown [182.253.183.169]) by gnuweeb.org (Postfix) with ESMTPSA id 299A57E3B6; Tue, 7 Mar 2023 20:39:06 +0000 (UTC) X-GW-Data: lPqxHiMPbJw1wb7CM9QUryAGzr0yq5atzVDdxTR0iA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gnuweeb.org; s=default; t=1678221549; bh=IMx6ex/rLOT7NC83zfmminX+0WNHq9zZx2/kJgKw2Tg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=QVtjiYbraMVInnsXLwgoKvRSu7RfnslcwMXXpOVDqm/ejLHCNPNL+peOOANIdNzJW ie4r93BrZij+zgb+gpoksSRINt7xLjldGvM60J6YsIoMZRHog5ZhTuG2hzr33gyuBX B7IVtJU7Bjpb6hI9O4mxJvGoHcz9XMi15G9MOD8Q9LPg3nEQbXO5uno8q8/4Zq0kqY SlzrOHbLlQ87iKxi8xA/LtZlVXsJOA2akeffdWi7RATpAR7lndHGVXyoOFD29ahI2H qmX4K0AqsfSnaOKyWB6Te3qfCbsVYoziw6LBYrtcDPaExrGTbQjvAGb9DastU1obPw VDQzActboGFAg== From: Ammar Faizi To: Jens Axboe Cc: Pavel Begunkov , io-uring Mailing List , Linux Kernel Mailing List , Ammar Faizi Subject: [PATCH liburing v1 2/3] github: Append `-Wno-sign-compare` to the GitHub build bot CFLAGS Date: Wed, 8 Mar 2023 03:38:29 +0700 Message-Id: <20230307203830.612939-3-ammarfaizi2@gnuweeb.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230307203830.612939-1-ammarfaizi2@gnuweeb.org> References: <20230307203830.612939-1-ammarfaizi2@gnuweeb.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Kill the sign-compare warning on the GitHub build bot because Jens doesn't like it. See commit 4c79857b9354 ("examples/send-zerocopy: cleanups"). Signed-off-by: Ammar Faizi --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 29b80bfec1d208c0..fed5b38c3a507336 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -86,7 +86,7 @@ jobs: cxx: mips-linux-gnu-g++ =20 env: - FLAGS: -g -O3 -Wall -Wextra -Werror ${{matrix.extra_flags}} + FLAGS: -g -O3 -Wall -Wextra -Werror -Wno-sign-compare ${{matrix.extr= a_flags}} =20 # Flags for building sources in src/ dir only. LIBURING_CFLAGS: ${{matrix.liburing_extra_flags}} --=20 Ammar Faizi From nobody Mon Apr 13 12:01:13 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0B8AAC742A7 for ; Tue, 7 Mar 2023 20:39:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230290AbjCGUjZ (ORCPT ); Tue, 7 Mar 2023 15:39:25 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60646 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230389AbjCGUjV (ORCPT ); Tue, 7 Mar 2023 15:39:21 -0500 Received: from gnuweeb.org (gnuweeb.org [51.81.211.47]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B91E999273; Tue, 7 Mar 2023 12:39:12 -0800 (PST) Received: from localhost.localdomain (unknown [182.253.183.169]) by gnuweeb.org (Postfix) with ESMTPSA id ECC2D7E3C0; Tue, 7 Mar 2023 20:39:09 +0000 (UTC) X-GW-Data: lPqxHiMPbJw1wb7CM9QUryAGzr0yq5atzVDdxTR0iA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gnuweeb.org; s=default; t=1678221552; bh=CsORVV9sXXTWCJ7OUgvpgf+wT1IVTb5A5E+oXyKczKw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=hpnP3sP2Qs+MeTu23VU2NMj+Eu2P6MdRvpdfDH/WII0Uh/v/VAhDfU51kn+D+q/MB yDNKGuZwwxfcgXElFX3xw1m/N4u4p2sEE89EAmoaDPn6Y0ayIOW6zfB4GKmh1IFLTX QRP1ZlHhTSelK2T5w89iek6i+lnhgV7RnHd4sIrN3EAVnjkf8MjDvxMwpYF6+dxt34 wBYcEWo6VmFu8/eXd8FKIEJA3f9tTz7L+wuTxmY0HaBPLcEHqKqMyxzpeIBuHp7xAr gJqPlM6ttf3W7kuJeq4B3l3jmri9XpXwb9mFxjO4+bna89NIrpZmAaHiLIF7RIWK0T P6/Nu4WFvz0ZA== From: Ammar Faizi To: Jens Axboe Cc: Pavel Begunkov , io-uring Mailing List , Linux Kernel Mailing List , Ammar Faizi , Rutvik Patel Subject: [PATCH liburing v1 3/3] man/io_uring_register_{buffers,files}: Kill trailing whitespaces Date: Wed, 8 Mar 2023 03:38:30 +0700 Message-Id: <20230307203830.612939-4-ammarfaizi2@gnuweeb.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230307203830.612939-1-ammarfaizi2@gnuweeb.org> References: <20230307203830.612939-1-ammarfaizi2@gnuweeb.org> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Kill trailing whitespaces introduced in e628f65b6a6e and e709d2cf2f39. The "git am" would have noticed this, but those commits were merged via a pull request. Cc: Rutvik Patel Signed-off-by: Ammar Faizi --- man/io_uring_register_buffers.3 | 10 +++++----- man/io_uring_register_files.3 | 22 +++++++++++----------- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/man/io_uring_register_buffers.3 b/man/io_uring_register_buffer= s.3 index 4f7d25a9fc1a887c..00861d917ed08566 100644 --- a/man/io_uring_register_buffers.3 +++ b/man/io_uring_register_buffers.3 @@ -40,9 +40,9 @@ belonging to the =20 The .BR io_uring_register_buffers_tags (3) -function behaves the same as=20 +function behaves the same as .BR io_uring_register_buffers (3) -function but additionally takes=20 +function but additionally takes .I tags parameter. See .B IORING_REGISTER_BUFFERS2 @@ -69,8 +69,8 @@ manipulating the page reference counts for each IO. =20 The .BR io_uring_register_buffers_update_tag (3) -function updates registered buffers with new ones, either turning a sparse=20 -entry into a real one, or replacing an existing entry. The=20 +function updates registered buffers with new ones, either turning a sparse +entry into a real one, or replacing an existing entry. The .I off is offset on which to start the update .I nr @@ -90,7 +90,7 @@ On success .BR io_uring_register_buffers_tags (3) and .BR io_uring_register_buffers_sparse (3) -return 0.=20 +return 0. .BR io_uring_register_buffers_update_tag (3) return number of buffers updated. On failure they return diff --git a/man/io_uring_register_files.3 b/man/io_uring_register_files.3 index 10ea665448b1694c..a4b00abf021edd09 100644 --- a/man/io_uring_register_files.3 +++ b/man/io_uring_register_files.3 @@ -46,9 +46,9 @@ for subsequent operations. =20 The .BR io_uring_register_files_tags (3) -function behaves the same as=20 +function behaves the same as .BR io_uring_register_files (3) -function but additionally takes=20 +function but additionally takes .I tags parameter. See .B IORING_REGISTER_BUFFERS2 @@ -72,9 +72,9 @@ shared, for example if the process has ever created any t= hreads, then this cost goes up even more. Using registered files reduces the overhead of file reference management across requests that operate on a file. =20 -The=20 -.BR io_uring_register_files_update (3)=20 -function updates existing registered files. The=20 +The +.BR io_uring_register_files_update (3) +function updates existing registered files. The .I off is offset on which to start the update .I nr_files @@ -83,13 +83,13 @@ number of files defined by the array belonging to the .IR ring . =20 -The=20 +The .BR io_uring_register_files_update_tag (3) -function behaves the same as=20 -.BR io_uring_register_files_update (3)=20 -function but additionally takes=20 +function behaves the same as +.BR io_uring_register_files_update (3) +function but additionally takes .I tags -parameter. See=20 +parameter. See .B IORING_REGISTER_BUFFERS2 for the resource tagging description. =20 @@ -99,7 +99,7 @@ On success .BR io_uring_register_files_tags (3) and .BR io_uring_register_files_sparse (3) -return 0.=20 +return 0. .BR io_uring_register_files_update (3) and .BR io_uring_register_files_update_tag (3) --=20 Ammar Faizi