Received: by 2002:ac0:950c:0:0:0:0:0 with SMTP id f12csp3559039imc; Wed, 13 Mar 2019 23:16:19 -0700 (PDT) X-Google-Smtp-Source: APXvYqymNNXWD+hMk7yfEw0tcMNHdfxuB9fbFgArfK93nW2Hu7DUDznfFeLl5u0V+TJWE8iLxRRq X-Received: by 2002:a63:f806:: with SMTP id n6mr43406930pgh.19.1552544178933; Wed, 13 Mar 2019 23:16:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1552544178; cv=none; d=google.com; s=arc-20160816; b=Gnnlx21Oav8H/SqfUcQikFSCvMam1i3LznT1BrNw5nFhox6MIPBwYlcsqL/L1TUoHA HPWtVOO5ROIis6vZ7UubaQGGejGNHGDgRLVwlko3Zh/wSIRJ+6SFljknhGUY2QHh7o3v ANvvtsUNEyK2hpMDoX2IUGQXrsrdk/bSBb7lerLl5aJCNLqOhlWVaxFjHuPuiLa+6f6w ohjlBdIKM6XebLXgwVh0VYG3HL7e3KnLKFcsgi6XzYxMAfoNf/Z4Vk0J9U9d2j8pZeM9 sMP3pf2ZYA9Jx+BzmNAo8Hp6kHMl/+np359ZzsAGTuUT0Vrf3fKvqMQh35uOJdIi0l8Q sW+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=q87LftWO5iBuJXaxM2/XOAFMoWPTRqR3XSEk65pBRv8=; b=tpPpN7qOmvXqvxv413+l4iV7TxtWcOhImW+vxD7hmUtLfocsbB5L8ejdRQMfShKnou aqja2CI0bQpqMBdMDXZQE7bG0uylZIafjM9m9pO6eZ98NcUMaRGnXu5Aj3XQoYbqVAGL NOw0P+Kcqy1pcfncyrkL9mK+Rl+g9UQ6WHWA9jRbrMrOYI3vLAQjuxB8CohBaZF8bzpR 09ZeXK5r8jTmyfaOJWso9TuC5F0Ll4g6u9RHEc42aasygR/kfY/H5DkKY/vPScfR/qlB OzVw4k4cgWORULHEnlIvQXG8LPBBpJnMx8WZvN2zjHSIzF071UIyegnAYpVh0Sql0UYR 5MNA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Av3AOM0k; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q189si12263687pgq.240.2019.03.13.23.16.03; Wed, 13 Mar 2019 23:16:18 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Av3AOM0k; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726980AbfCNGP2 (ORCPT + 99 others); Thu, 14 Mar 2019 02:15:28 -0400 Received: from mail-pf1-f196.google.com ([209.85.210.196]:36278 "EHLO mail-pf1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726527AbfCNGP2 (ORCPT ); Thu, 14 Mar 2019 02:15:28 -0400 Received: by mail-pf1-f196.google.com with SMTP id n22so3150457pfa.3; Wed, 13 Mar 2019 23:15:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=q87LftWO5iBuJXaxM2/XOAFMoWPTRqR3XSEk65pBRv8=; b=Av3AOM0kM7z41gbJ1u4uzSLlAN+B7ZVV+3SYwaAuw6F1PKTN5wr86Vi7FGYn1CfoTF KWAqiUTJysfSCBvn82caF3OCssa+zgMpY+kMxCgO0lfdMv1v56XS71rT67n/A5wlOH+S 6Pj6Y7rTONQTtCrT0jUSSYpU7uKI1FfkZ1jFFEoQQkQAgikxMPGcIZti4dCQ4eSfUa8F U1BYVJ9yW5iILc3mojeRx2wN/RY/VycJN4LOpv3wELmGDGPSqED56uTmDcdjoNkPDqUh BZS52mjtw1V0MQdKLdkkx8FfNsZNEUSA01uEWQX8NdO11VtJZoFyhD8lEVMraToODXHN a1Aw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=q87LftWO5iBuJXaxM2/XOAFMoWPTRqR3XSEk65pBRv8=; b=WefUEs2MYCGHgdEFDPvGjMJoIBjSaOwD6PP/SiI9yhZdonJ79ZwQh7ssGPs7YPfg4h wN+ns/V9n33OkXMIfAYbsuE1Vwlq6Hep5ARqhr6ljrqu2rxfgepDp48BClJfYoiPkG9D qFr4x+TNHQKr4QNA1DopUzpYqRUzUVhyO21jkQWkIplmBMgkGh9QZ2n6UQ5ycPMUNzTq 6HruagLHi07e6JrhZawTf9esAAS/G7YyvdHF2/s8aLsdbjK198jQ5z7uh66whxsgqTye HViDi3IroOlROWSRM6OvXwu4YN/xYtfDUX1uRJo2iAqgWcOfbeu//X/i4+um0NuLxdu0 UW3Q== X-Gm-Message-State: APjAAAWDupERO8ltHhzj7K2gz80v1t4r1dxJzU0B+YmoJgcwyb4tWuEj Z+bRnfuq4dyFPuWQHWAsa8A= X-Received: by 2002:a17:902:e85:: with SMTP id 5mr49965272plx.13.1552544126975; Wed, 13 Mar 2019 23:15:26 -0700 (PDT) Received: from localhost.localdomain ([175.223.23.218]) by smtp.gmail.com with ESMTPSA id k7sm17179498pgo.60.2019.03.13.23.15.23 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 13 Mar 2019 23:15:26 -0700 (PDT) From: Sergey Senozhatsky X-Google-Original-From: Sergey Senozhatsky To: Eric Dumazet Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Sergey Senozhatsky Subject: [PATCH] tcp: don't use __constant_cpu_to_be32 Date: Thu, 14 Mar 2019 15:15:14 +0900 Message-Id: <20190314061514.19586-1-sergey.senozhatsky@gmail.com> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org A trivial patch. cpu_to_be32() is capable enough to detect __builtin_constant_p() and to use an appropriate compile time ___constant_swahb32() function. So we can use cpu_to_be32() instead of __constant_cpu_to_be32(). Signed-off-by: Sergey Senozhatsky --- include/uapi/linux/tcp.h | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/include/uapi/linux/tcp.h b/include/uapi/linux/tcp.h index 8bb6cc5f3235..7d2330df9652 100644 --- a/include/uapi/linux/tcp.h +++ b/include/uapi/linux/tcp.h @@ -70,16 +70,16 @@ union tcp_word_hdr { #define tcp_flag_word(tp) ( ((union tcp_word_hdr *)(tp))->words [3]) enum { - TCP_FLAG_CWR = __constant_cpu_to_be32(0x00800000), - TCP_FLAG_ECE = __constant_cpu_to_be32(0x00400000), - TCP_FLAG_URG = __constant_cpu_to_be32(0x00200000), - TCP_FLAG_ACK = __constant_cpu_to_be32(0x00100000), - TCP_FLAG_PSH = __constant_cpu_to_be32(0x00080000), - TCP_FLAG_RST = __constant_cpu_to_be32(0x00040000), - TCP_FLAG_SYN = __constant_cpu_to_be32(0x00020000), - TCP_FLAG_FIN = __constant_cpu_to_be32(0x00010000), - TCP_RESERVED_BITS = __constant_cpu_to_be32(0x0F000000), - TCP_DATA_OFFSET = __constant_cpu_to_be32(0xF0000000) + TCP_FLAG_CWR = cpu_to_be32(0x00800000), + TCP_FLAG_ECE = cpu_to_be32(0x00400000), + TCP_FLAG_URG = cpu_to_be32(0x00200000), + TCP_FLAG_ACK = cpu_to_be32(0x00100000), + TCP_FLAG_PSH = cpu_to_be32(0x00080000), + TCP_FLAG_RST = cpu_to_be32(0x00040000), + TCP_FLAG_SYN = cpu_to_be32(0x00020000), + TCP_FLAG_FIN = cpu_to_be32(0x00010000), + TCP_RESERVED_BITS = cpu_to_be32(0x0F000000), + TCP_DATA_OFFSET = cpu_to_be32(0xF0000000) }; /* -- 2.21.0