DPDK patches and discussions
 help / color / mirror / Atom feed
From: Jiawen Wu <jiawenwu@trustnetic.com>
To: dev@dpdk.org
Cc: Jiawen Wu <jiawenwu@trustnetic.com>
Subject: [dpdk-dev] [PATCH] net/txgbe: remove direct use of compiler attribute
Date: Mon,  9 Nov 2020 15:43:46 +0800
Message-ID: <20201109074346.3896752-1-jiawenwu@trustnetic.com> (raw)

Remove direct use of compiler attribute.

Signed-off-by: Jiawen Wu <jiawenwu@trustnetic.com>
 drivers/net/txgbe/base/txgbe_dummy.h | 2 +-
 drivers/net/txgbe/base/txgbe_osdep.h | 6 ++----
 2 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/drivers/net/txgbe/base/txgbe_dummy.h b/drivers/net/txgbe/base/txgbe_dummy.h
index 0a3a76d0c..3a667dd31 100644
--- a/drivers/net/txgbe/base/txgbe_dummy.h
+++ b/drivers/net/txgbe/base/txgbe_dummy.h
@@ -7,7 +7,7 @@
 #ifdef TUP
 #elif defined(__GNUC__)
-#define TUP(x) x##_unused __attribute__((unused))
+#define TUP(x) (x##_unused txgbe_unused)
 #elif defined(__LCLINT__)
 #define TUP(x) x /*@unused@*/
diff --git a/drivers/net/txgbe/base/txgbe_osdep.h b/drivers/net/txgbe/base/txgbe_osdep.h
index f3d443ad3..c5386381c 100644
--- a/drivers/net/txgbe/base/txgbe_osdep.h
+++ b/drivers/net/txgbe/base/txgbe_osdep.h
@@ -30,6 +30,8 @@
 		rte_panic("TXGBE: x");	\
 } while (0)
+#define txgbe_unused __rte_unused
 #define usec_delay(x) rte_delay_us(x)
 #define msec_delay(x) rte_delay_ms(x)
 #define usleep(x)     rte_delay_us(x)
@@ -148,10 +150,6 @@ static inline u64 REVERT_BIT_MASK64(u64 mask)
 	       ((mask & 0xFFFFFFFF00000000) >> 32);
-#ifndef __rte_weak
-#define __rte_weak __attribute__((__weak__))
 #define IOMEM
 #define prefetch(x) rte_prefetch0(x)

             reply	other threads:[~2020-11-09  7:42 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-09  7:43 Jiawen Wu [this message]
2020-11-09 19:18 ` Ferruh Yigit
2020-11-10  2:09   ` Jiawen Wu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201109074346.3896752-1-jiawenwu@trustnetic.com \
    --to=jiawenwu@trustnetic.com \
    --cc=dev@dpdk.org \


* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

DPDK patches and discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://inbox.dpdk.org/dev/0 dev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dev dev/ https://inbox.dpdk.org/dev \
	public-inbox-index dev

Example config snippet for mirrors.
Newsgroup available over NNTP:

AGPL code for this site: git clone https://public-inbox.org/public-inbox.git