From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 681AF460C6; Tue, 21 Jan 2025 01:21:17 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 04F6340275; Tue, 21 Jan 2025 01:21:17 +0100 (CET) Received: from mail-pl1-f181.google.com (mail-pl1-f181.google.com [209.85.214.181]) by mails.dpdk.org (Postfix) with ESMTP id 461274026B for ; Tue, 21 Jan 2025 01:21:15 +0100 (CET) Received: by mail-pl1-f181.google.com with SMTP id d9443c01a7336-21631789fcdso72908555ad.1 for ; Mon, 20 Jan 2025 16:21:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1737418874; x=1738023674; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=fFMwHSAnVhu0a5iMpYpUJ3WdmAPKZOaTNXFY9x9VBD8=; b=T93vQSsyWHZDwD8VEdPrk7aTmraG6wEaM/6RlBaqzqcKcfxfOlOhStsmMkPwfJyI1Q s2Zc0S4NcySoOMX43JSth1Z6eWSAK/ys1GxIaFgzK0llvs433ks+ID6q4q7Inw4RCYeU k0BrxE79PClRocH7wIgBN+TzKQoDb1YPl6j87AygVVl0yUrfCte8F5YfStWZEDcJtSxJ 9/JbMQTn/AP/Z8u3wunP1i7bWQhX2WoODEtB1Bgy7oQCpmKK1Z/KeHykaha1aOF5Vuk+ BSHvO64FJD1z0p6v/5G84Xw9bhfMsfrcXh7bvN8eUNa7UvI6mrbQ+kP1zbvwa8KkB/Df Dgew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1737418874; x=1738023674; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=fFMwHSAnVhu0a5iMpYpUJ3WdmAPKZOaTNXFY9x9VBD8=; b=P0kiEeRqLsKnfuOPMPJ6jmyZJ0jklvoJ8UNkrBRCuoaCcU4zjRqKJdtVkuD6Ati62H 89p1SOhMWYf4Q432lY1HOYSVoOeuFjcKQshhpv+P/woUlnRyyRVunW2cN+SIO3fPFP/m YuzgeVGasuyX98sW4tnuvFgt6ybO67K19ucZB7GN4oWY0Hq2SdvVxPGGVqPF2iUpbi01 5UYbGsQv3IwH1ki8fknbJZn1TqjQvjCEH27CelH8kWqCs/Z26P2WjC/z96xK/iCatoWI SSd5z7U0TthLHe/kD+es4E9xLPXfprfJPwPBj4lmud8Y3v2uCDDA+LRjjhY59zyMMzUC nUUw== X-Gm-Message-State: AOJu0YwcEa1//IqVyUNLHp+0tkr8PPJ1zx//WLbRu6WlSe3frI0MNa3p HgzndFMRHe4a8vimc1mHzAckoa1BK8Y+jMIlc28NAFznB1RoiAmEHrAJrCJTu3M= X-Gm-Gg: ASbGncvGOVZxMR3hGnqMRCFXffrg/Th0fFX+UriJKVMaDWggN6nh7x+vJVvokOLO9bU hh8TtFH6sYNWcexK2fUuVN29UVwQo+yrsHPdejiIDCKpbycA+OEnw5MmBwafWa4mzwCoBX5gA7l QSZ6hBqoMeEDu5YgZXnR6sGPe6EPCWq3nIwlq8JH35bCqzQtou9iYRpg3b4rtmzSASs0p1nQp9Z Pnb+T7BvBYs2EQXdTWjV0xjnMR9tUFi0pxgsclAIGKTLlSNlMzP0Ld/JfPOQ3GKGMXU9XBRwD5Y DTyNV3BPpMaObZKLNMir9P+uKO3GSbGUPks8KacVSOBkVY0= X-Google-Smtp-Source: AGHT+IHhjAX2BNqt1DwEFGxWb9iWAIbRMARn/xl/DMXq7mNbIZahRNDxOiPzJvPd5QqUrAReRqWbhA== X-Received: by 2002:a05:6a20:12c6:b0:1e1:adb8:c011 with SMTP id adf61e73a8af0-1eb2174d3f3mr23029917637.18.1737418874287; Mon, 20 Jan 2025 16:21:14 -0800 (PST) Received: from hermes.local (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-72dab8458e0sm7589169b3a.74.2025.01.20.16.21.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 Jan 2025 16:21:14 -0800 (PST) Date: Mon, 20 Jan 2025 16:21:11 -0800 From: Stephen Hemminger To: Junlong Wang Cc: dev@dpdk.org Subject: Re: [PATCH v8 14/15] net/zxdh: basic stats ops implementations Message-ID: <20250120162111.63c6c543@hermes.local> In-Reply-To: <20250120034723.2980928-15-wang.junlong1@zte.com.cn> References: <20241210055333.782901-2-wang.junlong1@zte.com.cn> <20250120034723.2980928-1-wang.junlong1@zte.com.cn> <20250120034723.2980928-15-wang.junlong1@zte.com.cn> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Mon, 20 Jan 2025 11:47:22 +0800 Junlong Wang wrote: > > +struct __rte_packed_begin zxdh_hw_mac_stats { > + uint64_t rx_total; > + uint64_t rx_pause; > + uint64_t rx_unicast; > + uint64_t rx_multicast; > + uint64_t rx_broadcast; > + uint64_t rx_vlan; > + uint64_t rx_size_64; > + uint64_t rx_size_65_127; > + uint64_t rx_size_128_255; > + uint64_t rx_size_256_511; > + uint64_t rx_size_512_1023; > + uint64_t rx_size_1024_1518; > + uint64_t rx_size_1519_mru; > + uint64_t rx_undersize; > + uint64_t rx_oversize; > + uint64_t rx_fragment; > + uint64_t rx_jabber; > + uint64_t rx_control; > + uint64_t rx_eee; > + > + uint64_t tx_total; > + uint64_t tx_pause; > + uint64_t tx_unicast; > + uint64_t tx_multicast; > + uint64_t tx_broadcast; > + uint64_t tx_vlan; > + uint64_t tx_size_64; > + uint64_t tx_size_65_127; > + uint64_t tx_size_128_255; > + uint64_t tx_size_256_511; > + uint64_t tx_size_512_1023; > + uint64_t tx_size_1024_1518; > + uint64_t tx_size_1519_mtu; > + uint64_t tx_undersize; > + uint64_t tx_oversize; > + uint64_t tx_fragment; > + uint64_t tx_jabber; > + uint64_t tx_control; > + uint64_t tx_eee; > + > + uint64_t rx_error; > + uint64_t rx_fcs_error; > + uint64_t rx_drop; > + > + uint64_t tx_error; > + uint64_t tx_fcs_error; > + uint64_t tx_drop; > + > +} __rte_packed_end; > + > +struct __rte_packed_begin zxdh_hw_mac_bytes { > + uint64_t rx_total_bytes; > + uint64_t rx_good_bytes; > + uint64_t tx_total_bytes; > + uint64_t tx_good_bytes; > +} __rte_packed_end; > + Why do you need to mark these structures as packed? They contain only 64 bit counters, there is no packing needed.