-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Christian Borntraeger
authored and
Rusty Russell
committed
Jul 25, 2008
1 parent
ba6c542
commit cb312fb
Showing
9 changed files
with
106 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
--- | ||
refs/heads/master: 066f4d82a67f621ddd547bfa4b9c94631d8457b0 | ||
refs/heads/master: 611e097d7707741a336a0677d9d69bec40f29f3d |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
/* | ||
* Copyright IBM Corp. 2001,2008 | ||
* | ||
* This file contains the IRQ specific code for hvc_console | ||
* | ||
*/ | ||
|
||
#include <linux/interrupt.h> | ||
|
||
#include "hvc_console.h" | ||
|
||
static irqreturn_t hvc_handle_interrupt(int irq, void *dev_instance) | ||
{ | ||
/* if hvc_poll request a repoll, then kick the hvcd thread */ | ||
if (hvc_poll(dev_instance)) | ||
hvc_kick(); | ||
return IRQ_HANDLED; | ||
} | ||
|
||
/* | ||
* For IRQ based systems these callbacks can be used | ||
*/ | ||
int notifier_add_irq(struct hvc_struct *hp, int irq) | ||
{ | ||
int rc; | ||
|
||
if (!irq) { | ||
hp->irq_requested = 0; | ||
return 0; | ||
} | ||
rc = request_irq(irq, hvc_handle_interrupt, IRQF_DISABLED, | ||
"hvc_console", hp); | ||
if (!rc) | ||
hp->irq_requested = 1; | ||
return rc; | ||
} | ||
|
||
void notifier_del_irq(struct hvc_struct *hp, int irq) | ||
{ | ||
if (!irq) | ||
return; | ||
free_irq(irq, hp); | ||
hp->irq_requested = 0; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters