Skip to content

Commit 331a145

Browse files
geertuYuryNorov
authored andcommitted
EDAC/ie31200: Convert to common field_get() helper
Drop the driver-specific field_get() macro, in favor of the globally available variant from <linux/bitfield.h>. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Qiuxu Zhuo <qiuxu.zhuo@intel.com> Signed-off-by: Yury Norov (NVIDIA) <yury.norov@gmail.com>
1 parent 350f06c commit 331a145

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

drivers/edac/ie31200_edac.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
* but lo_hi_readq() ensures that we are safe across all e3-1200 processors.
4545
*/
4646

47+
#include <linux/bitfield.h>
4748
#include <linux/module.h>
4849
#include <linux/init.h>
4950
#include <linux/pci.h>
@@ -139,10 +140,6 @@
139140
#define IE31200_CAPID0_DDPCD BIT(6)
140141
#define IE31200_CAPID0_ECC BIT(1)
141142

142-
/* Non-constant mask variant of FIELD_GET() */
143-
#undef field_get
144-
#define field_get(_mask, _reg) (((_reg) & (_mask)) >> (ffs(_mask) - 1))
145-
146143
static int nr_channels;
147144
static struct pci_dev *mci_pdev;
148145
static int ie31200_registered = 1;

0 commit comments

Comments
 (0)