All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next] net: phy: mscc: add constants for used interrupt mask bits
@ 2020-03-01 20:57 Heiner Kallweit
  2020-03-01 21:40 ` Andrew Lunn
  2020-03-02  3:06 ` David Miller
  0 siblings, 2 replies; 3+ messages in thread
From: Heiner Kallweit @ 2020-03-01 20:57 UTC (permalink / raw)
  To: Florian Fainelli, Andrew Lunn, Russell King - ARM Linux, David Miller
  Cc: netdev

Add constants for the used interrupts bits. This avoids the magic
number for MII_VSC85XX_INT_MASK_MASK.

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
---
 drivers/net/phy/mscc.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/drivers/net/phy/mscc.c b/drivers/net/phy/mscc.c
index 8b1535c4d..32b551cbb 100644
--- a/drivers/net/phy/mscc.c
+++ b/drivers/net/phy/mscc.c
@@ -80,10 +80,16 @@ enum rgmii_rx_clock_delay {
 #define MSCC_PHY_EXT_PHY_CNTL_2		  24
 
 #define MII_VSC85XX_INT_MASK		  25
-#define MII_VSC85XX_INT_MASK_MASK	  0xa020
-#define MII_VSC85XX_INT_MASK_WOL	  0x0040
+#define MII_VSC85XX_INT_MASK_MDINT	  BIT(15)
+#define MII_VSC85XX_INT_MASK_LINK_CHG	  BIT(13)
+#define MII_VSC85XX_INT_MASK_WOL	  BIT(6)
+#define MII_VSC85XX_INT_MASK_EXT	  BIT(5)
 #define MII_VSC85XX_INT_STATUS		  26
 
+#define MII_VSC85XX_INT_MASK_MASK	  (MII_VSC85XX_INT_MASK_MDINT    | \
+					   MII_VSC85XX_INT_MASK_LINK_CHG | \
+					   MII_VSC85XX_INT_MASK_EXT)
+
 #define MSCC_PHY_WOL_MAC_CONTROL          27
 #define EDGE_RATE_CNTL_POS                5
 #define EDGE_RATE_CNTL_MASK               0x00E0
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH net-next] net: phy: mscc: add constants for used interrupt mask bits
  2020-03-01 20:57 [PATCH net-next] net: phy: mscc: add constants for used interrupt mask bits Heiner Kallweit
@ 2020-03-01 21:40 ` Andrew Lunn
  2020-03-02  3:06 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: Andrew Lunn @ 2020-03-01 21:40 UTC (permalink / raw)
  To: Heiner Kallweit
  Cc: Florian Fainelli, Russell King - ARM Linux, David Miller, netdev

On Sun, Mar 01, 2020 at 09:57:08PM +0100, Heiner Kallweit wrote:
> Add constants for the used interrupts bits. This avoids the magic
> number for MII_VSC85XX_INT_MASK_MASK.
> 
> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>

Reviewed-by: Andrew Lunn <andrew@lunn.ch>

    Andrew

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH net-next] net: phy: mscc: add constants for used interrupt mask bits
  2020-03-01 20:57 [PATCH net-next] net: phy: mscc: add constants for used interrupt mask bits Heiner Kallweit
  2020-03-01 21:40 ` Andrew Lunn
@ 2020-03-02  3:06 ` David Miller
  1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2020-03-02  3:06 UTC (permalink / raw)
  To: hkallweit1; +Cc: f.fainelli, andrew, linux, netdev

From: Heiner Kallweit <hkallweit1@gmail.com>
Date: Sun, 1 Mar 2020 21:57:08 +0100

> Add constants for the used interrupts bits. This avoids the magic
> number for MII_VSC85XX_INT_MASK_MASK.
> 
> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>

Applied to net-next.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-03-02  3:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-01 20:57 [PATCH net-next] net: phy: mscc: add constants for used interrupt mask bits Heiner Kallweit
2020-03-01 21:40 ` Andrew Lunn
2020-03-02  3:06 ` David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.