All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] [MIPS] vr41xx: add MACINT controls
@ 2007-01-11 14:53 Yoichi Yuasa
  2007-01-11 16:51 ` Ralf Baechle
  0 siblings, 1 reply; 2+ messages in thread
From: Yoichi Yuasa @ 2007-01-11 14:53 UTC (permalink / raw)
  To: Ralf Baechle; +Cc: yoichi_yuasa, linux-mips

Hi Ralf,

This patch has added MACINT controls.
They are necessary for VR4133 ethernet driver.

Yoichi

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>

diff -pruN -X mips/Documentation/dontdiff mips-orig/arch/mips/vr41xx/common/icu.c mips/arch/mips/vr41xx/common/icu.c
--- mips-orig/arch/mips/vr41xx/common/icu.c	2007-01-11 22:49:53.309677500 +0900
+++ mips/arch/mips/vr41xx/common/icu.c	2007-01-11 23:25:24.954897000 +0900
@@ -3,7 +3,7 @@
  *
  *  Copyright (C) 2001-2002  MontaVista Software Inc.
  *    Author: Yoichi Yuasa <yyuasa@mvista.com or source@mvista.com>
- *  Copyright (C) 2003-2005  Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
+ *  Copyright (C) 2003-2006  Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
  *
  *  This program is free software; you can redistribute it and/or modify
  *  it under the terms of the GNU General Public License as published by
@@ -68,6 +68,7 @@ static unsigned char sysint2_assign[16] 
 #define MPIUINTREG	0x0e
 #define MAIUINTREG	0x10
 #define MKIUINTREG	0x12
+#define MMACINTREG	0x12
 #define MGIUINTLREG	0x14
 #define MDSIUINTREG	0x16
 #define NMIREG		0x18
@@ -241,6 +242,30 @@ void vr41xx_disable_kiuint(uint16_t mask
 
 EXPORT_SYMBOL(vr41xx_disable_kiuint);
 
+void vr41xx_enable_macint(uint16_t mask)
+{
+	struct irq_desc *desc = irq_desc + ETHERNET_IRQ;
+	unsigned long flags;
+
+	spin_lock_irqsave(&desc->lock, flags);
+	icu1_set(MMACINTREG, mask);
+	spin_unlock_irqrestore(&desc->lock, flags);
+}
+
+EXPORT_SYMBOL(vr41xx_enable_macint);
+
+void vr41xx_disable_macint(uint16_t mask)
+{
+	struct irq_desc *desc = irq_desc + ETHERNET_IRQ;
+	unsigned long flags;
+
+	spin_lock_irqsave(&desc->lock, flags);
+	icu1_clear(MMACINTREG, mask);
+	spin_unlock_irqrestore(&desc->lock, flags);
+}
+
+EXPORT_SYMBOL(vr41xx_disable_macint);
+
 void vr41xx_enable_dsiuint(uint16_t mask)
 {
 	struct irq_desc *desc = irq_desc + DSIU_IRQ;

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

* Re: [PATCH] [MIPS] vr41xx: add MACINT controls
  2007-01-11 14:53 [PATCH] [MIPS] vr41xx: add MACINT controls Yoichi Yuasa
@ 2007-01-11 16:51 ` Ralf Baechle
  0 siblings, 0 replies; 2+ messages in thread
From: Ralf Baechle @ 2007-01-11 16:51 UTC (permalink / raw)
  To: Yoichi Yuasa; +Cc: linux-mips

On Thu, Jan 11, 2007 at 11:53:18PM +0900, Yoichi Yuasa wrote:

> This patch has added MACINT controls.
> They are necessary for VR4133 ethernet driver.

Okay, queued.

  Ralf

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

end of thread, other threads:[~2007-01-11 16:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-01-11 14:53 [PATCH] [MIPS] vr41xx: add MACINT controls Yoichi Yuasa
2007-01-11 16:51 ` Ralf Baechle

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.