Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754884AbbHJQOw (ORCPT ); Mon, 10 Aug 2015 12:14:52 -0400 Received: from mail-pa0-f46.google.com ([209.85.220.46]:34523 "EHLO mail-pa0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753366AbbHJQOr convert rfc822-to-8bit (ORCPT ); Mon, 10 Aug 2015 12:14:47 -0400 From: yalin wang Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8BIT Subject: [PATCH] net/fddi:change HWM_REVERSE() macro Message-Id: <6AE77A24-5AC5-47E4-8B9F-9BCDE0C6A8F9@gmail.com> Date: Tue, 11 Aug 2015 00:14:06 +0800 To: netdev@vger.kernel.org, open list Mime-Version: 1.0 (Mac OS X Mail 8.2 \(2098\)) X-Mailer: Apple Mail (2.2098) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1132 Lines: 46 change HWM_REVERSE() macro to generic le32_to_cpu() Signed-off-by: yalin wang --- drivers/net/fddi/skfp/h/hwmtm.h | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/drivers/net/fddi/skfp/h/hwmtm.h b/drivers/net/fddi/skfp/h/hwmtm.h index 5924d42..72701ef 100644 --- a/drivers/net/fddi/skfp/h/hwmtm.h +++ b/drivers/net/fddi/skfp/h/hwmtm.h @@ -14,7 +14,7 @@ #ifndef _HWM_ #define _HWM_ - +#include #include "mbuf.h" /* @@ -74,14 +74,7 @@ #define NULL 0 #endif -#ifdef LITTLE_ENDIAN -#define HWM_REVERSE(x) (x) -#else -#define HWM_REVERSE(x) ((((x)<<24L)&0xff000000L) + \ - (((x)<< 8L)&0x00ff0000L) + \ - (((x)>> 8L)&0x0000ff00L) + \ - (((x)>>24L)&0x000000ffL)) -#endif +#define HWM_REVERSE(x) le32_to_cpu(x) #define C_INDIC (1L<<25) #define A_INDIC (1L<<26) -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/