From patchwork Thu Dec 19 00:35:57 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joseph Myers X-Patchwork-Id: 103398 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id A5E373858D39 for ; Thu, 19 Dec 2024 00:37:31 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A5E373858D39 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=fF3wIP7D X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTP id B8FBF3858D20 for ; Thu, 19 Dec 2024 00:36:46 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org B8FBF3858D20 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org B8FBF3858D20 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1734568606; cv=none; b=FRJ49bfswddNoUi9dnMoNmkaretykarz5ud+9PP0mrJOGUUC3w9e8BS23ZVENMajtQE8SyXm7I0/off8PPxjc3sATCMMuyllaCXglIH6S9YfeLhqroxt+2VCgD2Rxn0bLHnN126DtVdX2hh9UwRkEROt+XuUXC1wR+1t8eGJ2zw= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1734568606; c=relaxed/simple; bh=cF3z2CsDibACrU60wmyh22JP0opx4mOX/muIDhkHwIY=; h=DKIM-Signature:Date:From:To:Subject:Message-ID:MIME-Version; b=l2Ij3Pq44uKOCBhZU0CMphJRva78BAOP89PzuR5tLqbOaPyT3eb+nZIlBqg9vFp1nQ9kHLsFhN16ePemUi7ManYhfGhW4OV15VGGc4+Tr62mYnYD7oABYn/fFftnLslTpZCSrvmX7kolF0+ZEMC4U73FdxlU+719MokuOwJg0HI= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B8FBF3858D20 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1734568606; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type; bh=Dakk+isdQZ/cgMdA0sNvpLaXrO7co/8oaFECvj0N554=; b=fF3wIP7DUTNpD4XXIwR4NWz208lrNMF5cPNVdqG0kvqFIfz9jbM8Qt9DGvqMY7Sy+Mdw0Z R/vvuMcrB2UwB1IGdY1yZU/Mvlyq8IKikHwXlF3jRLBUG9S/4hsUguEfP8Aa7UEokQ0RkK 16+qHn9d5VBw+bgqJm/5BlL8SLwTZQY= Received: from mail-wm1-f69.google.com (mail-wm1-f69.google.com [209.85.128.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-620-bBzdolV9Phy1BqMoq937Zg-1; Wed, 18 Dec 2024 19:36:45 -0500 X-MC-Unique: bBzdolV9Phy1BqMoq937Zg-1 X-Mimecast-MFC-AGG-ID: bBzdolV9Phy1BqMoq937Zg Received: by mail-wm1-f69.google.com with SMTP id 5b1f17b1804b1-4359206e1e4so1572565e9.2 for ; Wed, 18 Dec 2024 16:36:45 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734568604; x=1735173404; h=mime-version:message-id:subject:to:from:date:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=Dakk+isdQZ/cgMdA0sNvpLaXrO7co/8oaFECvj0N554=; b=EDxBmqBFX8LIhdu1Suc5HvKa2wuA1DybDMDOrDpKKQmh9DPjxu3wPPsjR2NyKJs85f PNtufVUGgGd/MutCynK8y016P9ZN2AnDz1ERSzMeyyHYxDsnvKz09TC6F0BZuH+C1h98 G2XwASjfqCMG6pd8DB7MVlpm34Sibp91E0c3sJR6C+JB6HTP5Zjm+huf9if9kRzPVOzQ oukZdNgA8wiWadvoVHwFwPY5WtbIHvznyP4UHTIX2XnSVITzj6UzvYfe1EiWDMKW7Dcw A/BlR27JUM5rcaSG3NIagW2+YPu1f7TiIL2aO8BRetde6yy3sVmomRcm05cQFAaAHsOn iReQ== X-Gm-Message-State: AOJu0YzhnUDy9EqQSUo98C5BsrfpcVsVmllHnUKMKBzqchb9Y25gFgkC ao6oS0LUfe/s7nonUBjDrhqUrJN7WQ/gXm1g8f1KbH+G5pnB7IZV3HSN0doZF0bXlNOBNuWiAlt 5OiFpOGItlRmz+XSH2/B4ZhUxGBSLTd19DjpFI4j0CjLzLLnpEODN3fwRgKVvqHtfbJEAyK3x1n /+8FZaXql+gSgOxkRSPMeig2MLewS+n2k1TopVIrWHIw== X-Gm-Gg: ASbGncuAiqaCdK1eGLDqM9lVvGhmVVReGzBoDfwGuaLhkcHr0SoukG7PO1E2boyPe2O L0rI+TOcdHISVqVHbYBOmOxUw2NGOW569mlR7ddEBTZ0L8T2HzbMOqAhY9buk+zldkxWvaZ1MkR KuCDhEaUYfNttpnPILnR7oTIWbBd+F+NduX1Tqn8Q2VBCvL5lKrScbQsbIpF0YzoGWponjWTQhq NT4M8uBJ4uVl48iyQpFTsjnhoyOtpb1Ws48RkxdAuH72ddNx1XwDPM6+iCdh5AnZK16Tja3dQ00 y54f0nGDvNAo X-Received: by 2002:a5d:598f:0:b0:382:40ad:44b2 with SMTP id ffacd0b85a97d-38a19b14631mr1327044f8f.34.1734568603916; Wed, 18 Dec 2024 16:36:43 -0800 (PST) X-Google-Smtp-Source: AGHT+IGtn98YU7WzkU6GLunA4+TcFasvt2hIAKyEFXPptS9QsHz92lMUozt0SidJEjzB3no8ws2nnQ== X-Received: by 2002:a5d:598f:0:b0:382:40ad:44b2 with SMTP id ffacd0b85a97d-38a19b14631mr1327032f8f.34.1734568603451; Wed, 18 Dec 2024 16:36:43 -0800 (PST) Received: from digraph.polyomino.org.uk (digraph.polyomino.org.uk. [2001:8b0:bf73:93f7::51bb:e332]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-38a1c8475cesm178930f8f.57.2024.12.18.16.36.42 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Dec 2024 16:36:43 -0800 (PST) Received: from jsm28 (helo=localhost) by digraph.polyomino.org.uk with local-esmtp (Exim 4.97) (envelope-from ) id 1tO4WD-00000000rhe-2PuF for libc-alpha@sourceware.org; Thu, 19 Dec 2024 00:35:57 +0000 Date: Thu, 19 Dec 2024 00:35:57 +0000 (UTC) From: Joseph Myers To: libc-alpha@sourceware.org Subject: Add MSG_SOCK_DEVMEM from Linux 6.12 to bits/socket.h Message-ID: <322320a9-4543-1be6-e300-ee605711edbb@redhat.com> MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: 1NtiAPsyY6fdT8x-VoK2qxTd6I1FscC1jx2wHU_AteI_1734568604 X-Mimecast-Originator: redhat.com X-Spam-Status: No, score=-9.7 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces~patchwork=sourceware.org@sourceware.org Linux 6.12 adds a constant MSG_SOCK_DEVMEM (recall that various constants such as this one are defined in the non-uapi linux/socket.h but still form part of the kernel/userspace interface, so that non-uapi header is one that needs checking each release for new such constants). Add it to glibc's bits/socket.h. Tested for x86_64. Reviewed-by: Florian Weimer diff --git a/sysdeps/unix/sysv/linux/bits/socket.h b/sysdeps/unix/sysv/linux/bits/socket.h index 5ab19a8c08..ca27a3c597 100644 --- a/sysdeps/unix/sysv/linux/bits/socket.h +++ b/sysdeps/unix/sysv/linux/bits/socket.h @@ -246,6 +246,8 @@ enum #define MSG_WAITFORONE MSG_WAITFORONE MSG_BATCH = 0x40000, /* sendmmsg: more messages coming. */ #define MSG_BATCH MSG_BATCH + MSG_SOCK_DEVMEM = 0x2000000, /* Receive devmem skbs as cmsg. */ +#define MSG_SOCK_DEVMEM MSG_SOCK_DEVMEM MSG_ZEROCOPY = 0x4000000, /* Use user data in kernel path. */ #define MSG_ZEROCOPY MSG_ZEROCOPY MSG_FASTOPEN = 0x20000000, /* Send data in TCP SYN. */