Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 232117
b: refs/heads/master
c: 9b141fa
h: refs/heads/master
i:
  232115: 81a7b98
v: v3
  • Loading branch information
Thomas Gleixner committed Jan 21, 2011
1 parent 3c93497 commit 9b0305c
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 27 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 1899a493b991cf9ea7a57d15b64588632fe32cf0
refs/heads/master: 9b141fa649b160c6a0854a79fe2cd741c5c99e80
42 changes: 16 additions & 26 deletions trunk/arch/m32r/platforms/opsput/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -227,42 +227,32 @@ static void enable_opsput_lcdpld_irq(unsigned int irq)
outw(data, port);
}

static void mask_and_ack_opsput_lcdpld(unsigned int irq)
static void mask_opsput_lcdpld(struct irq_data *data)
{
disable_opsput_lcdpld_irq(irq);
disable_opsput_lcdpld_irq(data->irq);
}

static void end_opsput_lcdpld_irq(unsigned int irq)
static void unmask_opsput_lcdpld(struct irq_data *data)
{
enable_opsput_lcdpld_irq(irq);
enable_opsput_lcdpld_irq(data->irq);
enable_opsput_irq(M32R_IRQ_INT2);
}

static unsigned int startup_opsput_lcdpld_irq(unsigned int irq)
{
enable_opsput_lcdpld_irq(irq);
return (0);
}

static void shutdown_opsput_lcdpld_irq(unsigned int irq)
static void shutdown_opsput_lcdpld(struct irq_data *data)
{
unsigned long port;
unsigned int pldirq;

pldirq = irq2lcdpldirq(irq);
pldirq = irq2lcdpldirq(data->irq);
port = lcdpldirq2port(pldirq);
outw(PLD_ICUCR_ILEVEL7, port);
}

static struct irq_chip opsput_lcdpld_irq_type =
{
"OPSPUT-PLD-LCD-IRQ",
startup_opsput_lcdpld_irq,
shutdown_opsput_lcdpld_irq,
enable_opsput_lcdpld_irq,
disable_opsput_lcdpld_irq,
mask_and_ack_opsput_lcdpld,
end_opsput_lcdpld_irq
static struct irq_chip opsput_lcdpld_irq_type = {
.name = "OPSPUT-PLD-LCD-IRQ",
.irq_shutdown = shutdown_opsput_lcdpld,
.irq_mask = mask_opsput_lcdpld,
.irq_unmask = unmask_opsput_lcdpld,
};

void __init init_IRQ(void)
Expand Down Expand Up @@ -358,11 +348,11 @@ void __init init_IRQ(void)
enable_opsput_irq(M32R_IRQ_INT1);

#if defined(CONFIG_USB)
outw(USBCR_OTGS, USBCR); /* USBCR: non-OTG */

set_irq_chip(OPSPUT_LCD_IRQ_USB_INT1, &opsput_lcdpld_irq_type);
lcdpld_icu_data[irq2lcdpldirq(OPSPUT_LCD_IRQ_USB_INT1)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD01; /* "L" level sense */
disable_opsput_lcdpld_irq(OPSPUT_LCD_IRQ_USB_INT1);
outw(USBCR_OTGS, USBCR); /* USBCR: non-OTG */
set_irq_chip_and_handler(OPSPUT_LCD_IRQ_USB_INT1,
&opsput_lcdpld_irq_type, handle_level_irq);
lcdpld_icu_data[irq2lcdpldirq(OPSPUT_LCD_IRQ_USB_INT1)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD01; /* "L" level sense */
disable_opsput_lcdpld_irq(OPSPUT_LCD_IRQ_USB_INT1);
#endif
/*
* INT2# is used for BAT, USB, AUDIO
Expand Down

0 comments on commit 9b0305c

Please sign in to comment.